Skip to content
Snippets Groups Projects
Commit 71bcc1b4 authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Greg Kroah-Hartman
Browse files

memory: renesas-rpc-if: fix possible NULL pointer dereference of resource


[ Upstream commit 59e27d7c ]

The platform_get_resource_byname() can return NULL which would be
immediately dereferenced by resource_size().  Instead dereference it
after validating the resource.

Addresses-Coverity: Dereference null return value
Fixes: ca7d8b98 ("memory: add Renesas RPC-IF driver")
Signed-off-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Link: https://lore.kernel.org/r/20210407154357.70200-1-krzysztof.kozlowski@canonical.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 73585b27
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment