]> git.baikalelectronics.ru Git - kernel.git/commit
platform/x86: intel_scu_ipc: Sleeping is fine when polling
authorMika Westerberg <mika.westerberg@linux.intel.com>
Wed, 22 Jan 2020 16:28:08 +0000 (19:28 +0300)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Wed, 22 Jan 2020 16:52:16 +0000 (18:52 +0200)
commit49178b3f0726deae54e840159668d79b8fe9efaf
tree020916ab2d66ceea8806c705a6de6b7c6c4cde63
parenta26673f81df13fccad7f6533f1fba6967707e7c4
platform/x86: intel_scu_ipc: Sleeping is fine when polling

There is no reason why the driver would need to block other threads from
running the CPU while it is waiting for the SCU IPC to complete its
work. For this reason switch the driver to use usleep_range() instead
with a bit more relaxed polling loop.

Also add constant for the timeout and use the same value for both
polling and interrupt modes.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/platform/x86/intel_scu_ipc.c