1. 如何快速去bring up bcm 的wifi chipset
? ?a. 首先的確認 編譯的BSP profile?
? ?b. 其次要先用 default 的kernel config 去編譯
? ?c. 現在我們的一些 PCIE/GPIO/driver 總線的設置 都在dts 中,有錯就去改dts
2. BCM 的板子bring up 注意事項
? ? a. ?fw: bcm963146GW_WL23D2D1GA_WLMLO_nand_squashfs_update.pkgtb?
? ? ? ? ? ?這里從fw 名字中包含幾種 信息(profile,flash 類型(nand,emmc)文件系統(ubi,squashfs)flashblock size(128、256),帶不帶bootloader(loader))
? ? ? ? .pkgtb 結尾的文件可以通過 bootloader cli ,webgui 的http 去升級
? ? ? ? ?.bin 結尾的可以用作燒錄機器燒錄(但一定要注意, 這個bin 有兩種,1. 是文件名中帶raw 的 1. 名字中沒有raw包含bootstrap) ?帶raw的是不帶ecc 的可以用作bootloader tftp 升級. 帶bootstrap 的是用作燒錄的帶ecc. ?
? ? ? ? ? ?這里注意 燒錄和tftp 千萬不要升錯了bin file
? ? ?b. ?啟動時的boardid 千萬不要選錯 boardid=968560REF_PCI2?
? ? ? ? 如何查看支持那些board id 可以在bootloader cli 中setenv ?boardid ?xx 來查看
? ? ? c. 這些信息可以給板子借一個console 來查看他的 星系
? ? ? ? ? U-Boot TPL 2019.07 (May 19 2024 - 00:53:56 -0700)
? ? ? ? ? U-Boot TPL 2019.07 (May 19 2024 - 00:53:56 -0700)
`Board is non secure`
`$TPL: 50404p3@499373 $`
`PMC driver initcall`
`BCM UBUS4 driver [ubus_sys] registered`
`BCM UBUS4 DCM clk driver [ubus_dcm_sys] registered`
`CPU Clock: 1500MHz`
`IMAGE is NAND`
`Trying to boot from NAND`
`nand flash device id 0xc2da9095, total size 256MB`
`block size 128KB, page size 2048 bytes, spare area 64 bytes required`
`ECC BCH-4`
`INFO: image from 2097152 to 2673868`
? ? ?3. BRCM EVM board 如何升級sc 的fw
? ? ? ? ? 首先 想用 brcm bootloader + sc 上層的方式是 不容易實現的 (flash map 不同) 要想這樣做一定要確定 brcm 的flash map 和sc 相同 并且 所用的ubi 的volume id 一定要相同
? ? ? ? ? 1. 通過tftp 吧整個image 更行 bootloader 和上層都是sercomm 的
? ? ? ? ? 2. 燒錄 flash.?
bcm wifi 啟動:
? 1. 首先 NONE csm fw 編譯(加上_BASESHELL) 即使none cms
? ? ?/release/maketargets??96856GWO_WL23D2D1GA_WLMLO_BASESHELL?
? ? 在這個項目中會遇到none cms viop 便不過,就直接自己解決brcm 說是宏報的不好
?2. 編譯MT DT test wifi driver (WLTEST=1 enable test driver)
? ? ?make PROFILE=96856GWO_WL23D2D1GA_WLMLO_BASESHELL WLTEST=1?
? ? ? wl -i wl0 ver 查看,入宮ver 中帶有test 字樣就是test driver
?3. test wifi driver bin
? ? ? DHD: /dhd/mfg/ ?現編時 test fw
? ? ? 普通 在/lib/modules/extra /wl_mfgtest.ko
?4. enable test fw?
? ? ?在bootloader cli 下 ?setenv wlFeature 0x2 ? // test?
? ? ? ? ? ? ? ? ? ? ? setenv wlFeature 0x0 ?//normal?
?5. application
? ? ?wlssk->ufnvram->hostapd
? ? ?wlssk-service.c
? ? ? wlconfig: wifi config
? ? ? ceventd/cevent ?時wifi 調試app和debug
? ? ??
?6. DHD enable
? ? bootargs_append=cma=56M ?48M for 63146
? ? ?dhd0=11
? ? ?dhd1=11
7. EVM board 可能 升級MCB 出錯。?
? ? ? shmoo completed OK
find magic number 0x64503301 at address 0x26000
reading blob from 0x26000 offset 0xc len 20492
digest sha256 OK
DPFE FW hpk3_16_ddr3 3.53.0.0 20210506 SEGMENT 2/4
FFF000F8 00000000 0090703D
DDR3
MCB rev=0x00020A01 Ref ID=0x0703D Sub Bld=0x009 Cookie=0x9E5C163A
Dram Timing 11-11-11
CMD @1T
Virt VTT on
Shmoo WL
One UI Steps : 0x76
? ?0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111
? ?0000000000111111111122222222223333333333444444444455555555556666666666777777777788888888889999999999000000000011111111
? ?0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567
00 X+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
01 X+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
shmoo completed with error
run shmoo error
MEMSYS init failed, return code 00000010
DPFE errors: 0x0 0x400000 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0
MHS errors: 0x10000 0x0
DDR scrambling enabled
### ERROR ### Please RESET the board ###
? ? ?ddr 4?
? ? ? ddr 0x40101615
? ? ?
? 2. 改bootloader 的code
? ? ??
?3. Bootloader 能燒錄的bin 要用par 文件來做,loader_xx.bin 不能用
?4. 如果啟動后 mtd 區域數據丟失或者 不可寫, 要看啟動過程中 有沒有人去寫gpio 的值。
5. 讀懂一個工程最快的步驟
? ? ?a. 要介紹文檔
? ? ?b. 下載工程
? ? ?c. ?看下下來的 源碼 找readme 來看
? ? ?d. ?在下載的 源碼中找介紹文檔讀
? 6. UIBI fs (var/ft)無法mount 上
? ? ?a. 首先要檢查 給的flash 的大小,ubi 最小3M,但是最好要是兩倍
? ? ?b. 我們遇到 inviald arguments 時 一般 都是 分區flash map 給的太小了
? ? ?
? ? ?用ubinfo -a 看 沒有可用空間
? ?
2.如何判斷一個bootloader 能否在另一個hw 上能不能起來
? ? a. 首先 他們的住chip的型號要相近 (也即bootcli 中的boardid 有支持列表)
? ? b. 他們的 flash、ram 都要能支持 (特別是 flash 他的blcok size 支持 DCH 4 還是8 )?
? ? c. 是否有security boot?
? ? ?d. 如何判斷 bootloader 能否帶起rootfs
? ? ? ? ?1. flash map 是否相同
? ? ? ? ?2. 是否有簽名校驗(校驗rootfs 不是ram 的整個ubi)
? ? ? ? ?3. ubi的volume name 是否和 bootloader 中的一樣。(不一樣找不到volum)
3.我們想要在 EVM board 上去跑sc fw 最快的方法
1. 如果 EVM board 的flash (block size,BCH 等都要看)和 ram 都是和 我們的hw 一樣,直接 在bcm 的bootloader cli 先tftp 升級(tftp VD4277B_evm_boot.bin ?
? ? nand erase.chip???
? ? nand write 0x1000000 0 $filesize) ?我們VD4277B sc hw 和evm board 不同
?????2. EVM board 和sc board hw 不同 (flash 和ram)
?????????這時最快的方法是 讓driver team 給以個bootloader 和sc 相同的flash map, 我們在升級 sc 的上層。
4.Broadcom wifi 如何 編譯 WLTEST fw(wlFeature=0x2)
? ? ? 首先 說明一點 如果是 dongle fw 編譯的的時候 在 dongle image 下有兩個錄 一個 formfw 的 一個mfg 的目錄就是 mfg test fw。
? ? ? 如果不是dongle fw, 則有連個ko for wl test (wl_mfgtest.ko ?hnd_mfgtest.ko), 這兩個 ko 在sdk 中有的有 prebuild 的ko 有的沒有就需要自己去編一個test ko。?
? ? ? ? ? build command: make clean; make PROFILE=<profile>_WLMFGTEST ? ?(在profile 加個后綴 _WLMFGTEST)
? ? ? ? ? 編出來后 的wl.ko ? 和 hnd.ko 就是 test image, 你再在編譯test image 時更名成wl_mfgtest.ko ?hnd_mfgtest.ko 然后copy 到你的rootfs中,然后去編。?
5. wl test fw 編譯方法:?
? ? ?make PROFILE=<profile> ?WLTEST=1 ?// 這種編譯方法只是 在編譯的時候安裝 mfg image ,不是 rebuild mfg test ko, 注意注意。?
? ? ? WLTEST=1 和 bsp config file 中 BUILD_HND_MFG=y ?都不是在編譯wl_mfgtest.ko 和 hnd_mfgtest.ko, 他只是去編譯一個test image, 包括hw test 時用到的default 值不同等。
? 6. ?Remove ?mfg test kernel module in formal release for flash size limtation.?
??????????????in bsp config file set BUILD_BCM_WLAN_NO_MFGBIN=y
?7. when you met the aclocal-1.14 command not found ?for compiler packets
? ? ? ?enter the directory && autoreconf -ivf?
?