Hmm. I guess what you really need is to be able to determine if the
thing is a module. Which might come in handy for other things as well.
Have a look at what the scsi subsystem does with its
if (rscsi_disks[target].device->host->hostt->module)
__MOD_INC_USE_COUNT(rscsi_disks[target].device->host->hostt->module);
It gets set via init_module in scsi_module.c, btw.
r~