mirror of https://gitee.com/openkylin/linux.git
spi: stm32: use NULL pointer instead of plain integer
Patch fixes sparse warning: Using plain integer as NULL pointer. Replaces second argument of function devm_clk_get from 0 to NULL. Signed-off-by: Cezary Gapinski <cezary.gapinski@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
d57a984ff7
commit
d4c9134a6c
|
@ -1100,7 +1100,7 @@ static int stm32_spi_probe(struct platform_device *pdev)
|
|||
goto err_master_put;
|
||||
}
|
||||
|
||||
spi->clk = devm_clk_get(&pdev->dev, 0);
|
||||
spi->clk = devm_clk_get(&pdev->dev, NULL);
|
||||
if (IS_ERR(spi->clk)) {
|
||||
ret = PTR_ERR(spi->clk);
|
||||
dev_err(&pdev->dev, "clk get failed: %d\n", ret);
|
||||
|
|
Loading…
Reference in New Issue