Date: Sat, 21 Nov 2009 20:51:22 -0500 From: David Horn <dhorn2000@gmail.com> To: "James R. Van Artsdalen" <james-freebsd-current@jrv.org> Cc: FreeBSD Current <freebsd-current@freebsd.org> Subject: Re: kldstat bug? Message-ID: <25ff90d60911211751l634c3cb6w8a66ee040e2c7189@mail.gmail.com> In-Reply-To: <4B0848EB.4070002@jrv.org> References: <4B0848EB.4070002@jrv.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Nov 21, 2009 at 3:09 PM, James R. Van Artsdalen <james-freebsd-current@jrv.org> wrote: > amd64, svn 199260, November 13, 2009 > > Is this behavior of kldstat a bug? =A0Some modules found, some not, and > the Id field differs even in success. > > # kldstat > Id Refs Address =A0 =A0 =A0 =A0 =A0 =A0Size =A0 =A0 Name > =A01 =A0 19 0xffffffff80100000 f15ee8 =A0 kernel > =A02 =A0 =A01 0xffffffff81016000 194220 =A0 zfs.ko > =A03 =A0 =A02 0xffffffff811ab000 3928 =A0 =A0 opensolaris.ko > =A04 =A0 =A01 0xffffffff811af000 24560 =A0 =A0geom_mirror.ko > =A05 =A0 =A01 0xffffffff811d4000 9ac0 =A0 =A0 siis.ko > =A06 =A0 =A01 0xffffffff811de000 d0a8 =A0 =A0 ahci.ko > # kldstat -m zfs > Id =A0Refs Name > =A03 =A0 =A01 zfs > # kldstat -m opensolaris > Id =A0Refs Name > =A01 =A0 =A01 opensolaris > # kldstat -m geom_mirror > kldstat: can't find module geom_mirror: No such file or directory > # kldstat -m siis > kldstat: can't find module siis: No such file or directory > # kldstat -m ahci > kldstat: can't find module ahci: No such file or directory > # > If you try using kldstat -v (verbose), you will likely understand a little better. There is a file id (for kernel modules *files* like siis.ko), and there are module ids (for individual modules within the kernel module file). The relationship is not necessarily 1:1, as there can be more than 1 module per kernel module file). For example: 24 1 0xffffffff810a1000 3c13 siis.ko (/boot/kernel/siis.ko) Contains modules: Id Name 440 siis/siisch 441 pci/siis Notice that the kernel module file (siis.ko) has an id of 24, and the modules in that file (siis/siisch and pci/siis) each have there own module id (440 and 441 repectively). If you would do a kldstat -m pci/siis you would be able to find that since the -m flag requires a module name, not a kernel module file name. Yes, module name versus kernel module file name and file id vs module id can cause confusion. Good Luck. ---Dave
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?25ff90d60911211751l634c3cb6w8a66ee040e2c7189>