From: Or Gerlitz <ogerlitz@mellanox.com>
To: Ben Hutchings <bhutchings@solarflare.com>
Cc: <davem@davemloft.net>, <roland@kernel.org>,
<netdev@vger.kernel.org>, <ali@mellanox.com>,
<sean.hefty@intel.com>, <shlomop@mellanox.com>,
Erez Shitrit <erezsh@mellanox.co.il>
Subject: Re: [PATCH net-next V1 7/9] net/eipoib: Add main driver functionality
Date: Thu, 19 Jul 2012 18:46:38 +0300 [thread overview]
Message-ID: <50082BDE.2040005@mellanox.com> (raw)
In-Reply-To: <1342705789.2617.15.camel@bwh-desktop.uk.solarflarecom.com>
On 7/19/2012 4:49 PM, Ben Hutchings wrote:
> On Wed, 2012-07-18 at 14:00 +0300, Or Gerlitz wrote:
> +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.
Indeed, will do ndo_get_stats64
>
>
>> + .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.
ok, here's the point, the eIPoIB driver maps Ethernet vlans to
infiniband/IPoIB pkeys
(partition keys). The underlying IPoIB devices work with these pkeys
in a way which is HW accelerated, and we want the eIPoIB driver to be
considered as one
that support HW accelerate vlans. E.g on the TX flow we don't want that
any special SW
handling by the 8021q driver will be done on the skb except for setting
the skb->vlan_tci
field, and in the RX flow, we set skb->vlan_tci field and don't want
that 8021q to try
and extract it from the headers, etc.
For that end, I was under the impression all the three
NETIF_F_HW_VLAN_{TX,RX,FILTER)
features need to be advertized. From your comment I understand now that
RX/TX are enough
in that respect?
>
>
> [...]
>> +/* 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.
will fix, thanks for spotting this.
Or.
next prev parent reply other threads:[~2012-07-19 15:46 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-18 10:59 [PATCH net-next V1 0/9] Add Ethernet IPoIB driver Or Gerlitz
2012-07-18 10:59 ` [PATCH net-next V1 1/9] IB/ipoib: Add support for clones / multiple childs on the same partition Or Gerlitz
2012-07-18 18:38 ` David Miller
2012-07-18 21:24 ` Or Gerlitz
2012-07-18 21:36 ` David Miller
2012-07-18 22:11 ` John Fastabend
2012-07-19 8:11 ` Or Gerlitz
2012-07-18 10:59 ` [PATCH net-next V1 2/9] include/linux: Add private flags for IPoIB interfaces Or Gerlitz
2012-07-18 10:59 ` [PATCH net-next V1 3/9] IB/ipoib: Add support for acting as VIF Or Gerlitz
2012-07-18 10:59 ` [PATCH net-next V1 4/9] net/eipoib: Add private header file Or Gerlitz
2012-07-18 10:59 ` [PATCH net-next V1 5/9] net/eipoib: Add ethtool file support Or Gerlitz
2012-07-18 18:37 ` Ben Hutchings
2012-07-19 15:55 ` Or Gerlitz
2012-07-18 10:59 ` [PATCH net-next V1 6/9] net/eipoib: Add sysfs support Or Gerlitz
2012-07-23 12:55 ` Or Gerlitz
2012-07-18 11:00 ` [PATCH net-next V1 7/9] net/eipoib: Add main driver functionality Or Gerlitz
2012-07-19 13:49 ` Ben Hutchings
2012-07-19 15:46 ` Or Gerlitz [this message]
2012-07-19 16:16 ` Ben Hutchings
2012-07-19 16:21 ` Or Gerlitz
2012-07-18 11:00 ` [PATCH net-next V1 8/9] net/eipoib: Add Makefile, Kconfig and MAINTAINERS entries Or Gerlitz
2012-07-18 11:00 ` [PATCH net-next V1 9/9] IB/ipoib: Add support for transmission of skbs w.o dst/neighbour Or Gerlitz
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=50082BDE.2040005@mellanox.com \
--to=ogerlitz@mellanox.com \
--cc=ali@mellanox.com \
--cc=bhutchings@solarflare.com \
--cc=davem@davemloft.net \
--cc=erezsh@mellanox.co.il \
--cc=netdev@vger.kernel.org \
--cc=roland@kernel.org \
--cc=sean.hefty@intel.com \
--cc=shlomop@mellanox.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.