summaryrefslogtreecommitdiff
path: root/drivers/acpi/processor_core.c
diff options
context:
space:
mode:
authorAkinobu Mita <akinobu.mita@gmail.com>2006-12-19 23:56:10 +0300
committerLen Brown <len.brown@intel.com>2006-12-20 08:33:07 +0300
commit83822fc9e6ad2e0f3799174f7c6ad3aa285b9488 (patch)
tree06a7bd36df6b45116bb15f9bb2ef4cd4bd1446d6 /drivers/acpi/processor_core.c
parentf10bb2544bab75b3e8df15a7b51a833c78cbd77f (diff)
downloadlinux-83822fc9e6ad2e0f3799174f7c6ad3aa285b9488.tar.xz
ACPI: prevent processor module from loading on failures
Make loading processor.ko fail when an error happens. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/processor_core.c')
-rw-r--r--drivers/acpi/processor_core.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/acpi/processor_core.c b/drivers/acpi/processor_core.c
index 1908e0d20222..22eb05efa64c 100644
--- a/drivers/acpi/processor_core.c
+++ b/drivers/acpi/processor_core.c
@@ -901,13 +901,13 @@ static int __init acpi_processor_init(void)
acpi_processor_dir = proc_mkdir(ACPI_PROCESSOR_CLASS, acpi_root_dir);
if (!acpi_processor_dir)
- return 0;
+ return -ENOMEM;
acpi_processor_dir->owner = THIS_MODULE;
result = acpi_bus_register_driver(&acpi_processor_driver);
if (result < 0) {
remove_proc_entry(ACPI_PROCESSOR_CLASS, acpi_root_dir);
- return 0;
+ return result;
}
acpi_processor_install_hotplug_notify();