Re: how to check if a module has been loaded

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 13, 2001 at 03:33:14AM -0800, Amit Kulkarni wrote:
> Hello all !
> 
> Is there a fast way to check if a particular module
> has been loaded ?
> I want to check if a module is loaded whenever apacket
> comes (so might be required to do it 100000 times/s
> !!!)

If you need to do it from kernelspace maybe a fast
way is to export some atomic var that the module
set on init and unset on cleanup, so you need just
a fast if() condition to test for the module.

-- 
Salvatore Sanfilippo <antirez@invece.org>
http://www.kyuzz.org/antirez
finger antirez@tella.alicom.com for PGP key
28 52 F5 4A 49 65 34 29 - 1D 1B F6 DA 24 C7 12 BF
--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
IRC Channel:   irc.openprojects.net / #kernelnewbies
Web Page:      http://www.kernelnewbies.org/



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux