pmdinfogen: fix cross compilation for ARM big endian
authorHemant Agrawal <hemant.agrawal@nxp.com>
Mon, 18 Dec 2017 07:56:45 +0000 (13:26 +0530)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 12 Jan 2018 16:26:41 +0000 (17:26 +0100)
commit74d6c4a72eb2ba9025f25706227f4cf304fe0ba6
tree7c983e295ec83fb5f4e47b6ce161c9e75972316d
parent7b74a6e0b638ce69b9d03367ce85258e0da19807
pmdinfogen: fix cross compilation for ARM big endian

Cross compiling DPDK for BE mode on ARM results into errors
"PMDINFO portal/dpaa2_hw_dpio.o.pmd.c No drivers registered"

The original code assumes the sh_size to be 32 bit, while it can
be Elf32_Word or Elf64_Xword based on 32bit or 64 bit systems.

This patches replaces the sh_size conversion routines to use ADDR_SIZE

Fixes: 98b0fdb0ffc6 ("pmdinfogen: add buildtools and pmdinfogen utility")
Cc: stable@dpdk.org
Signed-off-by: Jun Yang <jun.yang@nxp.com>
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
buildtools/pmdinfogen/pmdinfogen.c