mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 00:24:41 -04:00
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
This commit is contained in:
parent
83a047accb
commit
960fa2145c
2 changed files with 4 additions and 4 deletions
|
|
@ -109,6 +109,8 @@ static void pld_pcie_remove(struct pci_dev *pdev)
|
|||
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 @@ static void pld_pcie_remove(struct pci_dev *pdev)
|
|||
}
|
||||
}
|
||||
spin_unlock_irqrestore(&pld_context->pld_lock, flags);
|
||||
|
||||
pld_context->ops->remove(&pdev->dev, PLD_BUS_TYPE_PCIE);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_CNSS
|
||||
|
|
|
|||
|
|
@ -99,6 +99,8 @@ static void pld_snoc_remove(struct device *dev)
|
|||
if (!pld_context)
|
||||
return;
|
||||
|
||||
pld_context->ops->remove(dev, PLD_BUS_TYPE_SNOC);
|
||||
|
||||
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 == dev) {
|
||||
|
|
@ -107,8 +109,6 @@ static void pld_snoc_remove(struct device *dev)
|
|||
}
|
||||
}
|
||||
spin_unlock_irqrestore(&pld_context->pld_lock, flags);
|
||||
|
||||
pld_context->ops->remove(dev, PLD_BUS_TYPE_SNOC);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue