On Mon, Oct 03, 2011 at 01:46:46PM +0800, Hillf Danton wrote: > + unsigned int cpu, core_id; > + > + cpu = smp_processor_id(); > + core_id = (cpu >> 2) & 0x7; > + cpu_data[cpu].core = core_id; This is going to break in setups where Linux is not being booted on what the hardware considers CPU core 0. Which is not uncommon in embedded setups. You may want to probe the hardware for the core ID rather than relying on smp_processor_id() here. Ralf