diff --git a/drivers/usb/dwc_otg/Makefile b/drivers/usb/dwc_otg/Makefile index e60402dff923..6da2668e6b2a 100755 --- a/drivers/usb/dwc_otg/Makefile +++ b/drivers/usb/dwc_otg/Makefile @@ -13,6 +13,9 @@ ifeq ($(CONFIG_DWC_OTG_HOST_ONLY),y) EXTRA_CFLAGS += -DDWC_HOST_ONLY endif +ifneq ($(CONFIG_USB),y) +EXTRA_CFLAGS += -DDWC_DEVICE_ONLY +endif #ifeq ($(CONFIG_DWC_OTG_DEVICE_ONLY),y) #EXTRA_CFLAGS += -DDWC_DEVICE_ONLY #endif