From owner-freebsd-hackers@FreeBSD.ORG Wed Feb 6 16:06:52 2013 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CF31A80C; Wed, 6 Feb 2013 16:06:52 +0000 (UTC) (envelope-from gnn@neville-neil.com) Received: from vps.hungerhost.com (vps.hungerhost.com [216.38.53.176]) by mx1.freebsd.org (Postfix) with ESMTP id A9FA3695; Wed, 6 Feb 2013 16:06:52 +0000 (UTC) Received: from [38.105.238.108] (port=56842 helo=[10.7.1.235]) by vps.hungerhost.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.80) (envelope-from ) id 1U37WK-0002Sj-KG; Wed, 06 Feb 2013 11:06:51 -0500 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) Subject: Re: dtrace vs module unloading From: George Neville-Neil In-Reply-To: <51051C61.4060608@FreeBSD.org> Date: Wed, 6 Feb 2013 11:06:52 -0500 Content-Transfer-Encoding: quoted-printable Message-Id: References: <51051C61.4060608@FreeBSD.org> To: Andriy Gapon X-Mailer: Apple Mail (2.1499) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vps.hungerhost.com X-AntiAbuse: Original Domain - freebsd.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - neville-neil.com X-Get-Message-Sender-Via: vps.hungerhost.com: authenticated_id: gnn@neville-neil.com X-Mailman-Approved-At: Wed, 06 Feb 2013 16:46:41 +0000 Cc: freebsd-hackers@FreeBSD.org X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Feb 2013 16:06:52 -0000 On Jan 27, 2013, at 07:24 , Andriy Gapon wrote: >=20 > It seems that FreeBSD DTrace currently does not track module loading / = unloading > at all. dtrace_module_loaded/dtrace_module_unloaded are both under = ifdef sun. >=20 > I think that this is a root cause of e.g. fbt probes for some = functions > remaining after a module that provides the functions is unloaded. >=20 > It looks like currently we do not post any event when a module gets = loaded / > unloaded. Perhaps this is one of the factors in current situation. > OTOH, in Solaris they just have some dtrace hooks in the form of = function > pointers directly in the module handling code (equivalent of our = kern_linker). >=20 Hrm, sounds like a bug more than anythign else. I don't know enough yet = to say how to solve this but if you want to track this you're welcome to create a PR and = assign it to me. Best, George