All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: fsl-mc: fix coding stye errors
@ 2017-01-17  8:11 Dhananjay Balan
  2017-01-17  8:27 ` Dan Carpenter
  0 siblings, 1 reply; 7+ messages in thread
From: Dhananjay Balan @ 2017-01-17  8:11 UTC (permalink / raw)
  To: Stuart Yoder, Greg Kroah-Hartman; +Cc: devel, linux-kernel

Split line at boolean operator.

Error was reported by checkpatch.pl as
WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'

Signed-off-by: Dhananjay Balan <dhananjay@cliqz.com>
---
 drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
index 6b1cd57..6b19a21 100644
--- a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
+++ b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
@@ -94,8 +94,8 @@ int __init its_fsl_mc_msi_init(void)
 			continue;
 		}
 
-		WARN_ON(mc_msi_domain->
-				host_data != &its_fsl_mc_msi_domain_info);
+		WARN_ON(mc_msi_domain->host_data !=
+						&its_fsl_mc_msi_domain_info);
 
 		pr_info("fsl-mc MSI: %s domain created\n", np->full_name);
 	}
-- 
2.7.4

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

* Re: [PATCH] staging: fsl-mc: fix coding stye errors
  2017-01-17  8:11 [PATCH] staging: fsl-mc: fix coding stye errors Dhananjay Balan
@ 2017-01-17  8:27 ` Dan Carpenter
  2017-01-17  8:47   ` Joe Perches
  0 siblings, 1 reply; 7+ messages in thread
From: Dan Carpenter @ 2017-01-17  8:27 UTC (permalink / raw)
  To: Dhananjay Balan; +Cc: Stuart Yoder, Greg Kroah-Hartman, devel, linux-kernel

On Tue, Jan 17, 2017 at 09:11:28AM +0100, Dhananjay Balan wrote:
> Split line at boolean operator.
> 
> Error was reported by checkpatch.pl as
> WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'
> 
> Signed-off-by: Dhananjay Balan <dhananjay@cliqz.com>
> ---
>  drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
> index 6b1cd57..6b19a21 100644
> --- a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
> +++ b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
> @@ -94,8 +94,8 @@ int __init its_fsl_mc_msi_init(void)
>  			continue;
>  		}
>  
> -		WARN_ON(mc_msi_domain->
> -				host_data != &its_fsl_mc_msi_domain_info);
> +		WARN_ON(mc_msi_domain->host_data !=
> +						&its_fsl_mc_msi_domain_info);

Better to line it up like this:

		WARN_ON(mc_msi_domain->host_data !=
			&its_fsl_mc_msi_domain_info);

regards,
dan carpenter

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

* Re: [PATCH] staging: fsl-mc: fix coding stye errors
  2017-01-17  8:27 ` Dan Carpenter
@ 2017-01-17  8:47   ` Joe Perches
  2017-01-17 10:00     ` Dan Carpenter
  0 siblings, 1 reply; 7+ messages in thread
From: Joe Perches @ 2017-01-17  8:47 UTC (permalink / raw)
  To: Dan Carpenter, Dhananjay Balan
  Cc: Stuart Yoder, Greg Kroah-Hartman, devel, linux-kernel

On Tue, 2017-01-17 at 11:27 +0300, Dan Carpenter wrote:
> On Tue, Jan 17, 2017 at 09:11:28AM +0100, Dhananjay Balan wrote:
> > Split line at boolean operator.
> > 
> > Error was reported by checkpatch.pl as
> > WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'
[]
> > diff --git a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
[]
> > @@ -94,8 +94,8 @@ int __init its_fsl_mc_msi_init(void)
> >  			continue;
> >  		}
> >  
> > -		WARN_ON(mc_msi_domain->
> > -				host_data != &its_fsl_mc_msi_domain_info);
> > +		WARN_ON(mc_msi_domain->host_data !=
> > +						&its_fsl_mc_msi_domain_info);
> 
> Better to line it up like this:
> 
> 		WARN_ON(mc_msi_domain->host_data !=
> 			&its_fsl_mc_msi_domain_info);

At 81 chars, it might be better on a single line instead.

		WARN_ON(mc_msi_domain->host_data != &its_fsl_mc_msi_domain_info);

It also might be better to shorten some of the identifiers.

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

* Re: [PATCH] staging: fsl-mc: fix coding stye errors
  2017-01-17  8:47   ` Joe Perches
@ 2017-01-17 10:00     ` Dan Carpenter
  2017-01-18 10:53       ` [PATCH v2] " Dhananjay Balan
  0 siblings, 1 reply; 7+ messages in thread
From: Dan Carpenter @ 2017-01-17 10:00 UTC (permalink / raw)
  To: Joe Perches
  Cc: Dhananjay Balan, Stuart Yoder, Greg Kroah-Hartman, devel, linux-kernel

On Tue, Jan 17, 2017 at 12:47:30AM -0800, Joe Perches wrote:
> On Tue, 2017-01-17 at 11:27 +0300, Dan Carpenter wrote:
> > On Tue, Jan 17, 2017 at 09:11:28AM +0100, Dhananjay Balan wrote:
> > > Split line at boolean operator.
> > > 
> > > Error was reported by checkpatch.pl as
> > > WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'
> []
> > > diff --git a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
> []
> > > @@ -94,8 +94,8 @@ int __init its_fsl_mc_msi_init(void)
> > >  			continue;
> > >  		}
> > >  
> > > -		WARN_ON(mc_msi_domain->
> > > -				host_data != &its_fsl_mc_msi_domain_info);
> > > +		WARN_ON(mc_msi_domain->host_data !=
> > > +						&its_fsl_mc_msi_domain_info);
> > 
> > Better to line it up like this:
> > 
> > 		WARN_ON(mc_msi_domain->host_data !=
> > 			&its_fsl_mc_msi_domain_info);
> 
> At 81 chars, it might be better on a single line instead.
> 

Yeah.  Except you can't fight checkpatch.pl...  In the long run it will
just wear you down for no good reason.

> 		WARN_ON(mc_msi_domain->host_data != &its_fsl_mc_msi_domain_info);
> 
> It also might be better to shorten some of the identifiers.

Yeah.  Shorter names are a great idea.  This driver went a bit crazy
with all the prefixes.  It's a static variable.

regards,
dan carpenter

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

* [PATCH v2] staging: fsl-mc: fix coding stye errors
  2017-01-17 10:00     ` Dan Carpenter
@ 2017-01-18 10:53       ` Dhananjay Balan
  2017-01-18 11:14         ` Greg KH
  2017-01-18 17:20         ` Greg KH
  0 siblings, 2 replies; 7+ messages in thread
From: Dhananjay Balan @ 2017-01-18 10:53 UTC (permalink / raw)
  To: dan.carpenter
  Cc: joe, stuart.yoder, gregkh, devel, linux-kernel, Dhananjay Balan

Split line at boolean operator.

Error was reported by checkpatch.pl as
WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'

Signed-off-by: Dhananjay Balan <dhananjay@cliqz.com>
---
 drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
index 6b1cd57..7a402eb 100644
--- a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
+++ b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
@@ -94,8 +94,8 @@ int __init its_fsl_mc_msi_init(void)
 			continue;
 		}
 
-		WARN_ON(mc_msi_domain->
-				host_data != &its_fsl_mc_msi_domain_info);
+		WARN_ON(mc_msi_domain->host_data !=
+			&its_fsl_mc_msi_domain_info);
 
 		pr_info("fsl-mc MSI: %s domain created\n", np->full_name);
 	}
-- 
2.7.4

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

* Re: [PATCH v2] staging: fsl-mc: fix coding stye errors
  2017-01-18 10:53       ` [PATCH v2] " Dhananjay Balan
@ 2017-01-18 11:14         ` Greg KH
  2017-01-18 17:20         ` Greg KH
  1 sibling, 0 replies; 7+ messages in thread
From: Greg KH @ 2017-01-18 11:14 UTC (permalink / raw)
  To: Dhananjay Balan; +Cc: dan.carpenter, joe, stuart.yoder, devel, linux-kernel

On Wed, Jan 18, 2017 at 11:53:07AM +0100, Dhananjay Balan wrote:
> Split line at boolean operator.
> 
> Error was reported by checkpatch.pl as
> WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'
> 
> Signed-off-by: Dhananjay Balan <dhananjay@cliqz.com>
> ---
>  drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

What changed from v1?  Always put that information below the --- line.

Please try again with v3.

thanks,

greg k-h

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

* Re: [PATCH v2] staging: fsl-mc: fix coding stye errors
  2017-01-18 10:53       ` [PATCH v2] " Dhananjay Balan
  2017-01-18 11:14         ` Greg KH
@ 2017-01-18 17:20         ` Greg KH
  1 sibling, 0 replies; 7+ messages in thread
From: Greg KH @ 2017-01-18 17:20 UTC (permalink / raw)
  To: Dhananjay Balan; +Cc: dan.carpenter, devel, stuart.yoder, linux-kernel, joe

On Wed, Jan 18, 2017 at 11:53:07AM +0100, Dhananjay Balan wrote:
> Split line at boolean operator.
> 
> Error was reported by checkpatch.pl as
> WARNING: Avoid multiple line dereference - prefer 'mc_msi_domain->host_data'
> 
> Signed-off-by: Dhananjay Balan <dhananjay@cliqz.com>
> ---
>  drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

What changed in v2?  That has to go below the --- line.  Please fix it
up and resend v3 with that information and read
Documentation/SubmittingPatches for all of the details about this.

thanks,

greg k-h

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

end of thread, other threads:[~2017-01-18 17:28 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-17  8:11 [PATCH] staging: fsl-mc: fix coding stye errors Dhananjay Balan
2017-01-17  8:27 ` Dan Carpenter
2017-01-17  8:47   ` Joe Perches
2017-01-17 10:00     ` Dan Carpenter
2017-01-18 10:53       ` [PATCH v2] " Dhananjay Balan
2017-01-18 11:14         ` Greg KH
2017-01-18 17:20         ` Greg KH

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.