Message ID | cca18f9c630a41c18487729770b492bb@terma.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 3a38a829c8bc27d78552c28e582eb1d885d07d11 |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [net,v3] net: ll_temac: platform_get_resource replaced by wrong function | expand |
Hello: This patch was applied to netdev/net.git (main) by Jakub Kicinski <kuba@kernel.org>: On Thu, 21 Mar 2024 13:08:59 +0000 you wrote: > The function platform_get_resource was replaced with > devm_platform_ioremap_resource_byname and is called using 0 as name. > > This eventually ends up in platform_get_resource_byname in the call > stack, where it causes a null pointer in strcmp. > > if (type == resource_type(r) && !strcmp(r->name, name)) > > [...] Here is the summary with links: - [net,v3] net: ll_temac: platform_get_resource replaced by wrong function https://git.kernel.org/netdev/net/c/3a38a829c8bc You are awesome, thank you!
diff --git a/drivers/net/ethernet/xilinx/ll_temac_main.c b/drivers/net/ethernet/xilinx/ll_temac_main.c index 9df39cf8b097..1072e2210aed 100644 --- a/drivers/net/ethernet/xilinx/ll_temac_main.c +++ b/drivers/net/ethernet/xilinx/ll_temac_main.c @@ -1443,7 +1443,7 @@ static int temac_probe(struct platform_device *pdev) } /* map device registers */ - lp->regs = devm_platform_ioremap_resource_byname(pdev, 0); + lp->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(lp->regs)) { dev_err(&pdev->dev, "could not map TEMAC registers\n"); return -ENOMEM;