Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fea24857 authored by Colin Ian King's avatar Colin Ian King Committed by David S. Miller
Browse files

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: default avatarColin Ian King <colin.king@canonical.com>
Acked-by: default avatarYuval Mintz <Yuval.Mintz@qlogic.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 28fd3498
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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);