All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Add config check for cpu hotplug code
@ 2009-12-10  4:14 Jiang, Yunhong
  2009-12-10 21:43 ` Jeremy Fitzhardinge
  0 siblings, 1 reply; 4+ messages in thread
From: Jiang, Yunhong @ 2009-12-10  4:14 UTC (permalink / raw)
  To: Jeremy Fitzhardinge; +Cc: xen-devel@lists.xensource.com

[-- Attachment #1: Type: text/plain, Size: 1397 bytes --]

For acpi_parser branch.

Add CONFIG check to xen_get_apic_id() and xen_hotplug_notifier().

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>

diff --git a/drivers/xen/acpi_processor.c b/drivers/xen/acpi_processor.c
index 6e6d465..d6b3bc8 100644
--- a/drivers/xen/acpi_processor.c
+++ b/drivers/xen/acpi_processor.c
@@ -94,6 +94,7 @@ int processor_cntl_xen_pmthr(void)
 }
 EXPORT_SYMBOL(processor_cntl_xen_pmthr);
 
+#ifdef CONFIG_ACPI_HOTPLUG_CPU
 static int xen_get_apic_id(acpi_handle handle)
 {
 	struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
@@ -129,6 +130,12 @@ static int xen_get_apic_id(acpi_handle handle)
 
 	return physid;
 }
+#else
+static int xen_get_apic_id(acpi_handle handle)
+{
+	return -1;
+}
+#endif
 
 int processor_cntl_xen_notify(struct acpi_processor *pr, int event, int type)
 {
@@ -354,6 +361,7 @@ static int xen_tx_notifier(struct acpi_processor *pr, int action)
 	return -EINVAL;
 }
 
+#ifdef CONFIG_ACPI_HOTPLUG_CPU
 static int xen_hotplug_notifier(struct acpi_processor *pr, int event)
 {
 	int ret = -EINVAL;
@@ -396,6 +404,12 @@ static int xen_hotplug_notifier(struct acpi_processor *pr, int event)
 
 	return ret;
 }
+#else
+static int xen_hotplug_notifier(struct acpi_processor *pr, int event)
+{
+	return -ENOSYS;
+}
+#endif
 
 static int __init xen_acpi_processor_extcntl_init(void)
 {



[-- Attachment #2: config_option.patch --]
[-- Type: application/octet-stream, Size: 1316 bytes --]

Add CONFIG check to xen_get_apic_id() and xen_hotplug_notifier().

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>

diff --git a/drivers/xen/acpi_processor.c b/drivers/xen/acpi_processor.c
index 6e6d465..d6b3bc8 100644
--- a/drivers/xen/acpi_processor.c
+++ b/drivers/xen/acpi_processor.c
@@ -94,6 +94,7 @@ int processor_cntl_xen_pmthr(void)
 }
 EXPORT_SYMBOL(processor_cntl_xen_pmthr);
 
+#ifdef CONFIG_ACPI_HOTPLUG_CPU
 static int xen_get_apic_id(acpi_handle handle)
 {
 	struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
@@ -129,6 +130,12 @@ static int xen_get_apic_id(acpi_handle handle)
 
 	return physid;
 }
+#else
+static int xen_get_apic_id(acpi_handle handle)
+{
+	return -1;
+}
+#endif
 
 int processor_cntl_xen_notify(struct acpi_processor *pr, int event, int type)
 {
@@ -354,6 +361,7 @@ static int xen_tx_notifier(struct acpi_processor *pr, int action)
 	return -EINVAL;
 }
 
+#ifdef CONFIG_ACPI_HOTPLUG_CPU
 static int xen_hotplug_notifier(struct acpi_processor *pr, int event)
 {
 	int ret = -EINVAL;
@@ -396,6 +404,12 @@ static int xen_hotplug_notifier(struct acpi_processor *pr, int event)
 
 	return ret;
 }
+#else
+static int xen_hotplug_notifier(struct acpi_processor *pr, int event)
+{
+	return -ENOSYS;
+}
+#endif
 
 static int __init xen_acpi_processor_extcntl_init(void)
 {

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-12-11  9:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-10  4:14 [PATCH] Add config check for cpu hotplug code Jiang, Yunhong
2009-12-10 21:43 ` Jeremy Fitzhardinge
2009-12-11  7:46   ` Jiang, Yunhong
2009-12-11  9:54     ` Jiang, Yunhong

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.