[PATCH] fix stolen time for SMT without LPAR

Paul Mackerras paulus at samba.org
Thu Jun 7 11:33:51 EST 2007


Michael Neuling writes:

> -	if (!cpu_has_feature(CPU_FTR_PURR))
> +	if (!cpu_has_feature(CPU_FTR_PURR) &&
> +	    !firmware_has_feature(FW_FEATURE_SPLPAR))
>  		return;
>  	for_each_possible_cpu(cpu)
>  		spin_lock_init(&per_cpu(cpu_purr_data, cpu).lock);

This means that on a machine with SPLPAR but not a PURR, e.g. a JS21,
we'll try to read the PURR register and do the stolen time calculation
with whatever value was in the register before the mfspr from the
PURR.  If we're going to make this change then we also need to add
code to do the H_PURR hcall instead of reading the PURR directly on
such machines.

Paul.



More information about the Linuxppc-dev mailing list