Date: Tue, 8 Nov 2011 15:17:54 +0000 (UTC) From: Ryan Stone <rstone@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r227342 - head/sys/kern Message-ID: <201111081517.pA8FHtdF036980@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rstone Date: Tue Nov 8 15:17:54 2011 New Revision: 227342 URL: http://svn.freebsd.org/changeset/base/227342 Log: The in-kernel CTF parser caches the result of its first attempt to parse CTF data from a module. On subsequent attempts to retrieve CTF data for a module, return an error if there no CTF data. This fixes a panic if you try to enable fbt probes on a module with CTF data twice. Submitted by: Paul Ambrose (ambrosehua AT gmail DOT com) MFC after: 3 days Modified: head/sys/kern/kern_ctf.c Modified: head/sys/kern/kern_ctf.c ============================================================================== --- head/sys/kern/kern_ctf.c Tue Nov 8 14:47:28 2011 (r227341) +++ head/sys/kern/kern_ctf.c Tue Nov 8 15:17:54 2011 (r227342) @@ -90,7 +90,7 @@ link_elf_ctf_get(linker_file_t lf, linke * ctfcnt to -1. See below. */ if (ef->ctfcnt < 0) - return (0); + return (EFTYPE); /* Now check if we've already loaded the CTF data.. */ if (ef->ctfcnt > 0) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201111081517.pA8FHtdF036980>