summaryrefslogtreecommitdiffstats
path: root/drivers/staging/comedi/comedi_fops.c
diff options
context:
space:
mode:
authorH Hartley Sweeten2015-08-10 22:14:00 +0200
committerGreg Kroah-Hartman2015-08-15 03:35:49 +0200
commitc4237a2b59432a6ebf73f813ad9e94ab408bb8f1 (patch)
treeb4aec18c11164cf8eee2f92fee5fd3349cad5783 /drivers/staging/comedi/comedi_fops.c
parentstaging: comedi: comedi_fops: remove BUG_ON() in comedi_free_subdevice_minor() (diff)
downloadkernel-qcow2-linux-c4237a2b59432a6ebf73f813ad9e94ab408bb8f1.tar.gz
kernel-qcow2-linux-c4237a2b59432a6ebf73f813ad9e94ab408bb8f1.tar.xz
kernel-qcow2-linux-c4237a2b59432a6ebf73f813ad9e94ab408bb8f1.zip
staging: comedi: comedi_fops: remove BUG_ON() in comedi_dev_get_from_board_minor()
This function is only called by comedi_dev_get_from_minor() and the 'minor' value will always be < COMEDI_NUM_BOARD_MINORS. Remove the unnecessary BUG_ON(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/comedi/comedi_fops.c')
-rw-r--r--drivers/staging/comedi/comedi_fops.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c
index 2e69f5a4e7ec..f7db91ca974e 100644
--- a/drivers/staging/comedi/comedi_fops.c
+++ b/drivers/staging/comedi/comedi_fops.c
@@ -227,7 +227,6 @@ static struct comedi_device *comedi_dev_get_from_board_minor(unsigned minor)
{
struct comedi_device *dev;
- BUG_ON(minor >= COMEDI_NUM_BOARD_MINORS);
mutex_lock(&comedi_board_minor_table_lock);
dev = comedi_dev_get(comedi_board_minor_table[minor]);
mutex_unlock(&comedi_board_minor_table_lock);