--- /dev/null
+From 0b9567e59cbdb7bec4646278b5c5b3e770ea11f9 Mon Sep 17 00:00:00 2001
+From: Mathias Kresin <dev@kresin.me>
+Date: Mon, 28 Jan 2019 22:08:05 +0100
+Subject: [PATCH 1/6] MIPS: lantiq: pci: check return codes
+
+ltq_pci_startup() returns an error if something went wrong. Check and
+return the error instead of pretend everything is fine.
+
+Signed-off-by: Mathias Kresin <dev@kresin.me>
+---
+ arch/mips/pci/pci-lantiq.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/arch/mips/pci/pci-lantiq.c b/arch/mips/pci/pci-lantiq.c
+index 1ca42f482130..9afca76a7b02 100644
+--- a/arch/mips/pci/pci-lantiq.c
++++ b/arch/mips/pci/pci-lantiq.c
+@@ -207,6 +207,7 @@ static int ltq_pci_startup(struct platform_device *pdev)
+ static int ltq_pci_probe(struct platform_device *pdev)
+ {
+ struct resource *res_cfg, *res_bridge;
++ int ret;
+
+ pci_clear_flags(PCI_PROBE_ONLY);
+
+@@ -220,7 +221,9 @@ static int ltq_pci_probe(struct platform_device *pdev)
+ if (IS_ERR(ltq_pci_mapped_cfg))
+ return PTR_ERR(ltq_pci_mapped_cfg);
+
+- ltq_pci_startup(pdev);
++ ret = ltq_pci_startup(pdev);
++ if (ret < 0)
++ return ret;
+
+ pci_load_of_ranges(&pci_controller, pdev->dev.of_node);
+ register_pci_controller(&pci_controller);
+--
+2.17.1
+
--- /dev/null
+From 0b9567e59cbdb7bec4646278b5c5b3e770ea11f9 Mon Sep 17 00:00:00 2001
+From: Mathias Kresin <dev@kresin.me>
+Date: Mon, 28 Jan 2019 22:08:05 +0100
+Subject: [PATCH 1/6] MIPS: lantiq: pci: check return codes
+
+ltq_pci_startup() returns an error if something went wrong. Check and
+return the error instead of pretend everything is fine.
+
+Signed-off-by: Mathias Kresin <dev@kresin.me>
+---
+ arch/mips/pci/pci-lantiq.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/arch/mips/pci/pci-lantiq.c b/arch/mips/pci/pci-lantiq.c
+index 1ca42f482130..9afca76a7b02 100644
+--- a/arch/mips/pci/pci-lantiq.c
++++ b/arch/mips/pci/pci-lantiq.c
+@@ -207,6 +207,7 @@ static int ltq_pci_startup(struct platform_device *pdev)
+ static int ltq_pci_probe(struct platform_device *pdev)
+ {
+ struct resource *res_cfg, *res_bridge;
++ int ret;
+
+ pci_clear_flags(PCI_PROBE_ONLY);
+
+@@ -220,7 +221,9 @@ static int ltq_pci_probe(struct platform_device *pdev)
+ if (IS_ERR(ltq_pci_mapped_cfg))
+ return PTR_ERR(ltq_pci_mapped_cfg);
+
+- ltq_pci_startup(pdev);
++ ret = ltq_pci_startup(pdev);
++ if (ret < 0)
++ return ret;
+
+ pci_load_of_ranges(&pci_controller, pdev->dev.of_node);
+ register_pci_controller(&pci_controller);
+--
+2.17.1
+