[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1408460793-29793-3-git-send-email-abbotti@mev.co.uk>
Date: Tue, 19 Aug 2014 16:06:29 +0100
From: Ian Abbott <abbotti@....co.uk>
To: driverdev-devel@...uxdriverproject.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Ian Abbott <abbotti@....co.uk>,
H Hartley Sweeten <hartleys@...ionengravers.com>,
linux-kernel@...r.kernel.org
Subject: [PATCH 2/6] staging: comedi: ni_labpc: use braces on all arms of `if` statement
Fix checkpatch issues "CHECK: braces {} should be used on all arms of
this statement".
Signed-off-by: Ian Abbott <abbotti@....co.uk>
---
drivers/staging/comedi/drivers/ni_labpc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/comedi/drivers/ni_labpc.c b/drivers/staging/comedi/drivers/ni_labpc.c
index f5e78ad..4f49d51 100644
--- a/drivers/staging/comedi/drivers/ni_labpc.c
+++ b/drivers/staging/comedi/drivers/ni_labpc.c
@@ -397,8 +397,9 @@ static void labpc_set_ai_convert_period(struct comedi_cmd *cmd,
cmd->scan_begin_arg = ns;
if (cmd->convert_arg > cmd->scan_begin_arg)
cmd->convert_arg = cmd->scan_begin_arg;
- } else
+ } else {
cmd->convert_arg = ns;
+ }
}
static unsigned int labpc_ai_scan_period(const struct comedi_cmd *cmd,
@@ -1409,8 +1410,9 @@ int labpc_common_attach(struct comedi_device *dev,
for (i = 0; i < s->n_chan; i++)
write_caldac(dev, i, s->maxdata / 2);
- } else
+ } else {
s->type = COMEDI_SUBD_UNUSED;
+ }
/* EEPROM */
s = &dev->subdevices[4];
@@ -1424,8 +1426,9 @@ int labpc_common_attach(struct comedi_device *dev,
for (i = 0; i < s->n_chan; i++)
devpriv->eeprom_data[i] = labpc_eeprom_read(dev, i);
- } else
+ } else {
s->type = COMEDI_SUBD_UNUSED;
+ }
return 0;
}
--
2.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists