Re: [RFC PATCH 7/8] x86/lib_user_wait.h: Add APIs for user wait instructions

From: Thomas Gleixner
Date: Tue Jun 19 2018 - 05:12:20 EST


On Fri, 15 Jun 2018, Fenghua Yu wrote:

> A few new user wait instructions UMONITOR, UMWAIT, and TPAUSE are
> published in the latest Intel Instruction Set Extensions document.
>
> Define the APIs for user or kernel to use the instructions.

You're not defining APIs. You're adding a pile of misdesigned helper
functions which again add static storage per compilation unit and CPUID
fiddling.

If you want to add proper APIs then add the stuff to the VDSO and be done
with it.

Thanks,

tglx