qcacld-3.0: Fix error of invalid dev type when unloading wlan

PLD deletes dev node before calling HDD remove callback functions.
It causes an error of reporting invalid dev type when a platform
API is called within remove callback function. Deleting dev node
after remove callback being called will fix the issue.

CRs-Fixed: 1020538
Change-Id: I3df5810c20a5965b908f15d4182e9b927e033afc
diff --git a/core/pld/src/pld_pcie.c b/core/pld/src/pld_pcie.c
index 2b918b8..84175cd 100644
--- a/core/pld/src/pld_pcie.c
+++ b/core/pld/src/pld_pcie.c
@@ -109,6 +109,8 @@
 	if (!pld_context)
 		return;
 
+	pld_context->ops->remove(&pdev->dev, PLD_BUS_TYPE_PCIE);
+
 	spin_lock_irqsave(&pld_context->pld_lock, flags);
 	list_for_each_entry_safe(dev_node, tmp, &pld_context->dev_list, list) {
 		if (dev_node->dev == &pdev->dev) {
@@ -117,8 +119,6 @@
 		}
 	}
 	spin_unlock_irqrestore(&pld_context->pld_lock, flags);
-
-	pld_context->ops->remove(&pdev->dev, PLD_BUS_TYPE_PCIE);
 }
 
 #ifdef CONFIG_CNSS