* [PATCH 0/2] staging: greybus: simple formatting cleanup @ 2020-03-13 20:49 Lourdes Pedrajas 2020-03-13 20:49 ` [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting Lourdes Pedrajas 2020-03-13 20:49 ` [PATCH 2/2] staging: greybus: hid: remove unneded braces Lourdes Pedrajas 0 siblings, 2 replies; 9+ messages in thread From: Lourdes Pedrajas @ 2020-03-13 20:49 UTC (permalink / raw) To: outreachy-kernel, rmfrfs, johan, elder, gregkh, vireshk Patchset that performs simple code cleanup in greybus driver. Issues found with checkpatch. Lourdes Pedrajas (2): staging: greybus: gpio: improve bit fields formatting. staging: greybus: hid: remove unneded braces drivers/staging/greybus/gpio.c | 4 ++-- drivers/staging/greybus/hid.c | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) -- 2.17.1 ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting. 2020-03-13 20:49 [PATCH 0/2] staging: greybus: simple formatting cleanup Lourdes Pedrajas @ 2020-03-13 20:49 ` Lourdes Pedrajas 2020-03-13 21:03 ` [Outreachy kernel] " Julia Lawall 2020-03-16 9:55 ` [PATCH v2 " Johan Hovold 2020-03-13 20:49 ` [PATCH 2/2] staging: greybus: hid: remove unneded braces Lourdes Pedrajas 1 sibling, 2 replies; 9+ messages in thread From: Lourdes Pedrajas @ 2020-03-13 20:49 UTC (permalink / raw) To: outreachy-kernel, rmfrfs, johan, elder, gregkh, vireshk Fix the formatting of bit fields on structure gb_gpio_line, in order to not confuse them with unindented labels. Issue found with checkpatch. Signed-off-by: Lourdes Pedrajas <lu@pplo.net> --- drivers/staging/greybus/gpio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c index 36d99f9e419e..50e93a393dba 100644 --- a/drivers/staging/greybus/gpio.c +++ b/drivers/staging/greybus/gpio.c @@ -20,9 +20,9 @@ struct gb_gpio_line { /* The following has to be an array of line_max entries */ /* --> make them just a flags field */ - u8 active: 1, + u8 active: 1, direction: 1, /* 0 = output, 1 = input */ - value: 1; /* 0 = low, 1 = high */ + value: 1; /* 0 = low, 1 = high */ u16 debounce_usec; u8 irq_type; -- 2.17.1 ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [Outreachy kernel] [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting. 2020-03-13 20:49 ` [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting Lourdes Pedrajas @ 2020-03-13 21:03 ` Julia Lawall 2020-03-14 20:42 ` Lourdes Pedrajas 2020-03-16 9:55 ` [PATCH v2 " Johan Hovold 1 sibling, 1 reply; 9+ messages in thread From: Julia Lawall @ 2020-03-13 21:03 UTC (permalink / raw) To: Lourdes Pedrajas; +Cc: outreachy-kernel, rmfrfs, johan, elder, gregkh, vireshk On Fri, 13 Mar 2020, Lourdes Pedrajas wrote: > Fix the formatting of bit fields on structure gb_gpio_line, in order to > not confuse them with unindented labels. What do you mean by unindented labels? julia > Issue found with checkpatch. > > Signed-off-by: Lourdes Pedrajas <lu@pplo.net> > --- > drivers/staging/greybus/gpio.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c > index 36d99f9e419e..50e93a393dba 100644 > --- a/drivers/staging/greybus/gpio.c > +++ b/drivers/staging/greybus/gpio.c > @@ -20,9 +20,9 @@ > struct gb_gpio_line { > /* The following has to be an array of line_max entries */ > /* --> make them just a flags field */ > - u8 active: 1, > + u8 active: 1, > direction: 1, /* 0 = output, 1 = input */ > - value: 1; /* 0 = low, 1 = high */ > + value: 1; /* 0 = low, 1 = high */ > u16 debounce_usec; > > u8 irq_type; > -- > 2.17.1 > > -- > You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. > To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/88c5f940009f75813f026ebad57fc8865b242971.1584131593.git.lu%40pplo.net. > ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Outreachy kernel] [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting. 2020-03-13 21:03 ` [Outreachy kernel] " Julia Lawall @ 2020-03-14 20:42 ` Lourdes Pedrajas 0 siblings, 0 replies; 9+ messages in thread From: Lourdes Pedrajas @ 2020-03-14 20:42 UTC (permalink / raw) To: Julia Lawall; +Cc: outreachy-kernel, rmfrfs, johan, elder, gregkh, vireshk On Fri, Mar 13, 2020 at 10:03:23PM +0100, Julia Lawall wrote: > > > On Fri, 13 Mar 2020, Lourdes Pedrajas wrote: > > > Fix the formatting of bit fields on structure gb_gpio_line, in order to > > not confuse them with unindented labels. > > What do you mean by unindented labels? > > julia > I am sorry for this error! Corrected now thank you Julia! Lourdes ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2 1/2] staging: greybus: gpio: improve bit fields formatting. 2020-03-13 20:49 ` [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting Lourdes Pedrajas 2020-03-13 21:03 ` [Outreachy kernel] " Julia Lawall @ 2020-03-16 9:55 ` Johan Hovold 2020-03-16 20:01 ` Lourdes Pedrajas 1 sibling, 1 reply; 9+ messages in thread From: Johan Hovold @ 2020-03-16 9:55 UTC (permalink / raw) To: Lourdes Pedrajas; +Cc: outreachy-kernel, rmfrfs, johan, elder, gregkh, vireshk On Sat, Mar 14, 2020 at 09:40:20PM +0100, Lourdes Pedrajas wrote: > Fix the formatting of bit fields on structure gb_gpio_line, in order to > not confuse them with indented labels. > Issue found with checkpatch. This is not an in issue found by checkpatch. Rather, you've found an issue *with* checkpatch, which gets confused by these bit fields. I'd just leave this as is, since there's nothing wrong with the code. > Signed-off-by: Lourdes Pedrajas <lu@pplo.net> > --- > v2: log message correction > > drivers/staging/greybus/gpio.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c > index 36d99f9e419e..50e93a393dba 100644 > --- a/drivers/staging/greybus/gpio.c > +++ b/drivers/staging/greybus/gpio.c > @@ -20,9 +20,9 @@ > struct gb_gpio_line { > /* The following has to be an array of line_max entries */ > /* --> make them just a flags field */ > - u8 active: 1, > + u8 active: 1, > direction: 1, /* 0 = output, 1 = input */ > - value: 1; /* 0 = low, 1 = high */ > + value: 1; /* 0 = low, 1 = high */ > u16 debounce_usec; > > u8 irq_type; Johan ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2 1/2] staging: greybus: gpio: improve bit fields formatting. 2020-03-16 9:55 ` [PATCH v2 " Johan Hovold @ 2020-03-16 20:01 ` Lourdes Pedrajas 0 siblings, 0 replies; 9+ messages in thread From: Lourdes Pedrajas @ 2020-03-16 20:01 UTC (permalink / raw) To: Johan Hovold; +Cc: outreachy-kernel, rmfrfs, elder, gregkh, vireshk On Mon, Mar 16, 2020 at 10:55:11AM +0100, Johan Hovold wrote: > On Sat, Mar 14, 2020 at 09:40:20PM +0100, Lourdes Pedrajas wrote: > > Fix the formatting of bit fields on structure gb_gpio_line, in order to > > not confuse them with indented labels. > > Issue found with checkpatch. > > This is not an in issue found by checkpatch. Rather, you've found an > issue *with* checkpatch, which gets confused by these bit fields. > > I'd just leave this as is, since there's nothing wrong with the code. > > Johan Agreed, thank you! Lourdes ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 2/2] staging: greybus: hid: remove unneded braces 2020-03-13 20:49 [PATCH 0/2] staging: greybus: simple formatting cleanup Lourdes Pedrajas 2020-03-13 20:49 ` [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting Lourdes Pedrajas @ 2020-03-13 20:49 ` Lourdes Pedrajas 2020-03-17 11:47 ` Greg KH 1 sibling, 1 reply; 9+ messages in thread From: Lourdes Pedrajas @ 2020-03-13 20:49 UTC (permalink / raw) To: outreachy-kernel, rmfrfs, johan, elder, gregkh, vireshk Braces are not necessary for single statement blocks. Issue found with checkpatch. Signed-off-by: Lourdes Pedrajas <lu@pplo.net> --- drivers/staging/greybus/hid.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/staging/greybus/hid.c b/drivers/staging/greybus/hid.c index 04bfd9110502..9d4ca66e1c8d 100644 --- a/drivers/staging/greybus/hid.c +++ b/drivers/staging/greybus/hid.c @@ -290,9 +290,8 @@ static int gb_hid_parse(struct hid_device *hid) } rdesc = kzalloc(rsize, GFP_KERNEL); - if (!rdesc) { + if (!rdesc) return -ENOMEM; - } ret = gb_hid_get_report_desc(ghid, rdesc); if (ret) { -- 2.17.1 ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH 2/2] staging: greybus: hid: remove unneded braces 2020-03-13 20:49 ` [PATCH 2/2] staging: greybus: hid: remove unneded braces Lourdes Pedrajas @ 2020-03-17 11:47 ` Greg KH 2020-03-17 17:07 ` Lourdes Pedrajas 0 siblings, 1 reply; 9+ messages in thread From: Greg KH @ 2020-03-17 11:47 UTC (permalink / raw) To: Lourdes Pedrajas; +Cc: outreachy-kernel, rmfrfs, johan, elder, vireshk On Fri, Mar 13, 2020 at 09:49:37PM +0100, Lourdes Pedrajas wrote: > Braces are not necessary for single statement blocks. > Issue found with checkpatch. > > Signed-off-by: Lourdes Pedrajas <lu@pplo.net> > --- > drivers/staging/greybus/hid.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/staging/greybus/hid.c b/drivers/staging/greybus/hid.c > index 04bfd9110502..9d4ca66e1c8d 100644 > --- a/drivers/staging/greybus/hid.c > +++ b/drivers/staging/greybus/hid.c > @@ -290,9 +290,8 @@ static int gb_hid_parse(struct hid_device *hid) > } > > rdesc = kzalloc(rsize, GFP_KERNEL); > - if (!rdesc) { > + if (!rdesc) > return -ENOMEM; > - } > > ret = gb_hid_get_report_desc(ghid, rdesc); > if (ret) { This patch _ADDS_ checkpatch warnings :( Please always verify that your patch does what you think it does before you send it out... thanks, greg k-h ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 2/2] staging: greybus: hid: remove unneded braces 2020-03-17 11:47 ` Greg KH @ 2020-03-17 17:07 ` Lourdes Pedrajas 0 siblings, 0 replies; 9+ messages in thread From: Lourdes Pedrajas @ 2020-03-17 17:07 UTC (permalink / raw) To: Greg KH; +Cc: outreachy-kernel, rmfrfs, johan, elder, vireshk On Tue, Mar 17, 2020 at 12:47:15PM +0100, Greg KH wrote: > On Fri, Mar 13, 2020 at 09:49:37PM +0100, Lourdes Pedrajas wrote: > > > This patch _ADDS_ checkpatch warnings :( > > Please always verify that your patch does what you think it does > before you send it out... > > thanks, > > greg k-h It won't happen again :( Thank you, Lourdes ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2020-03-17 17:07 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-03-13 20:49 [PATCH 0/2] staging: greybus: simple formatting cleanup Lourdes Pedrajas 2020-03-13 20:49 ` [PATCH 1/2] staging: greybus: gpio: improve bit fields formatting Lourdes Pedrajas 2020-03-13 21:03 ` [Outreachy kernel] " Julia Lawall 2020-03-14 20:42 ` Lourdes Pedrajas 2020-03-16 9:55 ` [PATCH v2 " Johan Hovold 2020-03-16 20:01 ` Lourdes Pedrajas 2020-03-13 20:49 ` [PATCH 2/2] staging: greybus: hid: remove unneded braces Lourdes Pedrajas 2020-03-17 11:47 ` Greg KH 2020-03-17 17:07 ` Lourdes Pedrajas
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.