提交 f2772575 编写于 作者: L Len Brown

ACPI: hp-wmi, msi-wmi: clarify that wmi_install_notify_handler() returns an acpi_status

Emphasize that that wmi_install_notify_handler() returns an acpi_status
rather than -errno by by testing ACPI_SUCCESS(), ACPI_FAILURE().

No functional change in this patch, but this confusion caused a bug in dell-wmi.
Signed-off-by: NLen Brown <len.brown@intel.com>
上级 abb631bf
...@@ -581,7 +581,7 @@ static int __init hp_wmi_init(void) ...@@ -581,7 +581,7 @@ static int __init hp_wmi_init(void)
if (wmi_has_guid(HPWMI_EVENT_GUID)) { if (wmi_has_guid(HPWMI_EVENT_GUID)) {
err = wmi_install_notify_handler(HPWMI_EVENT_GUID, err = wmi_install_notify_handler(HPWMI_EVENT_GUID,
hp_wmi_notify, NULL); hp_wmi_notify, NULL);
if (!err) if (ACPI_SUCCESS(err))
hp_wmi_input_setup(); hp_wmi_input_setup();
} }
......
...@@ -236,7 +236,7 @@ static int __init msi_wmi_init(void) ...@@ -236,7 +236,7 @@ static int __init msi_wmi_init(void)
} }
err = wmi_install_notify_handler(MSIWMI_EVENT_GUID, err = wmi_install_notify_handler(MSIWMI_EVENT_GUID,
msi_wmi_notify, NULL); msi_wmi_notify, NULL);
if (err) if (ACPI_FAILURE(err))
return -EINVAL; return -EINVAL;
err = msi_wmi_input_setup(); err = msi_wmi_input_setup();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册