Skip to contentSkip to conversation

dbgp: fix compile error on building EARLY_PRINTK_DBGP without USB_SUPPORT

PATCH In review Hannes Frederic Sowa 2 participants 4 messages Oct 28, 2012 – Oct 29, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 dbgp: fix compile error on building EARLY_PRINTK_DBGP without USB_SUPPORT

This patch fixes following compile error:

drivers/built-in.o: In function `dbgp_reset_prep':
linux/drivers/usb/early/ehci-dbgp.c:984: undefined reference to xen_dbgp_reset_prep' drivers/built-in.o: In function dbgp_external_startup':
linux/drivers/usb/early/ehci-dbgp.c:619: undefined reference to `xen_dbgp_external_startup'

EARLY_PRINTK_DBGP should work without USB_SUPPORT.

---
 drivers/xen/Kconfig          | 3 +++
 drivers/xen/Makefile         | 2 +-
 include/linux/usb/ehci_def.h | 2 +-
 3 files changed, 5 insertions(+), 2 deletions(-)
drivers/xen/Kconfig +3 -0
index 126d8ce..9bb3420 100644
@@ -206,4 +206,7 @@ config XEN_MCE_LOG
 	  Allow kernel fetching MCE error from Xen platform and
 	  converting it into Linux mcelog format for mcelog tools
 
+config XEN_DBGP
+	def_bool y if XEN_DOM0 && (USB_SUPPORT || EARLY_PRINTK_DBGP)
+
 endmenu
drivers/xen/Makefile +1 -1
index 0e863703..d23ed07 100644
@@ -9,7 +9,7 @@ nostackp := $(call cc-option, -fno-stack-protector)
 CFLAGS_features.o			:= $(nostackp)
 
 dom0-$(CONFIG_PCI) += pci.o
-dom0-$(CONFIG_USB_SUPPORT) += dbgp.o
+dom0-$(CONFIG_XEN_DBGP) += dbgp.o
 dom0-$(CONFIG_ACPI) += acpi.o
 dom0-$(CONFIG_X86) += pcpu.o
 obj-$(CONFIG_XEN_DOM0)			+= $(dom0-y)
include/linux/usb/ehci_def.h +1 -1
index daec99a..7d8f7fe 100644
@@ -223,7 +223,7 @@ extern struct console early_dbgp_console;
 
 struct usb_hcd;
 
-#ifdef CONFIG_XEN_DOM0
+#ifdef CONFIG_XEN_DBGP
 extern int xen_dbgp_reset_prep(struct usb_hcd *);
 extern int xen_dbgp_external_startup(struct usb_hcd *);
 #else
#1 lore raw
Quoted 11 lines
Quoted 1 line
Quoted 1 line · Hannes Frederic Sowa

This patch fixes following compile error:

drivers/built-in.o: In function `dbgp_reset_prep':
linux/drivers/usb/early/ehci-dbgp.c:984: undefined reference to `xen_dbgp_reset_prep'
drivers/built-in.o: In function `dbgp_external_startup':
linux/drivers/usb/early/ehci-dbgp.c:619: undefined reference to `xen_dbgp_external_startup'

EARLY_PRINTK_DBGP should work without USB_SUPPORT.

An alternative patch was previously suggested to address this build problem.

Jan

Quoted 46 lines
---
 drivers/xen/Kconfig          | 3 +++
 drivers/xen/Makefile         | 2 +-
 include/linux/usb/ehci_def.h | 2 +-
 3 files changed, 5 insertions(+), 2 deletions(-)
drivers/xen/Kconfig +3 -0
index 126d8ce..9bb3420 100644
@@ -206,4 +206,7 @@ config XEN_MCE_LOG
 	  Allow kernel fetching MCE error from Xen platform and
 	  converting it into Linux mcelog format for mcelog tools
 
+config XEN_DBGP
+	def_bool y if XEN_DOM0 && (USB_SUPPORT || EARLY_PRINTK_DBGP)
+
 endmenu
drivers/xen/Makefile +1 -1
index 0e863703..d23ed07 100644
@@ -9,7 +9,7 @@ nostackp := $(call cc-option, -fno-stack-protector)
 CFLAGS_features.o			:= $(nostackp)
 
 dom0-$(CONFIG_PCI) += pci.o
-dom0-$(CONFIG_USB_SUPPORT) += dbgp.o
+dom0-$(CONFIG_XEN_DBGP) += dbgp.o
 dom0-$(CONFIG_ACPI) += acpi.o
 dom0-$(CONFIG_X86) += pcpu.o
 obj-$(CONFIG_XEN_DOM0)			+= $(dom0-y)
include/linux/usb/ehci_def.h +1 -1
index daec99a..7d8f7fe 100644
@@ -223,7 +223,7 @@ extern struct console early_dbgp_console;
 
 struct usb_hcd;
 
-#ifdef CONFIG_XEN_DOM0
+#ifdef CONFIG_XEN_DBGP
 extern int xen_dbgp_reset_prep(struct usb_hcd *);
 extern int xen_dbgp_external_startup(struct usb_hcd *);
 #else
#2 lore raw
Quoted 10 lines · Jan Beulich
Quoted 10 lines
Quoted 1 line
Quoted 1 line · Hannes Frederic Sowa

This patch fixes following compile error:

drivers/built-in.o: In function `dbgp_reset_prep':
linux/drivers/usb/early/ehci-dbgp.c:984: undefined reference to `xen_dbgp_reset_prep'
drivers/built-in.o: In function `dbgp_external_startup':
linux/drivers/usb/early/ehci-dbgp.c:619: undefined reference to `xen_dbgp_external_startup'

Quoted 4 lines
Quoted 1 line

EARLY_PRINTK_DBGP should work without USB_SUPPORT.

An alternative patch was previously suggested to address this build problem.

Hm, ok. I searched for a patch in the archives but did not find one. Do you have a link?

Greetings,

Hannes

#3 lore raw
Quoted 13 lines
Quoted 1 line
Quoted 1 line · Hannes Frederic Sowa
Quoted 1 line · Jan Beulich
Quoted 1 line
Quoted 1 line
Quoted 1 line

On 28.10.12 at 18:44, Hannes Frederic Sowa <[email protected]>

Quoted 9 lines · wrote:
Quoted 9 lines

This patch fixes following compile error:

drivers/built-in.o: In function `dbgp_reset_prep':
linux/drivers/usb/early/ehci-dbgp.c:984: undefined reference to `xen_dbgp_reset_prep'
drivers/built-in.o: In function `dbgp_external_startup':
linux/drivers/usb/early/ehci-dbgp.c:619: undefined reference to `xen_dbgp_external_startup'

Quoted 7 lines
Quoted 4 lines
Quoted 1 line

EARLY_PRINTK_DBGP should work without USB_SUPPORT.

An alternative patch was previously suggested to address this build problem.

Hm, ok. I searched for a patch in the archives but did not find one. Do you have a link?

Looks like I forgot to Cc any of the possibly relevant lists. But the patch is being debated upon still anyway.

Jan