brcmfmac: add BCM4334 support
authorFranky Lin <frankyl@broadcom.com>
Tue, 26 Jun 2012 19:26:39 +0000 (21:26 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 27 Jun 2012 19:23:18 +0000 (15:23 -0400)
BCM4334 is a dualband a/b/g/n WiFi chip support 20MHz/40MHz
channels. This patch adds support for its SDIO interface.

Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/brcm80211/brcmfmac/bcmsdh_sdmmc.c
drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.c
drivers/net/wireless/brcm80211/brcmfmac/sdio_chip.c
drivers/net/wireless/brcm80211/include/brcm_hw_ids.h

index 82f51dbd0d66449a8172b9c385fb00f8562f1d14..49765d34b4e0b43ac947aa360fb58d1fff88aa90 100644 (file)
@@ -44,6 +44,7 @@
 
 #define SDIO_DEVICE_ID_BROADCOM_4329   0x4329
 #define SDIO_DEVICE_ID_BROADCOM_4330   0x4330
+#define SDIO_DEVICE_ID_BROADCOM_4334   0x4334
 
 #define SDIO_FUNC1_BLOCKSIZE           64
 #define SDIO_FUNC2_BLOCKSIZE           512
@@ -52,6 +53,7 @@
 static const struct sdio_device_id brcmf_sdmmc_ids[] = {
        {SDIO_DEVICE(SDIO_VENDOR_ID_BROADCOM, SDIO_DEVICE_ID_BROADCOM_4329)},
        {SDIO_DEVICE(SDIO_VENDOR_ID_BROADCOM, SDIO_DEVICE_ID_BROADCOM_4330)},
+       {SDIO_DEVICE(SDIO_VENDOR_ID_BROADCOM, SDIO_DEVICE_ID_BROADCOM_4334)},
        { /* end: all zeroes */ },
 };
 MODULE_DEVICE_TABLE(sdio, brcmf_sdmmc_ids);
index 2ee19c1a0d515f0e8d06decd498538ab2393dc1f..5c5f1cd8ff22349d8a47674b0347c0d9d21182f6 100644 (file)
@@ -3885,6 +3885,8 @@ static bool brcmf_sdbrcm_chipmatch(u16 chipid)
                return true;
        if (chipid == BCM4330_CHIP_ID)
                return true;
+       if (chipid == BCM4334_CHIP_ID)
+               return true;
        return false;
 }
 
index f8e1f1c84d08eb6837e013b4c85216a34d24d268..58155e23d220fecc5f985be109901bbfce42070b 100644 (file)
@@ -403,6 +403,23 @@ static int brcmf_sdio_chip_recognition(struct brcmf_sdio_dev *sdiodev,
                ci->c_inf[3].cib = 0x03004211;
                ci->ramsize = 0x48000;
                break;
+       case BCM4334_CHIP_ID:
+               ci->c_inf[0].wrapbase = 0x18100000;
+               ci->c_inf[0].cib = 0x29004211;
+               ci->c_inf[1].id = BCMA_CORE_SDIO_DEV;
+               ci->c_inf[1].base = 0x18002000;
+               ci->c_inf[1].wrapbase = 0x18102000;
+               ci->c_inf[1].cib = 0x0d004211;
+               ci->c_inf[2].id = BCMA_CORE_INTERNAL_MEM;
+               ci->c_inf[2].base = 0x18004000;
+               ci->c_inf[2].wrapbase = 0x18104000;
+               ci->c_inf[2].cib = 0x13080401;
+               ci->c_inf[3].id = BCMA_CORE_ARM_CM3;
+               ci->c_inf[3].base = 0x18003000;
+               ci->c_inf[3].wrapbase = 0x18103000;
+               ci->c_inf[3].cib = 0x07004211;
+               ci->ramsize = 0x80000;
+               break;
        default:
                brcmf_dbg(ERROR, "chipid 0x%x is not supported\n", ci->chip);
                return -ENODEV;
index 333193f20e1cfeb9071ee483bc30f6f272564300..bcc79b4e3267ba1434c3c0bfdec1b2de6f50d18b 100644 (file)
@@ -37,5 +37,6 @@
 #define BCM4329_CHIP_ID                0x4329
 #define BCM4330_CHIP_ID                0x4330
 #define BCM4331_CHIP_ID                0x4331
+#define BCM4334_CHIP_ID                0x4334
 
 #endif                         /* _BRCM_HW_IDS_H_ */