hc
2024-05-14 bedbef8ad3e75a304af6361af235302bcc61d06b
kernel/drivers/watchdog/eurotechwdt.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0+
12 /*
23 * Eurotech CPU-1220/1410/1420 on board WDT driver
34 *
....@@ -10,11 +11,6 @@
1011 *
1112 * (c) Copyright 1996-1997 Alan Cox <alan@lxorguk.ukuu.org.uk>,
1213 * All Rights Reserved.
13
- *
14
- * This program is free software; you can redistribute it and/or
15
- * modify it under the terms of the GNU General Public License
16
- * as published by the Free Software Foundation; either version
17
- * 2 of the License, or (at your option) any later version.
1814 *
1915 * Neither Alan Cox nor CymruNet Ltd. admit liability nor provide
2016 * warranty for any of this software. This material is provided
....@@ -290,7 +286,7 @@
290286 eurwdt_timeout = time;
291287 eurwdt_set_timeout(time);
292288 spin_unlock(&eurwdt_lock);
293
- /* fall through */
289
+ fallthrough;
294290
295291 case WDIOC_GETTIMEOUT:
296292 return put_user(eurwdt_timeout, p);
....@@ -316,7 +312,7 @@
316312 eurwdt_timeout = WDT_TIMEOUT; /* initial timeout */
317313 /* Activate the WDT */
318314 eurwdt_activate_timer();
319
- return nonseekable_open(inode, file);
315
+ return stream_open(inode, file);
320316 }
321317
322318 /**
....@@ -375,6 +371,7 @@
375371 .llseek = no_llseek,
376372 .write = eurwdt_write,
377373 .unlocked_ioctl = eurwdt_ioctl,
374
+ .compat_ioctl = compat_ptr_ioctl,
378375 .open = eurwdt_open,
379376 .release = eurwdt_release,
380377 };