Przeglądaj źródła

libfs: use generic_file_llseek for simple_attr

Simple attribute files need to be seekable to
allow resetting the file for another read.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Arnd Bergmann 14 lat temu
rodzic
commit
1ec5584e3e
1 zmienionych plików z 1 dodań i 0 usunięć
  1. 1 0
      include/linux/fs.h

+ 1 - 0
include/linux/fs.h

@@ -2450,6 +2450,7 @@ static const struct file_operations __fops = {				\
 	.release = simple_attr_release,					\
 	.read	 = simple_attr_read,					\
 	.write	 = simple_attr_write,					\
+	.llseek	 = generic_file_llseek,					\
 };
 
 static inline void __attribute__((format(printf, 1, 2)))