netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next v2 RESEND 0/4] macvlan: fix some problem if mac address changes
@ 2014-06-07  7:45 Ding Tianhong
  2014-06-07  7:45 ` [PATCH net-next v2 RESEND 1/4] macvlan: support mac address changes when fwd_priv is enable Ding Tianhong
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Ding Tianhong @ 2014-06-07  7:45 UTC (permalink / raw)
  To: kaber, davem, edumazet, vyasevic, makita.toshiaki; +Cc: netdev

The macvlan may return failed when handle the NETDEV_CHANGEMTU message, and
the current code could not process the error value, so modify the
dev_set_mac_address to process the return value for notification chain,
revert the old mac address if set new mac address failed.

The macvlan and lowerdev should not have the same mac address for non-passthru
mode, so add restriction for that.

v1->v2: Now the current code support setting a same mac address for netdev, but
	most of time, it make no sense, but drivers need the user set flag regardless
	the address is same or not, so don't do anything only If the address has
	already been set by user and it is the same as before.

	If the lowerdev support L2 fwd offload, the macvlan address will be set to
	the hw rar only, and it the address changes, the fwd for macvlan need be rebuild,
	this patchset support this.

Ding Tianhong (4):
  macvlan: support mac address changes when fwd_priv is enable
  net: dev: revert the mac address when notifier failed
  macvlan: don't set the same mac address for non-passthru mode
  net: dev: don't set the same mac address for netdev

 drivers/net/macvlan.c | 27 ++++++++++++++++++++++++++-
 net/core/dev.c        | 30 ++++++++++++++++++++++++++----
 2 files changed, 52 insertions(+), 5 deletions(-)

-- 
1.8.0

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-06-14  5:03 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-07  7:45 [PATCH net-next v2 RESEND 0/4] macvlan: fix some problem if mac address changes Ding Tianhong
2014-06-07  7:45 ` [PATCH net-next v2 RESEND 1/4] macvlan: support mac address changes when fwd_priv is enable Ding Tianhong
2014-06-09 16:51   ` Vlad Yasevich
2014-06-12  1:45     ` Ding Tianhong
2014-06-12 14:24       ` Vlad Yasevich
2014-06-13  3:10         ` Ding Tianhong
2014-06-13 13:30           ` Vlad Yasevich
2014-06-14  5:01             ` Ding Tianhong
2014-06-07  7:45 ` [PATCH net-next v2 RESEND 2/4] net: dev: revert the mac address when notifier failed Ding Tianhong
2014-06-07  7:45 ` [PATCH net-next v2 RESEND 3/4] macvlan: don't set the same mac address for non-passthru mode Ding Tianhong
2014-06-07  7:45 ` [PATCH net-next v2 RESEND 4/4] net: dev: don't set the same mac address for netdev Ding Tianhong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).