Hi, sorry about the delayed reply… I reside in an area of direct influence from recent geopolitical events, irl priorities do take precedence.
There is a file inside that source package - the broadcom-sta-source:
/usr/src/broadcom-sta.tar.xz - it’s the source of the old Broadcom’s Linux STA driver from 2015ish. It included a lot of the scattered dependencies for building those two drivers:
Eventually, neither of those (or several others I tried) would build against the mainline 6.19.x sources, didn’t even try with 7.0.0-rc3, but I don’t think there’s any point to that.
Since the goal is to get wifi working on mainline, I thought I’d try armbian’s dkms for it, despite your (@MichaIng) reservations about it here, it was the only one updated enough that came close to building successfully, even against 7.0, no less:
[root@gppi01:~/bcmdhd-dkms/src] # make -C /lib/modules/$(uname -r)/build M=$PWD
make: Entering directory '/usr/src/linux-headers-7.0.0-rc3-edge-rockchip64'
make[1]: Entering directory '/root/bcmdhd-dkms/src'
warning: the compiler differs from the one used to build the kernel
The kernel was built by: aarch64-linux-gnu-gcc (Ubuntu 13.3.0-6ubuntu2~24.04.1) 13.3.0
You are using: gcc (Debian 14.2.0-19) 14.2.0
warning: pahole version differs from the one used to build the kernel
The kernel was built with: 125
You are using: 130
CC [M] dhd_static_buf.o
dhd_static_buf.c:188:1: warning: no previous prototype for ‘dhd_wlan_mem_prealloc’ [-Wmissing-prototypes]
188 | dhd_wlan_mem_prealloc(
| ^~~~~~~~~~~~~~~~~~~~~
LD [M] dhd_static_buf_.o
CC [M] aiutils.o
CC [M] siutils.o
siutils.c: In function ‘si_doattach’:
siutils.c:2893:78: warning: suggest braces around empty body in an ‘else’ statement [-Wempty-body]
2893 | SI_MSG(("Found chip type DVT (0x%08x)\n", w));
| ^
siutils.c: In function ‘si_tcm_size’:
siutils.c:7295:46: warning: suggest braces around empty body in an ‘else’ statement [-Wempty-body]
7295 | SI_ERROR(("si_iscoreup!!\n"));
| ^
In file included from ././include/typedefs.h:423,
from siutils.c:25:
siutils.c: At top level:
siutils.c:8942:15: warning: no previous prototype for ‘si_clear_backplane_to’ [-Wmissing-prototypes]
8942 | BCMPOSTTRAPFN(si_clear_backplane_to)(si_t *sih)
| ^~~~~~~~~~~~~~~~~~~~~
././include/bcmdefs.h:960:41: note: in definition of macro ‘BCMPOSTTRAPFN’
960 | #define BCMPOSTTRAPFN(_fn) _fn
| ^~~
siutils.c:8971:1: warning: no previous prototype for ‘si_slave_wrapper_add’ [-Wmissing-prototypes]
8971 | si_slave_wrapper_add(si_t *sih)
| ^~~~~~~~~~~~~~~~~~~~
CC [M] sbutils.o
sbutils.c: In function ‘sb_core_disable’:
sbutils.c:897:73: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
897 | SI_ERROR(("sb_core_disable: target state still busy\n"));
| ^
CC [M] bcmutils.o
bcmutils.c:1029:1: warning: no previous prototype for ‘prpkt’ [-Wmissing-prototypes]
1029 | prpkt(const char *msg, osl_t *osh, void *p0)
| ^~~~~
CC [M] bcmwifi_channels.o
CC [M] bcmxtlv.o
CC [M] bcm_app_utils.o
CC [M] bcmstdlib_s.o
CC [M] dhd_linux.o
dhd_linux.c: In function ‘dhd_process_cid_mac’:
dhd_linux.c:2222:18: error: implicit declaration of function ‘dhd_bus_chip_id’; did you mean ‘dhd_bus_chiprev’? [-Wimplicit-function-declaration]
2222 | chipid = dhd_bus_chip_id(dhdp);
| ^~~~~~~~~~~~~~~
| dhd_bus_chiprev
dhd_linux.c: At top level:
dhd_linux.c:2275:1: warning: no previous prototype for ‘dhd_set_packet_filter’ [-Wmissing-prototypes]
2275 | dhd_set_packet_filter(dhd_pub_t *dhd)
| ^~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:2816:1: warning: no previous prototype for ‘dhd_bssidx2bssid’ [-Wmissing-prototypes]
2816 | dhd_bssidx2bssid(dhd_pub_t *dhdp, int idx)
| ^~~~~~~~~~~~~~~~
dhd_linux.c:3014:1: warning: no previous prototype for ‘_dhd_set_mac_address’ [-Wmissing-prototypes]
3014 | _dhd_set_mac_address(dhd_info_t *dhd, int ifidx, uint8 *addr, bool skip_stop)
| ^~~~~~~~~~~~~~~~~~~~
dhd_linux.c:3190:7: warning: no previous prototype for ‘dhd_role_to_nl80211_iftype’ [-Wmissing-prototypes]
3190 | int32 dhd_role_to_nl80211_iftype(int32 role)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:3724:5: warning: no previous prototype for ‘dhd_sendup’ [-Wmissing-prototypes]
3724 | int dhd_sendup(dhd_pub_t *dhdp, int ifidx, void *p)
| ^~~~~~~~~~
dhd_linux.c:5087:6: warning: no previous prototype for ‘dhd_set_scb_probe’ [-Wmissing-prototypes]
5087 | void dhd_set_scb_probe(dhd_pub_t *dhd)
| ^~~~~~~~~~~~~~~~~
dhd_linux.c:6416:1: warning: no previous prototype for ‘dhd_force_collect_socram_during_wifi_onoff’ [-Wmissing-prototypes]
6416 | dhd_force_collect_socram_during_wifi_onoff(dhd_pub_t *dhdp)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:6817:1: warning: no previous prototype for ‘dhd_force_collect_init_fail_dumps’ [-Wmissing-prototypes]
6817 | dhd_force_collect_init_fail_dumps(dhd_pub_t *dhdp)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:6856:1: warning: no previous prototype for ‘dhd_open’ [-Wmissing-prototypes]
6856 | dhd_open(struct net_device *net)
| ^~~~~~~~
dhd_linux.c:7688:1: warning: no previous prototype for ‘dhd_is_static_ndev’ [-Wmissing-prototypes]
7688 | dhd_is_static_ndev(dhd_pub_t *dhdp, struct net_device *ndev)
| ^~~~~~~~~~~~~~~~~~
dhd_linux.c: In function ‘dhd_attach’:
dhd_linux.c:9035:38: error: ‘adapter’ undeclared (first use in this function)
9035 | dhd = wifi_platform_prealloc(adapter, DHD_PREALLOC_DHD_INFO, sizeof(dhd_info_t));
| ^~~~~~~
dhd_linux.c:9035:38: note: each undeclared identifier is reported only once for each function it appears in
dhd_linux.c: At top level:
dhd_linux.c:10311:5: warning: no previous prototype for ‘_dhd_tdls_enable’ [-Wmissing-prototypes]
10311 | int _dhd_tdls_enable(dhd_pub_t *dhd, bool tdls_on, bool auto_on, struct ether_addr *mac)
| ^~~~~~~~~~~~~~~~
dhd_linux.c:10755:1: warning: no previous prototype for ‘dhd_optimised_preinit_ioctls’ [-Wmissing-prototypes]
10755 | dhd_optimised_preinit_ioctls(dhd_pub_t * dhd)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:11563:1: warning: no previous prototype for ‘dhd_legacy_preinit_ioctls’ [-Wmissing-prototypes]
11563 | dhd_legacy_preinit_ioctls(dhd_pub_t *dhd)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:13444:5: warning: no previous prototype for ‘dhd_change_mtu’ [-Wmissing-prototypes]
13444 | int dhd_change_mtu(dhd_pub_t *dhdp, int new_mtu, int ifidx)
| ^~~~~~~~~~~~~~
dhd_linux.c:14117:1: warning: no previous prototype for ‘dhd_bus_detach’ [-Wmissing-prototypes]
14117 | dhd_bus_detach(dhd_pub_t *dhdp)
| ^~~~~~~~~~~~~~
dhd_linux.c:14997:5: warning: no previous prototype for ‘rockchip_wifi_init_module_rkwifi’ [-Wmissing-prototypes]
14997 | int rockchip_wifi_init_module_rkwifi(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:15011:6: warning: no previous prototype for ‘rockchip_wifi_exit_module_rkwifi’ [-Wmissing-prototypes]
15011 | void rockchip_wifi_exit_module_rkwifi(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:16008:1: warning: no previous prototype for ‘dhd_dev_init_ioctl’ [-Wmissing-prototypes]
16008 | dhd_dev_init_ioctl(struct net_device *dev)
| ^~~~~~~~~~~~~~~~~~
dhd_linux.c:17929:5: warning: no previous prototype for ‘write_file’ [-Wmissing-prototypes]
17929 | int write_file(const char * file_name, uint32 flags, uint8 *buf, int size)
| ^~~~~~~~~~
dhd_linux.c:18009:1: warning: no previous prototype for ‘write_dump_to_file’ [-Wmissing-prototypes]
18009 | write_dump_to_file(dhd_pub_t *dhd, uint8 *buf, int size, char *fname)
| ^~~~~~~~~~~~~~~~~~
dhd_linux.c:18145:5: warning: no previous prototype for ‘net_os_wake_lock_ctrl_timeout_enable’ [-Wmissing-prototypes]
18145 | int net_os_wake_lock_ctrl_timeout_enable(struct net_device *dev, int val)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:18830:5: warning: no previous prototype for ‘dhd_ioctl_entry_local’ [-Wmissing-prototypes]
18830 | int dhd_ioctl_entry_local(struct net_device *net, wl_ioctl_t *ioc, int cmd)
| ^~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:21375:1: warning: no previous prototype for ‘dhd_dbg_get_system_timestamp’ [-Wmissing-prototypes]
21375 | dhd_dbg_get_system_timestamp(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:21394:1: warning: no previous prototype for ‘dhd_log_dump_get_timestamp’ [-Wmissing-prototypes]
21394 | dhd_log_dump_get_timestamp(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
dhd_linux.c:24248:7: warning: no previous prototype for ‘dhd_get_conf’ [-Wmissing-prototypes]
24248 | void *dhd_get_conf(struct net_device *dev)
| ^~~~~~~~~~~~
make[3]: *** [/usr/src/linux-headers-7.0.0-rc3-edge-rockchip64/scripts/Makefile.build:292: dhd_linux.o] Error 1
make[2]: *** [/usr/src/linux-headers-7.0.0-rc3-edge-rockchip64/Makefile:2101: .] Error 2
make[1]: *** [/usr/src/linux-headers-7.0.0-rc3-edge-rockchip64/Makefile:248: __sub-make] Error 2
make[1]: Leaving directory '/root/bcmdhd-dkms/src'
make: *** [Makefile:248: __sub-make] Error 2
make: Leaving directory '/usr/src/linux-headers-7.0.0-rc3-edge-rockchip64'
Still failed though…