Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

PCI: plda: Remove dev_err_probe() when the errno is -ENOMEM

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>
[mani: reworded the subject]
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>

authored by

Xichao Zhao and committed by
Manivannan Sadhasivam
882569dc 8f5ae30d

+1 -2
+1 -2
drivers/pci/controller/plda/pcie-plda-host.c
··· 599 599 600 600 bridge = devm_pci_alloc_host_bridge(dev, 0); 601 601 if (!bridge) 602 - return dev_err_probe(dev, -ENOMEM, 603 - "failed to alloc bridge\n"); 602 + return -ENOMEM; 604 603 605 604 if (port->host_ops && port->host_ops->host_init) { 606 605 ret = port->host_ops->host_init(port);