2024-01-22 17:13:08

by Souradeep Chakrabarti

[permalink] [raw]
Subject: [PATCH 0/4 V2 net-next] net: mana: Assigning IRQ affinity on HT cores

This patch set introduces a new helper function irq_setup(),
to optimize IRQ distribution for MANA network devices.
The patch set makes the driver working 15% faster than
with cpumask_local_spread().

Souradeep Chakrabarti (1):
net: mana: Assigning IRQ affinity on HT cores

Yury Norov (3):
cpumask: add cpumask_weight_andnot()
cpumask: define cleanup function for cpumasks
net: mana: add a function to spread IRQs per CPUs

.../net/ethernet/microsoft/mana/gdma_main.c | 88 ++++++++++++++++---
include/linux/bitmap.h | 12 +++
include/linux/cpumask.h | 16 ++++
lib/bitmap.c | 7 ++
4 files changed, 113 insertions(+), 10 deletions(-)
--
Change:
V1 -> V2:
Added some details on the performance study on the patch 4/4.

--
2.34.1



2024-01-22 17:49:24

by Souradeep Chakrabarti

[permalink] [raw]
Subject: [PATCH 2/4 V2 net-next] cpumask: define cleanup function for cpumasks

From: Yury Norov <[email protected]>

Now we can simplify code that allocates cpumasks for local needs.

Signed-off-by: Yury Norov <[email protected]>
---
include/linux/cpumask.h | 3 +++
1 file changed, 3 insertions(+)

diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h
index 228c23eb36d2..1c29947db848 100644
--- a/include/linux/cpumask.h
+++ b/include/linux/cpumask.h
@@ -7,6 +7,7 @@
* set of CPUs in a system, one bit position per CPU number. In general,
* only nr_cpu_ids (<= NR_CPUS) bits are valid.
*/
+#include <linux/cleanup.h>
#include <linux/kernel.h>
#include <linux/threads.h>
#include <linux/bitmap.h>
@@ -990,6 +991,8 @@ static inline bool cpumask_available(cpumask_var_t mask)
}
#endif /* CONFIG_CPUMASK_OFFSTACK */

+DEFINE_FREE(free_cpumask_var, struct cpumask *, if (_T) free_cpumask_var(_T));
+
/* It's common to want to use cpu_all_mask in struct member initializers,
* so it has to refer to an address rather than a pointer. */
extern const DECLARE_BITMAP(cpu_all_bits, NR_CPUS);
--
2.34.1