The patch titled acpi: tie ACPI backlight devices to PCI devices if possible has been added to the -mm tree. Its filename is acpi-tie-acpi-backlight-devices-to-pci-devices-if-possible.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find out what to do about this The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: acpi: tie ACPI backlight devices to PCI devices if possible From: Matthew Garrett <mjg@xxxxxxxxxx> Dual-GPU machines may provide more than one ACPI backlight interface. Tie the backlight device to the GPU in order to allow userspace to identify the correct interface. Signed-off-by: Matthew Garrett <mjg@xxxxxxxxxx> Cc: Richard Purdie <rpurdie@xxxxxxxxx> Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> Cc: David Airlie <airlied@xxxxxxxx> Cc: Alex Deucher <alexdeucher@xxxxxxxxx> Cc: Ben Skeggs <bskeggs@xxxxxxxxxx> Cc: Zhang Rui <rui.zhang@xxxxxxxxx> Cc: Len Brown <lenb@xxxxxxxxxx> Cc: Jesse Barnes <jbarnes@xxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- drivers/acpi/video.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff -puN drivers/acpi/video.c~acpi-tie-acpi-backlight-devices-to-pci-devices-if-possible drivers/acpi/video.c --- a/drivers/acpi/video.c~acpi-tie-acpi-backlight-devices-to-pci-devices-if-possible +++ a/drivers/acpi/video.c @@ -782,6 +782,9 @@ static void acpi_video_device_find_cap(s if (acpi_video_backlight_support()) { struct backlight_properties props; + struct pci_dev *pdev; + acpi_handle acpi_parent; + struct device *parent = NULL; int result; static int count = 0; char *name; @@ -794,10 +797,20 @@ static void acpi_video_device_find_cap(s return; count++; + acpi_get_parent(device->dev->handle, &acpi_parent); + + pdev = acpi_get_pci_dev(acpi_parent); + if (pdev) { + parent = &pdev->dev; + pci_dev_put(pdev); + } + memset(&props, 0, sizeof(struct backlight_properties)); props.type = BACKLIGHT_FIRMWARE; props.max_brightness = device->brightness->count - 3; - device->backlight = backlight_device_register(name, NULL, device, + device->backlight = backlight_device_register(name, + parent, + device, &acpi_backlight_ops, &props); kfree(name); _ Patches currently in -mm which might be from mjg@xxxxxxxxxx are origin.patch acerhdf-add-support-for-aspire-1410-bios-v13314.patch backlight-add-backlight-type.patch i915-add-native-backlight-control.patch radeon-expose-backlight-class-device-for-legacy-lvds-encoder.patch nouveau-change-the-backlight-parent-device-to-the-connector-not-the-pci-dev.patch acpi-tie-acpi-backlight-devices-to-pci-devices-if-possible.patch mbp_nvidia_bl-remove-dmi-dependency.patch mbp_nvidia_bl-check-that-the-backlight-control-functions.patch mbp_nvidia_bl-rename-to-apple_bl.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html