Skip to content

Commit fc0ad6c

Browse files
committed
Merge branch 'acpi-fixes'
* acpi-fixes: ACPI / video: ignore BIOS initial backlight value for Fujitsu E753 PNP / ACPI: avoid garbage in resource name ACPI / memhotplug: Fix a stale pointer in error path ACPI / scan: Always call acpi_bus_scan() for bus check notifications ACPI / scan: Do not try to attach scan handlers to devices having them
2 parents ad81f05 + 9657a56 commit fc0ad6c

File tree

5 files changed

+20
-5
lines changed

5 files changed

+20
-5
lines changed

drivers/acpi/acpi_memhotplug.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -323,6 +323,7 @@ static int acpi_memory_device_add(struct acpi_device *device,
323323
/* Get the range from the _CRS */
324324
result = acpi_memory_get_device_resources(mem_device);
325325
if (result) {
326+
device->driver_data = NULL;
326327
kfree(mem_device);
327328
return result;
328329
}

drivers/acpi/scan.c

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -352,10 +352,12 @@ static void acpi_scan_bus_device_check(acpi_handle handle, u32 ost_source)
352352
mutex_lock(&acpi_scan_lock);
353353
lock_device_hotplug();
354354

355-
acpi_bus_get_device(handle, &device);
356-
if (device) {
357-
dev_warn(&device->dev, "Attempt to re-insert\n");
358-
goto out;
355+
if (ost_source != ACPI_NOTIFY_BUS_CHECK) {
356+
acpi_bus_get_device(handle, &device);
357+
if (device) {
358+
dev_warn(&device->dev, "Attempt to re-insert\n");
359+
goto out;
360+
}
359361
}
360362
acpi_evaluate_hotplug_ost(handle, ost_source,
361363
ACPI_OST_SC_INSERT_IN_PROGRESS, NULL);
@@ -1981,6 +1983,9 @@ static acpi_status acpi_bus_device_attach(acpi_handle handle, u32 lvl_not_used,
19811983
if (acpi_bus_get_device(handle, &device))
19821984
return AE_CTRL_DEPTH;
19831985

1986+
if (device->handler)
1987+
return AE_OK;
1988+
19841989
ret = acpi_scan_attach_handler(device);
19851990
if (ret)
19861991
return ret > 0 ? AE_OK : AE_CTRL_DEPTH;

drivers/acpi/video.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -448,6 +448,14 @@ static struct dmi_system_id video_dmi_table[] __initdata = {
448448
DMI_MATCH(DMI_PRODUCT_NAME, "HP Folio 13 - 2000 Notebook PC"),
449449
},
450450
},
451+
{
452+
.callback = video_ignore_initial_backlight,
453+
.ident = "Fujitsu E753",
454+
.matches = {
455+
DMI_MATCH(DMI_BOARD_VENDOR, "FUJITSU"),
456+
DMI_MATCH(DMI_PRODUCT_NAME, "LIFEBOOK E753"),
457+
},
458+
},
451459
{
452460
.callback = video_ignore_initial_backlight,
453461
.ident = "HP Pavilion dm4",

drivers/pnp/pnpacpi/rsparser.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ static acpi_status pnpacpi_allocated_resource(struct acpi_resource *res,
180180
struct pnp_dev *dev = data;
181181
struct acpi_resource_dma *dma;
182182
struct acpi_resource_vendor_typed *vendor_typed;
183-
struct resource r;
183+
struct resource r = {0};
184184
int i, flags;
185185

186186
if (acpi_dev_resource_memory(res, &r)

drivers/pnp/resource.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,7 @@ struct pnp_resource *pnp_add_resource(struct pnp_dev *dev,
515515
}
516516

517517
pnp_res->res = *res;
518+
pnp_res->res.name = dev->name;
518519
dev_dbg(&dev->dev, "%pR\n", res);
519520
return pnp_res;
520521
}

0 commit comments

Comments
 (0)