indydog_alive = 1;
printk(KERN_INFO "Started watchdog timer.\n");
- return nonseekable_open(inode, file);
+ return 0;
}
static int indydog_release(struct inode *inode, struct file *file)
static ssize_t indydog_write(struct file *file, const char *data, size_t len, loff_t *ppos)
{
+ /* Can't seek (pwrite) on this device */
+ if (ppos != &file->f_pos)
+ return -ESPIPE;
+
/* Refresh the timer. */
if (len) {
indydog_ping();