[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1342705789.2617.15.camel@bwh-desktop.uk.solarflarecom.com>
Date: Thu, 19 Jul 2012 14:49:49 +0100
From: Ben Hutchings <bhutchings@...arflare.com>
To: Or Gerlitz <ogerlitz@...lanox.com>
CC: <davem@...emloft.net>, <roland@...nel.org>,
<netdev@...r.kernel.org>, <ali@...lanox.com>,
<sean.hefty@...el.com>, <shlomop@...lanox.com>,
Erez Shitrit <erezsh@...lanox.co.il>
Subject: Re: [PATCH net-next V1 7/9] net/eipoib: Add main driver
functionality
On Wed, 2012-07-18 at 14:00 +0300, Or Gerlitz wrote:
[...]
> +/* ----------------------------- VLAN funcs ---------------------------------- */
> +static int eth_ipoib_vlan_rx_add_vid(struct net_device *dev,
> + unsigned short vid)
> +{
> + return 0;
> +}
> +
> +static int eth_ipoib_vlan_rx_kill_vid(struct net_device *dev,
> + unsigned short vid)
> +{
> + return 0;
> +}
[...]
> +/* -------------------------- Device entry points --------------------------- */
> +static struct net_device_stats *parent_get_stats(struct net_device *parent_dev)
> +{
[...]
> +static const struct net_device_ops parent_netdev_ops = {
> + .ndo_init = parent_init,
> + .ndo_uninit = parent_uninit,
> + .ndo_open = parent_open,
> + .ndo_stop = parent_close,
> + .ndo_start_xmit = parent_tx,
> + .ndo_select_queue = parent_select_q,
> + /* parnt mtu is min(slaves_mtus) */
> + .ndo_change_mtu = NULL,
> + .ndo_fix_features = parent_fix_features,
> + /*
> + * initial mac address is randomized, can be changed
> + * thru this func later
> + */
> + .ndo_set_mac_address = eth_mac_addr,
> + .ndo_get_stats = parent_get_stats,
Why not implement ndo_get_stats64? I don't think there's any good
reason for a new driver not to.
> + .ndo_vlan_rx_add_vid = eth_ipoib_vlan_rx_add_vid,
> + .ndo_vlan_rx_kill_vid = eth_ipoib_vlan_rx_kill_vid,
These shouldn't be needed.
[...]
> +/* netdev events handlers */
> +static inline int is_ipoib_pif_intf(struct net_device *dev)
> +{
> + if (ARPHRD_INFINIBAND == dev->type && dev->priv_flags & IFF_EIPOIB_PIF)
> + return 1;
[...]
Wrong indentation.
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.
--
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