Commit 7e4d01e7 authored by Jacob Keller's avatar Jacob Keller Committed by Jeff Kirsher

i40e: use cpumask_copy instead of direct assignment

According to the header file cpumask.h, we shouldn't be directly copying
a cpumask_t, since its a bitmap and might not be copied correctly. Lets
use the provided cpumask_copy() function instead.
Signed-off-by: default avatarJacob Keller <jacob.e.keller@intel.com>
Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent f0db7892
...@@ -3449,7 +3449,7 @@ static void i40e_irq_affinity_notify(struct irq_affinity_notify *notify, ...@@ -3449,7 +3449,7 @@ static void i40e_irq_affinity_notify(struct irq_affinity_notify *notify,
struct i40e_q_vector *q_vector = struct i40e_q_vector *q_vector =
container_of(notify, struct i40e_q_vector, affinity_notify); container_of(notify, struct i40e_q_vector, affinity_notify);
q_vector->affinity_mask = *mask; cpumask_copy(&q_vector->affinity_mask, mask);
} }
/** /**
......
...@@ -520,7 +520,7 @@ static void i40evf_irq_affinity_notify(struct irq_affinity_notify *notify, ...@@ -520,7 +520,7 @@ static void i40evf_irq_affinity_notify(struct irq_affinity_notify *notify,
struct i40e_q_vector *q_vector = struct i40e_q_vector *q_vector =
container_of(notify, struct i40e_q_vector, affinity_notify); container_of(notify, struct i40e_q_vector, affinity_notify);
q_vector->affinity_mask = *mask; cpumask_copy(&q_vector->affinity_mask, mask);
} }
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment