RDMA/erdma: Remove numa_node from struct erdma_devattr

Using dev_to_node() to get the pci device's numa information
instead of caching it in struct erdma_devattr.

Signed-off-by: Cheng Xu <chengyou@linux.alibaba.com>
Link: https://patch.msgid.link/20260305062929.58881-1-chengyou@linux.alibaba.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
This commit is contained in:
Cheng Xu 2026-03-05 14:29:26 +08:00 committed by Leon Romanovsky
parent 9d2994f97d
commit f30bc6f9b9
3 changed files with 2 additions and 3 deletions

View File

@ -127,7 +127,6 @@ struct erdma_devattr {
unsigned char peer_addr[ETH_ALEN];
unsigned long cap_flags;
int numa_node;
enum erdma_cc_alg cc;
u32 irq_num;

View File

@ -197,7 +197,8 @@ static int erdma_set_ceq_irq(struct erdma_dev *dev, u16 ceqn)
tasklet_init(&dev->ceqs[ceqn].tasklet, erdma_intr_ceq_task,
(unsigned long)&dev->ceqs[ceqn]);
cpumask_set_cpu(cpumask_local_spread(ceqn + 1, dev->attrs.numa_node),
cpumask_set_cpu(cpumask_local_spread(ceqn + 1,
dev_to_node(&dev->pdev->dev)),
&eqc->irq.affinity_hint_mask);
err = request_irq(eqc->irq.msix_vector, erdma_intr_ceq_handler, 0,

View File

@ -261,7 +261,6 @@ static int erdma_probe_dev(struct pci_dev *pdev)
pci_set_drvdata(pdev, dev);
dev->pdev = pdev;
dev->attrs.numa_node = dev_to_node(&pdev->dev);
bars = pci_select_bars(pdev, IORESOURCE_MEM);
err = pci_request_selected_regions(pdev, bars, DRV_MODULE_NAME);