Skip to content
Commit 8b740c08 authored by Zeng Jingxiang's avatar Zeng Jingxiang Committed by Miquel Raynal
Browse files

mtd: physmap-core: Fix NULL pointer dereferencing in of_select_probe_type()



Coverity complains of a possible NULL dereference:

in of_select_probe_type():
1. returned_null: of_match_device() returns NULL.
2. var_assigned: match = NULL return value from of_match_device()
309	match = of_match_device(of_flash_match, &dev->dev);

3.dereference: Dereferencing the NULL pointer match.
310	probe_type = match->data;

Signed-off-by: default avatarZeng Jingxiang <linuszeng@tencent.com>
Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20220727060302.1560325-1-zengjx95@gmail.com
parent 26e78443
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment