Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Dec 2008 12:58:45 +0000 (UTC)
From:      Ed Schouten <ed@FreeBSD.org>
To:        cvs-src-old@freebsd.org
Subject:   cvs commit: src/sys/compat/freebsd32 freebsd32_misc.c src/sys/compat/linux linux_misc.c src/sys/i386/ibcs2 ibcs2_sysi86.c src/sys/kern kern_sysctl.c kern_xxx.c
Message-ID:  <200812291259.mBTCxFw7070392@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
ed          2008-12-29 12:58:45 UTC

  FreeBSD src repository

  Modified files:
    sys/compat/freebsd32 freebsd32_misc.c 
    sys/compat/linux     linux_misc.c 
    sys/i386/ibcs2       ibcs2_sysi86.c 
    sys/kern             kern_sysctl.c kern_xxx.c 
  Log:
  SVN rev 186564 on 2008-12-29 12:58:45Z by ed
  
  Push down Giant inside sysctl. Also add some more assertions to the code.
  
  In the existing code we didn't really enforce that callers hold Giant
  before calling userland_sysctl(), even though there is no guarantee it
  is safe. Fix this by just placing Giant locks around the call to the oid
  handler. This also means we only pick up Giant for a very short period
  of time. Maybe we should add MPSAFE flags to sysctl or phase it out all
  together.
  
  I've also added SYSCTL_LOCK_ASSERT(). We have to make sure sysctl_root()
  and name2oid() are called with the sysctl lock held.
  
  Reviewed by:    Jille Timmermans <jille quis cx>
  
  Revision  Changes    Path
  1.86      +2 -5      src/sys/compat/freebsd32/freebsd32_misc.c
  1.231     +4 -12     src/sys/compat/linux/linux_misc.c
  1.24      +2 -6      src/sys/i386/ibcs2/ibcs2_sysi86.c
  1.183     +23 -19    src/sys/kern/kern_sysctl.c
  1.55      +16 -34    src/sys/kern/kern_xxx.c



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