Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Jun 2009 09:16:52 +0000 (UTC)
From:      Brian Somers <brian@FreeBSD.org>
To:        cvs-src-old@freebsd.org
Subject:   cvs commit: src/sys/kern kern_malloc.c
Message-ID:  <200906050917.n559H6IT064306@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help

brian       2009-06-05 09:16:52 UTC

  FreeBSD src repository

  Modified files:
    sys/kern             kern_malloc.c 
  Log:
  SVN rev 193490 on 2009-06-05 09:16:52Z by brian
  
  If we're passed garbage in malloc_init(), panic() rather than expecting
  a KASSERT to handle it.  People are likely to turn off INVARIANTS RSN
  and loading an old module can cause garbage-in here.
  
  I saw the issue with an older nvidia driver (x11/nvidia-driver) loading
  into a new kernel - a crash wasn't seen 'till sysctl_kern_malloc_stats().
  I was lucky that mtp->ks_shortdesc was NULL and not something horrible.
  
  While I'm here, KASSERT that malloc_uninit() isn't passed something that's
  not in kmemstatistics.
  
  MFC after:      3 weeks
  
  Revision  Changes    Path
  1.172     +7 -3      src/sys/kern/kern_malloc.c



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