netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
To: David Awogbemila <awogbemila@google.com>
Cc: Saeed Mahameed <saeed@kernel.org>,
	Netdev <netdev@vger.kernel.org>,
	Catherine Sullivan <csully@google.com>,
	Yangchun Fu <yangchun@google.com>
Subject: Re: [PATCH net-next v7 1/4] gve: Add support for raw addressing device option
Date: Fri, 20 Nov 2020 03:01:40 +0100	[thread overview]
Message-ID: <20201120020140.GA26162@ranger.igk.intel.com> (raw)
In-Reply-To: <CAL9ddJf1bPH2na9x6G7q22Jk-e_R7gP=yEVTe9y6vzrmnuRm6Q@mail.gmail.com>

On Thu, Nov 19, 2020 at 04:22:24PM -0800, David Awogbemila wrote:
> On Thu, Nov 19, 2020 at 12:21 PM Saeed Mahameed <saeed@kernel.org> wrote:
> >
> > On Wed, 2020-11-18 at 15:20 -0800, David Awogbemila wrote:
> > > From: Catherine Sullivan <csully@google.com>
> > >
> > > Add support to describe device for parsing device options. As
> > > the first device option, add raw addressing.
> > >
> > > "Raw Addressing" mode (as opposed to the current "qpl" mode) is an
> > > operational mode which allows the driver avoid bounce buffer copies
> > > which it currently performs using pre-allocated qpls
> > > (queue_page_lists)
> > > when sending and receiving packets.
> > > For egress packets, the provided skb data addresses will be
> > > dma_map'ed and
> > > passed to the device, allowing the NIC can perform DMA directly - the
> > > driver will not have to copy the buffer content into pre-allocated
> > > buffers/qpls (as in qpl mode).
> > > For ingress packets, copies are also eliminated as buffers are handed
> > > to
> > > the networking stack and then recycled or re-allocated as
> > > necessary, avoiding the use of skb_copy_to_linear_data().
> > >
> > > This patch only introduces the option to the driver.
> > > Subsequent patches will add the ingress and egress functionality.
> > >
> > > Reviewed-by: Yangchun Fu <yangchun@google.com>
> > > Signed-off-by: Catherine Sullivan <csully@google.com>
> > > Signed-off-by: David Awogbemila <awogbemila@google.com>
> > > ---
> > >
> > ...
> > > diff --git a/drivers/net/ethernet/google/gve/gve_adminq.c
> > > b/drivers/net/ethernet/google/gve/gve_adminq.c
> > > index 24ae6a28a806..1e2d407cb9d2 100644
> > > --- a/drivers/net/ethernet/google/gve/gve_adminq.c
> > > +++ b/drivers/net/ethernet/google/gve/gve_adminq.c
> > > @@ -14,6 +14,57 @@
> > >  #define GVE_ADMINQ_SLEEP_LEN         20
> > >  #define GVE_MAX_ADMINQ_EVENT_COUNTER_CHECK   100
> > >
> > > +#define GVE_DEVICE_OPTION_ERROR_FMT "%s option error:\n" \
> > > +"Expected: length=%d, feature_mask=%x.\n" \
> > > +"Actual: length=%d, feature_mask=%x.\n"
> > > +
> > > +static inline
> > > +struct gve_device_option *gve_get_next_option(struct
> > >
> >
> > Following Dave's policy, no static inline functions in C files.
> > This is control path so you don't really need the inline here.
> 
> Okay, I'll move it to a header file.

That's not what Saeed meant I suppose. Policy says that we let the
compiler to make the decision whether or not such static function should
be inlined. And since it's not a performance critical path as Saeed says
then drop the inline and keep the rest as-is.

> 
> >
> >
> >

  reply	other threads:[~2020-11-20  2:10 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-18 23:20 [PATCH net-next v7 0/4] GVE Raw Addressing David Awogbemila
2020-11-18 23:20 ` [PATCH net-next v7 1/4] gve: Add support for raw addressing device option David Awogbemila
2020-11-19 20:21   ` Saeed Mahameed
2020-11-20  0:22     ` David Awogbemila
2020-11-20  2:01       ` Maciej Fijalkowski [this message]
2020-11-20  5:07         ` David Awogbemila
2020-11-18 23:20 ` [PATCH net-next v7 2/4] gve: Add support for raw addressing to the rx path David Awogbemila
2020-11-18 23:20 ` [PATCH net-next v7 3/4] gve: Rx Buffer Recycling David Awogbemila
2020-11-18 23:20 ` [PATCH net-next v7 4/4] gve: Add support for raw addressing in the tx path David Awogbemila
2020-11-19 16:48 ` [PATCH net-next v7 0/4] GVE Raw Addressing Jakub Kicinski
2020-11-19 16:56 ` Alexander Duyck

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=20201120020140.GA26162@ranger.igk.intel.com \
    --to=maciej.fijalkowski@intel.com \
    --cc=awogbemila@google.com \
    --cc=csully@google.com \
    --cc=netdev@vger.kernel.org \
    --cc=saeed@kernel.org \
    --cc=yangchun@google.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).