mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-05 02:26:44 +07:00
net: ethernet: ax88796: avoid null pointer dereference
If platform_get_resource fails, mem2 is null. Do not dereference null. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
59d53bc213
commit
09d306d79d
@ -910,7 +910,8 @@ static int ax_probe(struct platform_device *pdev)
|
||||
iounmap(ax->map2);
|
||||
|
||||
exit_mem2:
|
||||
release_mem_region(mem2->start, mem2_size);
|
||||
if (mem2)
|
||||
release_mem_region(mem2->start, mem2_size);
|
||||
|
||||
exit_mem1:
|
||||
iounmap(ei_local->mem);
|
||||
|
Loading…
Reference in New Issue
Block a user