projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d50ac46
)
zorro: Fix reading of proc/bus/zorro/* in small chunks
author
Geert Uytterhoeven
<geert@linux-m68k.org>
Wed, 9 Jun 2010 09:24:32 +0000
(11:24 +0200)
committer
Geert Uytterhoeven
<geert@linux-m68k.org>
Mon, 9 Aug 2010 19:14:08 +0000
(21:14 +0200)
proc_bus_zorro_read() didn't take into account the current file position,
hence it always read from the start of the ConfigDev.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
drivers/zorro/proc.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/zorro/proc.c
b/drivers/zorro/proc.c
index 4f4ea88fbb7124728479b10e2c965d46d449941e..cafc504542927751f25650ce2ea2639dcdbc8bef 100644
(file)
--- a/
drivers/zorro/proc.c
+++ b/
drivers/zorro/proc.c
@@
-68,7
+68,7
@@
proc_bus_zorro_read(struct file *file, char __user *buf, size_t nbytes, loff_t *
cd.cd_BoardAddr = (void *)zorro_resource_start(z);
cd.cd_BoardSize = zorro_resource_len(z);
- if (copy_to_user(buf,
&cd
, nbytes))
+ if (copy_to_user(buf,
(void *)&cd + pos
, nbytes))
return -EFAULT;
*ppos += nbytes;