lkml.org 
[lkml]   [2022]   [Jan]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] fsl/fman: Check for null pointer after calling devm_ioremap
From
Date
Hello:

This patch was applied to netdev/net.git (master)
by David S. Miller <davem@davemloft.net>:

On Thu, 6 Jan 2022 18:04:10 +0800 you wrote:
> As the possible failure of the allocation, the devm_ioremap() may return
> NULL pointer.
> Take tgec_initialization() as an example.
> If allocation fails, the params->base_addr will be NULL pointer and will
> be assigned to tgec->regs in tgec_config().
> Then it will cause the dereference of NULL pointer in set_mac_address(),
> which is called by tgec_init().
> Therefore, it should be better to add the sanity check after the calling
> of the devm_ioremap().
>
> [...]

Here is the summary with links:
- fsl/fman: Check for null pointer after calling devm_ioremap
https://git.kernel.org/netdev/net/c/d5a73ec96cc5

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html


\
 
 \ /
  Last update: 2022-01-06 15:01    [W:0.060 / U:0.500 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site