[lkml]   [2005]   [Dec]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [discuss] [patch 3/3] x86_64: Node local pda take 2 -- node local pda allocation
    On Fri, Dec 16, 2005 at 01:19:34AM +0100, Andi Kleen wrote:
    > And for the APs you allocate the PDA in smpboot.c before actually sending
    > the startup IPI to the AP.

    You mean wakeup_secondary_via_INIT, called by do_boot_cpu?
    That is too late. sched_init happens much earlier, and the per-cpu offset
    table for all AP cpus not present is referenced, and I hit an early exception.
    sched_init is executed on the BP very early and sched_init does this:

    for (i = 0; i < NR_CPUS; i++) {
    prio_array_t *array;

    rq = cpu_rq(i);

    The cpu_rq macro ends up needing per-cpu offset table stored in cpu_pda of
    the AP cpus, even before we hit the code to send startup IPIs.
    (#define __per_cpu_offset(cpu) (cpu_pda[cpu].data_offset))
    This is way before slab is ready. So I either use alloc_bootmem before
    sched_init in setup_arch, or keep the static boot_cpu_pda.

    Am I missing something?

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-12-16 04:58    [W:0.020 / U:8.284 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site