Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Jul 2016 10:14:04 -0700
From:      Mark Johnston <markj@FreeBSD.org>
To:        Julian Elischer <julian@freebsd.org>
Cc:        freebsd-dtrace@freebsd.org, freebsd-current <freebsd-current@freebsd.org>
Subject:   Re: dtrace and kernel modules
Message-ID:  <20160712171404.GB71220@wkstn-mjohnston.west.isilon.com>
In-Reply-To: <d99a41d6-fe55-fb09-4466-c1d8082a40d6@freebsd.org>
References:  <d99a41d6-fe55-fb09-4466-c1d8082a40d6@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jul 07, 2016 at 12:51:52PM +0800, Julian Elischer wrote:
> I'm specifically interested in the case of kernel modules that 
> instantiate new syscalls.
> 
> How much support do we have for that?  In the one example in our 
> sources of a kld with a syscall (kgssapi.ko) dtrace seems to find 
> regular function entrypoints but not the syscall.
> 
> 
> root@porridge:/usr/src # dtrace -n ":kgssapi::entry {}"
> dtrace: description ':kgssapi::entry ' matched 138 probes
> ^C
> 
> root@porridge:/usr/src # dtrace -n "syscall:kgssapi::entry {}"
> dtrace: invalid probe specifier syscall:kgssapi::entry {}: probe 
> description syscall:kgssapi::entry does not match any probes
> root@porridge:/usr/src #
> 
> 
> Do we have plans to support dynamic syscall support?

I don't know of any plans to add support. It would be fairly
straightforward to dynamically create syscall probes using a hook or
eventhandler in syscall_register(), but getting argument type info would
be more difficult. Right now, argument types are specified by code
generated by makesyscalls.sh using the types in syscalls.master. I'm not
sure how one might obtain these types for dynamically-registered
syscalls.



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