summaryrefslogtreecommitdiff
path: root/lib/cfm.c
diff options
context:
space:
mode:
authorWang Sheng-Hui <shhuiw@gmail.com>2014-10-22 14:58:43 +0800
committerBen Pfaff <blp@nicira.com>2014-10-22 08:46:52 -0700
commit3bd0fd39ebeaca5f87284704e7606d225d0e1bbb (patch)
treedc783fa5bcb1aafc28d81f61ffef9c2b74907f8e /lib/cfm.c
parentd1da76691a84a16f910501116adeb6e33c9fb09c (diff)
downloadopenvswitch-3bd0fd39ebeaca5f87284704e7606d225d0e1bbb.tar.gz
Use magic ETH_ADDR_LEN instead of 6 for Ethernet address length.
ETH_ADDR_LEN is defined in lib/packets.h, valued 6. Use this macro instead of magic number 6 to represent the length of eth mac address. Signed-off-by: Wang Sheng-Hui <shhuiw@gmail.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'lib/cfm.c')
-rw-r--r--lib/cfm.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/cfm.c b/lib/cfm.c
index e3ae271e3..bc8be7114 100644
--- a/lib/cfm.c
+++ b/lib/cfm.c
@@ -43,8 +43,9 @@ VLOG_DEFINE_THIS_MODULE(cfm);
#define CFM_MAX_RMPS 256
/* Ethernet destination address of CCM packets. */
-static const uint8_t eth_addr_ccm[6] = { 0x01, 0x80, 0xC2, 0x00, 0x00, 0x30 };
-static const uint8_t eth_addr_ccm_x[6] = {
+static const uint8_t eth_addr_ccm[ETH_ADDR_LEN] = {
+ 0x01, 0x80, 0xC2, 0x00, 0x00, 0x30 };
+static const uint8_t eth_addr_ccm_x[ETH_ADDR_LEN] = {
0x01, 0x23, 0x20, 0x00, 0x00, 0x30
};