lkml.org 
[lkml]   [2012]   [Apr]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] staging/iio/meter: fix the coding style problem
On 04/30/2012 08:21 PM, joseph daniel wrote:
> Signed-off-by: joseph daniel <josephdanielwalter@gmail.com>
> ---
> Please consider this patch, previous one is wrong because my
> tabspace in vim was 4, instead 8. sorry..
>
> drivers/staging/iio/meter/ade7854-i2c.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/staging/iio/meter/ade7854-i2c.c b/drivers/staging/iio/meter/ade7854-i2c.c
> index 1e1faa0..ba97d6e 100644
> --- a/drivers/staging/iio/meter/ade7854-i2c.c
> +++ b/drivers/staging/iio/meter/ade7854-i2c.c
> @@ -195,7 +195,10 @@ static int ade7854_i2c_read_reg_32(struct device *dev,
> if (ret)
> goto out;
>
> - *val = (st->rx[0] << 24) | (st->rx[1] << 16) | (st->rx[2] << 8) | st->rx[3];
> + *val = (st->rx[0] << 24) |
> + (st->rx[1] << 16) |
> + (st->rx[2] << 8) |
> + st->rx[3];

Nack. In my opinion this doesn't make the code more readable. 80 chars per line
should be though of as a softlimit.

But this looks like something that could use be32_to_cpu though.

> out:
> mutex_unlock(&st->buf_lock);
> return ret;



\
 
 \ /
  Last update: 2012-04-30 20:41    [W:1.537 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site