| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0+ |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Industrial Computer Source PCI-WDT500/501 driver |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * (c) Copyright 1996-1997 Alan Cox <alan@lxorguk.ukuu.org.uk>, |
|---|
| 5 | 6 | * All Rights Reserved. |
|---|
| 6 | | - * |
|---|
| 7 | | - * This program is free software; you can redistribute it and/or |
|---|
| 8 | | - * modify it under the terms of the GNU General Public License |
|---|
| 9 | | - * as published by the Free Software Foundation; either version |
|---|
| 10 | | - * 2 of the License, or (at your option) any later version. |
|---|
| 11 | 7 | * |
|---|
| 12 | 8 | * Neither Alan Cox nor CymruNet Ltd. admit liability nor provide |
|---|
| 13 | 9 | * warranty for any of this software. This material is provided |
|---|
| .. | .. |
|---|
| 430 | 426 | if (wdtpci_set_heartbeat(new_heartbeat)) |
|---|
| 431 | 427 | return -EINVAL; |
|---|
| 432 | 428 | wdtpci_ping(); |
|---|
| 433 | | - /* fall through */ |
|---|
| 429 | + fallthrough; |
|---|
| 434 | 430 | case WDIOC_GETTIMEOUT: |
|---|
| 435 | 431 | return put_user(heartbeat, p); |
|---|
| 436 | 432 | default: |
|---|
| .. | .. |
|---|
| 461 | 457 | * Activate |
|---|
| 462 | 458 | */ |
|---|
| 463 | 459 | wdtpci_start(); |
|---|
| 464 | | - return nonseekable_open(inode, file); |
|---|
| 460 | + return stream_open(inode, file); |
|---|
| 465 | 461 | } |
|---|
| 466 | 462 | |
|---|
| 467 | 463 | /** |
|---|
| .. | .. |
|---|
| 524 | 520 | |
|---|
| 525 | 521 | static int wdtpci_temp_open(struct inode *inode, struct file *file) |
|---|
| 526 | 522 | { |
|---|
| 527 | | - return nonseekable_open(inode, file); |
|---|
| 523 | + return stream_open(inode, file); |
|---|
| 528 | 524 | } |
|---|
| 529 | 525 | |
|---|
| 530 | 526 | /** |
|---|
| .. | .. |
|---|
| 570 | 566 | .llseek = no_llseek, |
|---|
| 571 | 567 | .write = wdtpci_write, |
|---|
| 572 | 568 | .unlocked_ioctl = wdtpci_ioctl, |
|---|
| 569 | + .compat_ioctl = compat_ptr_ioctl, |
|---|
| 573 | 570 | .open = wdtpci_open, |
|---|
| 574 | 571 | .release = wdtpci_release, |
|---|
| 575 | 572 | }; |
|---|