brcmf_p2p_generate_bss_mac(9)
π brcmf_p2p_generate_bss_mac(9) π
okay so bestie, welcome to the Kernel API Manual β this is the page for brcmf_p2p_generate_bss_mac, and honestly? it's a little legend. it makes mac addresses appear out of thin air for P2P. witchcraft? maybe. iconic? absolutely. π§β¨
β¨ NAME β¨
brcmf_p2p_generate_bss_mac β derive mac addresses for P2P.
like... it conjures them. no cap. π
π¦ SYNOPSIS π¦
void brcmf_p2p_generate_bss_mac (struct brcmf_p2p_info *p2p , u8
*dev_addr );
no return value, it just does the thing and leaves. main character energy fr fr. π
πΈ ARGUMENTS πΈ
p2pβ the P2P specific data. this is the whole vibe container, it holds everything P2P needs to know about itself π«Άdev_addrβ an optional device address. optional!! so if you don't have one, don't stress, the function has a backup plan (spoiler: it's random, see below π)
π DESCRIPTION π
so here's the tea: P2P needs mac addresses for the P2P device and for the interface. two addresses, one function, very efficient of it honestly.
but the important bit β the part where you go "oh π" β is this: if no device address is specified, those mac addresses get derived from a random ethernet address. literally generated from scratch. from the void. from vibes.
so dev_addr being NULL/unspecified isn't a bug, bestie, it's a feature. the function just picks a random ethernet address and builds the P2P device and interface macs from it. slay. π₯
ngl there's no error return here β it's a void function, so you don't get a little "hey, that worked!" back. you just trust it. π«Ά
π SEE ALSO π
if you're the kind of person who reads the whole wiki instead of just the one page (respect), here's the full squad. π
the kernel file lives at ./drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c β that's the mothership, go say hi.
structs & enums first, because they're the building blocks:
struct brcmf_p2p_disc_st_le(9)enum brcmf_p2p_disc_state(9)struct brcmf_p2p_scan_le(9)struct brcmf_p2p_pub_act_frame(9)struct brcmf_p2p_action_frame(9)struct brcmf_p2psd_gas_pub_act_frame(9)struct brcmf_config_af_params(9)
then the functions, in the order the manual gives them, no skipping, no merging, we don't do that here:
brcmf_p2p_is_pub_action(9)brcmf_p2p_is_dpp_pub_action(9)brcmf_p2p_is_p2p_action(9)brcmf_p2p_is_gas_action(9)brcmf_p2p_print_actframe(9)brcmf_p2p_set_firmware(9)brcmf_p2p_scan_is_p2p_request(9)brcmf_p2p_set_discover_state(9)brcmf_p2p_deinit_discovery(9)brcmf_p2p_enable_discovery(9)brcmf_p2p_escan(9)brcmf_p2p_run_escan(9)brcmf_p2p_find_listen_channel(9)brcmf_p2p_scan_prep(9)brcmf_p2p_discover_listen(9)brcmf_p2p_remain_on_channel(9)brcmf_p2p_notify_listen_complete(9)brcmf_p2p_cancel_remain_on_channel(9)brcmf_p2p_act_frm_search(9)brcmf_p2p_afx_handler(9)brcmf_p2p_af_searching_channel(9)brcmf_p2p_scan_finding_common_channel(9)brcmf_p2p_abort_action_frame(9)brcmf_p2p_stop_wait_next_action_frame(9)brcmf_p2p_gon_req_collision(9)brcmf_p2p_notify_action_frame_rx(9)brcmf_p2p_notify_action_tx_complete(9)brcmf_p2p_tx_action_frame(9)brcmf_p2p_pub_af_tx(9)brcmf_p2p_send_action_frame(9)brcmf_p2p_notify_rx_mgmt_p2p_probereq(9)brcmf_p2p_get_current_chanspec(9)brcmf_p2p_ifchange(9)brcmf_p2p_create_p2pdev(9)brcmf_p2p_add_vif(9)brcmf_p2p_del_vif(9)brcmf_p2p_attach(9)brcmf_p2p_detach(9)
that's the whole group chat, all present and accounted for π
π sign-off π
okay that's the page!! sourced from ./drivers/net/wireless/broadco... (yes it's truncated in the footer, that's just how the manual prints it, don't come for me π), October 2026, and it's all brcmf_p2p_generate_bss_mac(9) flavored. go forth and let the kernel make you a random mac address. you're gonna eat. periodt. π
β¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms