IB/cm: Store and restore ah_attr during LAP msg processing
authorParav Pandit <parav@mellanox.com>
Mon, 14 May 2018 08:11:08 +0000 (11:11 +0300)
committerJason Gunthorpe <jgg@mellanox.com>
Wed, 16 May 2018 20:11:46 +0000 (14:11 -0600)
commit0e225dcb7681c0a8e52fb9dc68bd8ab973de4ca2
tree24b3330a9794d08c1e477958c36c1a6e2d619f29
parenta5c57d327272bdf3a8b19686eaca2ec683449e67
IB/cm: Store and restore ah_attr during LAP msg processing

During CM LAP processing, ah_attr is reinitialized on receiving LAP
request. First likely during CM request processing.

ah_attr might get zero out if LAP processing fails.
Therefore, attempt to create new ah_attr for the LAP message.
If the initialization fails, continue with older ah_attr.
If the initialization passes, consider the new ah_attr by overwriting
the older one.

Signed-off-by: Parav Pandit <parav@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/core/cm.c