From 9dec415fef268455335c088626d24f3cd5dd26fc Mon Sep 17 00:00:00 2001 From: jb Date: Mon, 22 Oct 2007 04:12:57 +0000 Subject: Add the full module path name to the kld_file_stat structure for kldstat(2). This allows libdtrace to determine the exact file from which a kernel module was loaded without having to guess. The kldstat(2) API is versioned with the size of the kld_file_stat structure, so this change creates version 2. Add the pathname to the verbose output of kldstat(8) too. MFC: 3 days --- lib/libc/sys/kldstat.2 | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lib/libc') diff --git a/lib/libc/sys/kldstat.2 b/lib/libc/sys/kldstat.2 index 946417a..f2ca2a6 100644 --- a/lib/libc/sys/kldstat.2 +++ b/lib/libc/sys/kldstat.2 @@ -53,6 +53,7 @@ struct kld_file_stat { int id; caddr_t address; /* load address */ size_t size; /* size in bytes */ + char pathname[MAXPATHLEN]; }; .Ed .Pp @@ -77,6 +78,10 @@ The id of the file specified in The load address of the kld file. .It size The size of the file. +.It pathname +The full name of the file referred to by +.Fa fileid , +including the path. .El .Sh RETURN VALUES .Rv -std kldstat -- cgit v1.1