iwpm_add_mapping(9)
π iwpm_add_mapping(9) π
okay bestie, welcome to the Kernel API Manual β¨ today's main character is iwpm_add_mapping(9) and honestly? she's giving "quietly essential glue code" and we're obsessed π«Ά
πΈ NAME πΈ
iwpm_add_mapping β sends a netlink add mapping request to the userspace port mapper π
β SYNOPSIS β
int iwpm_add_mapping (struct iwpm_sa_data *pm_msg , u8 nl_client );
π¦ ARGUMENTS π¦
pm_msgβ holds the local ip/tcp address info that we're sending out π literally the payload, the whole reason we're herenl_clientβ the index of the netlink client, i.e. which client we're repping π«
π DESCRIPTION π
so the netlink attributes we're working with are, in order:
[IWPM_NLA_MANAGE_MAPPING_SEQ] [IWPM_NLA_MANAGE_ADDR] [IWPM_NLA_MANAGE_FLAGS]
β¨ and here's the slay part: if the request goes through successfully, pm_msg stores the port mapper's response (that's the mapped address info, iykyk) π
no cap β the response lands back in pm_msg itself, so keep an eye on it π
π SEE ALSO π
kernel file ./drivers/infiniband/core/iwpm_msg.c, plus the whole friend group:
iwpm_valid_pid(9)iwpm_register_pid(9)iwpm_add_and_query_mapping(9)iwpm_remove_mapping(9)iwpm_register_pid_cb(9)iwpm_add_mapping_cb(9)iwpm_add_and_query_mapping_cb(9)iwpm_remote_info_cb(9)iwpm_mapping_info_cb(9)iwpm_ack_mapping_info_cb(9)iwpm_mapping_error_cb(9)iwpm_hello_cb(9)
like, the entire _cb squad showed up for this one π§π
that's the whole page, bestie β go forth and map those addresses π
sign-off szn: this lil number lives in ./drivers/infiniband/core, dated October 2026, and it's from the Kernel API Manual β¨ mwah, talk later π
π¦ 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