mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-01 22:54:01 +00:00
soc: qcom: ramp_controller: Fix an error handling path in qcom_ramp_controller_probe()
'qrc' is known to be non-NULL at this point.
Checking for 'qrc->desc' was expected instead, so use it.
Fixes: a723c95fa1
("soc: qcom: Add Qualcomm Ramp Controller driver")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Link: https://lore.kernel.org/r/84727a79d0261b4112411aec23b553504015c02c.1681684138.git.christophe.jaillet@wanadoo.fr
This commit is contained in:
parent
3395d36e68
commit
b3d0dcc8e3
1 changed files with 1 additions and 1 deletions
|
@ -296,7 +296,7 @@ static int qcom_ramp_controller_probe(struct platform_device *pdev)
|
|||
return -ENOMEM;
|
||||
|
||||
qrc->desc = device_get_match_data(&pdev->dev);
|
||||
if (!qrc)
|
||||
if (!qrc->desc)
|
||||
return -EINVAL;
|
||||
|
||||
qrc->regmap = devm_regmap_init_mmio(&pdev->dev, base, &qrc_regmap_config);
|
||||
|
|
Loading…
Reference in a new issue