Skip to contentSkip to conversation

Virtio-net: Replace the hardcode 6 with defined ETN_ALEN

PATCH Applied [email protected] 2 participants 2 messages May 23, 2010 – May 24, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Virtio-net: Replace the hardcode 6 with defined ETN_ALEN

From: Amos Kong <[email protected]>

hw/virtio-net.h:

    #define ETH_ALEN    6

ETH_ALEN was defined by commit 7967406801aa897fae83caad3278ac85a342adaa

---
 hw/virtio-net.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
hw/virtio-net.h +2 -2
index e55119b..235f1a9 100644
@@ -54,8 +54,8 @@
 
 struct virtio_net_config
 {
-    /* The config defining mac address (6 bytes) */
-    uint8_t mac[6];
+    /* The config defining mac address ($ETH_ALEN bytes) */
+    uint8_t mac[ETH_ALEN];
     /* See VIRTIO_NET_F_STATUS and VIRTIO_NET_S_* above */
     uint16_t status;
 } __attribute__((packed));
Signature · 1 line
1.7.0.4
#1 lore raw
Quoted 8 lines · On 05/22/2010 09:49 PM, [email protected] wrote:

From: Amos Kong<[email protected]>

hw/virtio-net.h:

     #define ETH_ALEN    6

ETH_ALEN was defined by commit 7967406801aa897fae83caad3278ac85a342adaa

Applied. Thanks.

Regards,

Anthony Liguori

Quoted 20 lines
---
  hw/virtio-net.h |    4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)
hw/virtio-net.h +2 -2
index e55119b..235f1a9 100644
@@ -54,8 +54,8 @@
 
  struct virtio_net_config
  {
-    /* The config defining mac address (6 bytes) */
-    uint8_t mac[6];
+    /* The config defining mac address ($ETH_ALEN bytes) */
+    uint8_t mac[ETH_ALEN];
      /* See VIRTIO_NET_F_STATUS and VIRTIO_NET_S_* above */
      uint16_t status;
  } __attribute__((packed));