eal/bsd: fix build on FreeBSD
authorBruce Richardson <bruce.richardson@intel.com>
Tue, 5 May 2015 12:47:34 +0000 (13:47 +0100)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Mon, 11 May 2015 13:45:27 +0000 (15:45 +0200)
commit11f51a26d3e3a3cf78efa4c0a20d6aa5b29117c2
tree4abb8ac8a99330eb920cb7501a2e2cca46b251ba
parent6234585feed434315c72c16789798c6040fc1ea8
eal/bsd: fix build on FreeBSD

Compilation on FreeBSD with clang was broken, giving the error message:

lib/librte_eal/bsdapp/eal/eal_pci.c:438:16: fatal error: assigning to
  'struct rte_pci_id *' from 'const struct rte_pci_id *' discards qualifiers
  [-Wincompatible-pointer-types-discards-qualifiers]
    for (id_table = dr->id_table ; id_table->vendor_id != 0; id_table++) {
                  ^ ~~~~~~~~~~~~

This patch fixes the issue by adding "const" to the type of id_table.

Fixes: 6065355a03fc ("pci: make device id tables const")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
lib/librte_eal/bsdapp/eal/eal_pci.c