diff options
author | Arnd Bergmann <arnd@arndb.de> | 2010-04-26 18:24:02 -0400 |
---|---|---|
committer | Frederic Weisbecker <fweisbec@gmail.com> | 2010-05-16 23:27:05 -0400 |
commit | 703c631ebbcadcfd861d01e697fdda7c388fec9a (patch) | |
tree | 7c93468e7c898f448a330ce266d6b9205238d64a /drivers/isdn/i4l | |
parent | f4927c45beda9a70e5c3bda0bd9f12b4f713c00b (diff) |
isdn: Push down BKL into ioctl functions
Push down bkl into isdn ioctl functions
[fweisbec: dropped drivers/isdn/divert/divert_procfs.c
as it has been pushed down in procfs branch already]
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Diffstat (limited to 'drivers/isdn/i4l')
-rw-r--r-- | drivers/isdn/i4l/isdn_common.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_common.c index 70044ee4b228..a44cdb492ea9 100644 --- a/drivers/isdn/i4l/isdn_common.c +++ b/drivers/isdn/i4l/isdn_common.c | |||
@@ -1272,9 +1272,9 @@ isdn_poll(struct file *file, poll_table * wait) | |||
1272 | 1272 | ||
1273 | 1273 | ||
1274 | static int | 1274 | static int |
1275 | isdn_ioctl(struct inode *inode, struct file *file, uint cmd, ulong arg) | 1275 | isdn_ioctl(struct file *file, uint cmd, ulong arg) |
1276 | { | 1276 | { |
1277 | uint minor = iminor(inode); | 1277 | uint minor = iminor(file->f_path.dentry->d_inode); |
1278 | isdn_ctrl c; | 1278 | isdn_ctrl c; |
1279 | int drvidx; | 1279 | int drvidx; |
1280 | int chidx; | 1280 | int chidx; |
@@ -1722,6 +1722,18 @@ isdn_ioctl(struct inode *inode, struct file *file, uint cmd, ulong arg) | |||
1722 | #undef cfg | 1722 | #undef cfg |
1723 | } | 1723 | } |
1724 | 1724 | ||
1725 | static long | ||
1726 | isdn_unlocked_ioctl(struct file *file, unsigned int cmd, unsigned long arg) | ||
1727 | { | ||
1728 | int ret; | ||
1729 | |||
1730 | lock_kernel(); | ||
1731 | ret = isdn_ioctl(file, cmd, arg); | ||
1732 | unlock_kernel(); | ||
1733 | |||
1734 | return ret; | ||
1735 | } | ||
1736 | |||
1725 | /* | 1737 | /* |
1726 | * Open the device code. | 1738 | * Open the device code. |
1727 | */ | 1739 | */ |
@@ -1838,7 +1850,7 @@ static const struct file_operations isdn_fops = | |||
1838 | .read = isdn_read, | 1850 | .read = isdn_read, |
1839 | .write = isdn_write, | 1851 | .write = isdn_write, |
1840 | .poll = isdn_poll, | 1852 | .poll = isdn_poll, |
1841 | .ioctl = isdn_ioctl, | 1853 | .unlocked_ioctl = isdn_unlocked_ioctl, |
1842 | .open = isdn_open, | 1854 | .open = isdn_open, |
1843 | .release = isdn_close, | 1855 | .release = isdn_close, |
1844 | }; | 1856 | }; |