| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * GE watchdog userspace interface |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Author: Martyn Welch <martyn.welch@ge.com> |
|---|
| 5 | 6 | * |
|---|
| 6 | 7 | * Copyright 2008 GE Intelligent Platforms Embedded Systems, Inc. |
|---|
| 7 | | - * |
|---|
| 8 | | - * This program is free software; you can redistribute it and/or modify it |
|---|
| 9 | | - * under the terms of the GNU General Public License as published by the |
|---|
| 10 | | - * Free Software Foundation; either version 2 of the License, or (at your |
|---|
| 11 | | - * option) any later version. |
|---|
| 12 | 8 | * |
|---|
| 13 | 9 | * Based on: mv64x60_wdt.c (MV64X60 watchdog userspace interface) |
|---|
| 14 | 10 | * Author: James Chapman <jchapman@katalix.com> |
|---|
| .. | .. |
|---|
| 205 | 201 | if (get_user(timeout, (int __user *)argp)) |
|---|
| 206 | 202 | return -EFAULT; |
|---|
| 207 | 203 | gef_wdt_set_timeout(timeout); |
|---|
| 208 | | - /* Fall through */ |
|---|
| 204 | + fallthrough; |
|---|
| 209 | 205 | |
|---|
| 210 | 206 | case WDIOC_GETTIMEOUT: |
|---|
| 211 | 207 | if (put_user(gef_wdt_timeout, (int __user *)argp)) |
|---|
| .. | .. |
|---|
| 229 | 225 | |
|---|
| 230 | 226 | gef_wdt_handler_enable(); |
|---|
| 231 | 227 | |
|---|
| 232 | | - return nonseekable_open(inode, file); |
|---|
| 228 | + return stream_open(inode, file); |
|---|
| 233 | 229 | } |
|---|
| 234 | 230 | |
|---|
| 235 | 231 | static int gef_wdt_release(struct inode *inode, struct file *file) |
|---|
| .. | .. |
|---|
| 252 | 248 | .llseek = no_llseek, |
|---|
| 253 | 249 | .write = gef_wdt_write, |
|---|
| 254 | 250 | .unlocked_ioctl = gef_wdt_ioctl, |
|---|
| 251 | + .compat_ioctl = compat_ptr_ioctl, |
|---|
| 255 | 252 | .open = gef_wdt_open, |
|---|
| 256 | 253 | .release = gef_wdt_release, |
|---|
| 257 | 254 | }; |
|---|