Re: [PATCH] platform: x86: intel_scu_ipc: Replace mdelay with usleep_range in intel_scu_ipc_i2c_cntrl

2018-04-10 Thread Andy Shevchenko
On Tue, Apr 10, 2018 at 3:57 PM, Jia-Ju Bai wrote: > intel_scu_ipc_i2c_cntrl() calls mutex_lock(), which indicates > this function is not called in atomic context. > > Despite never getting called from atomic context, > intel_scu_ipc_i2c_cntrl() calls mdelay to busily

Re: [PATCH] platform: x86: intel_scu_ipc: Replace mdelay with usleep_range in intel_scu_ipc_i2c_cntrl

2018-04-10 Thread Andy Shevchenko
On Tue, Apr 10, 2018 at 3:57 PM, Jia-Ju Bai wrote: > intel_scu_ipc_i2c_cntrl() calls mutex_lock(), which indicates > this function is not called in atomic context. > > Despite never getting called from atomic context, > intel_scu_ipc_i2c_cntrl() calls mdelay to busily wait. > This is not

[PATCH] platform: x86: intel_scu_ipc: Replace mdelay with usleep_range in intel_scu_ipc_i2c_cntrl

2018-04-10 Thread Jia-Ju Bai
intel_scu_ipc_i2c_cntrl() calls mutex_lock(), which indicates this function is not called in atomic context. Despite never getting called from atomic context, intel_scu_ipc_i2c_cntrl() calls mdelay to busily wait. This is not necessary and can be replaced with usleep_range to avoid busy waiting.

[PATCH] platform: x86: intel_scu_ipc: Replace mdelay with usleep_range in intel_scu_ipc_i2c_cntrl

2018-04-10 Thread Jia-Ju Bai
intel_scu_ipc_i2c_cntrl() calls mutex_lock(), which indicates this function is not called in atomic context. Despite never getting called from atomic context, intel_scu_ipc_i2c_cntrl() calls mdelay to busily wait. This is not necessary and can be replaced with usleep_range to avoid busy waiting.