From 3091fa77ffb1b91f4ac3ae005efe6213508f7ec1 Mon Sep 17 00:00:00 2001 From: Alan Stern Date: Wed, 22 Apr 2015 12:11:59 -0400 Subject: [PATCH] USB: don't build PCI quirks if USB support isn't configured MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The USB PCI quirks code gets built into the kernel whenever CONFIG_PCI is enabled, even if CONFIG_USB is not set. This can cause unnecessary messages to show up in the kernel log, such as "CONFIG_USB_XHCI_HCD is turned off, defaulting to EHCI" (which makes no sense when the kernel has been configured without host-side USB support). This patch addresses the problem by building pci-quirks.o only when CONFIG_PCI and CONFIG_USB are both enabled. Signed-off-by: Alan Stern Reported-by: Toralf Förster Signed-off-by: Greg Kroah-Hartman --- drivers/usb/host/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/usb/host/Makefile b/drivers/usb/host/Makefile index 65b0b6a58599..972a74a6f428 100644 --- a/drivers/usb/host/Makefile +++ b/drivers/usb/host/Makefile @@ -24,7 +24,9 @@ endif obj-$(CONFIG_USB_WHCI_HCD) += whci/ -obj-$(CONFIG_PCI) += pci-quirks.o +ifneq ($(CONFIG_USB), ) + obj-$(CONFIG_PCI) += pci-quirks.o +endif obj-$(CONFIG_USB_XHCI_PCI) += xhci-pci.o obj-$(CONFIG_USB_XHCI_PLATFORM) += xhci-plat-hcd.o -- 2.39.2