[ofa-general] Re: does ibv_modify_qp() check error ?

Michael S. Tsirkin mst at dev.mellanox.co.il
Tue Aug 21 10:38:07 PDT 2007


> Quoting Tang, Changqing <changquing.tang at hp.com>:
> Subject: does ibv_modify_qp() check  error ?
> 
>  
> Hi, if anyone can answer,
> 
> 	I have a question about ibv_modify_qp() behavior. I use
> ibv_modify_qp() to move QP state from INIT to RTR and then RTS.
> when INIT-->RTR, I need to provide peer's qp number and port lid. If qp
> number and port lid are not correct (for example, both
> QPs are connected to different switch, and there is no bridge link
> between the switches), my code is silently hanging.
> 
> 	Does ibv_modify_qp() check such error, or is there other way to
> detect such error ? so my code can error out, not hanging ?
> 
> 	Thanks.

Try posting a WR, e.g. a 0 size RDMA write.
You'll get a CQE with error if the QPN is wrong.

-- 
MST



More information about the general mailing list