Skip to content

Commit cbfa5be

Browse files
Ryceancurrykuba-moo
authored andcommitted
net: bcmasp: fix double free of WoL irq
We do not need to free wol_irq since it was instantiated with devm_request_irq(). So devres will free for us. Fixes: a2f0751 ("net: bcmasp: Add support for WoL magic packet") Signed-off-by: Justin Chen <[email protected]> Reviewed-by: Florian Fainelli <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 7a4fc5c commit cbfa5be

1 file changed

Lines changed: 0 additions & 8 deletions

File tree

  • drivers/net/ethernet/broadcom/asp2

drivers/net/ethernet/broadcom/asp2/bcmasp.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1152,12 +1152,6 @@ void bcmasp_enable_wol(struct bcmasp_intf *intf, bool en)
11521152
}
11531153
}
11541154

1155-
static void bcmasp_wol_irq_destroy(struct bcmasp_priv *priv)
1156-
{
1157-
if (priv->wol_irq > 0)
1158-
free_irq(priv->wol_irq, priv);
1159-
}
1160-
11611155
static void bcmasp_eee_fixup(struct bcmasp_intf *intf, bool en)
11621156
{
11631157
u32 reg, phy_lpi_overwrite;
@@ -1363,7 +1357,6 @@ static int bcmasp_probe(struct platform_device *pdev)
13631357
return ret;
13641358

13651359
err_cleanup:
1366-
bcmasp_wol_irq_destroy(priv);
13671360
bcmasp_remove_intfs(priv);
13681361

13691362
return ret;
@@ -1376,7 +1369,6 @@ static void bcmasp_remove(struct platform_device *pdev)
13761369
if (!priv)
13771370
return;
13781371

1379-
bcmasp_wol_irq_destroy(priv);
13801372
bcmasp_remove_intfs(priv);
13811373
}
13821374

0 commit comments

Comments
 (0)