summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_linker.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1998-10-10 02:29:07 +0000
committerpeter <peter@FreeBSD.org>1998-10-10 02:29:07 +0000
commitf763ec5d8107e2ef2422b057ab5bd5e1e3752c4c (patch)
tree6205cab318a23215b566b9c47b1ab29b69baf04d /sys/kern/kern_linker.c
parent35e06a4cdd1b5dee7b148baad7660390eae63d94 (diff)
downloadFreeBSD-src-f763ec5d8107e2ef2422b057ab5bd5e1e3752c4c.zip
FreeBSD-src-f763ec5d8107e2ef2422b057ab5bd5e1e3752c4c.tar.gz
Display module type as well as module name when we find one preloaded.
Diffstat (limited to 'sys/kern/kern_linker.c')
-rw-r--r--sys/kern/kern_linker.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/sys/kern/kern_linker.c b/sys/kern/kern_linker.c
index 3f15f0e..5435e66 100644
--- a/sys/kern/kern_linker.c
+++ b/sys/kern/kern_linker.c
@@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: kern_linker.c,v 1.7 1998/08/12 08:44:21 dfr Exp $
+ * $Id: kern_linker.c,v 1.8 1998/10/10 00:07:53 peter Exp $
*/
#include "opt_ddb.h"
@@ -685,6 +685,7 @@ linker_preload(void* arg)
{
caddr_t modptr;
char *modname;
+ char *modtype;
linker_file_t lf;
linker_class_t lc;
int error;
@@ -692,15 +693,19 @@ linker_preload(void* arg)
struct sysinit **sipp;
moduledata_t *moddata;
-
modptr = NULL;
while ((modptr = preload_search_next_name(modptr)) != NULL) {
modname = (char *)preload_search_info(modptr, MODINFO_NAME);
+ modtype = (char *)preload_search_info(modptr, MODINFO_TYPE);
if (modname == NULL) {
printf("Preloaded module at 0x%p does not have a name!\n", modptr);
continue;
}
- printf("Preloaded module %s at 0x%p.\n", modname, modptr);
+ if (modtype == NULL) {
+ printf("Preloaded module at 0x%p does not have a type!\n", modptr);
+ continue;
+ }
+ printf("Preloaded %s \"%s\" at 0x%p.\n", modtype, modname, modptr);
lf = linker_find_file_by_name(modname);
if (lf) {
lf->userrefs++;
OpenPOWER on IntegriCloud