Netdev Archive on lore.kernel.org
help / color / mirror / Atom feed
From: "Ramamurthy, Harshitha" <harshitha.ramamurthy@intel.com>
To: Daniel Borkmann <daniel@iogearbox.net>,
	"bpf@vger.kernel.org" <bpf@vger.kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"ast@kernel.org" <ast@kernel.org>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"kuba@kernel.org" <kuba@kernel.org>
Cc: "dsahern@gmail.com" <dsahern@gmail.com>,
	"Duyck, Alexander H" <alexander.h.duyck@intel.com>,
	"Herbert, Tom" <tom.herbert@intel.com>
Subject: RE: [PATCH bpf-next] bpf: add bpf_get_xdp_hash helper function
Date: Wed, 2 Sep 2020 00:54:38 +0000	[thread overview]
Message-ID: <MW3PR11MB45225675894AFEE20F52BE7E852F0@MW3PR11MB4522.namprd11.prod.outlook.com> (raw)
In-Reply-To: <0333522d-7b65-e665-f19e-d36d11bd7846@iogearbox.net>

> From: Daniel Borkmann <daniel@iogearbox.net>
> Sent: Monday, August 31, 2020 1:33 PM
> To: Ramamurthy, Harshitha <harshitha.ramamurthy@intel.com>;
> bpf@vger.kernel.org; netdev@vger.kernel.org; ast@kernel.org;
> davem@davemloft.net; kuba@kernel.org
> Cc: dsahern@gmail.com; Duyck, Alexander H
> <alexander.h.duyck@intel.com>; Herbert, Tom <tom.herbert@intel.com>
> Subject: Re: [PATCH bpf-next] bpf: add bpf_get_xdp_hash helper function
> 
> On 8/31/20 9:25 PM, Harshitha Ramamurthy wrote:
> > This patch adds a helper function called bpf_get_xdp_hash to calculate
> > the hash for a packet at the XDP layer. In the helper function, we
> > call the kernel flow dissector in non-skb mode by passing the net
> > pointer to calculate the hash.
> 
> So this commit msg says 'what' the patch does, but says nothing about 'why'
> it is needed especially given there's the 1 mio insn limit in place where it
> should be easy to write that up in BPF anyway. The commit msg needs to
> have a clear rationale which describes the motivation behind this helper..
> why it cannot be done in BPF itself?

Okay, will add a rationale in the commit message in the next version for use-case. 

Thanks,
Harshitha
> 
> > Changes since RFC:
> > - accounted for vlans(David Ahern)
> > - return the correct hash by not using skb_get_hash(David Ahern)
> > - call __skb_flow_dissect in non-skb mode
> >

  reply	other threads:[~2020-09-02  0:54 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-31 19:25 Harshitha Ramamurthy
2020-08-31 19:54 ` David Ahern
2020-09-02  0:52   ` Ramamurthy, Harshitha
2020-09-02  2:09     ` David Ahern
2020-08-31 20:33 ` Daniel Borkmann
2020-09-02  0:54   ` Ramamurthy, Harshitha [this message]
2020-09-02 15:56   ` Tom Herbert

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=MW3PR11MB45225675894AFEE20F52BE7E852F0@MW3PR11MB4522.namprd11.prod.outlook.com \
    --to=harshitha.ramamurthy@intel.com \
    --cc=alexander.h.duyck@intel.com \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=dsahern@gmail.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=tom.herbert@intel.com \
    --subject='RE: [PATCH bpf-next] bpf: add bpf_get_xdp_hash helper function' \
    /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

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).