Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 23 Jun 2011 22:21:28 +0000 (UTC)
From:      Nathan Whitehorn <nwhitehorn@FreeBSD.org>
To:        cvs-src-old@freebsd.org
Subject:   cvs commit: src/sys/powerpc/aim copyinout.c locore32.S locore64.S machdep.c mp_cpudep.c swtch32.S swtch64.S trap.c trap_subr32.S trap_subr64.S src/sys/powerpc/booke copyinout.c interrupt.c trap.c src/sys/powerpc/include pcpu.h src/sys/powerpc/ofw ofwcall32.S ...
Message-ID:  <201106232221.p5NMLp5q077606@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
nwhitehorn    2011-06-23 22:21:28 UTC

  FreeBSD src repository

  Modified files:
    sys/powerpc/aim      copyinout.c locore32.S locore64.S 
                         machdep.c mp_cpudep.c swtch32.S swtch64.S 
                         trap.c trap_subr32.S trap_subr64.S 
    sys/powerpc/booke    copyinout.c interrupt.c trap.c 
    sys/powerpc/include  pcpu.h 
    sys/powerpc/ofw      ofwcall32.S 
    sys/powerpc/powerpc  mp_machdep.c 
  Log:
  SVN rev 223485 on 2011-06-23 22:21:28Z by nwhitehorn
  
  Use the ABI-mandated thread pointer register (r2 for ppc32, r13 for ppc64)
  instead of a PCPU field for curthread. This averts a race on SMP systems
  with a high interrupt rate where the thread looking up the value of
  curthread could be preempted and migrated between obtaining the PCPU
  pointer and reading the value of pc_curthread, resulting in curthread being
  observed to be the current thread on the thread's original CPU. This played
  merry havoc with the system, in particular with mutexes. Many thanks to
  jhb for helping me work this one out.
  
  Note that Book-E is in principle susceptible to the same problem, but has
  not been modified yet due to lack of Book-E hardware.
  
  MFC after:      2 weeks
  
  Revision  Changes    Path
  1.25      +11 -11    src/sys/powerpc/aim/copyinout.c
  1.3       +1 -2      src/sys/powerpc/aim/locore32.S
  1.5       +1 -2      src/sys/powerpc/aim/locore64.S
  1.155     +2 -2      src/sys/powerpc/aim/machdep.c
  1.14      +1 -1      src/sys/powerpc/aim/mp_cpudep.c
  1.4       +8 -10     src/sys/powerpc/aim/swtch32.S
  1.6       +8 -10     src/sys/powerpc/aim/swtch64.S
  1.92      +3 -3      src/sys/powerpc/aim/trap.c
  1.5       +10 -4     src/sys/powerpc/aim/trap_subr32.S
  1.8       +9 -4      src/sys/powerpc/aim/trap_subr64.S
  1.3       +8 -8      src/sys/powerpc/booke/copyinout.c
  1.7       +1 -1      src/sys/powerpc/booke/interrupt.c
  1.9       +3 -3      src/sys/powerpc/booke/trap.c
  1.35      +8 -0      src/sys/powerpc/include/pcpu.h
  1.2       +8 -6      src/sys/powerpc/ofw/ofwcall32.S
  1.40      +0 -4      src/sys/powerpc/powerpc/mp_machdep.c



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