Hi,

I got a simple (probably silly question) while we were trying to hook
a system call few days back in one of the threads posted earlier.
Let's say I want to log all the users/calls of someone calling
kmem_cache_alloc() after the system has come up ie... any external
module which might be calling this during load.

 If I just add a printk to log it will record all the calls, not the
one which were made after the kernel came up and we logged into the
system (or userspace scripts loaded some module during booting). So
the basic question is how do i conditionalize this printk. From kernel
how can I know that my system is still booting or it has come up ?? Is
there any global variable for example which says kernel_state=BOOTING
or any other way which tells me in what phase of booting are we ? If
it were I could have easily done something like :-

if (kernel_state  >= BOOT_COMPLETE)
       printk(...........);

Makes sense ???

Thanks -
Manish

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to [EMAIL PROTECTED]
Please read the FAQ at http://kernelnewbies.org/FAQ

Reply via email to