提交 30282299 编写于 作者: L Liu Chuansheng 提交者: Rafael J. Wysocki

ACPI / osl: implement acpi_os_sleep() with msleep()

Currently, acpi_os_sleep() uses schedule_timeout_interruptible()
which can be interrupted by a signal, and that causes the real sleep
time to be shorter.

According to the ACPI spec:

 The Sleep term is used to implement long-term timing requirements.
 Execution is delayed for at least the required number of milliseconds.

The sleeping time should be at least the required number msecs, so use
msleep() which guarantees that to implement it.
Signed-off-by: NLiu Chuansheng <chuansheng.liu@intel.com>
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 4a10c2ac
......@@ -820,7 +820,7 @@ acpi_status acpi_os_remove_interrupt_handler(u32 irq, acpi_osd_handler handler)
void acpi_os_sleep(u64 ms)
{
schedule_timeout_interruptible(msecs_to_jiffies(ms));
msleep(ms);
}
void acpi_os_stall(u32 us)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册