From e39a7b8347b1055cca6e9cfadcfeca23f8236eb9 Mon Sep 17 00:00:00 2001 From: Damjan Marion Date: Tue, 26 Apr 2016 14:54:57 +0200 Subject: Fix compile errors reported by clang For using clang as a compiler it is enough to specify CC=clang in the make command line Change-Id: I06f1c1d418b68768f8119de5bdc8748c51f90c02 Signed-off-by: Damjan Marion --- vlib/vlib/pci/pci_config.h | 2 +- vlib/vlib/unix/pci.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'vlib') diff --git a/vlib/vlib/pci/pci_config.h b/vlib/vlib/pci/pci_config.h index 38215d82..9cada51c 100644 --- a/vlib/vlib/pci/pci_config.h +++ b/vlib/vlib/pci/pci_config.h @@ -417,7 +417,7 @@ pci_config_find_capability (pci_config_type0_regs_t * t, int cap_type) while (ttl-- && next_offset >= 0x40) { c = (void *) t + (next_offset &~ 3); - if (c->type == 0xff) + if ((u8) c->type == 0xff) break; if (c->type == cap_type) return c; diff --git a/vlib/vlib/unix/pci.c b/vlib/vlib/unix/pci.c index 75241f3f..b28b542b 100644 --- a/vlib/vlib/unix/pci.c +++ b/vlib/vlib/unix/pci.c @@ -420,7 +420,7 @@ u8 * format_os_pci_handle (u8 * s, va_list * va) l->bus_address.slot, l->bus_address.function); } -static inline pci_device_registration_t * +pci_device_registration_t * __attribute__((unused)) pci_device_next_registered (pci_device_registration_t * r) { uword i; -- cgit