mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2025-01-20 00:46:22 +07:00
net: qualcomm: rmnet: Fix leak in device creation failure
If the rmnet device creation fails in the newlink either while
registering with the physical device or after subsequent
operations, the rmnet endpoint information is never freed.
Fixes: ceed73a2cf
("drivers: net: ethernet: qualcomm: rmnet: Initial implementation")
Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
c20a548792
commit
6296928fa3
@ -195,6 +195,7 @@ static int rmnet_newlink(struct net *src_net, struct net_device *dev,
|
||||
err1:
|
||||
rmnet_unregister_real_device(real_dev, port);
|
||||
err0:
|
||||
kfree(ep);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user