Skip to content

Commit

Permalink
genirq/affinity: Remove const qualifier from node_to_cpumask argument
Browse files Browse the repository at this point in the history
When CONFIG_CPUMASK_OFFSTACK isn't enabled, 'cpumask_var_t' is as

'typedef struct cpumask cpumask_var_t[1]',

so the argument 'node_to_cpumask' alloc_nodes_vectors() can't be declared
as 'const cpumask_var_t *'

Fixes the following warning:

   kernel/irq/affinity.c: In function '__irq_build_affinity_masks':
     alloc_nodes_vectors(numvecs, node_to_cpumask, cpu_mask,
                                  ^
   kernel/irq/affinity.c:128:13: note: expected 'const struct cpumask (*)[1]' but argument is of type 'struct cpumask (*)[1]'
    static void alloc_nodes_vectors(unsigned int numvecs,
                ^
Fixes: b1a5a73 ("genirq/affinity: Spread vectors on node according to nr_cpu ratio")
Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/20190828085815.19931-1-ming.lei@redhat.com
  • Loading branch information
Ming Lei authored and Thomas Gleixner committed Aug 28, 2019
1 parent b1a5a73 commit 101f85b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/irq/affinity.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ static int ncpus_cmp_func(const void *l, const void *r)
* for each node.
*/
static void alloc_nodes_vectors(unsigned int numvecs,
const cpumask_var_t *node_to_cpumask,
cpumask_var_t *node_to_cpumask,
const struct cpumask *cpu_mask,
const nodemask_t nodemsk,
struct cpumask *nmsk,
Expand Down

0 comments on commit 101f85b

Please sign in to comment.