[PATCH net] net: stmmac: dwc-qos-eth: use devm_kzalloc() for AXI data

Andrew Lunn andrew at lunn.ch
Thu Mar 13 06:32:33 PDT 2025


On Wed, Mar 12, 2025 at 07:43:09PM +0000, Russell King (Oracle) wrote:
> Everywhere else in the driver uses devm_kzalloc() when allocating the
> AXI data, so there is no kfree() of this structure. However,
> dwc-qos-eth uses kzalloc(), which leads to this memory being leaked.
> Switch to use devm_kzalloc().
> 
> Fixes: d8256121a91a ("stmmac: adding new glue driver dwmac-dwc-qos-eth")
> Signed-off-by: Russell King (Oracle) <rmk+kernel at armlinux.org.uk>

Reviewed-by: Andrew Lunn <andrew at lunn.ch>

    Andrew



More information about the linux-arm-kernel mailing list