提交 0bf6368e 编写于 作者: L Lan Tianyu 提交者: Rafael J. Wysocki

ACPI / button: Add ACPI Button event via netlink routine

Commit 1696d9dc (ACPI: Remove the old /proc/acpi/event interface)
removed ACPI Button event which originally was sent to userspace via
/proc/acpi/event. This caused ACPI shutdown regression on gentoo
in VirtualBox. Now ACPI events are sent to userspace via netlink,
so add ACPI Button event back via netlink routine.

References: https://bugzilla.kernel.org/show_bug.cgi?id=71721Reported-and-tested-by: NRichard Musil <richard.musil@gmail.com>
Signed-off-by: NLan Tianyu <tianyu.lan@intel.com>
Cc: 3.11+ <stable@vger.kernel.org> # 3.11+
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 dcb99fd9
...@@ -302,6 +302,10 @@ static void acpi_button_notify(struct acpi_device *device, u32 event) ...@@ -302,6 +302,10 @@ static void acpi_button_notify(struct acpi_device *device, u32 event)
input_sync(input); input_sync(input);
pm_wakeup_event(&device->dev, 0); pm_wakeup_event(&device->dev, 0);
acpi_bus_generate_netlink_event(
device->pnp.device_class,
dev_name(&device->dev),
event, ++button->pushed);
} }
break; break;
default: default:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册