All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/2] staging: wilc1000: Enhance code formatting
@ 2017-03-09 22:30 Tamara Diaconita
  2017-03-09 23:29 ` [Outreachy kernel] " Alison Schofield
  0 siblings, 1 reply; 3+ messages in thread
From: Tamara Diaconita @ 2017-03-09 22:30 UTC (permalink / raw)
  To: aditya.shankar, ganesh.krishna, gregkh, outreachy-kernel; +Cc: Tamara Diaconita

This trims line size at 80 characters and makes code easier to read.

Problem found with checkpatch.pl.

Signed-off-by: Tamara Diaconita <diaconita.tamara@gmail.com>
---
 drivers/staging/wilc1000/coreconfigurator.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/wilc1000/coreconfigurator.h b/drivers/staging/wilc1000/coreconfigurator.h
index a2df5c7..00bb604 100644
--- a/drivers/staging/wilc1000/coreconfigurator.h
+++ b/drivers/staging/wilc1000/coreconfigurator.h
@@ -123,7 +123,8 @@ struct disconnect_info {
 s32 wilc_parse_network_info(u8 *msg_buffer,
 			    struct network_info **ret_network_info);
 s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
-			       struct connect_resp_info **ret_connect_resp_info);
+			       struct connect_resp_info
+			       **ret_connect_resp_info);
 void wilc_scan_complete_received(struct wilc *wilc, u8 *buffer,
 				 u32 length);
 void wilc_network_info_received(struct wilc *wilc, u8 *buffer,
-- 
2.9.3



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Outreachy kernel] [PATCH 2/2] staging: wilc1000: Enhance code formatting
  2017-03-09 22:30 [PATCH 2/2] staging: wilc1000: Enhance code formatting Tamara Diaconita
@ 2017-03-09 23:29 ` Alison Schofield
  2017-03-10  6:21   ` Julia Lawall
  0 siblings, 1 reply; 3+ messages in thread
From: Alison Schofield @ 2017-03-09 23:29 UTC (permalink / raw)
  To: Tamara Diaconita, julia.lawall
  Cc: aditya.shankar, ganesh.krishna, gregkh, outreachy-kernel,
	Tamara Diaconita

On Fri, Mar 10, 2017 at 12:30:59AM +0200, Tamara Diaconita wrote:
> This trims line size at 80 characters and makes code easier to read.
> 
> Problem found with checkpatch.pl.
> 
> Signed-off-by: Tamara Diaconita <diaconita.tamara@gmail.com>
> ---
>  drivers/staging/wilc1000/coreconfigurator.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/wilc1000/coreconfigurator.h b/drivers/staging/wilc1000/coreconfigurator.h
> index a2df5c7..00bb604 100644
> --- a/drivers/staging/wilc1000/coreconfigurator.h
> +++ b/drivers/staging/wilc1000/coreconfigurator.h
> @@ -123,7 +123,8 @@ struct disconnect_info {
>  s32 wilc_parse_network_info(u8 *msg_buffer,
>  			    struct network_info **ret_network_info);
>  s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
> -			       struct connect_resp_info **ret_connect_resp_info);
> +			       struct connect_resp_info
> +			       **ret_connect_resp_info);

Tamara,

Here I might take the checkpath CHECK on alignment, rather than split 
the structure..  

That is, do this:

s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
                              struct connect_resp_info **ret_connect_resp_info);

and live with this:

CHECK: Alignment should match open parenthesis
#126: FILE: coreconfigurator.h:126:
+s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
+			      struct connect_resp_info **ret_connect_resp_info);

It still looks better than the line over 80.

Let's ask Julia???

alisons


>  void wilc_scan_complete_received(struct wilc *wilc, u8 *buffer,
>  				 u32 length);
>  void wilc_network_info_received(struct wilc *wilc, u8 *buffer,
> -- 
> 2.9.3
> 
> -- 
> 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 post to this group, send email to outreachy-kernel@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20170309223059.7353-1-diaconita.tamara%40gmail.com.
> For more options, visit https://groups.google.com/d/optout.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Outreachy kernel] [PATCH 2/2] staging: wilc1000: Enhance code formatting
  2017-03-09 23:29 ` [Outreachy kernel] " Alison Schofield
@ 2017-03-10  6:21   ` Julia Lawall
  0 siblings, 0 replies; 3+ messages in thread
From: Julia Lawall @ 2017-03-10  6:21 UTC (permalink / raw)
  To: Alison Schofield
  Cc: Tamara Diaconita, julia.lawall, aditya.shankar, ganesh.krishna,
	gregkh, outreachy-kernel, Tamara Diaconita



On Thu, 9 Mar 2017, Alison Schofield wrote:

> On Fri, Mar 10, 2017 at 12:30:59AM +0200, Tamara Diaconita wrote:
> > This trims line size at 80 characters and makes code easier to read.
> >
> > Problem found with checkpatch.pl.
> >
> > Signed-off-by: Tamara Diaconita <diaconita.tamara@gmail.com>
> > ---
> >  drivers/staging/wilc1000/coreconfigurator.h | 3 ++-
> >  1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/staging/wilc1000/coreconfigurator.h b/drivers/staging/wilc1000/coreconfigurator.h
> > index a2df5c7..00bb604 100644
> > --- a/drivers/staging/wilc1000/coreconfigurator.h
> > +++ b/drivers/staging/wilc1000/coreconfigurator.h
> > @@ -123,7 +123,8 @@ struct disconnect_info {
> >  s32 wilc_parse_network_info(u8 *msg_buffer,
> >  			    struct network_info **ret_network_info);
> >  s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
> > -			       struct connect_resp_info **ret_connect_resp_info);
> > +			       struct connect_resp_info
> > +			       **ret_connect_resp_info);
>
> Tamara,
>
> Here I might take the checkpath CHECK on alignment, rather than split
> the structure..
>
> That is, do this:
>
> s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
>                               struct connect_resp_info **ret_connect_resp_info);
>
> and live with this:
>
> CHECK: Alignment should match open parenthesis
> #126: FILE: coreconfigurator.h:126:
> +s32 wilc_parse_assoc_resp_info(u8 *buffer, u32 buffer_len,
> +			      struct connect_resp_info **ret_connect_resp_info);
>
> It still looks better than the line over 80.
>
> Let's ask Julia???

I agree with Alison.  Getting the whole declaration on one line within 80
characters is the best thing.  Maybe the name of the variable could be
shortened.

julia


>
> alisons
>
>
> >  void wilc_scan_complete_received(struct wilc *wilc, u8 *buffer,
> >  				 u32 length);
> >  void wilc_network_info_received(struct wilc *wilc, u8 *buffer,
> > --
> > 2.9.3
> >
> > --
> > 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 post to this group, send email to outreachy-kernel@googlegroups.com.
> > To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20170309223059.7353-1-diaconita.tamara%40gmail.com.
> > For more options, visit https://groups.google.com/d/optout.
>
> --
> 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 post to this group, send email to outreachy-kernel@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20170309232939.GB16746%40d830.WORKGROUP.
> For more options, visit https://groups.google.com/d/optout.
>


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-03-10  6:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-09 22:30 [PATCH 2/2] staging: wilc1000: Enhance code formatting Tamara Diaconita
2017-03-09 23:29 ` [Outreachy kernel] " Alison Schofield
2017-03-10  6:21   ` Julia Lawall

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.