Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1205967 > unrolled thread
| Started by | "Shah, Yash (Y.)" <yshah1@visteon.com> |
|---|---|
| First post | 2015-08-12 13:20 +0200 |
| Last post | 2015-08-12 15:40 +0200 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH] Staging: media/bcm2048: Fix line over 80 characters warning as detected by checkpatch.pl "Shah, Yash (Y.)" <yshah1@visteon.com> - 2015-08-12 13:20 +0200
Re: [PATCH] Staging: media/bcm2048: Fix line over 80 characters warning as detected by checkpatch.pl Pali Rohár <pali.rohar@gmail.com> - 2015-08-12 13:30 +0200
Re: [PATCH] Staging: media/bcm2048: Fix line over 80 characters warning as detected by checkpatch.pl Frans Klaver <fransklaver@gmail.com> - 2015-08-12 15:40 +0200
| From | "Shah, Yash (Y.)" <yshah1@visteon.com> |
|---|---|
| Date | 2015-08-12 13:20 +0200 |
| Subject | [PATCH] Staging: media/bcm2048: Fix line over 80 characters warning as detected by checkpatch.pl |
| Message-ID | <pWCeC-2Kj-15@gated-at.bofh.it> |
From: Yash Shah <yshah1@visteon.com> Fix line over 80 characters warning as detected by checkpatch.pl Signed-off-by: Yash Shah <yshah1@visteon.com> --- drivers/staging/media/bcm2048/radio-bcm2048.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/media/bcm2048/radio-bcm2048.c b/drivers/staging/media/bcm2048/radio-bcm2048.c index 8bc68e2..d36350e 100644 --- a/drivers/staging/media/bcm2048/radio-bcm2048.c +++ b/drivers/staging/media/bcm2048/radio-bcm2048.c @@ -2243,7 +2243,8 @@ static ssize_t bcm2048_fops_read(struct file *file, char __user *buf, tmpbuf[i] = bdev->rds_info.radio_text[bdev->rd_index+i+2]; tmpbuf[i+1] = bdev->rds_info.radio_text[bdev->rd_index+i+1]; - tmpbuf[i+2] = (bdev->rds_info.radio_text[bdev->rd_index + i] & 0xf0) >> 4; + tmpbuf[i+2] = (bdev->rds_info.radio_text[bdev->rd_index + i] + & 0xf0) >> 4; if ((bdev->rds_info.radio_text[bdev->rd_index+i] & BCM2048_RDS_CRC_MASK) == BCM2048_RDS_CRC_UNRECOVARABLE) tmpbuf[i+2] |= 0x80; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Pali Rohár <pali.rohar@gmail.com> |
|---|---|
| Date | 2015-08-12 13:30 +0200 |
| Subject | Re: [PATCH] Staging: media/bcm2048: Fix line over 80 characters warning as detected by checkpatch.pl |
| Message-ID | <pWCoh-2VG-5@gated-at.bofh.it> |
| In reply to | #1205967 |
On Wednesday 12 August 2015 11:12:49 Shah, Yash (Y.) wrote: > From: Yash Shah <yshah1@visteon.com> > > Fix line over 80 characters warning as detected by checkpatch.pl > > Signed-off-by: Yash Shah <yshah1@visteon.com> > --- > drivers/staging/media/bcm2048/radio-bcm2048.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/drivers/staging/media/bcm2048/radio-bcm2048.c b/drivers/staging/media/bcm2048/radio-bcm2048.c > index 8bc68e2..d36350e 100644 > --- a/drivers/staging/media/bcm2048/radio-bcm2048.c > +++ b/drivers/staging/media/bcm2048/radio-bcm2048.c > @@ -2243,7 +2243,8 @@ static ssize_t bcm2048_fops_read(struct file *file, char __user *buf, > > tmpbuf[i] = bdev->rds_info.radio_text[bdev->rd_index+i+2]; > tmpbuf[i+1] = bdev->rds_info.radio_text[bdev->rd_index+i+1]; > - tmpbuf[i+2] = (bdev->rds_info.radio_text[bdev->rd_index + i] & 0xf0) >> 4; > + tmpbuf[i+2] = (bdev->rds_info.radio_text[bdev->rd_index + i] > + & 0xf0) >> 4; > if ((bdev->rds_info.radio_text[bdev->rd_index+i] & > BCM2048_RDS_CRC_MASK) == BCM2048_RDS_CRC_UNRECOVARABLE) > tmpbuf[i+2] |= 0x80; Hi! I think that code after this change is less readable as before. -- Pali Rohár pali.rohar@gmail.com -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Frans Klaver <fransklaver@gmail.com> |
|---|---|
| Date | 2015-08-12 15:40 +0200 |
| Subject | Re: [PATCH] Staging: media/bcm2048: Fix line over 80 characters warning as detected by checkpatch.pl |
| Message-ID | <pWEqa-5Pp-71@gated-at.bofh.it> |
| In reply to | #1205972 |
On Wed, Aug 12, 2015 at 1:19 PM, Pali Rohár <pali.rohar@gmail.com> wrote: > On Wednesday 12 August 2015 11:12:49 Shah, Yash (Y.) wrote: >> From: Yash Shah <yshah1@visteon.com> >> >> Fix line over 80 characters warning as detected by checkpatch.pl >> >> Signed-off-by: Yash Shah <yshah1@visteon.com> >> --- >> drivers/staging/media/bcm2048/radio-bcm2048.c | 3 ++- >> 1 file changed, 2 insertions(+), 1 deletion(-) >> >> diff --git a/drivers/staging/media/bcm2048/radio-bcm2048.c b/drivers/staging/media/bcm2048/radio-bcm2048.c >> index 8bc68e2..d36350e 100644 >> --- a/drivers/staging/media/bcm2048/radio-bcm2048.c >> +++ b/drivers/staging/media/bcm2048/radio-bcm2048.c >> @@ -2243,7 +2243,8 @@ static ssize_t bcm2048_fops_read(struct file *file, char __user *buf, >> >> tmpbuf[i] = bdev->rds_info.radio_text[bdev->rd_index+i+2]; >> tmpbuf[i+1] = bdev->rds_info.radio_text[bdev->rd_index+i+1]; >> - tmpbuf[i+2] = (bdev->rds_info.radio_text[bdev->rd_index + i] & 0xf0) >> 4; >> + tmpbuf[i+2] = (bdev->rds_info.radio_text[bdev->rd_index + i] >> + & 0xf0) >> 4; >> if ((bdev->rds_info.radio_text[bdev->rd_index+i] & >> BCM2048_RDS_CRC_MASK) == BCM2048_RDS_CRC_UNRECOVARABLE) >> tmpbuf[i+2] |= 0x80; > > Hi! I think that code after this change is less readable as before. I agree. I would do something about 'bdev->rds_info.radio_text' instead and shorten all three lines. Frans -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web