All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: vt6655: Break up function call with long line.
@ 2020-03-24  2:06 Briana Oursler
  2020-03-24 11:35 ` Greg KH
  0 siblings, 1 reply; 6+ messages in thread
From: Briana Oursler @ 2020-03-24  2:06 UTC (permalink / raw)
  To: gregkh, forest, outreachy-kernel; +Cc: Briana Oursler

Update matches style found elsewhere in file.
Issue found by checkpatch: line over 80 characters.

Signed-off-by: Briana Oursler <briana.oursler@gmail.com>
---
 drivers/staging/vt6655/device_main.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
index 0442f71494b2..b28f3b28849b 100644
--- a/drivers/staging/vt6655/device_main.c
+++ b/drivers/staging/vt6655/device_main.c
@@ -443,7 +443,10 @@ static bool device_init_rings(struct vnt_private *priv)
 
 	/*allocate all RD/TD rings a single pool*/
 	vir_pool = dma_alloc_coherent(&priv->pcid->dev,
-				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc) + priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc) + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc) + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
+				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc)
+				      + priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc)
+				      + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc)
+				      + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
 				      &priv->pool_dma, GFP_ATOMIC);
 	if (!vir_pool) {
 		dev_err(&priv->pcid->dev, "allocate desc dma memory failed\n");
-- 
2.24.1



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

* Re: [PATCH] staging: vt6655: Break up function call with long line.
  2020-03-24  2:06 [PATCH] staging: vt6655: Break up function call with long line Briana Oursler
@ 2020-03-24 11:35 ` Greg KH
  2020-03-24 18:38   ` [PATCH v2] " Briana Oursler
  0 siblings, 1 reply; 6+ messages in thread
From: Greg KH @ 2020-03-24 11:35 UTC (permalink / raw)
  To: Briana Oursler; +Cc: forest, outreachy-kernel

On Mon, Mar 23, 2020 at 07:06:19PM -0700, Briana Oursler wrote:
> Update matches style found elsewhere in file.
> Issue found by checkpatch: line over 80 characters.
> 
> Signed-off-by: Briana Oursler <briana.oursler@gmail.com>
> ---
>  drivers/staging/vt6655/device_main.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
> index 0442f71494b2..b28f3b28849b 100644
> --- a/drivers/staging/vt6655/device_main.c
> +++ b/drivers/staging/vt6655/device_main.c
> @@ -443,7 +443,10 @@ static bool device_init_rings(struct vnt_private *priv)
>  
>  	/*allocate all RD/TD rings a single pool*/
>  	vir_pool = dma_alloc_coherent(&priv->pcid->dev,
> -				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc) + priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc) + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc) + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
> +				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc)
> +				      + priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc)
> +				      + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc)
> +				      + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),

The "+" should go on the end of the line, not the front of the line.

thanks,

greg k-h


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

* [PATCH v2] staging: vt6655: Break up function call with long line.
  2020-03-24 11:35 ` Greg KH
@ 2020-03-24 18:38   ` Briana Oursler
  2020-03-30  1:02     ` [Outreachy kernel] " Stefano Brivio
  0 siblings, 1 reply; 6+ messages in thread
From: Briana Oursler @ 2020-03-24 18:38 UTC (permalink / raw)
  To: gregkh, forest, outreachy-kernel; +Cc: Briana Oursler

Update matches style found elsewhere in file.
Issue found by checkpatch: line over 80 characters.

Signed-off-by: Briana Oursler <briana.oursler@gmail.com>
---
 Changes in v2:
	- Move '+' operator to end of line.

 drivers/staging/vt6655/device_main.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
index 0442f71494b2..5c86cc60eb5c 100644
--- a/drivers/staging/vt6655/device_main.c
+++ b/drivers/staging/vt6655/device_main.c
@@ -443,7 +443,10 @@ static bool device_init_rings(struct vnt_private *priv)
 
 	/*allocate all RD/TD rings a single pool*/
 	vir_pool = dma_alloc_coherent(&priv->pcid->dev,
-				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc) + priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc) + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc) + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
+				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc) +
+				      priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc) +
+				      priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc) +
+				      priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
 				      &priv->pool_dma, GFP_ATOMIC);
 	if (!vir_pool) {
 		dev_err(&priv->pcid->dev, "allocate desc dma memory failed\n");
-- 
2.24.1



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

* Re: [Outreachy kernel] [PATCH v2] staging: vt6655: Break up function call with long line.
  2020-03-24 18:38   ` [PATCH v2] " Briana Oursler
@ 2020-03-30  1:02     ` Stefano Brivio
  2020-03-30  3:21       ` Briana Oursler
  0 siblings, 1 reply; 6+ messages in thread
From: Stefano Brivio @ 2020-03-30  1:02 UTC (permalink / raw)
  To: Briana Oursler; +Cc: gregkh, forest, outreachy-kernel

On Tue, 24 Mar 2020 11:38:12 -0700
Briana Oursler <briana.oursler@gmail.com> wrote:

> Update matches style found elsewhere in file.
> Issue found by checkpatch: line over 80 characters.
> 
> Signed-off-by: Briana Oursler <briana.oursler@gmail.com>
> ---
>  Changes in v2:
> 	- Move '+' operator to end of line.
> 
>  drivers/staging/vt6655/device_main.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
> index 0442f71494b2..5c86cc60eb5c 100644
> --- a/drivers/staging/vt6655/device_main.c
> +++ b/drivers/staging/vt6655/device_main.c
> @@ -443,7 +443,10 @@ static bool device_init_rings(struct vnt_private *priv)
>  
>  	/*allocate all RD/TD rings a single pool*/
>  	vir_pool = dma_alloc_coherent(&priv->pcid->dev,
> -				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc) + priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc) + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc) + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
> +				      priv->opts.rx_descs0 * sizeof(struct vnt_rx_desc) +
> +				      priv->opts.rx_descs1 * sizeof(struct vnt_rx_desc) +
> +				      priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc) +
> +				      priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),

Reviewed-by: Stefano Brivio <sbrivio@redhat.com>

Two notes:

- it's a bit unusual to post a new patch version as a reply of a
  comment to a previous version -- did you read about this somewhere?

- a * x + b * x = (a + b) * x

-- 
Stefano



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

* Re: [Outreachy kernel] [PATCH v2] staging: vt6655: Break up function call with long line.
  2020-03-30  1:02     ` [Outreachy kernel] " Stefano Brivio
@ 2020-03-30  3:21       ` Briana Oursler
  2020-03-30  6:24         ` Stefano Brivio
  0 siblings, 1 reply; 6+ messages in thread
From: Briana Oursler @ 2020-03-30  3:21 UTC (permalink / raw)
  To: Stefano Brivio; +Cc: gregkh, forest, outreachy-kernel

On Mon, 2020-03-30 at 03:02 +0200, Stefano Brivio wrote:
> On Tue, 24 Mar 2020 11:38:12 -0700
> Briana Oursler <briana.oursler@gmail.com> wrote:
> 
> > Update matches style found elsewhere in file.
> > Issue found by checkpatch: line over 80 characters.
> > 
> > Signed-off-by: Briana Oursler <briana.oursler@gmail.com>
> > ---
> >  Changes in v2:
> > 	- Move '+' operator to end of line.
> > 
> >  drivers/staging/vt6655/device_main.c | 5 ++++-
> >  1 file changed, 4 insertions(+), 1 deletion(-)
> > 
> > diff --git a/drivers/staging/vt6655/device_main.c
> > b/drivers/staging/vt6655/device_main.c
> > index 0442f71494b2..5c86cc60eb5c 100644
> > --- a/drivers/staging/vt6655/device_main.c
> > +++ b/drivers/staging/vt6655/device_main.c
> > @@ -443,7 +443,10 @@ static bool device_init_rings(struct
> > vnt_private *priv)
> >  
> >  	/*allocate all RD/TD rings a single pool*/
> >  	vir_pool = dma_alloc_coherent(&priv->pcid->dev,
> > -				      priv->opts.rx_descs0 *
> > sizeof(struct vnt_rx_desc) + priv->opts.rx_descs1 * sizeof(struct
> > vnt_rx_desc) + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc)
> > + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
> > +				      priv->opts.rx_descs0 *
> > sizeof(struct vnt_rx_desc) +
> > +				      priv->opts.rx_descs1 *
> > sizeof(struct vnt_rx_desc) +
> > +				      priv->opts.tx_descs[0] *
> > sizeof(struct vnt_tx_desc) +
> > +				      priv->opts.tx_descs[1] *
> > sizeof(struct vnt_tx_desc),
> 
> Reviewed-by: Stefano Brivio <sbrivio@redhat.com>
> 
> Two notes:
> 
> - it's a bit unusual to post a new patch version as a reply of a
>   comment to a previous version -- did you read about this somewhere?

I think I basically misunderstood the normal use case of 'in-reply-to'. 
Rereading that section of the first patch tutorial, I definitely
misread it. I've been resending all my patches as replies. I'll change
that up.

> 
> - a * x + b * x = (a + b) * x

Wow, yes. I will try to think more critically about context, it seems
so obvious now. Should I update it, or is it too late in the process?
Is there a 'too late'? Thank you,

-- Briana
> 




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

* Re: [Outreachy kernel] [PATCH v2] staging: vt6655: Break up function call with long line.
  2020-03-30  3:21       ` Briana Oursler
@ 2020-03-30  6:24         ` Stefano Brivio
  0 siblings, 0 replies; 6+ messages in thread
From: Stefano Brivio @ 2020-03-30  6:24 UTC (permalink / raw)
  To: Briana Oursler; +Cc: gregkh, forest, outreachy-kernel

On Sun, 29 Mar 2020 20:21:24 -0700
Briana Oursler <briana.oursler@gmail.com> wrote:

> On Mon, 2020-03-30 at 03:02 +0200, Stefano Brivio wrote:
> > On Tue, 24 Mar 2020 11:38:12 -0700
> > Briana Oursler <briana.oursler@gmail.com> wrote:
> >   
> > > Update matches style found elsewhere in file.
> > > Issue found by checkpatch: line over 80 characters.
> > > 
> > > Signed-off-by: Briana Oursler <briana.oursler@gmail.com>
> > > ---
> > >  Changes in v2:
> > > 	- Move '+' operator to end of line.
> > > 
> > >  drivers/staging/vt6655/device_main.c | 5 ++++-
> > >  1 file changed, 4 insertions(+), 1 deletion(-)
> > > 
> > > diff --git a/drivers/staging/vt6655/device_main.c
> > > b/drivers/staging/vt6655/device_main.c
> > > index 0442f71494b2..5c86cc60eb5c 100644
> > > --- a/drivers/staging/vt6655/device_main.c
> > > +++ b/drivers/staging/vt6655/device_main.c
> > > @@ -443,7 +443,10 @@ static bool device_init_rings(struct
> > > vnt_private *priv)
> > >  
> > >  	/*allocate all RD/TD rings a single pool*/
> > >  	vir_pool = dma_alloc_coherent(&priv->pcid->dev,
> > > -				      priv->opts.rx_descs0 *
> > > sizeof(struct vnt_rx_desc) + priv->opts.rx_descs1 * sizeof(struct
> > > vnt_rx_desc) + priv->opts.tx_descs[0] * sizeof(struct vnt_tx_desc)
> > > + priv->opts.tx_descs[1] * sizeof(struct vnt_tx_desc),
> > > +				      priv->opts.rx_descs0 *
> > > sizeof(struct vnt_rx_desc) +
> > > +				      priv->opts.rx_descs1 *
> > > sizeof(struct vnt_rx_desc) +
> > > +				      priv->opts.tx_descs[0] *
> > > sizeof(struct vnt_tx_desc) +
> > > +				      priv->opts.tx_descs[1] *
> > > sizeof(struct vnt_tx_desc),  
> > 
> > Reviewed-by: Stefano Brivio <sbrivio@redhat.com>
> > 
> > Two notes:
> > 
> > - it's a bit unusual to post a new patch version as a reply of a
> >   comment to a previous version -- did you read about this somewhere?  
> 
> I think I basically misunderstood the normal use case of 'in-reply-to'. 
> Rereading that section of the first patch tutorial, I definitely
> misread it. I've been resending all my patches as replies. I'll change
> that up.

Ah, I see now. By the way, you can also refer to
Documentation/process/submitting-patches.rst -- it might be more
explanatory than the first patch tutorial. This, in particular, is
covered by section:

	15) Explicit In-Reply-To headers

> > - a * x + b * x = (a + b) * x  
> 
> Wow, yes. I will try to think more critically about context, it seems
> so obvious now. Should I update it, or is it too late in the process?

No, I don't think you should update it, your patch is fine, that might
be perceived as an unrelated change, and that's also why I gave my
Reviewed-by. I was just suggesting a further clean-up.

> Is there a 'too late'? Thank you,

If the maintainer has already merged your patch, well, it's "too late"
in the sense that you simply need to post another patch.

Ideally, you would update your copy of the git tree just before you
restart working on it. If it's not there, reply to your patch asking
for it to be discarded, proceed updating it and re-post. It might also
be that the maintainer has merged it in the meantime, in which case
they will tell you and you'll need to rebase.

If the patch is already there and you find a mistake, post a follow-up
with a Fixes: tag (see submitting-patches.rst for that).

-- 
Stefano



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

end of thread, other threads:[~2020-03-30  6:25 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-24  2:06 [PATCH] staging: vt6655: Break up function call with long line Briana Oursler
2020-03-24 11:35 ` Greg KH
2020-03-24 18:38   ` [PATCH v2] " Briana Oursler
2020-03-30  1:02     ` [Outreachy kernel] " Stefano Brivio
2020-03-30  3:21       ` Briana Oursler
2020-03-30  6:24         ` Stefano Brivio

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.