staging: comedi: Fix checkpatch warning
PATCH 1/1 staging: comedi: Fix checkpatch warning
This patch is part of eudyptula challenge
--- drivers/staging/comedi/comedi_fops.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
drivers/staging/comedi/comedi_fops.c +5 -2
@@ -1435,13 +1435,16 @@ static int __comedi_get_user_cmd(struct comedi_device *dev, s = &dev->subdevices[cmd->subdev];if (s->type ==COMEDI_SUBD_UNUSED ) { -dev_dbg (dev->class_dev,"%d not valid subdevice\n" , cmd->subdev); +dev_dbg (dev->class_dev, +"%d not valid subdevice\n" , + cmd->subdev);return -EIO ; }if (!s->do_cmd || !s->do_cmdtest || !s->async) {dev_dbg (dev->class_dev, -"subdevice %d does not support commands\n" , cmd->subdev); +"subdevice %d does not support commands\n" , + cmd->subdev);return -EIO ; }
Signature · 1 line
1.9.1
Quoted 1 line · Camille Begue
This patch is part of eudyptula challenge
Hello Camille.
Please do not write commit log messages like this. Say what's wrong with the code, not why you did it.
Write something like:
Wrap lines > 80 columns.
drivers/staging/comedi/comedi_fops.c
Quoted 1 line
drivers/staging/comedi/comedi_fops.c +0
-0
[]
drivers/staging/comedi/comedi_fops.c static int __comedi_get_user_cmd(struct comedi_device *dev, · line 1440
Quoted 8 lines
drivers/staging/comedi/comedi_fops.c +3
-1@@ -1435,13 +1435,16 @@ static int __comedi_get_user_cmd(struct comedi_device *dev, s = &dev->subdevices[cmd->subdev];if (s->type ==COMEDI_SUBD_UNUSED ) { -dev_dbg (dev->class_dev,"%d not valid subdevice\n" , cmd->subdev); +dev_dbg (dev->class_dev, +"%d not valid subdevice\n" , + cmd->subdev);
If you really want to fix > 80 column lines, it'd be better to keep the dev_dbg and format on the same line
1 2 3 4 5 6 7 8
12345678901234567890123456789012345678901234567890123456789012345678901234567890
dev_dbg(dev->class_dev, "%d not valid subdevice\n", cmd->subdev);
drivers/staging/comedi/comedi_fops.c static int __comedi_get_user_cmd(struct comedi_device *dev, · line 1450
Quoted 11 lines
drivers/staging/comedi/comedi_fops.c +2
-1return -EIO ; }if (!s->do_cmd || !s->do_cmdtest || !s->async) {dev_dbg (dev->class_dev, -"subdevice %d does not support commands\n" , cmd->subdev); +"subdevice %d does not support commands\n" , + cmd->subdev);return -EIO ; }
here too
Quoted 2 lines · Camille Begue
This patch is part of eudyptula challenge
The changelog should mention something about lines over 80 characte long.
Quoted 10 lines
Signed-off-by Camille Begue <[email protected]>--- drivers/staging/comedi/comedi_fops.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)drivers/staging/comedi/comedi_fops.c +0
-0
drivers/staging/comedi/comedi_fops.c static int __comedi_get_user_cmd(struct comedi_device *dev, · line 1440
Quoted 7 lines
drivers/staging/comedi/comedi_fops.c +3
-1@@ -1435,13 +1435,16 @@ static int __comedi_get_user_cmd(struct comedi_device *dev, s = &dev->subdevices[cmd->subdev];if (s->type ==COMEDI_SUBD_UNUSED ) { -dev_dbg (dev->class_dev,"%d not valid subdevice\n" , cmd->subdev); +dev_dbg (dev->class_dev, +"%d not valid subdevice\n" , + cmd->subdev);
Do this instead:
dev_dbg(dev->class_dev, "%d not valid subdevice\n", cmd->subdev);
drivers/staging/comedi/comedi_fops.c static int __comedi_get_user_cmd(struct comedi_device *dev, · line 1443
Quoted 3 lines
drivers/staging/comedi/comedi_fops.c +0
-0return -EIO ; }
regards,
dan carpenter