summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/osl.c
diff options
context:
space:
mode:
authorBjorn Helgaas <bjorn.helgaas@hp.com>2009-08-31 22:32:15 +0000
committerLen Brown <len.brown@intel.com>2009-09-19 02:15:05 -0400
commit59fc9e5e21baf2bf5c87d8006e006007c3a708c2 (patch)
tree358619eee9602d0b9cd9875d6d68fc49a5454f3c /drivers/acpi/osl.c
parent9ac6185669d0d277c4082fa92ba8eb2e55534cbf (diff)
downloadop-kernel-dev-59fc9e5e21baf2bf5c87d8006e006007c3a708c2.zip
op-kernel-dev-59fc9e5e21baf2bf5c87d8006e006007c3a708c2.tar.gz
ACPI: remove null pointer checks in deferred execution path
Better to oops and learn about a bug than to silently cover it up. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/osl.c')
-rw-r--r--drivers/acpi/osl.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/drivers/acpi/osl.c b/drivers/acpi/osl.c
index d753206..56071b6 100644
--- a/drivers/acpi/osl.c
+++ b/drivers/acpi/osl.c
@@ -699,18 +699,12 @@ void acpi_os_derive_pci_id(acpi_handle rhandle, /* upper bound */
static void acpi_os_execute_deferred(struct work_struct *work)
{
struct acpi_os_dpc *dpc = container_of(work, struct acpi_os_dpc, work);
- if (!dpc) {
- printk(KERN_ERR PREFIX "Invalid (NULL) context\n");
- return;
- }
if (dpc->wait)
acpi_os_wait_events_complete(NULL);
dpc->function(dpc->context);
kfree(dpc);
-
- return;
}
/*******************************************************************************
@@ -739,9 +733,6 @@ static acpi_status __acpi_os_execute(acpi_execute_type type,
"Scheduling function [%p(%p)] for deferred execution.\n",
function, context));
- if (!function)
- return AE_BAD_PARAMETER;
-
/*
* Allocate/initialize DPC structure. Note that this memory will be
* freed by the callee. The kernel handles the work_struct list in a
OpenPOWER on IntegriCloud