diff options
author | Alan Cox <alan@redhat.com> | 2006-01-09 09:35:28 -0500 |
---|---|---|
committer | Chris Wright <chrisw@sous-sol.org> | 2006-01-14 22:15:30 -0800 |
commit | f72e024e3a4705336b04109756bc619e7ae62fdb (patch) | |
tree | c477bb2c721a4b31c4e624e19100b5d02836ab32 | |
parent | 7abeff5a23abb2d0edc54cc1cc3acaf886ea98ca (diff) |
[PATCH] moxa serial: add proper capability check
This requires the proper capabilities for the moxa bios update ioctl's.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
-rw-r--r-- | drivers/char/moxa.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/char/moxa.c b/drivers/char/moxa.c index 79e490ef2cf..68844439b59 100644 --- a/drivers/char/moxa.c +++ b/drivers/char/moxa.c @@ -1661,6 +1661,8 @@ int MoxaDriverIoctl(unsigned int cmd, unsigned long arg, int port) case MOXA_FIND_BOARD: case MOXA_LOAD_C320B: case MOXA_LOAD_CODE: + if (!capable(CAP_SYS_RAWIO)) + return -EPERM; break; } |