]> git.baikalelectronics.ru Git - kernel.git/commit
IB/cm: Store and restore ah_attr during CM message processing
authorParav Pandit <parav@mellanox.com>
Mon, 14 May 2018 08:11:09 +0000 (11:11 +0300)
committerJason Gunthorpe <jgg@mellanox.com>
Wed, 16 May 2018 20:11:46 +0000 (14:11 -0600)
commitfe2a818f554f13de3f67083689e2fe049ba317ab
tree11742b699931a9832cbb896dc1a67f892b2758b9
parent17331862915681ec812a04ab0f6ba1c06d0634dc
IB/cm: Store and restore ah_attr during CM message processing

During CM request processing flow, ah_attr is initialized twice.
First based on wc. Secondly based on primary path record.
ah_attr initialization from path record can fail, which leads to ah_attr
zeroed out.

Therefore, always initialize ah_attr on stack during reinitialization
phase. If ah_attr init is successful, use the new ah_attry by
overwriting the old one. If the ah_attr init fails, continue to use the
last ah_attr.

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