[dpdk-dev,v3,08/16] enic: fix re-define freebsd compile complain
Commit Message
Some macro already been defined by freebsd 'sys/param.h'.
Signed-off-by: Cunming Liang <cunming.liang@intel.com>
---
lib/librte_pmd_enic/enic.h | 1 +
lib/librte_pmd_enic/enic_compat.h | 1 +
2 files changed, 2 insertions(+)
@@ -66,6 +66,7 @@
#define ENIC_CALC_IP_CKSUM 1
#define ENIC_CALC_TCP_UDP_CKSUM 2
#define ENIC_MAX_MTU 9000
+#undef PAGE_SIZE
#define PAGE_SIZE 4096
#define PAGE_ROUND_UP(x) \
((((unsigned long)(x)) + PAGE_SIZE-1) & (~(PAGE_SIZE-1)))
@@ -67,6 +67,7 @@
#define pr_warn(y, args...) dev_warning(0, y, ##args)
#define BUG() pr_err("BUG at %s:%d", __func__, __LINE__)
+#undef ALIGN
#define ALIGN(x, a) __ALIGN_MASK(x, (typeof(x))(a)-1)
#define __ALIGN_MASK(x, mask) (((x)+(mask))&~(mask))
#define udelay usleep