Skip to contentSkip to conversation

cxgb3 - Allocate multiqueues at init time

PATCH Applied Divy Le Ray 2 participants 3 messages Oct 9, 2008

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/8 cxgb3 - Allocate multiqueues at init time

From: Divy Le Ray <[email protected]>

Allocate a queue set per core, up to the maximum of available qsets. Share the queue sets on multi port adapters.
Rename MSI-X interrupt vectors ethX-N, N being the queue set number.

---

 drivers/net/cxgb3/common.h      |    1 
 drivers/net/cxgb3/cxgb3_ioctl.h |    2 
 drivers/net/cxgb3/cxgb3_main.c  |  179 +++++++++++++++++++++++++++++++--------
 3 files changed, 145 insertions(+), 37 deletions(-)
drivers/net/cxgb3/common.h +1 -0
index d6dbcd4..ace6b58 100644
@@ -358,6 +358,7 @@ struct qset_params {		/* SGE queue set parameters */
 	unsigned int jumbo_size;	/* # of entries in jumbo free list */
 	unsigned int txq_size[SGE_TXQ_PER_SET];	/* Tx queue sizes */
 	unsigned int cong_thres;	/* FL congestion threshold */
+	unsigned int vector;		/* Interrupt (line or vector) number */
 };
 
 struct sge_params {
drivers/net/cxgb3/cxgb3_ioctl.h +2 -0
index 68200a1..3e8d5fa 100644
@@ -92,6 +92,8 @@ struct ch_qset_params {
 	int32_t polling;
 	int32_t lro;
 	int32_t cong_thres;
+	int32_t  vector;
+	int32_t  qnum;
 };
 
 struct ch_pktsched_params {
drivers/net/cxgb3/cxgb3_main.c +142 -37

313 lines not on this page · raw message

maintainer Applied
#1 lore raw

From: Divy Le Ray <[email protected]>
Date: Wed, 08 Oct 2008 17:34:02 -0700

Quoted 5 lines

Allocate a queue set per core, up to the maximum of available qsets. Share the queue sets on multi port adapters.
Rename MSI-X interrupt vectors ethX-N, N being the queue set number.

Applied, but...

This "num processors" logic and policy belongs in some generic place. Perhaps "num_possible_cpus()" is more appropriate, who knows right?

Otherwise every stinking driver is going to implement this in their own way and use their own policy, and from a user experience perspective that totally sucks.

#2 lore raw
Quoted 8 lines · David Miller

From: Divy Le Ray <[email protected]>
Date: Wed, 08 Oct 2008 17:34:02 -0700

Quoted 4 lines

Allocate a queue set per core, up to the maximum of available qsets. Share the queue sets on multi port adapters.
Rename MSI-X interrupt vectors ethX-N, N being the queue set number.

Quoted 8 lines
Quoted 2 lines

Applied, but...

This "num processors" logic and policy belongs in some generic place. Perhaps "num_possible_cpus()" is more appropriate, who knows right?

I'll look into it.

Cheers,
Divy