[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <493E81F3.60800@trash.net>
Date: Tue, 09 Dec 2008 15:34:27 +0100
From: Patrick McHardy <kaber@...sh.net>
To: Sathya Perla <sathyap@...verengines.com>
CC: netdev <netdev@...r.kernel.org>, jgarzik@...ox.com,
jeff@...zik.org, subbu <subbus@...verengines.com>
Subject: Re: [PATCH 02/11] benet: interrupt/i/o handling, network layer i/f
and ethtool functions
Sathya Perla wrote:
> +/*
> + * This is the driver entry point to add a vlan vlan_id
> + * with the device netdev
> + */
> +static void benet_vlan_add_vid(struct net_device *netdev, u16 vlan_id)
> +{
> + struct be_net_object *pnob = netdev->priv;
> +
> + if (pnob->num_vlans == (BE_NUM_VLAN_SUPPORTED - 1)) {
> + /* no way to return an error */
> + dev_info(&netdev->dev,
> + "BladeEngine: Cannot configure more than %d Vlans\n",
> + BE_NUM_VLAN_SUPPORTED);
> + return;
I'd suggest to either make ->vlan_add_vid() return an error code
or disable VLAN hardware filtering completely when you exceed the
number of supported VLANs. The later is probably the better choice
since people expect to be able to add any number of VLANs.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists