summaryrefslogtreecommitdiffstats
path: root/kernel/irq
diff options
context:
space:
mode:
authorMing Lei <ming.lei@redhat.com>2022-12-27 10:29:00 +0800
committerThomas Gleixner <tglx@linutronix.de>2023-01-17 18:50:06 +0100
commitcdf07f0ea48a3b52f924714d477366ac510ee870 (patch)
tree839916c66d333cce7313b90cd60291efe71ce68d /kernel/irq
parent0e2213fe0ab4c04da0e2354e84ec3b90e59939a4 (diff)
downloadlinux-stable-cdf07f0ea48a3b52f924714d477366ac510ee870.tar.gz
linux-stable-cdf07f0ea48a3b52f924714d477366ac510ee870.tar.bz2
linux-stable-cdf07f0ea48a3b52f924714d477366ac510ee870.zip
genirq/affinity: Remove the 'firstvec' parameter from irq_build_affinity_masks
The 'firstvec' parameter is always same with the parameter of 'startvec', so use 'startvec' directly inside irq_build_affinity_masks(). Signed-off-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: John Garry <john.g.garry@oracle.com> Reviewed-by: Jens Axboe <axboe@kernel.dk> Link: https://lore.kernel.org/r/20221227022905.352674-2-ming.lei@redhat.com
Diffstat (limited to 'kernel/irq')
-rw-r--r--kernel/irq/affinity.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/irq/affinity.c b/kernel/irq/affinity.c
index d9a5c1d65a79..3361e36ebaa1 100644
--- a/kernel/irq/affinity.c
+++ b/kernel/irq/affinity.c
@@ -337,10 +337,10 @@ static int __irq_build_affinity_masks(unsigned int startvec,
* 2) spread other possible CPUs on these vectors
*/
static int irq_build_affinity_masks(unsigned int startvec, unsigned int numvecs,
- unsigned int firstvec,
struct irq_affinity_desc *masks)
{
unsigned int curvec = startvec, nr_present = 0, nr_others = 0;
+ unsigned int firstvec = startvec;
cpumask_var_t *node_to_cpumask;
cpumask_var_t nmsk, npresmsk;
int ret = -ENOMEM;
@@ -463,8 +463,7 @@ irq_create_affinity_masks(unsigned int nvecs, struct irq_affinity *affd)
unsigned int this_vecs = affd->set_size[i];
int ret;
- ret = irq_build_affinity_masks(curvec, this_vecs,
- curvec, masks);
+ ret = irq_build_affinity_masks(curvec, this_vecs, masks);
if (ret) {
kfree(masks);
return NULL;