Skip to content

Commit 67259af

Browse files
Xichao Zhaobroonie
authored andcommitted
spi: pxa2xx: 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-6-zhao.xichao@vivo.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 2bee48c commit 67259af

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/spi/spi-pxa2xx.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1283,7 +1283,7 @@ int pxa2xx_spi_probe(struct device *dev, struct ssp_device *ssp,
12831283
else
12841284
controller = devm_spi_alloc_host(dev, sizeof(*drv_data));
12851285
if (!controller)
1286-
return dev_err_probe(dev, -ENOMEM, "cannot alloc spi_controller\n");
1286+
return -ENOMEM;
12871287

12881288
drv_data = spi_controller_get_devdata(controller);
12891289
drv_data->controller = controller;

0 commit comments

Comments
 (0)