public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Ben Hutchings <bhutchings@solarflare.com>
To: Ajit Khaparde <ajit.khaparde@emulex.com>
Cc: <davem@davemloft.net>, <shemminger@linux-foundation.org>,
	<netdev@vger.kernel.org>
Subject: Re: [RFC net-next 1/2] if_link : add support for VF privileges
Date: Tue, 14 Feb 2012 23:24:57 +0000	[thread overview]
Message-ID: <1329261897.2443.60.camel@bwh-desktop> (raw)
In-Reply-To: <20120214192627.GA14163@akhaparde-VBox>

On Tue, 2012-02-14 at 13:26 -0600, Ajit Khaparde wrote:
> Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com>
> ---
>  include/linux/if_link.h   |   21 +++++++++++++++++++++
>  include/linux/netdevice.h |    3 +++
>  net/core/rtnetlink.c      |   17 ++++++++++++++++-
>  3 files changed, 40 insertions(+), 1 deletions(-)
> 
> diff --git a/include/linux/if_link.h b/include/linux/if_link.h
> index c52d4b5..9c93a8e 100644
> --- a/include/linux/if_link.h
> +++ b/include/linux/if_link.h
> @@ -280,11 +280,26 @@ enum {
>  	IFLA_VF_VLAN,
>  	IFLA_VF_TX_RATE,	/* TX Bandwidth Allocation */
>  	IFLA_VF_SPOOFCHK,	/* Spoof Checking on/off switch */
> +	IFLA_VF_PRIVILEGE,	/* VF Privilege level setting */
>  	__IFLA_VF_MAX,
>  };
>  
>  #define IFLA_VF_MAX (__IFLA_VF_MAX - 1)
>  
> +enum {
> +	IFLA_VF_PRIVILEGE_DEFAULT = 1,	/* Default privileges */

What are the default privileges?  Should existing drivers report that
their VFs have this?

> +	IFLA_VF_PRIVILEGE_STATS	= 2,	/* Privilege to gather statistics */

I assume that means port or board statistics as opposed to statistics
for the VF?

> +	IFLA_VF_PRIVILEGE_LNK_MGMT = 4,	/* Privilege to manage link params */
> +	IFLA_VF_PRIVILEGE_DIAG	= 8,	/* Privilege to perform diagnostics */
> +	IFLA_VF_PRIVILEGE_MAC	= 16,	/* Privilege to modify MAC address */
> +	IFLA_VF_PRIVILEGE_VLAN	= 32,	/* Privilege to add or remove VLANs */

I assume these two apply to RX filtering of the VF itself.  How about
control over TX filtering?

> +	IFLA_VF_PRIVILEGE_DEV_CFG = 64,	/* Unrestricted admin access privlege */

Does that include all the other privileges, or does it mean 'everything
else'?

> +	IFLA_VF_PRIVILEGE_SECURE = 128,	/* Privilege to access secure content */

What does that mean?

> +	__IFLA_VF_PRIVILEGE_MAX,
> +};
> +
> +#define IFLA_VF_PRIVILEGE_MAX (__IFLA_VF_PRIVILEGE_MAX - 1)
[...]

This doesn't seem to make sense for an enumeration of flags.

Ben.

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

  reply	other threads:[~2012-02-14 23:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-14 19:26 [RFC net-next 1/2] if_link : add support for VF privileges Ajit Khaparde
2012-02-14 23:24 ` Ben Hutchings [this message]
2012-02-21 22:02   ` Ajit.Khaparde
2012-02-21 22:04     ` David Miller
2012-02-21 22:43       ` Ben Hutchings
2012-03-01 18:54         ` Ajit.Khaparde
2012-03-01 18:53       ` Ajit.Khaparde

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=1329261897.2443.60.camel@bwh-desktop \
    --to=bhutchings@solarflare.com \
    --cc=ajit.khaparde@emulex.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=shemminger@linux-foundation.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