RDMA/hns: Simplify the state judgment code of qp
authorLang Cheng <chenglang@huawei.com>
Wed, 15 Apr 2020 08:14:34 +0000 (16:14 +0800)
committerJason Gunthorpe <jgg@mellanox.com>
Fri, 24 Apr 2020 13:19:11 +0000 (10:19 -0300)
commit357f342946860b323d1981cc42370516dbb209d2
treed452f80797ac82ede35a8fd79d30e7504f7e5740
parent7c044adca272768d821921f11d3da4587dcec68a
RDMA/hns: Simplify the state judgment code of qp

Use state table to make the qp state migrate code more readable.

Link: https://lore.kernel.org/r/1586938475-37049-6-git-send-email-liweihang@huawei.com
Signed-off-by: Lang Cheng <chenglang@huawei.com>
Signed-off-by: Weihang Li <liweihang@huawei.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/hns/hns_roce_hw_v2.c