]> git.karo-electronics.de Git - linux-beck.git/commitdiff
ACPI / osl: implement acpi_os_sleep() with msleep()
authorLiu Chuansheng <chuansheng.liu@intel.com>
Wed, 11 Sep 2013 17:42:57 +0000 (01:42 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 25 Sep 2013 15:08:12 +0000 (17:08 +0200)
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: Liu Chuansheng <chuansheng.liu@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/osl.c

index e5f416c7f66e9e92e1ed988c3a709bc2820d56f4..b1629b571cb26997b53bd1dcae52eff7216cf96f 100644 (file)
@@ -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)