]> git.baikalelectronics.ru Git - kernel.git/commit
octeontx2-pf: mcs: fix possible memory leak in otx2_probe()
authorYang Yingliang <yangyingliang@huawei.com>
Mon, 10 Oct 2022 03:39:45 +0000 (11:39 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 10 Oct 2022 07:39:39 +0000 (08:39 +0100)
commitaf7d23f9d96a3e9647cff8619a6860d73b109b5f
treeda6fa13ceb5b8dfcee3eb755db0b6569125f8e45
parent84cdf5bcbdce1622eeb6c857f8a7e383de1074a9
octeontx2-pf: mcs: fix possible memory leak in otx2_probe()

In error path after calling cn10k_mcs_init(), cn10k_mcs_free() need
be called to avoid memory leak.

Fixes: c54ffc73601c ("octeontx2-pf: mcs: Introduce MACSEC hardware offloading")
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c