[linux-pm] [PATCH 02/12] powermac: support G5 CPU hotplug

Paul Mackerras paulus at samba.org
Fri Feb 9 08:59:53 EST 2007


Johannes Berg writes:

> +#ifdef CONFIG_CPU_HOTPLUG
> +	/* if we have fake CPU hotplug just to support suspend to disk
> +	 * and can't really turn off a CPU, it may be taking timer interrupts
> +	 * even when it is dead. Avoid doing anything in that case so global
> +	 * state is not modified for and by a CPU that doesn't really exist. */
> +	if (__get_cpu_var(cpu_state) == CPU_DEAD)
> +		return;
> +#endif

Are you sure this is necessary?  IIRC, the if (!cpu_is_offline(cpu)) a
little bit further down is there to cope with this exact situation.
And cpu hotplug already works on G4 SMP powermacs, where we can't
physically remove the cpu either - we just put it into sleep mode with
interrupts disabled, which is what we would be doing on a G5 powermac
also.

Paul.



More information about the Linuxppc-dev mailing list