Skip to content

Commit 0d00ebc

Browse files
Xichao Zhaobroonie
authored andcommitted
spi: SPISG: Remove the use of dev_err_probe()
The dev_err_probe() doesn't do anything when error is '-ENOMEM'. Therefore, remove the useless call to dev_err_probe(), and just return the value instead. Signed-off-by: Xichao Zhao <zhao.xichao@vivo.com> Link: https://patch.msgid.link/20250819092044.549464-3-zhao.xichao@vivo.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 2a5d410 commit 0d00ebc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/spi/spi-amlogic-spisg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -733,7 +733,7 @@ static int aml_spisg_probe(struct platform_device *pdev)
733733
else
734734
ctlr = spi_alloc_host(dev, sizeof(*spisg));
735735
if (!ctlr)
736-
return dev_err_probe(dev, -ENOMEM, "controller allocation failed\n");
736+
return -ENOMEM;
737737

738738
spisg = spi_controller_get_devdata(ctlr);
739739
spisg->controller = ctlr;

0 commit comments

Comments
 (0)