octeontx2-af: returning uninitialized variable

Fix coverity error 'use of uninitialized variable'. err is uninitialized
and is returned which can lead to unintended results. err has been replaced
with -einval.
Coverity issue: 1518921 (uninitialized scalar variable)

Signed-off-by: Sebin Sebastian <mailmesebin00@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Sebin Sebastian 2022-07-13 13:08:58 +05:30 committed by David S. Miller
parent d86a153aca
commit 6a605eb1d7

View file

@ -1959,7 +1959,7 @@ int rvu_npc_exact_init(struct rvu *rvu)
dev_err(rvu->dev,
"%s: failed to set drop info for cgx=%d, lmac=%d, chan=%llx\n",
__func__, cgx_id, lmac_id, chan_val);
return err;
return -EINVAL;
}
err = npc_install_mcam_drop_rule(rvu, *drop_mcam_idx,