Messages in this thread | | | Subject | Re: [PATCH] kernel: x86: tboot: Replace mdelay with usleep_range in tboot_wait_for_aps | From | Jia-Ju Bai <> | Date | Wed, 24 Jan 2018 21:37:46 +0800 |
| |
On 2018/1/24 19:47, Thomas Gleixner wrote: > On Wed, 24 Jan 2018, Jia-Ju Bai wrote: > >> The function tboot_wait_for_aps is not called in atomic context. >> Thus mdelay can be replaced with usleep_range, to reduce busy wait. > And how did you establish that it's not called in atomic context? > > Thanks, > > tglx
It is reported by a static analysis tool written by myself. This tool finds that mdelay in tboot_wait_for_aps is not called by holding a spinlock or in an interrupt handler, thus mdelay can be replaced.
Thanks, Jia-Ju Bai
| |