Staging: comedi: Fix line length exceeding 80 characters
PATCH 1/1 Staging: comedi: Fix line length exceeding 80 characters
--- drivers/staging/comedi/comedi_fops.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/staging/comedi/comedi_fops.c +2 -1
@@ -1481,7 +1481,8 @@ static int do_cmd_ioctl(struct comedi_device *dev, async->cmd.data =NULL ;/* load channel/gain list */ async->cmd.chanlist =memdup_user (user_chanlist, - async->cmd.chanlist_len *sizeof (int )); + async->cmd.chanlist_len + *sizeof (int ));if (IS_ERR (async->cmd.chanlist)) { ret =PTR_ERR (async->cmd.chanlist); async->cmd.chanlist =NULL ;
Signature · 1 line
1.7.9.5
Quoted 10 lines · Monam Agarwal
Signed-off-by Monam Agarwal <[email protected]>--- drivers/staging/comedi/comedi_fops.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/staging/comedi/comedi_fops.c +0
-0
drivers/staging/comedi/comedi_fops.c static int do_cmd_ioctl(struct comedi_device *dev, · line 1485
Quoted 6 lines
drivers/staging/comedi/comedi_fops.c +2
-1@@ -1481,7 +1481,8 @@ static int do_cmd_ioctl(struct comedi_device *dev, async->cmd.data =NULL ;/* load channel/gain list */ async->cmd.chanlist =memdup_user (user_chanlist, - async->cmd.chanlist_len *sizeof (int )); + async->cmd.chanlist_len + *sizeof (int ));
The * operator should go at the end of the line according to the CodingStyle.
Quoted 4 lines
drivers/staging/comedi/comedi_fops.c +0
-0if (IS_ERR (async->cmd.chanlist)) { ret =PTR_ERR (async->cmd.chanlist); async->cmd.chanlist =NULL ;
Signature · 2 lines
-=( Ian Abbott @ MEV Ltd. E-mail: <[email protected]> )=- -=( Tel: +44 (0)161 477 1898 FAX: +44 (0)161 718 3587 )=-
Quoted 1 line · Ian Abbott
On 2014-02-24 16:49, Monam Agarwal wrote:
[]
Quoted 1 line
drivers/staging/comedi/comedi_fops.c
Quoted 1 line
drivers/staging/comedi/comedi_fops.c +0
-0
[]
Quoted 10 lines
drivers/staging/comedi/comedi_fops.c static int do_cmd_ioctl(struct comedi_device *dev, · line 1485
Quoted 7 lines
drivers/staging/comedi/comedi_fops.c +2
-1@@ -1481,7 +1481,8 @@ static int do_cmd_ioctl(struct comedi_device *dev, async->cmd.data =NULL ;/* load channel/gain list */ async->cmd.chanlist =memdup_user (user_chanlist, - async->cmd.chanlist_len *sizeof (int )); + async->cmd.chanlist_len + *sizeof (int ));The
*operator should go at the end of the line according to the CodingStyle.
I don't believe there's a CodingStyle guide for this.
Another way to do this is to move the memdup_user to a separate line like:
async->cmd_chanlist = memdup_user(user_chanlist, async->cmd.chanlist_len * sizeof(int));
but I'm not bothered by the existing > 80 column use.
Quoted 16 lines · Joe Perches
Quoted 1 line · Ian Abbott
On 2014-02-24 16:49, Monam Agarwal wrote:
[]
Quoted 1 line
drivers/staging/comedi/comedi_fops.c
Quoted 1 line
drivers/staging/comedi/comedi_fops.c +0
-0[]
Quoted 10 lines
drivers/staging/comedi/comedi_fops.c static int do_cmd_ioctl(struct comedi_device *dev, · line 1485
Quoted 7 lines
drivers/staging/comedi/comedi_fops.c +2
-1@@ -1481,7 +1481,8 @@ static int do_cmd_ioctl(struct comedi_device *dev, async->cmd.data =NULL ;/* load channel/gain list */ async->cmd.chanlist =memdup_user (user_chanlist, - async->cmd.chanlist_len *sizeof (int )); + async->cmd.chanlist_len + *sizeof (int ));The
*operator should go at the end of the line according to the CodingStyle.
Quoted 2 lines
I don't believe there's a CodingStyle guide for this.
Meanwhile you have felt totally justified in correcting me on this in the past. :P
Anyway, it should be that the operator goes on the first line like Ian says...
regards,
dan carpenter
Quoted 15 lines · Dan Carpenter
Quoted 14 lines · Joe Perches
Quoted 1 line · Ian Abbott
On 2014-02-24 16:49, Monam Agarwal wrote:
[]
Quoted 1 line
drivers/staging/comedi/comedi_fops.c
Quoted 1 line
drivers/staging/comedi/comedi_fops.c +0
-0[]
Quoted 9 lines
drivers/staging/comedi/comedi_fops.c static int do_cmd_ioctl(struct comedi_device *dev, · line 1485
Quoted 7 lines
drivers/staging/comedi/comedi_fops.c +2
-1@@ -1481,7 +1481,8 @@ static int do_cmd_ioctl(struct comedi_device *dev, async->cmd.data =NULL ;/* load channel/gain list */ async->cmd.chanlist =memdup_user (user_chanlist, - async->cmd.chanlist_len *sizeof (int )); + async->cmd.chanlist_len + *sizeof (int ));The
*operator should go at the end of the line according to the CodingStyle.
Quoted 3 lines
Quoted 1 line
I don't believe there's a CodingStyle guide for this.
Meanwhile you have felt totally justified in correcting me on this in the past. :P
Doubtful. You're probably thinking of something else.
Besides, we generally agree on style. Anything I may have written was more more suggestion than correction.
Quoted 2 lines
Anyway, it should be that the operator goes on the first line like Ian says...
Feel free to use whatever style you want.
Feel free to update CodingStyle too.
cheers, Joe
[email protected]
maintainerQuoted 6 lines · Ian Abbott
Quoted 5 lines · Monam Agarwal
Signed-off-by Monam Agarwal <[email protected]>--- drivers/staging/comedi/comedi_fops.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Quoted 14 lines
drivers/staging/comedi/comedi_fops.c static int do_cmd_ioctl(struct comedi_device *dev, · line 1485
Quoted 11 lines
drivers/staging/comedi/comedi_fops.c +2
-1@@ -1481,7 +1481,8 @@ static int do_cmd_ioctl(struct comedi_device *dev, async->cmd.data =NULL ;/* load channel/gain list */ async->cmd.chanlist =memdup_user (user_chanlist, - async->cmd.chanlist_len *sizeof (int )); + async->cmd.chanlist_len + *sizeof (int ));The
*operator should go at the end of the line according to the CodingStyle.
Which is why I modified it by hand before applying it :)