aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/acpi')
-rw-r--r--drivers/acpi/pci_link.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/acpi/pci_link.c b/drivers/acpi/pci_link.c
index 68ee80a6e6f7..8197c0e40769 100644
--- a/drivers/acpi/pci_link.c
+++ b/drivers/acpi/pci_link.c
@@ -83,7 +83,6 @@ struct acpi_pci_link_irq {
83struct acpi_pci_link { 83struct acpi_pci_link {
84 struct list_head node; 84 struct list_head node;
85 struct acpi_device *device; 85 struct acpi_device *device;
86 acpi_handle handle;
87 struct acpi_pci_link_irq irq; 86 struct acpi_pci_link_irq irq;
88 int refcnt; 87 int refcnt;
89}; 88};
@@ -249,8 +248,7 @@ static int acpi_pci_link_get_current(struct acpi_pci_link *link)
249 acpi_status status = AE_OK; 248 acpi_status status = AE_OK;
250 int irq = 0; 249 int irq = 0;
251 250
252 251 if (!link)
253 if (!link || !link->handle)
254 return -EINVAL; 252 return -EINVAL;
255 253
256 link->irq.active = 0; 254 link->irq.active = 0;
@@ -726,7 +724,6 @@ static int acpi_pci_link_add(struct acpi_device *device)
726 memset(link, 0, sizeof(struct acpi_pci_link)); 724 memset(link, 0, sizeof(struct acpi_pci_link));
727 725
728 link->device = device; 726 link->device = device;
729 link->handle = device->handle;
730 strcpy(acpi_device_name(device), ACPI_PCI_LINK_DEVICE_NAME); 727 strcpy(acpi_device_name(device), ACPI_PCI_LINK_DEVICE_NAME);
731 strcpy(acpi_device_class(device), ACPI_PCI_LINK_CLASS); 728 strcpy(acpi_device_class(device), ACPI_PCI_LINK_CLASS);
732 acpi_driver_data(device) = link; 729 acpi_driver_data(device) = link;