* [patch] ACPI: remove a pointless NULL check
@ 2014-01-30 11:56 Dan Carpenter
0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2014-01-30 11:56 UTC (permalink / raw)
To: Len Brown; +Cc: Rafael J. Wysocki, linux-acpi, kernel-janitors
"element" can't be NULL because it is the address of a struct member.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/drivers/acpi/utils.c b/drivers/acpi/utils.c
index 492cf4f409fd..94dbbcb5827b 100644
--- a/drivers/acpi/utils.c
+++ b/drivers/acpi/utils.c
@@ -98,10 +98,6 @@ acpi_extract_package(union acpi_object *package,
union acpi_object *element = &(package->package.elements[i]);
- if (!element) {
- return AE_BAD_DATA;
- }
-
switch (element->type) {
case ACPI_TYPE_INTEGER:
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2014-01-30 11:56 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-30 11:56 [patch] ACPI: remove a pointless NULL check Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox