Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 348342
b: refs/heads/master
c: 0271f4f
h: refs/heads/master
v: v3
  • Loading branch information
Rafael J. Wysocki committed Jan 3, 2013
1 parent 64c9ae9 commit fb9578d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 23415eb5233eb3c1939c4cb7d6235af98a3a2955
refs/heads/master: 0271f4f1176d7205b2b73ef956b169db8f417932
11 changes: 2 additions & 9 deletions trunk/drivers/acpi/power.c
Original file line number Diff line number Diff line change
Expand Up @@ -445,11 +445,8 @@ int acpi_power_resource_register_device(struct device *dev, acpi_handle handle)
return -ENODEV;

ret = acpi_bus_get_device(handle, &acpi_dev);
if (ret)
goto no_power_resource;

if (!acpi_dev->power.flags.power_resources)
goto no_power_resource;
if (ret || !acpi_dev->power.flags.power_resources)
return -ENODEV;

powered_device = kzalloc(sizeof(*powered_device), GFP_KERNEL);
if (!powered_device)
Expand All @@ -471,10 +468,6 @@ int acpi_power_resource_register_device(struct device *dev, acpi_handle handle)
}

return ret;

no_power_resource:
printk(KERN_DEBUG PREFIX "Invalid Power Resource to register!\n");
return -ENODEV;
}
EXPORT_SYMBOL_GPL(acpi_power_resource_register_device);

Expand Down

0 comments on commit fb9578d

Please sign in to comment.