projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b1dd3b2
)
/dev/mem: allow rewinding
author
Eric Dumazet
<
[email protected]
>
Tue, 6 Apr 2010 21:35:01 +0000
(14:35 -0700)
committer
Linus Torvalds
<
[email protected]
>
Wed, 7 Apr 2010 15:38:04 +0000
(08:38 -0700)
commit
dcefafb6
("/dev/mem: dont allow seek to last page") inadvertently
disabled rewinding on /dev/mem.
This broke x86info for example.
Signed-off-by: Eric Dumazet <
[email protected]
>
Acked-by: Wu Fengguang <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
drivers/char/mem.c
patch
|
blob
|
history
diff --git
a/drivers/char/mem.c
b/drivers/char/mem.c
index 47c8452f485fa6bcc03683754bb1432e8a082e2a..9cdbadc6860814476ad147283dc2ba2675539509 100644
(file)
--- a/
drivers/char/mem.c
+++ b/
drivers/char/mem.c
@@
-710,11
+710,6
@@
static loff_t memory_lseek(struct file *file, loff_t offset, int orig)
switch (orig) {
case SEEK_CUR:
offset += file->f_pos;
- if ((unsigned long long)offset <
- (unsigned long long)file->f_pos) {
- ret = -EOVERFLOW;
- break;
- }
case SEEK_SET:
/* to avoid userland mistaking f_pos=-9 as -EBADF=-9 */
if ((unsigned long long)offset >= ~0xFFFULL) {