irdma: change name of interrupts
Subsystems (2)
Add more information in interrupt names.
Before this patch it was:
irdma
CEQ
CEQ
...
Now:
irdma-ice-AEQ
irdma-ice-CEQ-0
irdma-ice-CEQ-1
...
--- drivers/infiniband/hw/irdma/defs.h | 2 ++ drivers/infiniband/hw/irdma/hw.c | 14 +++++++++++--- drivers/infiniband/hw/irdma/main.h | 1 + 3 files changed, 14 insertions(+), 3 deletions(-)
drivers/infiniband/hw/irdma/defs.h +2 -0
@@ -20,6 +20,8 @@#define IRDMA_IRD_HW_SIZE_128 3#define IRDMA_IRD_HW_SIZE_256 4 +#define IRDMA_INT_NAME_STR_LEN (32) +enum irdma_protocol_used {IRDMA_ANY_PROTOCOL =0 ,IRDMA_IWARP_PROTOCOL_ONLY =1 ,
drivers/infiniband/hw/irdma/hw.c +11 -3
@@ -1087,14 +1087,20 @@ static int irdma_cfg_ceq_vector(struct irdma_pci_f *rf, struct irdma_ceq *iwceq,int status;if (rf->msix_shared && !ceq_id) { +snprintf (msix_vec->name,sizeof (msix_vec->name) -1 , +"irdma-%s-AEQCEQ-%d" , +dev_driver_string (&rf->pcidev->dev), ceq_id);tasklet_setup (&rf->dpc_tasklet, irdma_dpc); status =request_irq (msix_vec->irq, irdma_irq_handler,0 , -"AEQCEQ" , rf); + msix_vec->name, rf); }else { +snprintf (msix_vec->name,sizeof (msix_vec->name) -1 , +"irdma-%s-CEQ-%d" , +dev_driver_string (&rf->pcidev->dev), ceq_id);tasklet_setup (&iwceq->dpc_tasklet, irdma_ceq_dpc); status =request_irq (msix_vec->irq, irdma_ceq_handler,0 , -"CEQ" , iwceq); + msix_vec->name, iwceq); }cpumask_clear (&msix_vec->mask);cpumask_set_cpu (msix_vec->cpu_affinity, &msix_vec->mask);
@@ -1123,9 +1129,11 @@ static int irdma_cfg_aeq_vector(struct irdma_pci_f *rf)u32 ret =0 ;if (!rf->msix_shared) { +snprintf (msix_vec->name,sizeof (msix_vec->name) -1 , +"irdma-%s-AEQ" ,dev_driver_string (&rf->pcidev->dev));tasklet_setup (&rf->dpc_tasklet, irdma_dpc); ret =request_irq (msix_vec->irq, irdma_irq_handler,0 , -"irdma" , rf); + msix_vec->name, rf); }if (ret) {ibdev_dbg (&rf->iwdev->ibdev,"ERR: aeq irq config fail\n" );
drivers/infiniband/hw/irdma/main.h +1 -0
@@ -212,6 +212,7 @@ struct irdma_msix_vector {u32 cpu_affinity;u32 ceq_id;cpumask_t mask; +char name[IRDMA_INT_NAME_STR_LEN ]; };struct irdma_mc_table_info {
Signature · 6 lines
2.36.1 _______________________________________________ Intel-wired-lan mailing list [email protected] https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
Quoted 2 lines
Subject: [net-next] irdma: change name of interrupts
This cant go through net-next. It needs to go through the rdma tree. I will co-ordinate w. Tony on it.
Use "RDMA/irdma: change name of interrupts" for the subject.
Quoted 8 lines
Add more information in interrupt names.
Before this patch it was:
irdma
CEQ
CEQ
...
Quoted 4 lines
Now:
irdma-ice-AEQ
irdma-ice-CEQ-0
irdma-ice-CEQ-1
This is better for sure. But we need to add the device name. Not sure if adding "ice" is adding any value.
Ideally, for the RDMA drivers, this should be ib_device name. But there is a limitation in RDMA subsystem that doesn't set the name till after the ib device is registered which happens later in the drv.probe() flow.
So I think our best option is to use the PCI device name.
Quoted 15 lines
...
Signed-off-by Michal Swiatkowski <[email protected]>Suggested-by Piotr Raczynski <[email protected]>--- drivers/infiniband/hw/irdma/defs.h | 2 ++ drivers/infiniband/hw/irdma/hw.c | 14 +++++++++++--- drivers/infiniband/hw/irdma/main.h | 1 + 3 files changed, 14 insertions(+), 3 deletions(-)drivers/infiniband/hw/irdma/defs.h +0
-0
drivers/infiniband/hw/irdma/defs.h line 23
Quoted 4 lines
drivers/infiniband/hw/irdma/defs.h +1
-0@@ -20,6 +20,8 @@#define IRDMA_IRD_HW_SIZE_128 3#define IRDMA_IRD_HW_SIZE_256 4 +#define IRDMA_INT_NAME_STR_LEN (32)
INT to IRQ which is more used in this driver to reflect interrupt. Drop the (). And move to this main.h where the irdma_msix_vector struct is defined.
Quoted 9 lines
drivers/infiniband/hw/irdma/defs.h +1
-0+enum irdma_protocol_used {IRDMA_ANY_PROTOCOL =0 ,IRDMA_IWARP_PROTOCOL_ONLY =1 ,drivers/infiniband/hw/irdma/hw.c +0
-0
drivers/infiniband/hw/irdma/hw.c static int irdma_cfg_ceq_vector(struct irdma_pci_f *rf, · line 1093
Quoted 7 lines
drivers/infiniband/hw/irdma/hw.c +3
-0@@ -1087,14 +1087,20 @@ static int irdma_cfg_ceq_vector(struct irdma_pci_f *rf,struct irdma_ceq *iwceq, int status;if (rf->msix_shared && !ceq_id) { +snprintf (msix_vec->name,sizeof (msix_vec->name) -1 , +"irdma-%s-AEQCEQ-%d" , +dev_driver_string (&rf->pcidev->dev), ceq_id);
As per previous comment, I think dev_name((&rf->pcidev->dev) is better. Given this should we make the msix_vec.name be a 64b variable?
Shiraz
_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
Quoted 7 lines · Shiraz
Quoted 2 lines
Subject: [net-next] irdma: change name of interrupts
This cant go through net-next. It needs to go through the rdma tree. I will co-ordinate w. Tony on it.
Use "RDMA/irdma: change name of interrupts" for the subject.
I will remember, is "rdma" the name of tree?
Quoted 13 lines
Quoted 8 lines
Add more information in interrupt names.
Before this patch it was:
irdma
CEQ
CEQ
...Quoted 4 lines
Now:
irdma-ice-AEQ
irdma-ice-CEQ-0
irdma-ice-CEQ-1
Quoted 7 lines
This is better for sure. But we need to add the device name. Not sure if adding "ice" is adding any value.
Ideally, for the RDMA drivers, this should be
ib_devicename. But there is a limitation in RDMA subsystem that doesn't set the name till after the ib device is registered which happens later in thedrv.probe()flow.So I think our best option is to use the PCI device name.
Sure, will change it, thanks.
Quoted 18 lines
Quoted 18 lines
...
Signed-off-by Michal Swiatkowski <[email protected]>Suggested-by Piotr Raczynski <[email protected]>--- drivers/infiniband/hw/irdma/defs.h | 2 ++ drivers/infiniband/hw/irdma/hw.c | 14 +++++++++++--- drivers/infiniband/hw/irdma/main.h | 1 + 3 files changed, 14 insertions(+), 3 deletions(-)drivers/infiniband/hw/irdma/defs.h +0
-0@@ -20,6 +20,8 @@#define IRDMA_IRD_HW_SIZE_128 3#define IRDMA_IRD_HW_SIZE_256 4
Quoted 4 lines
drivers/infiniband/hw/irdma/defs.h line 23
Quoted 1 line
drivers/infiniband/hw/irdma/defs.h +1
-0+#define IRDMA_INT_NAME_STR_LEN (32)INT to IRQ which is more used in this driver to reflect interrupt. Drop the (). And move to this
main.hwhere theirdma_msix_vectorstruct is defined.
Done
Quoted 12 lines
Quoted 12 lines
drivers/infiniband/hw/irdma/defs.h +1
-0+enum irdma_protocol_used {IRDMA_ANY_PROTOCOL =0 ,IRDMA_IWARP_PROTOCOL_ONLY =1 ,drivers/infiniband/hw/irdma/hw.c +0
-0@@ -1087,14 +1087,20 @@ static int irdma_cfg_ceq_vector(struct irdma_pci_f *rf,struct irdma_ceq *iwceq, int status;
Quoted 7 lines
drivers/infiniband/hw/irdma/hw.c static int irdma_cfg_ceq_vector(struct irdma_pci_f *rf, struct irdma_ceq *iwceq, · line 1092
Quoted 4 lines
drivers/infiniband/hw/irdma/hw.c +3
-0if (rf->msix_shared && !ceq_id) { +snprintf (msix_vec->name,sizeof (msix_vec->name) -1 , +"irdma-%s-AEQCEQ-%d" , +dev_driver_string (&rf->pcidev->dev), ceq_id);As per previous comment, I think dev_name((&rf->pcidev->dev) is better. Given this should we make the msix_vec.name be a 64b variable?
Yeah, it looks better, thanks. I changed name to 64b.
Quoted 3 lines
Shiraz
_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan