DPDK patches and discussions
 help / color / mirror / Atom feed
From: "David Harton (dharton)" <dharton@cisco.com>
To: "Wiles, Keith" <keith.wiles@intel.com>
Cc: "skhare@vmware.com" <skhare@vmware.com>, "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] vmxnet3: replenish ring buffers in rx processing
Date: Fri, 25 Aug 2017 15:51:42 +0000	[thread overview]
Message-ID: <70fc1a1c786b4643b55d2f24284b6d2b@XCH-RCD-016.cisco.com> (raw)
In-Reply-To: <6EECE57F-E22D-4513-B232-B97548EE4676@intel.com>



> -----Original Message-----
> From: Wiles, Keith [mailto:keith.wiles@intel.com]
> Sent: Friday, August 25, 2017 11:41 AM
> To: David Harton (dharton) <dharton@cisco.com>
> Cc: skhare@vmware.com; dev@dpdk.org
> Subject: Re: [dpdk-dev] [PATCH] vmxnet3: replenish ring buffers in rx
> processing
> 
> 
> > On Aug 25, 2017, at 10:22 AM, David Harton <dharton@cisco.com> wrote:
> >
> > vmxnet3 rx processing should replenish ring buffers after new buffers
> > are available to prevent the interface from getting stuck in a state
> > that no new work is processed.
> >
> > Signed-off-by: David Harton <dharton@cisco.com>
> > ---
> > drivers/net/vmxnet3/vmxnet3_rxtx.c | 17 +++++++++++++++++
> > 1 file changed, 17 insertions(+)
> >
> > diff --git a/drivers/net/vmxnet3/vmxnet3_rxtx.c
> > b/drivers/net/vmxnet3/vmxnet3_rxtx.c
> > index d9cf437..9861d35 100644
> > --- a/drivers/net/vmxnet3/vmxnet3_rxtx.c
> > +++ b/drivers/net/vmxnet3/vmxnet3_rxtx.c
> > @@ -880,6 +880,23 @@
> > 		}
> > 	}
> >
> > +	if (unlikely(nb_rxd == 0)) {
> > +		uint32_t avail;
> > +		for (ring_idx = 0; ring_idx < VMXNET3_RX_CMDRING_SIZE;
> ring_idx++) {
> > +			avail = vmxnet3_cmd_ring_desc_avail(&rxq-
> >cmd_ring[ring_idx]);
> > +			if (unlikely(avail > 0)) {
> > +				/* try to alloc new buf and renew descriptors */
> > +				vmxnet3_post_rx_bufs(rxq, ring_idx);
> > +			}
> > +		}
> > +		if (unlikely(rxq->shared->ctrl.updateRxProd)) {
> > +			for (ring_idx = 0; ring_idx < VMXNET3_RX_CMDRING_SIZE;
> ring_idx++) {
> > +				VMXNET3_WRITE_BAR0_REG(hw, rxprod_reg[ring_idx] +
> (rxq->queue_id
> > +* VMXNET3_REG_ALIGN),
> 
> Did you run checkpatch here as it seems the line length is greater then
> 80.

I did.  I'm following the conventions already established in the file.
Several lines above the file are > 80 characters.  In fact, some just a few lines above these diffs.

Are you asking me to deviate from the established code convention?

Thanks,
Dave

> 
> BTW, I think requirements of 80 and tab length of 8, is a bit outdated in
> 2017 :-(
> 
> > +						       rxq-
> >cmd_ring[ring_idx].next2fill);
> > +			}
> > +		}
> > +	}
> > +
> > 	return nb_rx;
> > }
> >
> > --
> > 1.8.3.1
> >
> 
> Regards,
> Keith

  reply	other threads:[~2017-08-25 15:51 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-25 15:22 David Harton
2017-08-25 15:41 ` Wiles, Keith
2017-08-25 15:51   ` David Harton (dharton) [this message]
2017-08-25 15:57     ` Wiles, Keith
2017-09-10 16:47 ` Shrikrishna Khare
2017-09-11 13:19   ` Ferruh Yigit

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=70fc1a1c786b4643b55d2f24284b6d2b@XCH-RCD-016.cisco.com \
    --to=dharton@cisco.com \
    --cc=dev@dpdk.org \
    --cc=keith.wiles@intel.com \
    --cc=skhare@vmware.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).