repo.or.cz
/
linux
/
fpc-iii.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
mtd: nand: omap: Fix comment in platform data using wrong Kconfig symbol
[linux/fpc-iii.git]
/
arch
/
h8300
/
lib
/
strncpy.S
blob
8b65d7c4727b280ee30b406a1091642683369f04
1
;;; SPDX-License-Identifier: GPL-2.0
2
;;; strncpy.S
3
4
#include <asm/linkage.h>
5
6
.text
7
.global strncpy_from_user
8
9
;;; long strncpy_from_user(void *to, void *from, size_t n)
10
strncpy_from_user:
11
mov.l er2,er2
12
bne 1f
13
sub.l er0,er0
14
rts
15
1:
16
mov.l er4,@-sp
17
sub.l er3,er3
18
2:
19
mov.b @er1+,r4l
20
mov.b r4l,@er0
21
adds #1,er0
22
beq 3f
23
inc.l #1,er3
24
dec.l #1,er2
25
bne 2b
26
3:
27
dec.l #1,er2
28
4:
29
mov.b r4l,@er0
30
adds #1,er0
31
dec.l #1,er2
32
bne 4b
33
mov.l er3,er0
34
mov.l @sp+,er4
35
rts