diff options
author | Colin Ian King <colin.king@canonical.com> | 2016-03-29 20:00:50 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-03-30 22:48:15 +0300 |
commit | fea24857bb62990b839feb62090ad72a1c93735a (patch) | |
tree | dde35b5bc364514ebe4b6e8623bb54d25a3f9ddd /drivers/net | |
parent | 28fd34985bd5edaea6282a0586f91bcddd336f5e (diff) | |
download | linux-fea24857bb62990b839feb62090ad72a1c93735a.tar.xz |
qed: initialize return rc to avoid returning garbage
in the case where qed_slowpath_irq_req is not called, rc is not
assigned and so qed_int_igu_enable will return a garbage value.
Fix this by initializing rc to 0.
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ethernet/qlogic/qed/qed_int.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/qlogic/qed/qed_int.c b/drivers/net/ethernet/qlogic/qed/qed_int.c index ffd0accc2ec9..2017b0121f5f 100644 --- a/drivers/net/ethernet/qlogic/qed/qed_int.c +++ b/drivers/net/ethernet/qlogic/qed/qed_int.c @@ -2750,7 +2750,7 @@ void qed_int_igu_enable_int(struct qed_hwfn *p_hwfn, int qed_int_igu_enable(struct qed_hwfn *p_hwfn, struct qed_ptt *p_ptt, enum qed_int_mode int_mode) { - int rc; + int rc = 0; /* Configure AEU signal change to produce attentions */ qed_wr(p_hwfn, p_ptt, IGU_REG_ATTENTION_ENABLE, 0); |