summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorLeon Romanovsky <leonro@nvidia.com>2026-07-13 07:41:25 -0400
committerLeon Romanovsky <leonro@nvidia.com>2026-07-13 07:41:25 -0400
commit9f674ba674a0d1d6c418752c237364e12620dd89 (patch)
tree14a30e292087ef5d6f59629035ef13a07357f322 /tools/perf/scripts/python
parent8e17e101e04a3dc062e2719da57ff78c1c060632 (diff)
RDMA/hfi1: Allocate device data after PCI initialization
After the preceding changes, module parameter validation and common PCI setup no longer need hfi1_devdata. init_one() nevertheless allocates it first, so failures in those early steps return without releasing it. Move the allocation after hfi1_pcie_init() and return directly when no resources are held. Use dev_err() and pci_info() for diagnostics emitted before allocation so they retain the adapter BDF. Once PCI setup succeeds, unwind allocation failures through hfi1_pcie_cleanup() to disable the device and release its regions. Some PCI error delivery paths are not serialized against probe. Keep their diagnostics based on pci_dev and skip resume while driver data is absent, preventing recovery from dereferencing a missing hfi1_devdata. Fixes: 57f97e96625f ("IB/hfi1: Get the hfi1_devdata structure as early as possible") Reported-by: Dawei Feng <dawei.feng@seu.edu.cn> Closes: https://lore.kernel.org/all/20260627060159.2543686-1-dawei.feng@seu.edu.cn/ Link: https://patch.msgid.link/20260708-clean-init-one-hfi1-v1-8-b9e9641268a5@nvidia.com Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions