STRUCT IB_USER_MAD_REG_REQ(9)
π NAME
struct ib_user_mad_reg_req β the MAD registration request, aka the little form you fill out when you want the kernel to slide unsolicited MADs your way π«Ά
(this is from the Kernel API Manual, bestie β yes we're in kernel-land now, stay with me)
β¨ SYNOPSIS
struct ib_user_mad_reg_req {
__u32 id;
packed_ulong method_mask[IB_USER_MAD_LONGS_PER_METHOD_MASK];
__u8 qpn;
__u8 mgmt_class;
__u8 mgmt_class_version;
__u8 oui[3];
__u8 rmpp_version;
};
okay so that's the actual struct, copied character for character because I would never mess with a struct definition on you π
π Members
Let's do a vibe check on every single field, one by one, no skipping π
idβ set by the kernel, not you. It's how the kernel identifies your agent in future requests. So like, the kernel picked your name and you just have to live with it πmethod_maskβ you'll receive unsolicited MADs for any method wheremethod_mask= 1. That's the whole deal, fr fr. It's an array ofIB_USER_MAD_LONGS_PER_METHOD_MASKpacked ulongs, so it's giving "bitmap behaviour" π¦qpnβ queue pair number. Must be0or1. That's it. Those are the only two options, no cap πmgmt_classβ tells the kernel which management class of MADs the caller should receive. This field is only required if you actually want to receive unsolicited MADs β otherwise it should be0. So if you're not here for the unsolicited ones, leave it at zero and move on β¨mgmt_class_versionβ indicates which version of MADs, for the given management class, you want to receive πouiβ indicates the IEEE OUI whenmgmt_classis a vendor class in the range from0x30to0x4f. Otherwise it's not used. Not used! Iconic honestly. It's 3 bytes of__u8and it's doing nothing πΈrmpp_versionβ if set, indicates the RMPP version used. That's the whole sentence, she's short but she ate π₯
π SEE ALSO
- The kernel file itself:
./include/uapi/rdma/ib_user_mad.hπ struct ib_user_mad_hdr_old(9)struct ib_user_mad_hdr(9)struct ib_user_mad(9)struct ib_user_mad_reg_req2(9)β yes there's a sequel, main character energy π
ok bestie real talk: this is kernel API territory, so the fields mean exactly what they say and nothing more. I'm not out here inventing behaviour for you π«Ά
and that's the page! shoutout to ./include/uapi/rdma for being the source, October 2026 for the date, and the whole Kernel API Manual for having us. mwah ππ§π
π¦ 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