Fix the two checkpatch.pl warnings in this file: WARNING: else is not generally useful after a break or return
Signed-off-by: H Hartley Sweeten <hswee...@visionengravers.com> Cc: Ian Abbott <abbo...@mev.co.uk> Cc: Greg Kroah-Hartman <gr...@linuxfoundation.org> --- drivers/staging/comedi/comedi_fops.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c index 038b69a..3686296 100644 --- a/drivers/staging/comedi/comedi_fops.c +++ b/drivers/staging/comedi/comedi_fops.c @@ -206,8 +206,8 @@ struct comedi_device *comedi_dev_get_from_minor(unsigned minor) { if (minor < COMEDI_NUM_BOARD_MINORS) return comedi_dev_get_from_board_minor(minor); - else - return comedi_dev_get_from_subdevice_minor(minor); + + return comedi_dev_get_from_subdevice_minor(minor); } EXPORT_SYMBOL_GPL(comedi_dev_get_from_minor); @@ -2625,10 +2625,9 @@ static int __init comedi_init(void) unregister_chrdev_region(MKDEV(COMEDI_MAJOR, 0), COMEDI_NUM_MINORS); return PTR_ERR(dev); - } else { - /* comedi_alloc_board_minor() locked the mutex */ - mutex_unlock(&dev->mutex); } + /* comedi_alloc_board_minor() locked the mutex */ + mutex_unlock(&dev->mutex); } return 0; -- 1.9.3 _______________________________________________ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel