summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRam Amrani <Ram.Amrani@cavium.com>2017-02-20 22:43:33 +0200
committerDavid S. Miller <davem@davemloft.net>2017-02-20 17:11:54 -0500
commitc2dedf8773e873474535bd4a158609b9eda5403d (patch)
tree2e273b2f1576488f3a92f9a7aaf5be788fb7cf38
parent300c0d7c232da572cb640f3bc803554f74e08f69 (diff)
qed: Reserve doorbell BAR space for present CPUs
Reserving doorbell BAR space according to the currently active CPUs may result in a bug if disabled CPUs are later enabled but no doorbell space was reserved for them. Signed-off-by: Ram Amrani <Ram.Amrani@cavium.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@cavium.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/qlogic/qed/qed_dev.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/qlogic/qed/qed_dev.c b/drivers/net/ethernet/qlogic/qed/qed_dev.c
index 5ee7f040c50a..d6c5a8165b5f 100644
--- a/drivers/net/ethernet/qlogic/qed/qed_dev.c
+++ b/drivers/net/ethernet/qlogic/qed/qed_dev.c
@@ -913,7 +913,7 @@ qed_hw_init_pf_doorbell_bar(struct qed_hwfn *p_hwfn, struct qed_ptt *p_ptt)
/* Either EDPM is mandatory, or we are attempting to allocate a
* WID per CPU.
*/
- n_cpus = num_active_cpus();
+ n_cpus = num_present_cpus();
rc = qed_hw_init_dpi_size(p_hwfn, p_ptt, pwm_regsize, n_cpus);
}