mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-27 03:49:57 -04:00
net: microchip: sparx5: Fix uninitialized variable in vcap_path_exist()
The "eport" variable needs to be initialized to NULL for this code to
work.
Fixes: 814e769320 ("net: microchip: vcap api: Add a storage state to a VCAP rule")
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Steen Hegelund <Steen.Hegelund@microchip.com>
Link: https://lore.kernel.org/r/Y8qbYAb+YSXo1DgR@kili
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
8a8b70b3f2
commit
3bee9b573a
@@ -2010,7 +2010,8 @@ static int vcap_get_next_chain(struct vcap_control *vctrl,
|
||||
static bool vcap_path_exist(struct vcap_control *vctrl, struct net_device *ndev,
|
||||
int dst_cid)
|
||||
{
|
||||
struct vcap_enabled_port *eport, *elem;
|
||||
struct vcap_enabled_port *eport = NULL;
|
||||
struct vcap_enabled_port *elem;
|
||||
struct vcap_admin *admin;
|
||||
int tmp;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user