cpuidle: Handle TIF_NR_POLLING on behalf of software polling idle states

Software polling idle states set again TIF_NR_POLLING and clear it upon
exit. This involves error prone duplicated code and wasted cycles
performing atomic operations, sometimes RmW fully ordered.

To avoid this, benefit instead from the same generic TIF_NR_POLLING
handling that is currently in use for hardware monitoring states.

Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
4 files changed