On Thu, 2011-03-10 at 11:23 -0600, Meador Inge wrote: > I agree. I shouldn't have cached that. We should probably introduce a > helper function to get the cpuid, though. The: > > unsigned int cpu = 0; > > if (mpic->flags & MPIC_PRIMARY) > cpu = hard_smp_processor_id(); > > code is scattered in three places: '_mpic_cpu_write', '_mpic_cpu_read', > and 'mpic_init'.
Right, but that code must act on the current CPU, not a cached per-MPIC variant. Doing a helper to factor the above 2 lines is fine if you wish to do so but then make it a separate patch. Cheers, Ben. _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev