[ewg] Link available/unavailable notification

Sandeep Dhavale Sandeep_Dhavale at symantec.com
Wed Feb 6 18:21:53 PST 2013


Hi,
Is there any API in the Linux kernel to register for change in Link/port state of HCA or event like cable pull etc? 

>From user land "ibv_devinfo -v" tells us the current link state. From IB spec It can be 

"Link Unavaliable" states
a.	LinkDown state
b.	LinkInitialize state
c.	LinkArm state

"Link Avaliable" states
d.	LinkActive state
e.	LinkActDefer state

I initially thought that with the use of ib_register_event_handler() I can achieve this. But after reading a little bit more (IB spec chapter 11 and chapter 7) it looks like only one such handler can be registered with the device. So if my module has to co-exist with any other kernel module using the IB device for such events, this approach may not work. Any comments on this? I am simply interested in getting to know the change in port status as soon as it is done (event based approach preferred than polling for it).

Thanks,
Sandeep.



More information about the ewg mailing list