diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2018-03-18 12:58:18 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2018-03-28 08:58:19 -0400 |
commit | e4eacd6b899abc5fa2a0b6d20d5c430feba96858 (patch) | |
tree | 32248210ef1b26dae3eaf7751a37c07c50d9b4eb | |
parent | 0c8efd610b58cb23cefdfa12015799079aef94ae (diff) |
alpha: switch pci syscalls to SYSCALL_DEFINE
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | arch/alpha/kernel/pci-noop.c | 15 | ||||
-rw-r--r-- | arch/alpha/kernel/pci.c | 5 |
2 files changed, 10 insertions, 10 deletions
diff --git a/arch/alpha/kernel/pci-noop.c b/arch/alpha/kernel/pci-noop.c index b995987b1557..b6ebb65127a8 100644 --- a/arch/alpha/kernel/pci-noop.c +++ b/arch/alpha/kernel/pci-noop.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <linux/sched.h> | 15 | #include <linux/sched.h> |
16 | #include <linux/dma-mapping.h> | 16 | #include <linux/dma-mapping.h> |
17 | #include <linux/scatterlist.h> | 17 | #include <linux/scatterlist.h> |
18 | #include <linux/syscalls.h> | ||
18 | 19 | ||
19 | #include "proto.h" | 20 | #include "proto.h" |
20 | 21 | ||
@@ -46,8 +47,8 @@ alloc_resource(void) | |||
46 | return alloc_bootmem(sizeof(struct resource)); | 47 | return alloc_bootmem(sizeof(struct resource)); |
47 | } | 48 | } |
48 | 49 | ||
49 | asmlinkage long | 50 | SYSCALL_DEFINE3(pciconfig_iobase, long, which, unsigned long, bus, |
50 | sys_pciconfig_iobase(long which, unsigned long bus, unsigned long dfn) | 51 | unsigned long, dfn) |
51 | { | 52 | { |
52 | struct pci_controller *hose; | 53 | struct pci_controller *hose; |
53 | 54 | ||
@@ -84,9 +85,8 @@ sys_pciconfig_iobase(long which, unsigned long bus, unsigned long dfn) | |||
84 | return -EOPNOTSUPP; | 85 | return -EOPNOTSUPP; |
85 | } | 86 | } |
86 | 87 | ||
87 | asmlinkage long | 88 | SYSCALL_DEFINE5(pciconfig_read, unsigned long, bus, unsigned long, dfn, |
88 | sys_pciconfig_read(unsigned long bus, unsigned long dfn, | 89 | unsigned long, off, unsigned long, len, void __user *, buf) |
89 | unsigned long off, unsigned long len, void *buf) | ||
90 | { | 90 | { |
91 | if (!capable(CAP_SYS_ADMIN)) | 91 | if (!capable(CAP_SYS_ADMIN)) |
92 | return -EPERM; | 92 | return -EPERM; |
@@ -94,9 +94,8 @@ sys_pciconfig_read(unsigned long bus, unsigned long dfn, | |||
94 | return -ENODEV; | 94 | return -ENODEV; |
95 | } | 95 | } |
96 | 96 | ||
97 | asmlinkage long | 97 | SYSCALL_DEFINE5(pciconfig_write, unsigned long, bus, unsigned long, dfn, |
98 | sys_pciconfig_write(unsigned long bus, unsigned long dfn, | 98 | unsigned long, off, unsigned long, len, void __user *, buf) |
99 | unsigned long off, unsigned long len, void *buf) | ||
100 | { | 99 | { |
101 | if (!capable(CAP_SYS_ADMIN)) | 100 | if (!capable(CAP_SYS_ADMIN)) |
102 | return -EPERM; | 101 | return -EPERM; |
diff --git a/arch/alpha/kernel/pci.c b/arch/alpha/kernel/pci.c index 2e86ebb680ae..c668c3b7a167 100644 --- a/arch/alpha/kernel/pci.c +++ b/arch/alpha/kernel/pci.c | |||
@@ -22,6 +22,7 @@ | |||
22 | #include <linux/module.h> | 22 | #include <linux/module.h> |
23 | #include <linux/cache.h> | 23 | #include <linux/cache.h> |
24 | #include <linux/slab.h> | 24 | #include <linux/slab.h> |
25 | #include <linux/syscalls.h> | ||
25 | #include <asm/machvec.h> | 26 | #include <asm/machvec.h> |
26 | 27 | ||
27 | #include "proto.h" | 28 | #include "proto.h" |
@@ -409,8 +410,8 @@ alloc_resource(void) | |||
409 | /* Provide information on locations of various I/O regions in physical | 410 | /* Provide information on locations of various I/O regions in physical |
410 | memory. Do this on a per-card basis so that we choose the right hose. */ | 411 | memory. Do this on a per-card basis so that we choose the right hose. */ |
411 | 412 | ||
412 | asmlinkage long | 413 | SYSCALL_DEFINE3(pciconfig_iobase, long, which, unsigned long, bus, |
413 | sys_pciconfig_iobase(long which, unsigned long bus, unsigned long dfn) | 414 | unsigned long, dfn) |
414 | { | 415 | { |
415 | struct pci_controller *hose; | 416 | struct pci_controller *hose; |
416 | struct pci_dev *dev; | 417 | struct pci_dev *dev; |