Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

rtc-m41t80: use nonseekable_open()

Use nonseekable_open() for this since seeking is not supported anyway.

Signed-off-by: Jan Blunck <jblunck@suse.de>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Paul Gortmaker <p_gortmaker@yahoo.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Jan Blunck and committed by
Linus Torvalds
09eeb1f5 b627dbce

+1 -5
+1 -5
drivers/rtc/rtc-m41t80.c
··· 595 595 static ssize_t wdt_write(struct file *file, const char __user *buf, 596 596 size_t count, loff_t *ppos) 597 597 { 598 - /* Can't seek (pwrite) on this device 599 - if (ppos != &file->f_pos) 600 - return -ESPIPE; 601 - */ 602 598 if (count) { 603 599 wdt_ping(); 604 600 return 1; ··· 703 707 */ 704 708 wdt_is_open = 1; 705 709 unlock_kernel(); 706 - return 0; 710 + return nonseekable_open(inode, file); 707 711 } 708 712 return -ENODEV; 709 713 }