cpu/hotplug: Get rid of cpu_dying_mask

The cpu_dying_mask is not only undocumented but also to some extent a
misnomer. It's purpose is to capture the last direction of a cpu_up() or
cpu_down() operation taking eventual rollback operations into account.  The
name and the lack of documentation lured already someone to use it in the
wrong way.

The initial user is the scheduler code which needs to keep the decision
correct whether to schedule tasks on a CPU, which is between the
CPUHP_ONLINE and the CPUHP_ACTIVE state and has the balance_push() hook
installed.

cpu_dying mask is not really useful for general consumption. The
cpu_dying_mask bits are sticky even after cpu_up() or cpu_down()
completes. 

It might be argued, that the cpu_dying_mask bit could be cleared when
cpu_down() completes, but that's not possible under all circumstances.

Especially not with partial hotplug operations. In that case the bit must
be sticky in order to keep the initial user, i.e. the scheduler correct.

Replace the cpumask completely by:

  - recording the direction internally in the CPU hotplug core state

  - exposing that state via a documented function to the scheduler

After that cpu_dying_mask is not longer in use and removed before the next
user trips over it.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
4 files changed