From 48fef95b79920611ba284a946d5950b8afeeb38b Mon Sep 17 00:00:00 2001 From: Thomas Heijligen Date: Tue, 15 Mar 2022 12:55:40 +0100 Subject: NEED_PCI: remove macro The NEED_PCI macro is only used to guard prototypes. This is not needed. Change-Id: I6895b795bc96b3e251700bff4b0054407aac789a Signed-off-by: Thomas Heijligen Reviewed-on: https://review.coreboot.org/c/flashrom/+/62834 Tested-by: build bot (Jenkins) Reviewed-by: Nico Huber --- Makefile | 1 - meson.build | 1 - programmer.h | 2 -- 3 files changed, 4 deletions(-) diff --git a/Makefile b/Makefile index bfa9c679..367d8ee7 100644 --- a/Makefile +++ b/Makefile @@ -838,7 +838,6 @@ endif USE_LIBPCI := $(if $(call filter_deps,$(DEPENDS_ON_LIBPCI)),yes,no) ifeq ($(USE_LIBPCI), yes) PROGRAMMER_OBJS += pcidev.o -FEATURE_FLAGS += -D'NEED_PCI=1' override CFLAGS += $(CONFIG_LIBPCI_CFLAGS) override LDFLAGS += $(CONFIG_LIBPCI_LDFLAGS) endif diff --git a/meson.build b/meson.build index 5a6bc2ad..f8ca1d3d 100644 --- a/meson.build +++ b/meson.build @@ -159,7 +159,6 @@ endif if get_option('pciutils') srcs += 'pcidev.c' deps += dependency('libpci') - cargs += '-DNEED_PCI=1' elif need_libpci error('pciutils is disabled but one or more enabled programmer requires PCI access') endif diff --git a/programmer.h b/programmer.h index 47d2dc31..86e45f76 100644 --- a/programmer.h +++ b/programmer.h @@ -115,7 +115,6 @@ struct bitbang_spi_master { unsigned int half_period; }; -#if NEED_PCI == 1 struct pci_dev; struct pci_filter; @@ -141,7 +140,6 @@ struct pci_dev *pcidev_find(uint16_t vendor, uint16_t device); int rpci_write_byte(struct pci_dev *dev, int reg, uint8_t data); int rpci_write_word(struct pci_dev *dev, int reg, uint16_t data); int rpci_write_long(struct pci_dev *dev, int reg, uint32_t data); -#endif #if CONFIG_INTERNAL == 1 struct penable { -- cgit v1.2.3