Jim Crumley wrote:
> 
> On Fri, Sep 07, 2001 at 11:20:55AM -0500, Jesse Erdmann wrote:
> > Does anyone know a way to programtically tell what module a NIC is
> > using, or alternatively find out which NICs are using a particular
> > module?
> >
> > For instance, say you have a machine with two eepro100s and a 3c509b.  I
> > need a way to determine which, if any are using the 3c509b module.  I
> > don't care if it's a tool like ifconfig or some ioctl that I could whip
> > up a C proggie to use.
> 
> Is /proc/modules or /proc/ioports enough info?

/proc/modules tells me how many devices are using a specific module, but
it doesn't tell me which ones.  I really need to know something like
ethX is using moduleX.  I need to send an ioctl with the name of the
device (eth0, eth1, etc).  If I use eth1 when eth1 is using some other
module, that ioctl might mean something very different to the module
eth1 is using.  That could cause bad things to happen.

-- 

Jesse Erdmann 
Engineer 
Secure Computing Corp.