/* Pat the watchdog whenever device is written to.  */
static ssize_t pikawdt_write(struct file *file, const char __user *data, size_t len, loff_t *ppos)
/* Pat the watchdog whenever device is written to.  */
static ssize_t pikawdt_write(struct file *file, const char __user *data, size_t len, loff_t *ppos)
{
	if (!len)
		return 0;
	if (!nowayout) {
		size_t i;
		pikawdt_private.expect_close = 0;
		for (i = 0; i < len; i++) {
			char c;
			if (get_user(c, data + i))
				return -EFAULT;
			if (c == 'V') {
				pikawdt_private.expect_close = 42;
				break;
			}
		}
	}
	pikawdt_keepalive();
	return len;
}