Search Linux Wireless

[PATCH 14/14] brcmfmac: CR4 takes precedence over CM3 in brcmf_chip_enter_download()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In the enter and exit download sequence the chip core info was checked
for presence of CM3 ARM core. If found it would enter download state for
the CM3. However, on devices that have a CM3 and CR4 this is not correct
and the CR4 should be used to enter download state. This patch changes
the ARM core lookup giving CR4 precedence.

Reviewed-by: Hante Meuleman <meuleman@xxxxxxxxxxxx>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@xxxxxxxxxxxx>
Signed-off-by: Arend van Spriel <arend@xxxxxxxxxxxx>
---
 drivers/net/wireless/brcm80211/brcmfmac/chip.c |   12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/net/wireless/brcm80211/brcmfmac/chip.c b/drivers/net/wireless/brcm80211/brcmfmac/chip.c
index b04ea95..18fc20e 100644
--- a/drivers/net/wireless/brcm80211/brcmfmac/chip.c
+++ b/drivers/net/wireless/brcm80211/brcmfmac/chip.c
@@ -967,13 +967,13 @@ void brcmf_chip_enter_download(struct brcmf_chip *pub)
 	brcmf_dbg(TRACE, "Enter\n");
 
 	chip = container_of(pub, struct brcmf_chip_priv, pub);
-	arm = brcmf_chip_get_core(pub, BCMA_CORE_ARM_CM3);
+	arm = brcmf_chip_get_core(pub, BCMA_CORE_ARM_CR4);
 	if (arm) {
-		brcmf_chip_cm3_enterdl(chip);
+		brcmf_chip_cr4_enterdl(chip);
 		return;
 	}
 
-	brcmf_chip_cr4_enterdl(chip);
+	brcmf_chip_cm3_enterdl(chip);
 }
 
 bool brcmf_chip_exit_download(struct brcmf_chip *pub, u32 rstvec)
@@ -984,11 +984,11 @@ bool brcmf_chip_exit_download(struct brcmf_chip *pub, u32 rstvec)
 	brcmf_dbg(TRACE, "Enter\n");
 
 	chip = container_of(pub, struct brcmf_chip_priv, pub);
-	arm = brcmf_chip_get_core(pub, BCMA_CORE_ARM_CM3);
+	arm = brcmf_chip_get_core(pub, BCMA_CORE_ARM_CR4);
 	if (arm)
-		return brcmf_chip_cm3_exitdl(chip);
+		return brcmf_chip_cr4_exitdl(chip, rstvec);
 
-	return brcmf_chip_cr4_exitdl(chip, rstvec);
+	return brcmf_chip_cm3_exitdl(chip);
 }
 
 bool brcmf_chip_sr_capable(struct brcmf_chip *pub)
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux