Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 Jan 2010 01:54:29 +0000 (UTC)
From:      Neel Natu <neel@FreeBSD.org>
To:        cvs-src-old@freebsd.org
Subject:   cvs commit: src/sys/mips/include cpu.h pcpu.h src/sys/mips/mips genassym.c locore.S machdep.c pmap.c
Message-ID:  <201001300154.o0U1slbH052176@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
neel        2010-01-30 01:54:29 UTC

  FreeBSD src repository

  Modified files:
    sys/mips/include     cpu.h pcpu.h 
    sys/mips/mips        genassym.c locore.S machdep.c pmap.c 
  Log:
  SVN rev 203180 on 2010-01-30 01:54:29Z by neel
  
  Provide access to pcpu structures for SMP kernels.
  
  The basic idea is to use a the same virtual address as a window onto
  distinct physical memory locations - one per processor. The physical
  address that you access through this mapping depends on which cpu you
  are currently executing on. We can now use the same virtual address
  on any processor to access its per-cpu area.
  
  The details are:
  
  - The virtual address for 'struct pcpu *pcpup' is obtained by
    stealing 2 pages worth of KVA in pmap_bootstrap().
  
  - The mapping from the constant virtual address to a distinct
    physical page is done in cpu_pcpu_init() through a wired TLB entry.
  
  - A side-effect of this is that we reserve 2 pages worth of memory
    for the pcpu but in reality it needs much less than that. The unused
    memory is now used as the boot stack for the BSP and APs.
  
  Remove SMP-specific bits from locore.S. The plan is to use a separate
  mpboot.S for AP bootstrap.
  
  Discussed on: freebsd-mips
  
  Approved by: imp (mentor)
  
  Revision  Changes    Path
  1.4       +8 -0      src/sys/mips/include/cpu.h
  1.3       +4 -24     src/sys/mips/include/pcpu.h
  1.3       +0 -1      src/sys/mips/mips/genassym.c
  1.5       +9 -80     src/sys/mips/mips/locore.S
  1.20      +43 -12    src/sys/mips/mips/machdep.c
  1.28      +13 -2     src/sys/mips/mips/pmap.c



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001300154.o0U1slbH052176>