From: John Fastabend <john.fastabend@gmail.com>
To: intel-wired-lan@osuosl.org
Subject: [Intel-wired-lan] [net-next PATCH v4 1/2] ethtool: Add helper routines to pass vf to rx_flow_spec
Date: Tue, 26 May 2015 08:21:53 -0700 [thread overview]
Message-ID: <55648F91.6060902@gmail.com> (raw)
In-Reply-To: <20150518161847.8927.65430.stgit@nitbit.x32>
On 05/18/2015 09:18 AM, John Fastabend wrote:
> The ring_cookie is 64 bits wide which is much larger than can be used
> for actual queue index values. So provide some helper routines to
> pack a VF index into the cookie. This is useful to steer packets to
> a VF ring without having to know the queue layout of the device.
>
> Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
> ---
> include/uapi/linux/ethtool.h | 25 +++++++++++++++++++++++++
> 1 file changed, 25 insertions(+)
>
> diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h
> index 2e49fc8..b5b4287 100644
> --- a/include/uapi/linux/ethtool.h
> +++ b/include/uapi/linux/ethtool.h
> @@ -796,6 +796,31 @@ struct ethtool_rx_flow_spec {
> __u32 location;
> };
>
> +/* How rings are layed out when accessing virtual functions or
> + * offloaded queues is device specific. To allow users to do flow
> + * steering and specify these queues the ring cookie is partitioned
> + * into a 32bit queue index with an 8 bit virtual function id.
> + * This also leaves the 3bytes for further specifiers. It is possible
> + * future devices may support more than 256 virtual functions if
> + * devices start supporting PCIe w/ARI. However at the moment I
> + * do not know of any devices that support this so I do not reserve
> + * space for this at this time. If a future patch consumes the next
> + * byte it should be aware of this possiblity.
> + */
> +#define ETHTOOL_RX_FLOW_SPEC_RING 0x00000000FFFFFFFF
> +#define ETHTOOL_RX_FLOW_SPEC_RING_VF 0x000000FF00000000
This needs an LL,
+#define ETHTOOL_RX_FLOW_SPEC_RING 0x00000000FFFFFFFFLL
+#define ETHTOOL_RX_FLOW_SPEC_RING_VF 0x000000FF00000000LL
so I guess I'll have to send a v5.
Thanks,
John
--
John Fastabend Intel Corporation
prev parent reply other threads:[~2015-05-26 15:21 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-18 16:18 [Intel-wired-lan] [net-next PATCH v4 1/2] ethtool: Add helper routines to pass vf to rx_flow_spec John Fastabend
2015-05-18 16:19 ` [Intel-wired-lan] [net-next PATCH v4 2/2] ixgbe: Allow flow director to use entire queue space John Fastabend
2015-05-22 23:34 ` Singh, Krishneil K
2015-05-22 23:33 ` [Intel-wired-lan] [net-next PATCH v4 1/2] ethtool: Add helper routines to pass vf to rx_flow_spec Singh, Krishneil K
2015-05-26 15:21 ` John Fastabend [this message]
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=55648F91.6060902@gmail.com \
--to=john.fastabend@gmail.com \
--cc=intel-wired-lan@osuosl.org \
/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