mirror of
https://github.com/gnuton/asuswrt-merlin.ng.git
synced 2025-05-19 07:51:46 +02:00
698 lines
20 KiB
C
698 lines
20 KiB
C
|
|
/*
|
|
Copyright 2000-2018 Broadcom Corporation
|
|
|
|
<:label-BRCM:2011:DUAL/GPL:standard
|
|
|
|
Unless you and Broadcom execute a separate written software license
|
|
agreement governing use of this software, this software is licensed
|
|
to you under the terms of the GNU General Public License version 2
|
|
(the "GPL"), available at http://www.broadcom.com/licenses/GPLv2.php,
|
|
with the following added to such license:
|
|
|
|
As a special exception, the copyright holders of this software give
|
|
you permission to link this software with independent modules, and
|
|
to copy and distribute the resulting executable under terms of your
|
|
choice, provided that you also meet, for each linked independent
|
|
module, the terms and conditions of the license of that module.
|
|
An independent module is a module which is not derived from this
|
|
software. The special exception does not apply to any modifications
|
|
of the software.
|
|
|
|
Not withstanding the above, under no circumstances may you combine
|
|
this software in any way with any other Broadcom software provided
|
|
under a license other than the GPL, without Broadcom's express prior
|
|
written consent.
|
|
|
|
:>
|
|
*/
|
|
|
|
#include "bp_defs.h"
|
|
#include "boardparms.h"
|
|
|
|
WLAN_PCI_PATCH_INFO wlanPciInfo[]={
|
|
#if defined(_BCM963268_) || defined(CONFIG_BCM963268)
|
|
/* this is the patch to boardtype(boardid) for 63268MBV */
|
|
{"963268MBV", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168MBV_17A */
|
|
{"963168MBV_17A", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168MBV_30A */
|
|
{"963168MBV_30A", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168MBV3 */
|
|
{"963168MBV3", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168MBV17A302 */
|
|
{"963168MBV17A302", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168MBV30A302 */
|
|
{"963168MBV30A302", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963268V30A */
|
|
{"963268V30A", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5E714e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 63268BU */
|
|
{"963268BU", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5A714e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 63168ACH5 */
|
|
{"963168ACH5", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5A714e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168VX */
|
|
{"963168VX", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5A814e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168VX_P300 */
|
|
{"963168VX_P300", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5A814e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168VX_P400 */
|
|
{"963168VX_P400", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5A814e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 63168XH */
|
|
{"963168XH", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5E214e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 63168XM */
|
|
{"963168XM", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x61f14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168XH5 */
|
|
{"963168XH5", 0x435f14e4, 64,
|
|
{{"deviceids", 0, 0x434f14e4},
|
|
{"subpciids", 11, 0x64014e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168XN5 */
|
|
{"963168XN5", 0x435f14e4, 64,
|
|
{{"deviceids", 0, 0x434f14e4},
|
|
{"subpciids", 11, 0x68414e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168XM5 */
|
|
{"963168XM5", 0x435f14e4, 64,
|
|
{{"deviceids", 0, 0x434f14e4},
|
|
{"subpciids", 11, 0x68514e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168XM5_6302 */
|
|
{"963168XM5_6302", 0x435f14e4, 64,
|
|
{{"deviceids", 0, 0x434f14e4},
|
|
{"subpciids", 11, 0x68614e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 963168MP */
|
|
{"963168MP", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
/* this is the patch to boardtype(boardid) for 63168WFAR */
|
|
{"963168WFAR", 0x435f14e4, 64,
|
|
{{"subpciids", 11, 0x5BB14e4},
|
|
{"", 0, 0}}},
|
|
#endif
|
|
{"", 0, 0, {{"", 0, 0}}}, /* last entry*/
|
|
};
|
|
|
|
#if defined(_BCM963268_) || defined(CONFIG_BCM963268)
|
|
/* The unique part contains the subSytemId (boardId) and the BoardRev number */
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963268MBV[] = {
|
|
{2, 0x5BB},
|
|
{65, 0x1204},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963268V30A[] = {
|
|
{2, 0x5E7},
|
|
{65, 0x1101},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963268BU[] = {
|
|
{2, 0x5A7},
|
|
{65, 0x1201},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168XH[] = {
|
|
{2, 0x5E2},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168XM[] = {
|
|
{2, 0x61F},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168XH5[] = {
|
|
{2, 0x640},
|
|
{48, 0x434f},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168XN5[] = {
|
|
{2, 0x684},
|
|
{48, 0x434f},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168XM5[] = {
|
|
{2, 0x685},
|
|
{48, 0x434f},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168XM5_6302[] = {
|
|
{2, 0x686},
|
|
{48, 0x434f},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963168MP[] = {
|
|
{2, 0x5BB},
|
|
{48, 0x433f},
|
|
{65, 0x1100},
|
|
{0, 0}
|
|
};
|
|
|
|
/* The common part contains the entries that are valid for multiple boards */
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963268MBV[] = {
|
|
{ 78, 0x0303},
|
|
{ 79, 0x0202},
|
|
{ 80, 0xff02},
|
|
{ 87, 0x0315},
|
|
{ 88, 0x0315},
|
|
{ 94, 0x001E},
|
|
{ 96, 0x2048},
|
|
{ 97, 0xFFB5},
|
|
{ 98, 0x175F},
|
|
{ 99, 0xFB29},
|
|
{ 100, 0x3E40},
|
|
{ 101, 0x403C},
|
|
{ 102, 0xFF15},
|
|
{ 103, 0x1455},
|
|
{ 104, 0xFB95},
|
|
{ 108, 0xFF28},
|
|
{ 109, 0x1315},
|
|
{ 110, 0xFBF0},
|
|
{ 112, 0x2048},
|
|
{ 113, 0xFFD7},
|
|
{ 114, 0x17D6},
|
|
{ 115, 0xFB67},
|
|
{ 116, 0x3E40},
|
|
{ 117, 0x403C},
|
|
{ 118, 0xFE87},
|
|
{ 119, 0x110F},
|
|
{ 120, 0xFB4B},
|
|
{ 124, 0xFF8D},
|
|
{ 125, 0x1146},
|
|
{ 126, 0xFCD6},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x4444},
|
|
{ 163, 0x0000},
|
|
{ 164, 0x2222},
|
|
{ 165, 0x0000},
|
|
{ 166, 0x2222},
|
|
{ 167, 0x0000},
|
|
{ 168, 0x2222},
|
|
{ 169, 0x4000},
|
|
{ 170, 0x4444},
|
|
{ 171, 0x4000},
|
|
{ 172, 0x4444},
|
|
{ 177, 0x2000},
|
|
{ 178, 0x2222},
|
|
{ 179, 0x2000},
|
|
{ 180, 0x2222},
|
|
{ 185, 0x2000},
|
|
{ 186, 0x2222},
|
|
{ 187, 0x2000},
|
|
{ 188, 0x2222},
|
|
{ 193, 0x2000},
|
|
{ 194, 0x2222},
|
|
{ 195, 0x2000},
|
|
{ 196, 0x2222},
|
|
{ 201, 0x1111},
|
|
{ 202, 0x2222},
|
|
{ 203, 0x4446},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963168XH[] = {
|
|
{ 66, 0x3200},
|
|
{ 67, 0x8000},
|
|
{ 87, 0x031f},
|
|
{ 88, 0x031f},
|
|
{ 93, 0x0202},
|
|
{ 96, 0x2064},
|
|
{ 97, 0xfe59},
|
|
{ 98, 0x1c81},
|
|
{ 99, 0xf911},
|
|
{ 112, 0x2064},
|
|
{ 113, 0xfe55},
|
|
{ 114, 0x1c00},
|
|
{ 115, 0xf92c},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x0000},
|
|
{ 169, 0x0000},
|
|
{ 170, 0x0000},
|
|
{ 171, 0x0000},
|
|
{ 172, 0x0000},
|
|
{ 203, 0x2222},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963168XM[] = {
|
|
{ 66, 0x3200},
|
|
{ 67, 0x8000},
|
|
{ 87, 0x031f},
|
|
{ 88, 0x031f},
|
|
{ 93, 0x0202},
|
|
{ 96, 0x205c},
|
|
{ 97, 0xfe94},
|
|
{ 98, 0x1c92},
|
|
{ 99, 0xf948},
|
|
{ 112, 0x205c},
|
|
{ 113, 0xfe81},
|
|
{ 114, 0x1be6},
|
|
{ 115, 0xf947},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x0000},
|
|
{ 169, 0x0000},
|
|
{ 170, 0x0000},
|
|
{ 171, 0x0000},
|
|
{ 172, 0x0000},
|
|
{ 203, 0x2222},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963168XH5[] = {
|
|
{ 66, 0x3200},
|
|
{ 67, 0x8000},
|
|
{ 78, 0x0300},
|
|
{ 87, 0x031f},
|
|
{ 88, 0x033f},
|
|
{ 93, 0x0202},
|
|
{ 97, 0xffb5},
|
|
{ 98, 0x175f},
|
|
{ 99, 0xfb29},
|
|
{ 100, 0x4060},
|
|
{ 101, 0x6060},
|
|
{ 102, 0xfee4},
|
|
{ 103, 0x1d2c},
|
|
{ 104, 0xfa0c},
|
|
{ 105, 0xfea2},
|
|
{ 106, 0x149a},
|
|
{ 107, 0xfafc},
|
|
{ 108, 0xfead},
|
|
{ 109, 0x1da8},
|
|
{ 110, 0xf986},
|
|
{ 113, 0xffd7},
|
|
{ 114, 0x17d6},
|
|
{ 115, 0xfb67},
|
|
{ 116, 0x4060},
|
|
{ 117, 0x6060},
|
|
{ 118, 0xfee4},
|
|
{ 119, 0x1d2c},
|
|
{ 120, 0xfa0c},
|
|
{ 121, 0xfea2},
|
|
{ 122, 0x149a},
|
|
{ 123, 0xfafc},
|
|
{ 124, 0xfead},
|
|
{ 125, 0x1da8},
|
|
{ 126, 0xf986},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x0000},
|
|
{ 169, 0x0000},
|
|
{ 170, 0x0000},
|
|
{ 171, 0x0000},
|
|
{ 172, 0x0000},
|
|
{ 203, 0x2222},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963168XN5[] = {
|
|
{ 66, 0x2200},
|
|
{ 67, 0x8000},
|
|
{ 78, 0x0300},
|
|
{ 87, 0x031f},
|
|
{ 88, 0x033f},
|
|
{ 96, 0x4054},
|
|
{ 97, 0xffb5},
|
|
{ 98, 0x175f},
|
|
{ 99, 0xfb29},
|
|
{ 100, 0x405c},
|
|
{ 101, 0x5c5c},
|
|
{ 102, 0xfedf},
|
|
{ 103, 0x1670},
|
|
{ 104, 0xfabf},
|
|
{ 105, 0xfeb2},
|
|
{ 106, 0x1691},
|
|
{ 107, 0xfa6a},
|
|
{ 108, 0xfec0},
|
|
{ 109, 0x16cd},
|
|
{ 110, 0xfaa5},
|
|
{ 112, 0x404e},
|
|
{ 113, 0xffd7},
|
|
{ 114, 0x17d6},
|
|
{ 115, 0xfb67},
|
|
{ 116, 0x405c},
|
|
{ 117, 0x5c5c},
|
|
{ 118, 0xfeb2},
|
|
{ 119, 0x1691},
|
|
{ 120, 0xfa6a},
|
|
{ 121, 0xfeb2},
|
|
{ 122, 0x1691},
|
|
{ 123, 0xfa6a},
|
|
{ 124, 0xfe60},
|
|
{ 125, 0x1685},
|
|
{ 126, 0xfa09},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x0000},
|
|
{ 163, 0x8888},
|
|
{ 164, 0x8888},
|
|
{ 165, 0x8888},
|
|
{ 166, 0x8888},
|
|
{ 167, 0x8888},
|
|
{ 168, 0x8888},
|
|
{ 169, 0x0000},
|
|
{ 170, 0x0000},
|
|
{ 171, 0x0000},
|
|
{ 172, 0x0000},
|
|
{ 177, 0x0000},
|
|
{ 178, 0x8888},
|
|
{ 179, 0x8888},
|
|
{ 180, 0x8888},
|
|
{ 181, 0x8888},
|
|
{ 182, 0x8888},
|
|
{ 183, 0x8888},
|
|
{ 184, 0x8888},
|
|
{ 185, 0x8888},
|
|
{ 186, 0x8888},
|
|
{ 187, 0x0000},
|
|
{ 188, 0x8888},
|
|
{ 189, 0x8888},
|
|
{ 190, 0x8888},
|
|
{ 191, 0x8888},
|
|
{ 192, 0x8888},
|
|
{ 193, 0x8888},
|
|
{ 194, 0x8888},
|
|
{ 195, 0x8888},
|
|
{ 196, 0x8888},
|
|
{ 197, 0x0000},
|
|
{ 198, 0x8888},
|
|
{ 199, 0x8888},
|
|
{ 200, 0x8888},
|
|
{ 201, 0x2222},
|
|
{ 202, 0x2222},
|
|
{ 203, 0x2222},
|
|
{ 204, 0x2222},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963168XM5[] = {
|
|
{ 66, 0x3200},
|
|
{ 67, 0x8000},
|
|
{ 78, 0x0300},
|
|
{ 87, 0x031f},
|
|
{ 88, 0x033f},
|
|
{ 93, 0x0202},
|
|
{ 96, 0x405c},
|
|
{ 97, 0xffb5},
|
|
{ 98, 0x175f},
|
|
{ 99, 0xfb29},
|
|
{ 100, 0x405c},
|
|
{ 101, 0x5c5c},
|
|
{ 102, 0xfedd},
|
|
{ 103, 0x1a8b},
|
|
{ 104, 0xfa70},
|
|
{ 105, 0xfea2},
|
|
{ 106, 0x149a},
|
|
{ 107, 0xfafc},
|
|
{ 108, 0xfee7},
|
|
{ 109, 0x1a87},
|
|
{ 110, 0xfa84},
|
|
{ 112, 0x405c},
|
|
{ 113, 0xffd7},
|
|
{ 114, 0x17d6},
|
|
{ 115, 0xfb67},
|
|
{ 116, 0x405c},
|
|
{ 117, 0x5c5c},
|
|
{ 118, 0xfedd},
|
|
{ 119, 0x1a8b},
|
|
{ 120, 0xfa70},
|
|
{ 121, 0xfea2},
|
|
{ 122, 0x149a},
|
|
{ 123, 0xfafc},
|
|
{ 124, 0xfee7},
|
|
{ 125, 0x1a87},
|
|
{ 126, 0xfa84},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x0000},
|
|
{ 169, 0x0000},
|
|
{ 170, 0x0000},
|
|
{ 171, 0x0000},
|
|
{ 172, 0x0000},
|
|
{ 203, 0x1111},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963168MP[] = {
|
|
{ 78, 0x0303},
|
|
{ 79, 0x0202},
|
|
{ 80, 0xff02},
|
|
{ 87, 0x0315},
|
|
{ 88, 0x0315},
|
|
{ 96, 0x2048},
|
|
{ 97, 0xffb5},
|
|
{ 98, 0x168c},
|
|
{ 99, 0xfb31},
|
|
{ 100, 0x3E40},
|
|
{ 101, 0x403C},
|
|
{ 102, 0xFF15},
|
|
{ 103, 0x1455},
|
|
{ 104, 0xFB95},
|
|
{ 108, 0xFF28},
|
|
{ 109, 0x1315},
|
|
{ 110, 0xFBF0},
|
|
{ 112, 0x2048},
|
|
{ 113, 0xffd7},
|
|
{ 114, 0x17b6},
|
|
{ 115, 0xfb68},
|
|
{ 116, 0x3E40},
|
|
{ 117, 0x403C},
|
|
{ 118, 0xFE87},
|
|
{ 119, 0x110F},
|
|
{ 120, 0xFB4B},
|
|
{ 124, 0xFF8D},
|
|
{ 125, 0x1146},
|
|
{ 126, 0xFCD6},
|
|
{ 161, 0x0000},
|
|
{ 162, 0x4444},
|
|
{ 163, 0x0000},
|
|
{ 164, 0x2222},
|
|
{ 165, 0x0000},
|
|
{ 166, 0x2222},
|
|
{ 167, 0x0000},
|
|
{ 168, 0x2222},
|
|
{ 169, 0x4000},
|
|
{ 170, 0x4444},
|
|
{ 171, 0x4000},
|
|
{ 172, 0x4444},
|
|
{ 177, 0x2000},
|
|
{ 178, 0x2222},
|
|
{ 179, 0x2000},
|
|
{ 180, 0x2222},
|
|
{ 185, 0x2000},
|
|
{ 186, 0x2222},
|
|
{ 187, 0x2000},
|
|
{ 188, 0x2222},
|
|
{ 193, 0x2000},
|
|
{ 194, 0x2222},
|
|
{ 195, 0x2000},
|
|
{ 196, 0x2222},
|
|
{ 201, 0x1111},
|
|
{ 202, 0x2222},
|
|
{ 203, 0x4446},
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963167REF2[] = {
|
|
{97, 0xfe97},
|
|
{98, 0x189e},
|
|
{99, 0xfa0c},
|
|
{113, 0xfe8b},
|
|
{114, 0x187b},
|
|
{115, 0xfa0a},
|
|
{0, 0}
|
|
};
|
|
|
|
#endif
|
|
|
|
#if defined(_BCM96838_) || defined(CONFIG_BCM96838)
|
|
/* The unique part contains the subSytemId (boardId) and the BoardRev number */
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_968380GERG[] = {
|
|
{ 2, 0x05e9},
|
|
{ 65, 0x1256},
|
|
{0, 0}
|
|
};
|
|
|
|
/* The common part contains the entries that are valid for multiple boards */
|
|
static WLAN_SROM_ENTRY wlan_patch_common_968380GERG[] = {
|
|
{ 113, 0xfe94},
|
|
{ 114, 0x1904},
|
|
{ 115, 0xfa18},
|
|
{ 162, 0x4444},
|
|
{ 170, 0x4444},
|
|
{ 172, 0x4444},
|
|
{0, 0}
|
|
};
|
|
#endif
|
|
|
|
#if defined(_BCM963138_) || defined(CONFIG_BCM963138)
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963138REF[] = {
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963138REF[] = {
|
|
{ 66, 0x200},
|
|
{ 68, 0x9800},
|
|
{ 87, 0x41f},
|
|
{ 96, 0x204A},
|
|
{ 97, 0xFE9B},
|
|
{ 98, 0x17D5},
|
|
{ 99, 0xFAAD},
|
|
{ 112, 0x204A},
|
|
{ 113, 0xFE74},
|
|
{ 114, 0x1646},
|
|
{ 115, 0xFAC2},
|
|
{ 162, 0x4444},
|
|
{ 170, 0x4444},
|
|
{ 172, 0x4444},
|
|
{0, 0}
|
|
};
|
|
#endif
|
|
|
|
#if defined(_BCM963381_) || defined(CONFIG_BCM963381)
|
|
static WLAN_SROM_ENTRY wlan_patch_unique_963381REF[] = {
|
|
{0, 0}
|
|
};
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_common_963381[] = {
|
|
{ 97, 0xfe46},
|
|
{ 98, 0x170e},
|
|
{ 99, 0xfa44},
|
|
{ 113, 0xfe87},
|
|
{ 114, 0x1932},
|
|
{ 115, 0xfa2d},
|
|
{0, 0}
|
|
};
|
|
#endif
|
|
|
|
|
|
static WLAN_SROM_ENTRY wlan_patch_LAST[] = {
|
|
{0, 0}
|
|
};
|
|
/* this data structure could be moved to boardparams structure in the future */
|
|
/* does not require to rebuild cfe here if more srom entries are needed */
|
|
WLAN_SROM_PATCH_INFO wlanPaInfo[]={
|
|
#if defined(_BCM963268_) || defined(CONFIG_BCM963268)
|
|
{"963268MBV", 0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963168MBV_17A", 0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963168MBV_30A", 0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963168MBV3", 0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963168MBV17A302",0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963168MBV30A302",0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963268V30A", 0x6362, 220, wlan_patch_unique_963268V30A, wlan_patch_common_963268MBV},
|
|
{"963268BU", 0x6362, 220, wlan_patch_unique_963268BU, wlan_patch_common_963268MBV},
|
|
{"963268BU_P300", 0x6362, 220, wlan_patch_unique_963268BU, wlan_patch_common_963268MBV},
|
|
{"963168AC5", 0x6362, 220, wlan_patch_unique_963268BU, wlan_patch_common_963268MBV},
|
|
{"963168ACH5", 0x6362, 220, wlan_patch_unique_963268BU, wlan_patch_common_963268MBV},
|
|
{"963168XH", 0x6362, 220, wlan_patch_unique_963168XH, wlan_patch_common_963168XH},
|
|
{"963167REF1", 0x6362, 220, wlan_patch_unique_963168XH, wlan_patch_common_963168XH},
|
|
{"963167REF2", 0x6362, 220, wlan_patch_unique_963167REF2, wlan_patch_common_963168XH},
|
|
{"963167REF3", 0x6362, 220, wlan_patch_unique_963268BU, wlan_patch_common_963268MBV},
|
|
{"963168XM", 0x6362, 220, wlan_patch_unique_963168XM, wlan_patch_common_963168XM},
|
|
{"963168XH5", 0x6362, 220, wlan_patch_unique_963168XH5, wlan_patch_common_963168XH5},
|
|
{"963168XN5", 0x6362, 220, wlan_patch_unique_963168XN5, wlan_patch_common_963168XN5},
|
|
{"963168XM5", 0x6362, 220, wlan_patch_unique_963168XM5, wlan_patch_common_963168XM5},
|
|
{"963168XM5_6302", 0x6362, 220, wlan_patch_unique_963168XM5_6302,wlan_patch_common_963168XM5},
|
|
{"963168WFAR", 0x6362, 220, wlan_patch_unique_963268MBV, wlan_patch_common_963268MBV},
|
|
{"963168MP", 0x6362, 220, wlan_patch_unique_963168MP, wlan_patch_common_963168MP},
|
|
#endif
|
|
|
|
#if defined(_BCM96838_) || defined(CONFIG_BCM96838)
|
|
{"968380GERG", 0xa8d1, 220, wlan_patch_unique_968380GERG, wlan_patch_common_968380GERG},
|
|
#endif
|
|
|
|
#if defined(_BCM963138_) || defined(CONFIG_BCM963138)
|
|
{"963138REF_LTE", 0xa8d1, 220, wlan_patch_unique_963138REF, wlan_patch_common_963138REF},
|
|
{"963138LTE_P302", 0xa8d1, 220, wlan_patch_unique_963138REF, wlan_patch_common_963138REF},
|
|
#endif
|
|
|
|
#if defined(_BCM963381_) || defined(CONFIG_BCM963381)
|
|
{"963381REF1", 0xa8d1, 220, wlan_patch_unique_963381REF, wlan_patch_common_963381},
|
|
{"963381A_REF1", 0xa8d1, 220, wlan_patch_unique_963381REF, wlan_patch_common_963381},
|
|
{"963381REF1_A0", 0xa8d1, 220, wlan_patch_unique_963381REF, wlan_patch_common_963381},
|
|
#endif
|
|
|
|
{"", 0, 0, wlan_patch_LAST, wlan_patch_LAST}, /* last entry*/
|
|
};
|
|
|
|
#if !defined(_CFE_)
|
|
#include "6802_map_part.h"
|
|
|
|
// MoCA init command sequence
|
|
// Enable RGMII_0 to MOCA. 1Gbps
|
|
// Enable RGMII_1 to GPHY. 1Gbps
|
|
BpCmdElem moca6802InitSeq[] = {
|
|
{ CMD_WRITE, SUN_TOP_CTRL_SW_INIT_0_CLEAR, 0x0FFFFFFF }, //clear sw_init signals
|
|
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_CTRL_0, 0x11110011 }, //pinmux, rgmii, 3450
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_CTRL_1, 0x11111111 }, //rgmii
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_CTRL_2, 0x11111111 }, //rgmii
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_CTRL_3, 0x22221111 }, // enable sideband all,0,1,2, rgmii
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_CTRL_4, 0x10000022 }, // enable sideband 3,4, host intr
|
|
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_CTRL_6, 0x00001100 }, // mdio, mdc
|
|
|
|
// { CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_PAD_CTRL_2, 0x00555510 }, // set gpio 38,39,40 to PULL_NONE
|
|
{ CMD_WRITE, SUN_TOP_CTRL_PIN_MUX_PAD_CTRL_3, 0x2402 }, // Set GPIO 41 to PULL_UP
|
|
|
|
{ CMD_WRITE, SUN_TOP_CTRL_GENERAL_CTRL_NO_SCAN_0, 0x11 }, // , Use 2.5V for rgmii
|
|
{ CMD_WRITE, SUN_TOP_CTRL_GENERAL_CTRL_NO_SCAN_1, 0x3 }, // Disable GPHY LDO
|
|
{ CMD_WRITE, SUN_TOP_CTRL_GENERAL_CTRL_NO_SCAN_5, 0x47 }, // set test_drive_sel to 16mA
|
|
|
|
{ CMD_WRITE, EPORT_REG_EMUX_CNTRL, 0x02 }, // Select port mode. Activate both GPHY and MOCA phys.
|
|
|
|
{ CMD_WRITE, EPORT_REG_RGMII_0_CNTRL, 0x1 }, // Enable rgmii0.
|
|
{ CMD_WRITE, EPORT_REG_RGMII_1_CNTRL, 0x0 }, // Disable rgmii1.
|
|
#if defined(_BCM963138_) || defined(CONFIG_BCM963138) || defined(_BCM963148_) || defined(CONFIG_BCM963148) || defined(_BCM94908_) || defined(CONFIG_BCM94908)
|
|
{ CMD_WRITE, EPORT_REG_RGMII_0_RX_CLOCK_DELAY_CNTRL, 0xc0 }, // disable 2nd delay
|
|
#endif
|
|
{ CMD_WRITE, EPORT_REG_GPHY_CNTRL, 0x02A4C00F }, // Shutdown Gphy
|
|
|
|
{ CMD_WRITE, CLKGEN_PAD_CLOCK_DISABLE, 0x1 }, // Disable clkobsv output pin
|
|
|
|
{ CMD_WRITE, CLKGEN_LEAP_TOP_INST_CLOCK_DISABLE, 0x7 }, // Disable LEAP clocks
|
|
|
|
{ CMD_WRITE, PM_CONFIG, 0x4000 }, // disable uarts
|
|
{ CMD_WRITE, PM_CLK_CTRL, 0x1810c }, // disable second I2C port, PWMA and timers
|
|
|
|
{ CMD_END, 0, 0 }
|
|
};
|
|
|
|
#endif
|
|
|
|
|