]> git.baikalelectronics.ru Git - kernel.git/commit
virtio-net: introduce a new control to set macaddr
authorAmos Kong <akong@redhat.com>
Mon, 21 Jan 2013 01:17:23 +0000 (01:17 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 21 Jan 2013 19:07:44 +0000 (14:07 -0500)
commit9ea54965fd62d53e23f147fbc4bc7c07af6af680
tree26b31fbcf0995c22b073394946717eba0151fbe5
parentb001fa5c389c545f8840d12efbd65aa9cf12bc1a
virtio-net: introduce a new control to set macaddr

Currently we write MAC address to pci config space byte by byte,
this means that we have an intermediate step where mac is wrong.
This patch introduced a new control command to set MAC address,
it's atomic.

VIRTIO_NET_F_CTRL_MAC_ADDR is a new feature bit for compatibility.

Signed-off-by: Amos Kong <akong@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/virtio_net.c
include/uapi/linux/virtio_net.h