From: Thomas Monjalon Subject: [PATCH] pmd: use byte ordering functions from dpdk Date: Mon, 30 Sep 2013 10:55:53 +0200 Message-ID: <1380531353-23482-1-git-send-email-thomas.monjalon@6wind.com> To: dev-VfR2kkLFssw@public.gmane.org Return-path: List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" CPU should always use little endian on Intel but it is more consistent to use DPDK macros. Signed-off-by: Thomas Monjalon --- pmd/vmx_user.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pmd/vmx_user.h b/pmd/vmx_user.h index 4a1a95c..7181a3b 100644 --- a/pmd/vmx_user.h +++ b/pmd/vmx_user.h @@ -1,5 +1,5 @@ /* - * Copyright 6WIND 2012-2013, All rights reserved. + * Copyright 2012-2013 6WIND S.A. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -40,12 +40,12 @@ typedef uint32_t u32; typedef uint64_t u64; typedef phys_addr_t dma_addr_t; -#define le16_to_cpu(x) (x) -#define cpu_to_le16(x) (x) -#define le32_to_cpu(x) (x) -#define cpu_to_le32(x) (x) -#define le64_to_cpu(x) (x) -#define cpu_to_le64(x) (x) +#define le16_to_cpu(x) rte_le_to_cpu_16(x) +#define cpu_to_le16(x) rte_cpu_to_le_16(x) +#define le32_to_cpu(x) rte_le_to_cpu_32(x) +#define cpu_to_le32(x) rte_cpu_to_le_32(x) +#define le64_to_cpu(x) rte_le_to_cpu_64(x) +#define cpu_to_le64(x) rte_cpu_to_le_64(x) #define readl(addr) \ (*((volatile uint32_t*)((unsigned long)(addr)))) -- 1.7.10.4