Re: when and how Notifier Chains calling?

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

 





On Tue, Nov 1, 2011 at 6:38 PM, vichy <vichy.kuo@xxxxxxxxx> wrote:
hi all:
if I register a user-defined notification chain as below:
blocking_notifier_chain_register(&my_noti_chain, &my_notifier);
under what circumstances it will be called?


Hi,

If you are asking when does the above register function will be called,
then you should call it whenever any other code path tries to register its
callback function to your new notifier event.

However, in case you are asking when the actual callbacks registered for
your new notifier are called, then they are called when you call
blocking_notifier_call_chain() function.

Refer to kernel/power/main.c for an example.

Regards,
Srivatsa S. Bhat
 
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

[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