]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
RDMA/hns: Include hnae3.h in hns_roce_hw_v2.h
authorJunxian Huang <huangjunxian6@hisilicon.com>
Mon, 21 Apr 2025 13:27:49 +0000 (21:27 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Jun 2025 10:05:12 +0000 (11:05 +0100)
[ Upstream commit 2b11d33de23262cb20d1dcb24b586dbb8f54d463 ]

hns_roce_hw_v2.h has a direct dependency on hnae3.h due to the
inline function hns_roce_write64(), but it doesn't include this
header currently. This leads to that files including
hns_roce_hw_v2.h must also include hnae3.h to avoid compilation
errors, even if they themselves don't really rely on hnae3.h.
This doesn't make sense, hns_roce_hw_v2.h should include hnae3.h
directly.

Fixes: d3743fa94ccd ("RDMA/hns: Fix the chip hanging caused by sending doorbell during reset")
Signed-off-by: Junxian Huang <huangjunxian6@hisilicon.com>
Link: https://patch.msgid.link/20250421132750.1363348-6-huangjunxian6@hisilicon.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/infiniband/hw/hns/hns_roce_hw_v2.c
drivers/infiniband/hw/hns/hns_roce_hw_v2.h
drivers/infiniband/hw/hns/hns_roce_main.c
drivers/infiniband/hw/hns/hns_roce_restrack.c

index 4f2e8f9d228bdd15d0ddb744ee6c926a1b034ddf..e10fe47d45c1dd65d050354ca91ec35fea24a62b 100644 (file)
@@ -42,7 +42,6 @@
 #include <rdma/ib_umem.h>
 #include <rdma/uverbs_ioctl.h>
 
-#include "hnae3.h"
 #include "hns_roce_common.h"
 #include "hns_roce_device.h"
 #include "hns_roce_cmd.h"
index a03dfde796ca4f2d5739f7b433c903099cd55c07..07ea5fe4a59bb025c3cfcd94b7c29e1d1fad2c69 100644 (file)
@@ -34,6 +34,7 @@
 #define _HNS_ROCE_HW_V2_H
 
 #include <linux/bitops.h>
+#include "hnae3.h"
 
 #define HNS_ROCE_VF_QPC_BT_NUM                 256
 #define HNS_ROCE_VF_SCCC_BT_NUM                        64
index 4fc8e0c8b7ab0107f2cbd26d8457768be7f99ef9..5bafd451ca8dafc7d7e8f61b5e720764114f2f65 100644 (file)
@@ -38,7 +38,6 @@
 #include <rdma/ib_smi.h>
 #include <rdma/ib_user_verbs.h>
 #include <rdma/ib_cache.h>
-#include "hnae3.h"
 #include "hns_roce_common.h"
 #include "hns_roce_device.h"
 #include "hns_roce_hem.h"
index 259444c0a6301a547e76843bb9a488fa14b5fff8..8acab99f7ea6a74221522dc5f79cf0f575f2ef05 100644 (file)
@@ -4,7 +4,6 @@
 #include <rdma/rdma_cm.h>
 #include <rdma/restrack.h>
 #include <uapi/rdma/rdma_netlink.h>
-#include "hnae3.h"
 #include "hns_roce_common.h"
 #include "hns_roce_device.h"
 #include "hns_roce_hw_v2.h"