1. 16 Jan, 2009 7 commits
    • Tejun Heo's avatar
      x86: use static _cpu_pda array · c8f3329a
      Tejun Heo authored
      _cpu_pda array first uses statically allocated storage in data.init
      and then switches to allocated bootmem to conserve space.  However,
      after folding pda area into percpu area, _cpu_pda array will be
      removed completely.  Drop the reallocation part to simplify the code
      for soon-to-follow changes.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      c8f3329a
    • Tejun Heo's avatar
      x86: load pointer to pda into %gs while brining up a CPU · f32ff538
      Tejun Heo authored
      [ Based on original patch from Christoph Lameter and Mike Travis. ]
      
      CPU startup code in head_64.S loaded address of a zero page into %gs
      for temporary use till pda is loaded but address to the actual pda is
      available at the point.  Load the real address directly instead.
      
      This will help unifying percpu and pda handling later on.
      
      This patch is mostly taken from Mike Travis' "x86_64: Fold pda into
      per cpu area" patch.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      f32ff538
    • Tejun Heo's avatar
      x86: make percpu symbols zerobased on SMP · 3e5d8f97
      Tejun Heo authored
      [ Based on original patch from Christoph Lameter and Mike Travis. ]
      
      This patch makes percpu symbols zerobased on x86_64 SMP by adding
      PERCPU_VADDR() to vmlinux.lds.h which helps setting explicit vaddr on
      the percpu output section and using it in vmlinux_64.lds.S.  A new
      PHDR is added as existing ones cannot contain sections near address
      zero.  PERCPU_VADDR() also adds a new symbol __per_cpu_load which
      always points to the vaddr of the loaded percpu data.init region.
      
      The following adjustments have been made to accomodate the address
      change.
      
      * code to locate percpu gdt_page in head_64.S is updated to add the
        load address to the gdt_page offset.
      
      * __per_cpu_load is used in places where access to the init data area
        is necessary.
      
      * pda->data_offset is initialized soon after C code is entered as zero
        value doesn't work anymore.
      
      This patch is mostly taken from Mike Travis' "x86_64: Base percpu
      variables at zero" patch.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      3e5d8f97
    • Tejun Heo's avatar
      x86: make vmlinux_32.lds.S use PERCPU() macro · a698c823
      Tejun Heo authored
      Make vmlinux_32.lds.S use the generic PERCPU() macro instead of open
      coding it.  This will ease future changes.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      a698c823
    • Mike Travis's avatar
      x86: cleanup early setup_percpu references · c90aa894
      Mike Travis authored
      [ Based on original patch from Christoph Lameter and Mike Travis. ]
      
        * Ruggedize some calls in setup_percpu.c to prevent mishaps
          in early calls, particularly for non-critical functions.
      
        * Cleanup DEBUG_PER_CPU_MAPS usages and some comments.
      Signed-off-by: default avatarMike Travis <travis@sgi.com>
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      c90aa894
    • Tejun Heo's avatar
      x86: make early_per_cpu() a lvalue and use it · f10fcd47
      Tejun Heo authored
      Make early_per_cpu() a lvalue as per_cpu() is and use it where
      applicable.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      f10fcd47
    • Tejun Heo's avatar
      x86: fix pda_to_op() · 7de6883f
      Tejun Heo authored
      There's no instruction to move a 64bit immediate into memory location.
      Drop "i".
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      7de6883f
  2. 15 Jan, 2009 5 commits
  3. 14 Jan, 2009 6 commits
  4. 13 Jan, 2009 22 commits