projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid
[firefly-linux-kernel-4.4.55.git]
/
drivers
/
char
/
generic_nvram.c
diff --git
a/drivers/char/generic_nvram.c
b/drivers/char/generic_nvram.c
index 0e941b57482e7d1021d409320e9184148888412b..6c4f4b5a9dd3aebb80920b2cae781c4a858fccac 100644
(file)
--- a/
drivers/char/generic_nvram.c
+++ b/
drivers/char/generic_nvram.c
@@
-34,12
+34,16
@@
static ssize_t nvram_len;
static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
{
switch (origin) {
+ case 0:
+ break;
case 1:
offset += file->f_pos;
break;
case 2:
offset += nvram_len;
break;
+ default:
+ offset = -1;
}
if (offset < 0)
return -EINVAL;