€•Œsphinx.addnodes”Œdocument”“”)�”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)�”}”(hhh]”(hŒ pending_xref”“”)�”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…”�”}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ//translations/zh_CN/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)�”}”(hhh]”hŒChinese (Traditional)”…”�”}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/zh_TW/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒItalian”…”�”}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/it_IT/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒJapanese”…”�”}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/ja_JP/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒKorean”…”�”}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/ko_KR/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒPortuguese (Brazilian)”…”�”}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/pt_BR/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒSpanish”…”�”}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/sp_SP/userspace-api/netlink/intro”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)�”}”(hŒ%SPDX-License-Identifier: BSD-3-Clause”h]”hŒ%SPDX-License-Identifier: BSD-3-Clause”…”�”}”hh·sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1hµhhh²hh³ŒI/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro.rst”h´KubhŒsection”“”)�”}”(hhh]”(hŒtitle”“”)�”}”(hŒIntroduction to Netlink”h]”hŒIntroduction to Netlink”…”�”}”(hhÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhhÊh²hh³hÇh´KubhŒ paragraph”“”)�”}”(hŒÂNetlink is often described as an ioctl() replacement. It aims to replace fixed-format C structures as supplied to ioctl() with a format which allows an easy way to add or extended the arguments.”h]”hŒÂNetlink is often described as an ioctl() replacement. It aims to replace fixed-format C structures as supplied to ioctl() with a format which allows an easy way to add or extended the arguments.”…”�”}”(hhßh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KhhÊh²hubhÞ)�”}”(hŒŒTo achieve this Netlink uses a minimal fixed-format metadata header followed by multiple attributes in the TLV (type, length, value) format.”h]”hŒŒTo achieve this Netlink uses a minimal fixed-format metadata header followed by multiple attributes in the TLV (type, length, value) format.”…”�”}”(hhíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K hhÊh²hubhÞ)�”}”(hXUnfortunately the protocol has evolved over the years, in an organic and undocumented fashion, making it hard to coherently explain. To make the most practical sense this document starts by describing netlink as it is used today and dives into more "historical" uses in later sections.”h]”hX!Unfortunately the protocol has evolved over the years, in an organic and undocumented fashion, making it hard to coherently explain. To make the most practical sense this document starts by describing netlink as it is used today and dives into more “historicalâ€� uses in later sections.”…”�”}”(hhûh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KhhÊh²hubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒOpening a socket”h]”hŒOpening a socket”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj h²hh³hÇh´KubhÞ)�”}”(hŒNNetlink communication happens over sockets, a socket needs to be opened first:”h]”hŒNNetlink communication happens over sockets, a socket needs to be opened first:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Khj h²hubhŒ literal_block”“”)�”}”(hŒ3fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_GENERIC);”h]”hŒ3fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_GENERIC);”…”�”}”hj*sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆŒforce”‰Œlanguage”Œc”Œhighlight_args”}”uh1j(h³hÇh´Khj h²hubhÞ)�”}”(hXThe use of sockets allows for a natural way of exchanging information in both directions (to and from the kernel). The operations are still performed synchronously when applications send() the request but a separate recv() system call is needed to read the reply.”h]”hXThe use of sockets allows for a natural way of exchanging information in both directions (to and from the kernel). The operations are still performed synchronously when applications send() the request but a separate recv() system call is needed to read the reply.”…”�”}”(hj=h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Khj h²hubhÞ)�”}”(hŒNA very simplified flow of a Netlink "call" will therefore look something like:”h]”hŒRA very simplified flow of a Netlink “callâ€� will therefore look something like:”…”�”}”(hjKh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K$hj h²hubj))�”}”(hŒ¹fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_GENERIC); /* format the request */ send(fd, &request, sizeof(request)); n = recv(fd, &response, RSP_BUFFER_SIZE); /* interpret the response */”h]”hŒ¹fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_GENERIC); /* format the request */ send(fd, &request, sizeof(request)); n = recv(fd, &response, RSP_BUFFER_SIZE); /* interpret the response */”…”�”}”hjYsbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆj8‰j9j:j;}”uh1j(h³hÇh´K'hj h²hubhÞ)�”}”(hŒšNetlink also provides natural support for "dumping", i.e. communicating to user space all objects of a certain type (e.g. dumping all network interfaces).”h]”hŒžNetlink also provides natural support for “dumpingâ€�, i.e. communicating to user space all objects of a certain type (e.g. dumping all network interfaces).”…”�”}”(hjhh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K0hj h²hubj))�”}”(hX†fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_GENERIC); /* format the dump request */ send(fd, &request, sizeof(request)); while (1) { n = recv(fd, &buffer, RSP_BUFFER_SIZE); /* one recv() call can read multiple messages, hence the loop below */ for (nl_msg in buffer) { if (nl_msg.nlmsg_type == NLMSG_DONE) goto dump_finished; /* process the object */ } } dump_finished:”h]”hX†fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_GENERIC); /* format the dump request */ send(fd, &request, sizeof(request)); while (1) { n = recv(fd, &buffer, RSP_BUFFER_SIZE); /* one recv() call can read multiple messages, hence the loop below */ for (nl_msg in buffer) { if (nl_msg.nlmsg_type == NLMSG_DONE) goto dump_finished; /* process the object */ } } dump_finished:”…”�”}”hjvsbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆj8‰j9j:j;}”uh1j(h³hÇh´K4hj h²hubhÞ)�”}”(hX)The first two arguments of the socket() call require little explanation - it is opening a Netlink socket, with all headers provided by the user (hence NETLINK, RAW). The last argument is the protocol within Netlink. This field used to identify the subsystem with which the socket will communicate.”h]”hX)The first two arguments of the socket() call require little explanation - it is opening a Netlink socket, with all headers provided by the user (hence NETLINK, RAW). The last argument is the protocol within Netlink. This field used to identify the subsystem with which the socket will communicate.”…”�”}”(hj…h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KEhj h²hubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒClassic vs Generic Netlink”h]”hŒClassic vs Generic Netlink”…”�”}”(hj–h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj“h²hh³hÇh´KLubhÞ)�”}”(hX�Initial implementation of Netlink depended on a static allocation of IDs to subsystems and provided little supporting infrastructure. Let us refer to those protocols collectively as **Classic Netlink**. The list of them is defined on top of the ``include/uapi/linux/netlink.h`` file, they include among others - general networking (NETLINK_ROUTE), iSCSI (NETLINK_ISCSI), and audit (NETLINK_AUDIT).”h]”(hŒ¶Initial implementation of Netlink depended on a static allocation of IDs to subsystems and provided little supporting infrastructure. Let us refer to those protocols collectively as ”…”�”}”(hj¤h²hh³Nh´NubhŒstrong”“”)�”}”(hŒ**Classic Netlink**”h]”hŒClassic Netlink”…”�”}”(hj®h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hj¤ubhŒ,. The list of them is defined on top of the ”…”�”}”(hj¤h²hh³Nh´NubhŒliteral”“”)�”}”(hŒ ``include/uapi/linux/netlink.h``”h]”hŒinclude/uapi/linux/netlink.h”…”�”}”(hjÂh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj¤ubhŒx file, they include among others - general networking (NETLINK_ROUTE), iSCSI (NETLINK_ISCSI), and audit (NETLINK_AUDIT).”…”�”}”(hj¤h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KNhj“h²hubhÞ)�”}”(hŒÁ**Generic Netlink** (introduced in 2005) allows for dynamic registration of subsystems (and subsystem ID allocation), introspection and simplifies implementing the kernel side of the interface.”h]”(j­)�”}”(hŒ**Generic Netlink**”h]”hŒGeneric Netlink”…”�”}”(hjÞh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hjÚubhŒ® (introduced in 2005) allows for dynamic registration of subsystems (and subsystem ID allocation), introspection and simplifies implementing the kernel side of the interface.”…”�”}”(hjÚh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KUhj“h²hubhÞ)�”}”(hXÆThe following section describes how to use Generic Netlink, as the number of subsystems using Generic Netlink outnumbers the older protocols by an order of magnitude. There are also no plans for adding more Classic Netlink protocols to the kernel. Basic information on how communicating with core networking parts of the Linux kernel (or another of the 20 subsystems using Classic Netlink) differs from Generic Netlink is provided later in this document.”h]”hXÆThe following section describes how to use Generic Netlink, as the number of subsystems using Generic Netlink outnumbers the older protocols by an order of magnitude. There are also no plans for adding more Classic Netlink protocols to the kernel. Basic information on how communicating with core networking parts of the Linux kernel (or another of the 20 subsystems using Classic Netlink) differs from Generic Netlink is provided later in this document.”…”�”}”(hjöh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KYhj“h²hubeh}”(h]”Œclassic-vs-generic-netlink”ah ]”h"]”Œclassic vs generic netlink”ah$]”h&]”uh1hÈhj h²hh³hÇh´KLubeh}”(h]”Œopening-a-socket”ah ]”h"]”Œopening a socket”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´KubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒGeneric Netlink”h]”hŒGeneric Netlink”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjh²hh³hÇh´KbubhÞ)�”}”(hŒÓIn addition to the Netlink fixed metadata header each Netlink protocol defines its own fixed metadata header. (Similarly to how network headers stack - Ethernet > IP > TCP we have Netlink > Generic N. > Family.)”h]”hŒÓIn addition to the Netlink fixed metadata header each Netlink protocol defines its own fixed metadata header. (Similarly to how network headers stack - Ethernet > IP > TCP we have Netlink > Generic N. > Family.)”…”�”}”(hj%h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kdhjh²hubhÞ)�”}”(hŒ«A Netlink message always starts with struct nlmsghdr, which is followed by a protocol-specific header. In case of Generic Netlink the protocol header is struct genlmsghdr.”h]”hŒ«A Netlink message always starts with struct nlmsghdr, which is followed by a protocol-specific header. In case of Generic Netlink the protocol header is struct genlmsghdr.”…”�”}”(hj3h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Khhjh²hubhÞ)�”}”(hŒMThe practical meaning of the fields in case of Generic Netlink is as follows:”h]”hŒMThe practical meaning of the fields in case of Generic Netlink is as follows:”…”�”}”(hjAh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Klhjh²hubj))�”}”(hX8struct nlmsghdr { __u32 nlmsg_len; /* Length of message including headers */ __u16 nlmsg_type; /* Generic Netlink Family (subsystem) ID */ __u16 nlmsg_flags; /* Flags - request or dump */ __u32 nlmsg_seq; /* Sequence number */ __u32 nlmsg_pid; /* Port ID, set to 0 */ }; struct genlmsghdr { __u8 cmd; /* Command, as defined by the Family */ __u8 version; /* Irrelevant, set to 1 */ __u16 reserved; /* Reserved, set to 0 */ }; /* TLV attributes follow... */”h]”hX8struct nlmsghdr { __u32 nlmsg_len; /* Length of message including headers */ __u16 nlmsg_type; /* Generic Netlink Family (subsystem) ID */ __u16 nlmsg_flags; /* Flags - request or dump */ __u32 nlmsg_seq; /* Sequence number */ __u32 nlmsg_pid; /* Port ID, set to 0 */ }; struct genlmsghdr { __u8 cmd; /* Command, as defined by the Family */ __u8 version; /* Irrelevant, set to 1 */ __u16 reserved; /* Reserved, set to 0 */ }; /* TLV attributes follow... */”…”�”}”hjOsbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆj8‰j9j:j;}”uh1j(h³hÇh´Knhjh²hubhÞ)�”}”(hXqIn Classic Netlink :c:member:`nlmsghdr.nlmsg_type` used to identify which operation within the subsystem the message was referring to (e.g. get information about a netdev). Generic Netlink needs to mux multiple subsystems in a single protocol so it uses this field to identify the subsystem, and :c:member:`genlmsghdr.cmd` identifies the operation instead. (See :ref:`res_fam` for information on how to find the Family ID of the subsystem of interest.) Note that the first 16 values (0 - 15) of this field are reserved for control messages both in Classic Netlink and Generic Netlink. See :ref:`nl_msg_type` for more details.”h]”(hŒIn Classic Netlink ”…”�”}”(hj^h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_type`”h]”jÁ)�”}”(hjhh]”hŒnlmsghdr.nlmsg_type”…”�”}”(hjjh²hh³Nh´Nubah}”(h]”h ]”(Œxref”j:Œc-member”eh"]”h$]”h&]”uh1jÀhjfubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”Œuserspace-api/netlink/intro”Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰Œ reftarget”Œnlmsghdr.nlmsg_type”uh1hh³hÇh´K~hj^ubhŒö used to identify which operation within the subsystem the message was referring to (e.g. get information about a netdev). Generic Netlink needs to mux multiple subsystems in a single protocol so it uses this field to identify the subsystem, and ”…”�”}”(hj^h²hh³Nh´Nubh)�”}”(hŒ:c:member:`genlmsghdr.cmd`”h]”jÁ)�”}”(hjŽh]”hŒgenlmsghdr.cmd”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhjŒubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œgenlmsghdr.cmd”uh1hh³hÇh´K~hj^ubhŒ( identifies the operation instead. (See ”…”�”}”(hj^h²hh³Nh´Nubh)�”}”(hŒ:ref:`res_fam`”h]”hŒinline”“”)�”}”(hj±h]”hŒres_fam”…”�”}”(hjµh²hh³Nh´Nubah}”(h]”h ]”(jtŒstd”Œstd-ref”eh"]”h$]”h&]”uh1j³hj¯ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j¿Œreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆj†Œres_fam”uh1hh³hÇh´K~hj^ubhŒÕ for information on how to find the Family ID of the subsystem of interest.) Note that the first 16 values (0 - 15) of this field are reserved for control messages both in Classic Netlink and Generic Netlink. See ”…”�”}”(hj^h²hh³Nh´Nubh)�”}”(hŒ:ref:`nl_msg_type`”h]”j´)�”}”(hj×h]”hŒ nl_msg_type”…”�”}”(hjÙh²hh³Nh´Nubah}”(h]”h ]”(jtŒstd”Œstd-ref”eh"]”h$]”h&]”uh1j³hjÕubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”jãŒreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆj†Œ nl_msg_type”uh1hh³hÇh´K~hj^ubhŒ for more details.”…”�”}”(hj^h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K~hjh²hubhÞ)�”}”(hŒAThere are 3 usual types of message exchanges on a Netlink socket:”h]”hŒAThere are 3 usual types of message exchanges on a Netlink socket:”…”�”}”(hjÿh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K‰hjh²hubhŒ block_quote”“”)�”}”(hŒ- performing a single action (``do``); - dumping information (``dump``); - getting asynchronous notifications (``multicast``). ”h]”hŒ bullet_list”“”)�”}”(hhh]”(hŒ list_item”“”)�”}”(hŒ$performing a single action (``do``);”h]”hÞ)�”}”(hjh]”(hŒperforming a single action (”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``do``”h]”hŒdo”…”�”}”(hj%h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ);”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K‹hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubj)�”}”(hŒdumping information (``dump``);”h]”hÞ)�”}”(hjEh]”(hŒdumping information (”…”�”}”(hjGh²hh³Nh´NubjÁ)�”}”(hŒ``dump``”h]”hŒdump”…”�”}”(hjNh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjGubhŒ);”…”�”}”(hjGh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KŒhjCubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubj)�”}”(hŒ4getting asynchronous notifications (``multicast``). ”h]”hÞ)�”}”(hŒ3getting asynchronous notifications (``multicast``).”h]”(hŒ$getting asynchronous notifications (”…”�”}”(hjph²hh³Nh´NubjÁ)�”}”(hŒ ``multicast``”h]”hŒ multicast”…”�”}”(hjxh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjpubhŒ).”…”�”}”(hjph²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K�hjlubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubeh}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ-”uh1jh³hÇh´K‹hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j h³hÇh´K‹hjh²hubhÞ)�”}”(hŒ�Classic Netlink is very flexible and presumably allows other types of exchanges to happen, but in practice those are the three that get used.”h]”hŒ�Classic Netlink is very flexible and presumably allows other types of exchanges to happen, but in practice those are the three that get used.”…”�”}”(hj¤h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K�hjh²hubhÞ)�”}”(hŒßAsynchronous notifications are sent by the kernel and received by the user sockets which subscribed to them. ``do`` and ``dump`` requests are initiated by the user. :c:member:`nlmsghdr.nlmsg_flags` should be set as follows:”h]”(hŒmAsynchronous notifications are sent by the kernel and received by the user sockets which subscribed to them. ”…”�”}”(hj²h²hh³Nh´NubjÁ)�”}”(hŒ``do``”h]”hŒdo”…”�”}”(hjºh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj²ubhŒ and ”…”�”}”(hj²h²hh³Nh´NubjÁ)�”}”(hŒ``dump``”h]”hŒdump”…”�”}”(hjÌh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj²ubhŒ% requests are initiated by the user. ”…”�”}”(hj²h²hh³Nh´Nubh)�”}”(hŒ :c:member:`nlmsghdr.nlmsg_flags`”h]”jÁ)�”}”(hjàh]”hŒnlmsghdr.nlmsg_flags”…”�”}”(hjâh²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhjÞubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_flags”uh1hh³hÇh´K“hj²ubhŒ should be set as follows:”…”�”}”(hj²h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K“hjh²hubj)�”}”(hŒg- for ``do``: ``NLM_F_REQUEST | NLM_F_ACK`` - for ``dump``: ``NLM_F_REQUEST | NLM_F_ACK | NLM_F_DUMP`` ”h]”j)�”}”(hhh]”(j)�”}”(hŒ)for ``do``: ``NLM_F_REQUEST | NLM_F_ACK``”h]”hÞ)�”}”(hjh]”(hŒfor ”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``do``”h]”hŒdo”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ: ”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_REQUEST | NLM_F_ACK``”h]”hŒNLM_F_REQUEST | NLM_F_ACK”…”�”}”(hj+h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K˜hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj ubj)�”}”(hŒ9for ``dump``: ``NLM_F_REQUEST | NLM_F_ACK | NLM_F_DUMP`` ”h]”hÞ)�”}”(hŒ8for ``dump``: ``NLM_F_REQUEST | NLM_F_ACK | NLM_F_DUMP``”h]”(hŒfor ”…”�”}”(hjIh²hh³Nh´NubjÁ)�”}”(hŒ``dump``”h]”hŒdump”…”�”}”(hjQh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjIubhŒ: ”…”�”}”(hjIh²hh³Nh´NubjÁ)�”}”(hŒ*``NLM_F_REQUEST | NLM_F_ACK | NLM_F_DUMP``”h]”hŒ&NLM_F_REQUEST | NLM_F_ACK | NLM_F_DUMP”…”�”}”(hjch²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjIubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K™hjEubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj ubeh}”(h]”h ]”h"]”h$]”h&]”jœj�uh1jh³hÇh´K˜hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j h³hÇh´K˜hjh²hubhÞ)�”}”(hX}:c:member:`nlmsghdr.nlmsg_seq` should be a set to a monotonically increasing value. The value gets echoed back in responses and doesn't matter in practice, but setting it to an increasing value for each message sent is considered good hygiene. The purpose of the field is matching responses to requests. Asynchronous notifications will have :c:member:`nlmsghdr.nlmsg_seq` of ``0``.”h]”(h)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_seq`”h]”jÁ)�”}”(hj�h]”hŒnlmsghdr.nlmsg_seq”…”�”}”(hj‘h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj�ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_seq”uh1hh³hÇh´K›hj‰ubhX9 should be a set to a monotonically increasing value. The value gets echoed back in responses and doesn’t matter in practice, but setting it to an increasing value for each message sent is considered good hygiene. The purpose of the field is matching responses to requests. Asynchronous notifications will have ”…”�”}”(hj‰h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_seq`”h]”jÁ)�”}”(hj²h]”hŒnlmsghdr.nlmsg_seq”…”�”}”(hj´h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj°ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_seq”uh1hh³hÇh´K›hj‰ubhŒ of ”…”�”}”(hj‰h²hh³Nh´NubjÁ)�”}”(hŒ``0``”h]”hŒ0”…”�”}”(hjÓh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj‰ubhŒ.”…”�”}”(hj‰h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K›hjh²hubhÞ)�”}”(hŒ½:c:member:`nlmsghdr.nlmsg_pid` is the Netlink equivalent of an address. This field can be set to ``0`` when talking to the kernel. See :ref:`nlmsg_pid` for the (uncommon) uses of the field.”h]”(h)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_pid`”h]”jÁ)�”}”(hjñh]”hŒnlmsghdr.nlmsg_pid”…”�”}”(hjóh²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhjïubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_pid”uh1hh³hÇh´K¢hjëubhŒC is the Netlink equivalent of an address. This field can be set to ”…”�”}”(hjëh²hh³Nh´NubjÁ)�”}”(hŒ``0``”h]”hŒ0”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjëubhŒ! when talking to the kernel. See ”…”�”}”(hjëh²hh³Nh´Nubh)�”}”(hŒ:ref:`nlmsg_pid`”h]”j´)�”}”(hj&h]”hŒ nlmsg_pid”…”�”}”(hj(h²hh³Nh´Nubah}”(h]”h ]”(jtŒstd”Œstd-ref”eh"]”h$]”h&]”uh1j³hj$ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j2Œreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆj†Œ nlmsg_pid”uh1hh³hÇh´K¢hjëubhŒ& for the (uncommon) uses of the field.”…”�”}”(hjëh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K¢hjh²hubhÞ)�”}”(hŒÚThe expected use for :c:member:`genlmsghdr.version` was to allow versioning of the APIs provided by the subsystems. No subsystem to date made significant use of this field, so setting it to ``1`` seems like a safe bet.”h]”(hŒThe expected use for ”…”�”}”(hjNh²hh³Nh´Nubh)�”}”(hŒ:c:member:`genlmsghdr.version`”h]”jÁ)�”}”(hjXh]”hŒgenlmsghdr.version”…”�”}”(hjZh²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhjVubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œgenlmsghdr.version”uh1hh³hÇh´K¦hjNubhŒ‹ was to allow versioning of the APIs provided by the subsystems. No subsystem to date made significant use of this field, so setting it to ”…”�”}”(hjNh²hh³Nh´NubjÁ)�”}”(hŒ``1``”h]”hŒ1”…”�”}”(hjyh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjNubhŒ seems like a safe bet.”…”�”}”(hjNh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K¦hjh²hubhŒtarget”“”)�”}”(hŒ.. _nl_msg_type:”h]”h}”(h]”h ]”h"]”h$]”h&]”Œrefid”Œ nl-msg-type”uh1j‘h´K«hjh²hh³hÇubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒNetlink message types”h]”hŒNetlink message types”…”�”}”(hj¢h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjŸh²hh³hÇh´K®ubhÞ)�”}”(hŒãAs previously mentioned :c:member:`nlmsghdr.nlmsg_type` carries protocol specific values but the first 16 identifiers are reserved (first subsystem specific message type should be equal to ``NLMSG_MIN_TYPE`` which is ``0x10``).”h]”(hŒAs previously mentioned ”…”�”}”(hj°h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_type`”h]”jÁ)�”}”(hjºh]”hŒnlmsghdr.nlmsg_type”…”�”}”(hj¼h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj¸ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_type”uh1hh³hÇh´K°hj°ubhŒ† carries protocol specific values but the first 16 identifiers are reserved (first subsystem specific message type should be equal to ”…”�”}”(hj°h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_MIN_TYPE``”h]”hŒNLMSG_MIN_TYPE”…”�”}”(hjÛh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj°ubhŒ which is ”…”�”}”(hj°h²hh³Nh´NubjÁ)�”}”(hŒ``0x10``”h]”hŒ0x10”…”�”}”(hjíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj°ubhŒ).”…”�”}”(hj°h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K°hjŸh²hubhÞ)�”}”(hŒ2There are only 4 Netlink control messages defined:”h]”hŒ2There are only 4 Netlink control messages defined:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KµhjŸh²hubj)�”}”(hŒë- ``NLMSG_NOOP`` - ignore the message, not used in practice; - ``NLMSG_ERROR`` - carries the return code of an operation; - ``NLMSG_DONE`` - marks the end of a dump; - ``NLMSG_OVERRUN`` - socket buffer has overflown, not used to date. ”h]”j)�”}”(hhh]”(j)�”}”(hŒ:``NLMSG_NOOP`` - ignore the message, not used in practice;”h]”hÞ)�”}”(hjh]”(jÁ)�”}”(hŒ``NLMSG_NOOP``”h]”hŒ NLMSG_NOOP”…”�”}”(hj!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ, - ignore the message, not used in practice;”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K·hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubj)�”}”(hŒ:``NLMSG_ERROR`` - carries the return code of an operation;”h]”hÞ)�”}”(hjAh]”(jÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hjFh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjCubhŒ+ - carries the return code of an operation;”…”�”}”(hjCh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K¸hj?ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubj)�”}”(hŒ)``NLMSG_DONE`` - marks the end of a dump;”h]”hÞ)�”}”(hjfh]”(jÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hjkh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjhubhŒ - marks the end of a dump;”…”�”}”(hjhh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K¹hjdubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubj)�”}”(hŒC``NLMSG_OVERRUN`` - socket buffer has overflown, not used to date. ”h]”hÞ)�”}”(hŒB``NLMSG_OVERRUN`` - socket buffer has overflown, not used to date.”h]”(jÁ)�”}”(hŒ``NLMSG_OVERRUN``”h]”hŒ NLMSG_OVERRUN”…”�”}”(hj‘h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj�ubhŒ1 - socket buffer has overflown, not used to date.”…”�”}”(hj�h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kºhj‰ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubeh}”(h]”h ]”h"]”h$]”h&]”jœj�uh1jh³hÇh´K·hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j h³hÇh´K·hjŸh²hubhÞ)�”}”(hXC``NLMSG_ERROR`` and ``NLMSG_DONE`` are of practical importance. They carry return codes for operations. Note that unless the ``NLM_F_ACK`` flag is set on the request Netlink will not respond with ``NLMSG_ERROR`` if there is no error. To avoid having to special-case this quirk it is recommended to always set ``NLM_F_ACK``.”h]”(jÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hj¿h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj»ubhŒ and ”…”�”}”(hj»h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hjÑh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj»ubhŒ[ are of practical importance. They carry return codes for operations. Note that unless the ”…”�”}”(hj»h²hh³Nh´NubjÁ)�”}”(hŒ ``NLM_F_ACK``”h]”hŒ NLM_F_ACK”…”�”}”(hjãh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj»ubhŒ: flag is set on the request Netlink will not respond with ”…”�”}”(hj»h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hjõh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj»ubhŒb if there is no error. To avoid having to special-case this quirk it is recommended to always set ”…”�”}”(hj»h²hh³Nh´NubjÁ)�”}”(hŒ ``NLM_F_ACK``”h]”hŒ NLM_F_ACK”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj»ubhŒ.”…”�”}”(hj»h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K¼hjŸh²hubhÞ)�”}”(hŒ?The format of ``NLMSG_ERROR`` is described by struct nlmsgerr::”h]”(hŒThe format of ”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hj'h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ! is described by struct nlmsgerr:”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KÂhjŸh²hubj))�”}”(hX---------------------------------------------- | struct nlmsghdr - response header | ---------------------------------------------- | int error | ---------------------------------------------- | struct nlmsghdr - original request header | ---------------------------------------------- | ** optionally (1) payload of the request | ---------------------------------------------- | ** optionally (2) extended ACK | ----------------------------------------------”h]”hX---------------------------------------------- | struct nlmsghdr - response header | ---------------------------------------------- | int error | ---------------------------------------------- | struct nlmsghdr - original request header | ---------------------------------------------- | ** optionally (1) payload of the request | ---------------------------------------------- | ** optionally (2) extended ACK | ----------------------------------------------”…”�”}”hj?sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´KÄhjŸh²hubhÞ)�”}”(hX!There are two instances of struct nlmsghdr here, first of the response and second of the request. ``NLMSG_ERROR`` carries the information about the request which led to the error. This could be useful when trying to match requests to responses or re-parse the request to dump it into logs.”h]”(hŒbThere are two instances of struct nlmsghdr here, first of the response and second of the request. ”…”�”}”(hjMh²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hjUh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjMubhŒ° carries the information about the request which led to the error. This could be useful when trying to match requests to responses or re-parse the request to dump it into logs.”…”�”}”(hjMh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KÐhjŸh²hubhÞ)�”}”(hXlThe payload of the request is not echoed in messages reporting success (``error == 0``) or if ``NETLINK_CAP_ACK`` setsockopt() was set. The latter is common and perhaps recommended as having to read a copy of every request back from the kernel is rather wasteful. The absence of request payload is indicated by ``NLM_F_CAPPED`` in :c:member:`nlmsghdr.nlmsg_flags`.”h]”(hŒHThe payload of the request is not echoed in messages reporting success (”…”�”}”(hjmh²hh³Nh´NubjÁ)�”}”(hŒ``error == 0``”h]”hŒ error == 0”…”�”}”(hjuh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjmubhŒ) or if ”…”�”}”(hjmh²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_CAP_ACK``”h]”hŒNETLINK_CAP_ACK”…”�”}”(hj‡h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjmubhŒÆ setsockopt() was set. The latter is common and perhaps recommended as having to read a copy of every request back from the kernel is rather wasteful. The absence of request payload is indicated by ”…”�”}”(hjmh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_CAPPED``”h]”hŒ NLM_F_CAPPED”…”�”}”(hj™h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjmubhŒ in ”…”�”}”(hjmh²hh³Nh´Nubh)�”}”(hŒ :c:member:`nlmsghdr.nlmsg_flags`”h]”jÁ)�”}”(hj­h]”hŒnlmsghdr.nlmsg_flags”…”�”}”(hj¯h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj«ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_flags”uh1hh³hÇh´KÖhjmubhŒ.”…”�”}”(hjmh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KÖhjŸh²hubhÞ)�”}”(hŒÙThe second optional element of ``NLMSG_ERROR`` are the extended ACK attributes. See :ref:`ext_ack` for more details. The presence of extended ACK is indicated by ``NLM_F_ACK_TLVS`` in :c:member:`nlmsghdr.nlmsg_flags`.”h]”(hŒThe second optional element of ”…”�”}”(hjÔh²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hjÜh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÔubhŒ& are the extended ACK attributes. See ”…”�”}”(hjÔh²hh³Nh´Nubh)�”}”(hŒ:ref:`ext_ack`”h]”j´)�”}”(hjðh]”hŒext_ack”…”�”}”(hjòh²hh³Nh´Nubah}”(h]”h ]”(jtŒstd”Œstd-ref”eh"]”h$]”h&]”uh1j³hjîubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”jüŒreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆj†Œext_ack”uh1hh³hÇh´KÝhjÔubhŒ@ for more details. The presence of extended ACK is indicated by ”…”�”}”(hjÔh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_ACK_TLVS``”h]”hŒNLM_F_ACK_TLVS”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÔubhŒ in ”…”�”}”(hjÔh²hh³Nh´Nubh)�”}”(hŒ :c:member:`nlmsghdr.nlmsg_flags`”h]”jÁ)�”}”(hj&h]”hŒnlmsghdr.nlmsg_flags”…”�”}”(hj(h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj$ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_flags”uh1hh³hÇh´KÝhjÔubhŒ.”…”�”}”(hjÔh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KÝhjŸh²hubhÞ)�”}”(hŒg``NLMSG_DONE`` is simpler, the request is never echoed but the extended ACK attributes may be present::”h]”(jÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hjQh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjMubhŒX is simpler, the request is never echoed but the extended ACK attributes may be present:”…”�”}”(hjMh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KâhjŸh²hubj))�”}”(hXH---------------------------------------------- | struct nlmsghdr - response header | ---------------------------------------------- | int error | ---------------------------------------------- | ** optionally extended ACK | ----------------------------------------------”h]”hXH---------------------------------------------- | struct nlmsghdr - response header | ---------------------------------------------- | int error | ---------------------------------------------- | ** optionally extended ACK | ----------------------------------------------”…”�”}”hjisbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´KåhjŸh²hubhÞ)�”}”(hŒ·Note that some implementations may issue custom ``NLMSG_DONE`` messages in reply to ``do`` action requests. In that case the payload is implementation-specific and may also be absent.”h]”(hŒ0Note that some implementations may issue custom ”…”�”}”(hjwh²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjwubhŒ messages in reply to ”…”�”}”(hjwh²hh³Nh´NubjÁ)�”}”(hŒ``do``”h]”hŒdo”…”�”}”(hj‘h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjwubhŒ] action requests. In that case the payload is implementation-specific and may also be absent.”…”�”}”(hjwh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KíhjŸh²hubj’)�”}”(hŒ .. _res_fam:”h]”h}”(h]”h ]”h"]”h$]”h&]”j�Œres-fam”uh1j‘h´KñhjŸh²hh³hÇubeh}”(h]”(Œnetlink-message-types”jžeh ]”h"]”(Œnetlink message types”Œ nl_msg_type”eh$]”h&]”uh1hÈhjh²hh³hÇh´K®Œexpect_referenced_by_name”}”jºj“sŒexpect_referenced_by_id”}”jžj“subhÉ)�”}”(hhh]”(hÎ)�”}”(hŒResolving the Family ID”h]”hŒResolving the Family ID”…”�”}”(hjÄh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjÁh²hh³hÇh´KôubhÞ)�”}”(hŒ~This section explains how to find the Family ID of a subsystem. It also serves as an example of Generic Netlink communication.”h]”hŒ~This section explains how to find the Family ID of a subsystem. It also serves as an example of Generic Netlink communication.”…”�”}”(hjÒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KöhjÁh²hubhÞ)�”}”(hXSGeneric Netlink is itself a subsystem exposed via the Generic Netlink API. To avoid a circular dependency Generic Netlink has a statically allocated Family ID (``GENL_ID_CTRL`` which is equal to ``NLMSG_MIN_TYPE``). The Generic Netlink family implements a command used to find out information about other families (``CTRL_CMD_GETFAMILY``).”h]”(hŒ Generic Netlink is itself a subsystem exposed via the Generic Netlink API. To avoid a circular dependency Generic Netlink has a statically allocated Family ID (”…”�”}”(hjàh²hh³Nh´NubjÁ)�”}”(hŒ``GENL_ID_CTRL``”h]”hŒ GENL_ID_CTRL”…”�”}”(hjèh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjàubhŒ which is equal to ”…”�”}”(hjàh²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_MIN_TYPE``”h]”hŒNLMSG_MIN_TYPE”…”�”}”(hjúh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjàubhŒf). The Generic Netlink family implements a command used to find out information about other families (”…”�”}”(hjàh²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_CMD_GETFAMILY``”h]”hŒCTRL_CMD_GETFAMILY”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjàubhŒ).”…”�”}”(hjàh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KùhjÁh²hubhÞ)�”}”(hXüTo get information about the Generic Netlink family named for example ``"test1"`` we need to send a message on the previously opened Generic Netlink socket. The message should target the Generic Netlink Family (1), be a ``do`` (2) call to ``CTRL_CMD_GETFAMILY`` (3). A ``dump`` version of this call would make the kernel respond with information about *all* the families it knows about. Last but not least the name of the family in question has to be specified (4) as an attribute with the appropriate type::”h]”(hŒFTo get information about the Generic Netlink family named for example ”…”�”}”(hj$ h²hh³Nh´NubjÁ)�”}”(hŒ ``"test1"``”h]”hŒ"test1"”…”�”}”(hj, h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj$ ubhŒ‹ we need to send a message on the previously opened Generic Netlink socket. The message should target the Generic Netlink Family (1), be a ”…”�”}”(hj$ h²hh³Nh´NubjÁ)�”}”(hŒ``do``”h]”hŒdo”…”�”}”(hj> h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj$ ubhŒ (2) call to ”…”�”}”(hj$ h²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_CMD_GETFAMILY``”h]”hŒCTRL_CMD_GETFAMILY”…”�”}”(hjP h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj$ ubhŒ (3). A ”…”�”}”(hj$ h²hh³Nh´NubjÁ)�”}”(hŒ``dump``”h]”hŒdump”…”�”}”(hjb h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj$ ubhŒK version of this call would make the kernel respond with information about ”…”�”}”(hj$ h²hh³Nh´NubhŒemphasis”“”)�”}”(hŒ*all*”h]”hŒall”…”�”}”(hjv h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jt hj$ ubhŒ– the families it knows about. Last but not least the name of the family in question has to be specified (4) as an attribute with the appropriate type:”…”�”}”(hj$ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KÿhjÁh²hubj))�”}”(hX#struct nlmsghdr: __u32 nlmsg_len: 32 __u16 nlmsg_type: GENL_ID_CTRL // (1) __u16 nlmsg_flags: NLM_F_REQUEST | NLM_F_ACK // (2) __u32 nlmsg_seq: 1 __u32 nlmsg_pid: 0 struct genlmsghdr: __u8 cmd: CTRL_CMD_GETFAMILY // (3) __u8 version: 2 /* or 1, doesn't matter */ __u16 reserved: 0 struct nlattr: // (4) __u16 nla_len: 10 __u16 nla_type: CTRL_ATTR_FAMILY_NAME char data: test1\0 (padding:) char data: \0\0”h]”hX#struct nlmsghdr: __u32 nlmsg_len: 32 __u16 nlmsg_type: GENL_ID_CTRL // (1) __u16 nlmsg_flags: NLM_F_REQUEST | NLM_F_ACK // (2) __u32 nlmsg_seq: 1 __u32 nlmsg_pid: 0 struct genlmsghdr: __u8 cmd: CTRL_CMD_GETFAMILY // (3) __u8 version: 2 /* or 1, doesn't matter */ __u16 reserved: 0 struct nlattr: // (4) __u16 nla_len: 10 __u16 nla_type: CTRL_ATTR_FAMILY_NAME char data: test1\0 (padding:) char data: \0\0”…”�”}”hjŽ sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´MhjÁh²hubhÞ)�”}”(hX7The length fields in Netlink (:c:member:`nlmsghdr.nlmsg_len` and :c:member:`nlattr.nla_len`) always *include* the header. Attribute headers in netlink must be aligned to 4 bytes from the start of the message, hence the extra ``\0\0`` after ``CTRL_ATTR_FAMILY_NAME``. The attribute lengths *exclude* the padding.”h]”(hŒThe length fields in Netlink (”…”�”}”(hjœ h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_len`”h]”jÁ)�”}”(hj¦ h]”hŒnlmsghdr.nlmsg_len”…”�”}”(hj¨ h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj¤ ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_len”uh1hh³hÇh´Mhjœ ubhŒ and ”…”�”}”(hjœ h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlattr.nla_len`”h]”jÁ)�”}”(hjÉ h]”hŒnlattr.nla_len”…”�”}”(hjË h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhjÇ ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlattr.nla_len”uh1hh³hÇh´Mhjœ ubhŒ ) always ”…”�”}”(hjœ h²hh³Nh´Nubju )�”}”(hŒ *include*”h]”hŒinclude”…”�”}”(hjê h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jt hjœ ubhŒt the header. Attribute headers in netlink must be aligned to 4 bytes from the start of the message, hence the extra ”…”�”}”(hjœ h²hh³Nh´NubjÁ)�”}”(hŒ``\0\0``”h]”hŒ\0\0”…”�”}”(hjü h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjœ ubhŒ after ”…”�”}”(hjœ h²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_ATTR_FAMILY_NAME``”h]”hŒCTRL_ATTR_FAMILY_NAME”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjœ ubhŒ. The attribute lengths ”…”�”}”(hjœ h²hh³Nh´Nubju )�”}”(hŒ *exclude*”h]”hŒexclude”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jt hjœ ubhŒ the padding.”…”�”}”(hjœ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MhjÁh²hubhÞ)�”}”(hŒtIf the family is found kernel will reply with two messages, the response with all the information about the family::”h]”hŒsIf the family is found kernel will reply with two messages, the response with all the information about the family:”…”�”}”(hj8 h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M!hjÁh²hubj))�”}”(hXR/* Message #1 - reply */ struct nlmsghdr: __u32 nlmsg_len: 136 __u16 nlmsg_type: GENL_ID_CTRL __u16 nlmsg_flags: 0 __u32 nlmsg_seq: 1 /* echoed from our request */ __u32 nlmsg_pid: 5831 /* The PID of our user space process */ struct genlmsghdr: __u8 cmd: CTRL_CMD_GETFAMILY __u8 version: 2 __u16 reserved: 0 struct nlattr: __u16 nla_len: 10 __u16 nla_type: CTRL_ATTR_FAMILY_NAME char data: test1\0 (padding:) data: \0\0 struct nlattr: __u16 nla_len: 6 __u16 nla_type: CTRL_ATTR_FAMILY_ID __u16: 123 /* The Family ID we are after */ (padding:) char data: \0\0 struct nlattr: __u16 nla_len: 9 __u16 nla_type: CTRL_ATTR_FAMILY_VERSION __u16: 1 /* ... etc, more attributes will follow. */”h]”hXR/* Message #1 - reply */ struct nlmsghdr: __u32 nlmsg_len: 136 __u16 nlmsg_type: GENL_ID_CTRL __u16 nlmsg_flags: 0 __u32 nlmsg_seq: 1 /* echoed from our request */ __u32 nlmsg_pid: 5831 /* The PID of our user space process */ struct genlmsghdr: __u8 cmd: CTRL_CMD_GETFAMILY __u8 version: 2 __u16 reserved: 0 struct nlattr: __u16 nla_len: 10 __u16 nla_type: CTRL_ATTR_FAMILY_NAME char data: test1\0 (padding:) data: \0\0 struct nlattr: __u16 nla_len: 6 __u16 nla_type: CTRL_ATTR_FAMILY_ID __u16: 123 /* The Family ID we are after */ (padding:) char data: \0\0 struct nlattr: __u16 nla_len: 9 __u16 nla_type: CTRL_ATTR_FAMILY_VERSION __u16: 1 /* ... etc, more attributes will follow. */”…”�”}”hjF sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´M$hjÁh²hubhÞ)�”}”(hŒNAnd the error code (success) since ``NLM_F_ACK`` had been set on the request::”h]”(hŒ#And the error code (success) since ”…”�”}”(hjT h²hh³Nh´NubjÁ)�”}”(hŒ ``NLM_F_ACK``”h]”hŒ NLM_F_ACK”…”�”}”(hj\ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjT ubhŒ had been set on the request:”…”�”}”(hjT h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MHhjÁh²hubj))�”}”(hX/* Message #2 - the ACK */ struct nlmsghdr: __u32 nlmsg_len: 36 __u16 nlmsg_type: NLMSG_ERROR __u16 nlmsg_flags: NLM_F_CAPPED /* There won't be a payload */ __u32 nlmsg_seq: 1 /* echoed from our request */ __u32 nlmsg_pid: 5831 /* The PID of our user space process */ int error: 0 struct nlmsghdr: /* Copy of the request header as we sent it */ __u32 nlmsg_len: 32 __u16 nlmsg_type: GENL_ID_CTRL __u16 nlmsg_flags: NLM_F_REQUEST | NLM_F_ACK __u32 nlmsg_seq: 1 __u32 nlmsg_pid: 0”h]”hX/* Message #2 - the ACK */ struct nlmsghdr: __u32 nlmsg_len: 36 __u16 nlmsg_type: NLMSG_ERROR __u16 nlmsg_flags: NLM_F_CAPPED /* There won't be a payload */ __u32 nlmsg_seq: 1 /* echoed from our request */ __u32 nlmsg_pid: 5831 /* The PID of our user space process */ int error: 0 struct nlmsghdr: /* Copy of the request header as we sent it */ __u32 nlmsg_len: 32 __u16 nlmsg_type: GENL_ID_CTRL __u16 nlmsg_flags: NLM_F_REQUEST | NLM_F_ACK __u32 nlmsg_seq: 1 __u32 nlmsg_pid: 0”…”�”}”hjt sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´MJhjÁh²hubhÞ)�”}”(hŒpThe order of attributes (struct nlattr) is not guaranteed so the user has to walk the attributes and parse them.”h]”hŒpThe order of attributes (struct nlattr) is not guaranteed so the user has to walk the attributes and parse them.”…”�”}”(hj‚ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M[hjÁh²hubhÞ)�”}”(hXNote that Generic Netlink sockets are not associated or bound to a single family. A socket can be used to exchange messages with many different families, selecting the recipient family on message-by-message basis using the :c:member:`nlmsghdr.nlmsg_type` field.”h]”(hŒßNote that Generic Netlink sockets are not associated or bound to a single family. A socket can be used to exchange messages with many different families, selecting the recipient family on message-by-message basis using the ”…”�”}”(hj� h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_type`”h]”jÁ)�”}”(hjš h]”hŒnlmsghdr.nlmsg_type”…”�”}”(hjœ h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj˜ ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_type”uh1hh³hÇh´M^hj� ubhŒ field.”…”�”}”(hj� h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M^hjÁh²hubj’)�”}”(hŒ .. _ext_ack:”h]”h}”(h]”h ]”h"]”h$]”h&]”j�Œext-ack”uh1j‘h´MchjÁh²hh³hÇubeh}”(h]”(Œresolving-the-family-id”j³eh ]”h"]”(Œresolving the family id”Œres_fam”eh$]”h&]”uh1hÈhjh²hh³hÇh´Kôj½}”jÒ j©sj¿}”j³j©subhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ Extended ACK”h]”hŒ Extended ACK”…”�”}”(hjÚ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj× h²hh³hÇh´MfubhÞ)�”}”(hŒ÷Extended ACK controls reporting of additional error/warning TLVs in ``NLMSG_ERROR`` and ``NLMSG_DONE`` messages. To maintain backward compatibility this feature has to be explicitly enabled by setting the ``NETLINK_EXT_ACK`` setsockopt() to ``1``.”h]”(hŒDExtended ACK controls reporting of additional error/warning TLVs in ”…”�”}”(hjè h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hjð h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjè ubhŒ and ”…”�”}”(hjè h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjè ubhŒg messages. To maintain backward compatibility this feature has to be explicitly enabled by setting the ”…”�”}”(hjè h²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_EXT_ACK``”h]”hŒNETLINK_EXT_ACK”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjè ubhŒ setsockopt() to ”…”�”}”(hjè h²hh³Nh´NubjÁ)�”}”(hŒ``1``”h]”hŒ1”…”�”}”(hj& h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjè ubhŒ.”…”�”}”(hjè h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mhhj× h²hubhÞ)�”}”(hŒ¶Types of extended ack attributes are defined in enum nlmsgerr_attrs. The most commonly used attributes are ``NLMSGERR_ATTR_MSG``, ``NLMSGERR_ATTR_OFFS`` and ``NLMSGERR_ATTR_MISS_*``.”h]”(hŒkTypes of extended ack attributes are defined in enum nlmsgerr_attrs. The most commonly used attributes are ”…”�”}”(hj> h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSGERR_ATTR_MSG``”h]”hŒNLMSGERR_ATTR_MSG”…”�”}”(hjF h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj> ubhŒ, ”…”�”}”(hj> h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSGERR_ATTR_OFFS``”h]”hŒNLMSGERR_ATTR_OFFS”…”�”}”(hjX h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj> ubhŒ and ”…”�”}”(hj> h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSGERR_ATTR_MISS_*``”h]”hŒNLMSGERR_ATTR_MISS_*”…”�”}”(hjj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj> ubhŒ.”…”�”}”(hj> h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mmhj× h²hubhÞ)�”}”(hŒ¶``NLMSGERR_ATTR_MSG`` carries a message in English describing the encountered problem. These messages are far more detailed than what can be expressed thru standard UNIX error codes.”h]”(jÁ)�”}”(hŒ``NLMSGERR_ATTR_MSG``”h]”hŒNLMSGERR_ATTR_MSG”…”�”}”(hj† h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj‚ ubhŒ¡ carries a message in English describing the encountered problem. These messages are far more detailed than what can be expressed thru standard UNIX error codes.”…”�”}”(hj‚ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mqhj× h²hubhÞ)�”}”(hŒH``NLMSGERR_ATTR_OFFS`` points to the attribute which caused the problem.”h]”(jÁ)�”}”(hŒ``NLMSGERR_ATTR_OFFS``”h]”hŒNLMSGERR_ATTR_OFFS”…”�”}”(hj¢ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjž ubhŒ2 points to the attribute which caused the problem.”…”�”}”(hjž h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Muhj× h²hubhÞ)�”}”(hŒ]``NLMSGERR_ATTR_MISS_TYPE`` and ``NLMSGERR_ATTR_MISS_NEST`` inform about a missing attribute.”h]”(jÁ)�”}”(hŒ``NLMSGERR_ATTR_MISS_TYPE``”h]”hŒNLMSGERR_ATTR_MISS_TYPE”…”�”}”(hj¾ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjº ubhŒ and ”…”�”}”(hjº h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSGERR_ATTR_MISS_NEST``”h]”hŒNLMSGERR_ATTR_MISS_NEST”…”�”}”(hjÐ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjº ubhŒ" inform about a missing attribute.”…”�”}”(hjº h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mwhj× h²hubhÞ)�”}”(hŒqExtended ACKs can be reported on errors as well as in case of success. The latter should be treated as a warning.”h]”hŒqExtended ACKs can be reported on errors as well as in case of success. The latter should be treated as a warning.”…”�”}”(hjè h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mzhj× h²hubhÞ)�”}”(hŒƒExtended ACKs greatly improve the usability of Netlink and should always be enabled, appropriately parsed and reported to the user.”h]”hŒƒExtended ACKs greatly improve the usability of Netlink and should always be enabled, appropriately parsed and reported to the user.”…”�”}”(hjö h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M}hj× h²hubeh}”(h]”(Œ extended-ack”jË eh ]”h"]”(Œ extended ack”Œext_ack”eh$]”h&]”uh1hÈhjh²hh³hÇh´Mfj½}”j jÁ sj¿}”jË jÁ subeh}”(h]”Œgeneric-netlink”ah ]”h"]”Œgeneric netlink”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´KbubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒAdvanced topics”h]”hŒAdvanced topics”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj h²hh³hÇh´M�ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒDump consistency”h]”hŒDump consistency”…”�”}”(hj+ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj( h²hh³hÇh´M„ubhÞ)�”}”(hŒµSome of the data structures kernel uses for storing objects make it hard to provide an atomic snapshot of all the objects in a dump (without impacting the fast-paths updating them).”h]”hŒµSome of the data structures kernel uses for storing objects make it hard to provide an atomic snapshot of all the objects in a dump (without impacting the fast-paths updating them).”…”�”}”(hj9 h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M†hj( h²hubhÞ)�”}”(hŒñKernel may set the ``NLM_F_DUMP_INTR`` flag on any message in a dump (including the ``NLMSG_DONE`` message) if the dump was interrupted and may be inconsistent (e.g. missing objects). User space should retry the dump if it sees the flag set.”h]”(hŒKernel may set the ”…”�”}”(hjG h²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_DUMP_INTR``”h]”hŒNLM_F_DUMP_INTR”…”�”}”(hjO h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjG ubhŒ. flag on any message in a dump (including the ”…”�”}”(hjG h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hja h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjG ubhŒ� message) if the dump was interrupted and may be inconsistent (e.g. missing objects). User space should retry the dump if it sees the flag set.”…”�”}”(hjG h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MŠhj( h²hubeh}”(h]”Œdump-consistency”ah ]”h"]”Œdump consistency”ah$]”h&]”uh1hÈhj h²hh³hÇh´M„ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ Introspection”h]”hŒ Introspection”…”�”}”(hj„ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj� h²hh³hÇh´M�ubhÞ)�”}”(hXíThe basic introspection abilities are enabled by access to the Family object as reported in :ref:`res_fam`. User can query information about the Generic Netlink family, including which operations are supported by the kernel and what attributes the kernel understands. Family information includes the highest ID of an attribute kernel can parse, a separate command (``CTRL_CMD_GETPOLICY``) provides detailed information about supported attributes, including ranges of values the kernel accepts.”h]”(hŒ\The basic introspection abilities are enabled by access to the Family object as reported in ”…”�”}”(hj’ h²hh³Nh´Nubh)�”}”(hŒ:ref:`res_fam`”h]”j´)�”}”(hjœ h]”hŒres_fam”…”�”}”(hjž h²hh³Nh´Nubah}”(h]”h ]”(jtŒstd”Œstd-ref”eh"]”h$]”h&]”uh1j³hjš ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j¨ Œreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆj†Œres_fam”uh1hh³hÇh´M’hj’ ubhX. User can query information about the Generic Netlink family, including which operations are supported by the kernel and what attributes the kernel understands. Family information includes the highest ID of an attribute kernel can parse, a separate command (”…”�”}”(hj’ h²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_CMD_GETPOLICY``”h]”hŒCTRL_CMD_GETPOLICY”…”�”}”(hj¾ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj’ ubhŒj) provides detailed information about supported attributes, including ranges of values the kernel accepts.”…”�”}”(hj’ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M’hj� h²hubhÞ)�”}”(hŒ•Querying family information is useful in cases when user space needs to make sure that the kernel has support for a feature before issuing a request.”h]”hŒ•Querying family information is useful in cases when user space needs to make sure that the kernel has support for a feature before issuing a request.”…”�”}”(hjÖ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mšhj� h²hubj’)�”}”(hŒ.. _nlmsg_pid:”h]”h}”(h]”h ]”h"]”h$]”h&]”j�Œ nlmsg-pid”uh1j‘h´Mžhj� h²hh³hÇubeh}”(h]”Œ introspection”ah ]”h"]”Œ introspection”ah$]”h&]”uh1hÈhj h²hh³hÇh´M�ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ nlmsg_pid”h]”hŒ nlmsg_pid”…”�”}”(hjú h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj÷ h²hh³hÇh´M¡ubhÞ)�”}”(hXJ:c:member:`nlmsghdr.nlmsg_pid` is the Netlink equivalent of an address. It is referred to as Port ID, sometimes Process ID because for historical reasons if the application does not select (bind() to) an explicit Port ID kernel will automatically assign it the ID equal to its Process ID (as reported by the getpid() system call).”h]”(h)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_pid`”h]”jÁ)�”}”(hj h]”hŒnlmsghdr.nlmsg_pid”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_pid”uh1hh³hÇh´M£hj ubhX, is the Netlink equivalent of an address. It is referred to as Port ID, sometimes Process ID because for historical reasons if the application does not select (bind() to) an explicit Port ID kernel will automatically assign it the ID equal to its Process ID (as reported by the getpid() system call).”…”�”}”(hj h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M£hj÷ h²hubhÞ)�”}”(hŒÝSimilarly to the bind() semantics of the TCP/IP network protocols the value of zero means "assign automatically", hence it is common for applications to leave the :c:member:`nlmsghdr.nlmsg_pid` field initialized to ``0``.”h]”(hŒ§Similarly to the bind() semantics of the TCP/IP network protocols the value of zero means “assign automaticallyâ€�, hence it is common for applications to leave the ”…”�”}”(hj5 h²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_pid`”h]”jÁ)�”}”(hj? h]”hŒnlmsghdr.nlmsg_pid”…”�”}”(hjA h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj= ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_pid”uh1hh³hÇh´M©hj5 ubhŒ field initialized to ”…”�”}”(hj5 h²hh³Nh´NubjÁ)�”}”(hŒ``0``”h]”hŒ0”…”�”}”(hj` h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj5 ubhŒ.”…”�”}”(hj5 h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M©hj÷ h²hubhÞ)�”}”(hXThe field is still used today in rare cases when kernel needs to send a unicast notification. User space application can use bind() to associate its socket with a specific PID, it then communicates its PID to the kernel. This way the kernel can reach the specific user space process.”h]”hXThe field is still used today in rare cases when kernel needs to send a unicast notification. User space application can use bind() to associate its socket with a specific PID, it then communicates its PID to the kernel. This way the kernel can reach the specific user space process.”…”�”}”(hjx h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M­hj÷ h²hubhÞ)�”}”(hŒ«This sort of communication is utilized in UMH (User Mode Helper)-like scenarios when kernel needs to trigger user space processing or ask user space for a policy decision.”h]”hŒ«This sort of communication is utilized in UMH (User Mode Helper)-like scenarios when kernel needs to trigger user space processing or ask user space for a policy decision.”…”�”}”(hj† h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M²hj÷ h²hubeh}”(h]”(jî Œid1”eh ]”h"]”Œ nlmsg_pid”ah$]”Œ nlmsg_pid”ah&]”uh1hÈhj h²hh³hÇh´M¡Œ referenced”Kj½}”j™ jä sj¿}”jî jä subhÉ)�”}”(hhh]”(hÎ)�”}”(hŒMulticast notifications”h]”hŒMulticast notifications”…”�”}”(hj£ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj  h²hh³hÇh´M·ubhÞ)�”}”(hŒëOne of the strengths of Netlink is the ability to send event notifications to user space. This is a unidirectional form of communication (kernel -> user) and does not involve any control messages like ``NLMSG_ERROR`` or ``NLMSG_DONE``.”h]”(hŒÉOne of the strengths of Netlink is the ability to send event notifications to user space. This is a unidirectional form of communication (kernel -> user) and does not involve any control messages like ”…”�”}”(hj± h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_ERROR``”h]”hŒ NLMSG_ERROR”…”�”}”(hj¹ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj± ubhŒ or ”…”�”}”(hj± h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSG_DONE``”h]”hŒ NLMSG_DONE”…”�”}”(hjË h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj± ubhŒ.”…”�”}”(hj± h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M¹hj  h²hubhÞ)�”}”(hŒÙFor example the Generic Netlink family itself defines a set of multicast notifications about registered families. When a new family is added the sockets subscribed to the notifications will get the following message::”h]”hŒØFor example the Generic Netlink family itself defines a set of multicast notifications about registered families. When a new family is added the sockets subscribed to the notifications will get the following message:”…”�”}”(hjã h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M¾hj  h²hubj))�”}”(hXístruct nlmsghdr: __u32 nlmsg_len: 136 __u16 nlmsg_type: GENL_ID_CTRL __u16 nlmsg_flags: 0 __u32 nlmsg_seq: 0 __u32 nlmsg_pid: 0 struct genlmsghdr: __u8 cmd: CTRL_CMD_NEWFAMILY __u8 version: 2 __u16 reserved: 0 struct nlattr: __u16 nla_len: 10 __u16 nla_type: CTRL_ATTR_FAMILY_NAME char data: test1\0 (padding:) data: \0\0 struct nlattr: __u16 nla_len: 6 __u16 nla_type: CTRL_ATTR_FAMILY_ID __u16: 123 /* The Family ID we are after */ (padding:) char data: \0\0 struct nlattr: __u16 nla_len: 9 __u16 nla_type: CTRL_ATTR_FAMILY_VERSION __u16: 1 /* ... etc, more attributes will follow. */”h]”hXístruct nlmsghdr: __u32 nlmsg_len: 136 __u16 nlmsg_type: GENL_ID_CTRL __u16 nlmsg_flags: 0 __u32 nlmsg_seq: 0 __u32 nlmsg_pid: 0 struct genlmsghdr: __u8 cmd: CTRL_CMD_NEWFAMILY __u8 version: 2 __u16 reserved: 0 struct nlattr: __u16 nla_len: 10 __u16 nla_type: CTRL_ATTR_FAMILY_NAME char data: test1\0 (padding:) data: \0\0 struct nlattr: __u16 nla_len: 6 __u16 nla_type: CTRL_ATTR_FAMILY_ID __u16: 123 /* The Family ID we are after */ (padding:) char data: \0\0 struct nlattr: __u16 nla_len: 9 __u16 nla_type: CTRL_ATTR_FAMILY_VERSION __u16: 1 /* ... etc, more attributes will follow. */”…”�”}”hjñ sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´MÂhj  h²hubhÞ)�”}”(hŒeThe notification contains the same information as the response to the ``CTRL_CMD_GETFAMILY`` request.”h]”(hŒFThe notification contains the same information as the response to the ”…”�”}”(hjÿ h²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_CMD_GETFAMILY``”h]”hŒCTRL_CMD_GETFAMILY”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÿ ubhŒ request.”…”�”}”(hjÿ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Måhj  h²hubhÞ)�”}”(hŒÏThe Netlink headers of the notification are mostly 0 and irrelevant. The :c:member:`nlmsghdr.nlmsg_seq` may be either zero or a monotonically increasing notification sequence number maintained by the family.”h]”(hŒIThe Netlink headers of the notification are mostly 0 and irrelevant. The ”…”�”}”(hjh²hh³Nh´Nubh)�”}”(hŒ:c:member:`nlmsghdr.nlmsg_seq`”h]”jÁ)�”}”(hj)h]”hŒnlmsghdr.nlmsg_seq”…”�”}”(hj+h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-member”eh"]”h$]”h&]”uh1jÀhj'ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œmember”Œ refexplicit”‰Œrefwarn”‰j†Œnlmsghdr.nlmsg_seq”uh1h•h³hÇh´MèhjubhŒh may be either zero or a monotonically increasing notification sequence number maintained by the family.”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mèhj  h²hubhÞ)�”}”(hXuTo receive notifications the user socket must subscribe to the relevant notification group. Much like the Family ID, the Group ID for a given multicast group is dynamic and can be found inside the Family information. The ``CTRL_ATTR_MCAST_GROUPS`` attribute contains nests with names (``CTRL_ATTR_MCAST_GRP_NAME``) and IDs (``CTRL_ATTR_MCAST_GRP_ID``) of the groups family.”h]”(hŒÝTo receive notifications the user socket must subscribe to the relevant notification group. Much like the Family ID, the Group ID for a given multicast group is dynamic and can be found inside the Family information. The ”…”�”}”(hjPh²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_ATTR_MCAST_GROUPS``”h]”hŒCTRL_ATTR_MCAST_GROUPS”…”�”}”(hjXh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjPubhŒ& attribute contains nests with names (”…”�”}”(hjPh²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_ATTR_MCAST_GRP_NAME``”h]”hŒCTRL_ATTR_MCAST_GRP_NAME”…”�”}”(hjjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjPubhŒ ) and IDs (”…”�”}”(hjPh²hh³Nh´NubjÁ)�”}”(hŒ``CTRL_ATTR_MCAST_GRP_ID``”h]”hŒCTRL_ATTR_MCAST_GRP_ID”…”�”}”(hj|h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjPubhŒ) of the groups family.”…”�”}”(hjPh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mìhj  h²hubhÞ)�”}”(hŒLOnce the Group ID is known a setsockopt() call adds the socket to the group:”h]”hŒLOnce the Group ID is known a setsockopt() call adds the socket to the group:”…”�”}”(hj”h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Móhj  h²hubj))�”}”(hŒ“unsigned int group_id; /* .. find the group ID... */ setsockopt(fd, SOL_NETLINK, NETLINK_ADD_MEMBERSHIP, &group_id, sizeof(group_id));”h]”hŒ“unsigned int group_id; /* .. find the group ID... */ setsockopt(fd, SOL_NETLINK, NETLINK_ADD_MEMBERSHIP, &group_id, sizeof(group_id));”…”�”}”hj¢sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆj8‰j9j:j;}”uh1j(h³hÇh´Mõhj  h²hubhÞ)�”}”(hŒ*The socket will now receive notifications.”h]”hŒ*The socket will now receive notifications.”…”�”}”(hj±h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mþhj  h²hubhÞ)�”}”(hŒïIt is recommended to use separate sockets for receiving notifications and sending requests to the kernel. The asynchronous nature of notifications means that they may get mixed in with the responses making the message handling much harder.”h]”hŒïIt is recommended to use separate sockets for receiving notifications and sending requests to the kernel. The asynchronous nature of notifications means that they may get mixed in with the responses making the message handling much harder.”…”�”}”(hj¿h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mhj  h²hubeh}”(h]”Œmulticast-notifications”ah ]”h"]”Œmulticast notifications”ah$]”h&]”uh1hÈhj h²hh³hÇh´M·ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ Buffer sizing”h]”hŒ Buffer sizing”…”�”}”(hjØh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjÕh²hh³hÇh´MubhÞ)�”}”(hX�Netlink sockets are datagram sockets rather than stream sockets, meaning that each message must be received in its entirety by a single recv()/recvmsg() system call. If the buffer provided by the user is too short, the message will be truncated and the ``MSG_TRUNC`` flag set in struct msghdr (struct msghdr is the second argument of the recvmsg() system call, *not* a Netlink header).”h]”(hŒýNetlink sockets are datagram sockets rather than stream sockets, meaning that each message must be received in its entirety by a single recv()/recvmsg() system call. If the buffer provided by the user is too short, the message will be truncated and the ”…”�”}”(hjæh²hh³Nh´NubjÁ)�”}”(hŒ ``MSG_TRUNC``”h]”hŒ MSG_TRUNC”…”�”}”(hjîh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjæubhŒ_ flag set in struct msghdr (struct msghdr is the second argument of the recvmsg() system call, ”…”�”}”(hjæh²hh³Nh´Nubju )�”}”(hŒ*not*”h]”hŒnot”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jt hjæubhŒ a Netlink header).”…”�”}”(hjæh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MhjÕh²hubhÞ)�”}”(hŒ?Upon truncation the remaining part of the message is discarded.”h]”hŒ?Upon truncation the remaining part of the message is discarded.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MhjÕh²hubhÞ)�”}”(hXRNetlink expects that the user buffer will be at most 8kB or a page size of the CPU architecture, whichever is smaller. Particular Netlink families may, however, require a larger buffer. 32kB buffer is recommended for most efficient handling of dumps (larger buffer fits more dumped objects and therefore fewer recvmsg() calls are needed).”h]”hXRNetlink expects that the user buffer will be at most 8kB or a page size of the CPU architecture, whichever is smaller. Particular Netlink families may, however, require a larger buffer. 32kB buffer is recommended for most efficient handling of dumps (larger buffer fits more dumped objects and therefore fewer recvmsg() calls are needed).”…”�”}”(hj&h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MhjÕh²hubj’)�”}”(hŒ.. _classic_netlink:”h]”h}”(h]”h ]”h"]”h$]”h&]”j�Œclassic-netlink”uh1j‘h´MhjÕh²hh³hÇubeh}”(h]”Œ buffer-sizing”ah ]”h"]”Œ buffer sizing”ah$]”h&]”uh1hÈhj h²hh³hÇh´Mubeh}”(h]”Œadvanced-topics”ah ]”h"]”Œadvanced topics”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´M�ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒClassic Netlink”h]”hŒClassic Netlink”…”�”}”(hjRh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjOh²hh³hÇh´MubhÞ)�”}”(hX5The main differences between Classic and Generic Netlink are the dynamic allocation of subsystem identifiers and availability of introspection. In theory the protocol does not differ significantly, however, in practice Classic Netlink experimented with concepts which were abandoned in Generic Netlink (really, they usually only found use in a small corner of a single subsystem). This section is meant as an explainer of a few of such concepts, with the explicit goal of giving the Generic Netlink users the confidence to ignore them when reading the uAPI headers.”h]”hX5The main differences between Classic and Generic Netlink are the dynamic allocation of subsystem identifiers and availability of introspection. In theory the protocol does not differ significantly, however, in practice Classic Netlink experimented with concepts which were abandoned in Generic Netlink (really, they usually only found use in a small corner of a single subsystem). This section is meant as an explainer of a few of such concepts, with the explicit goal of giving the Generic Netlink users the confidence to ignore them when reading the uAPI headers.”…”�”}”(hj`h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MhjOh²hubhÞ)�”}”(hŒáMost of the concepts and examples here refer to the ``NETLINK_ROUTE`` family, which covers much of the configuration of the Linux networking stack. Real documentation of that family, deserves a chapter (or a book) of its own.”h]”(hŒ4Most of the concepts and examples here refer to the ”…”�”}”(hjnh²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_ROUTE``”h]”hŒ NETLINK_ROUTE”…”�”}”(hjvh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjnubhŒœ family, which covers much of the configuration of the Linux networking stack. Real documentation of that family, deserves a chapter (or a book) of its own.”…”�”}”(hjnh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M%hjOh²hubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒFamilies”h]”hŒFamilies”…”�”}”(hj‘h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjŽh²hh³hÇh´M*ubhÞ)�”}”(hŒ±Netlink refers to subsystems as families. This is a remnant of using sockets and the concept of protocol families, which are part of message demultiplexing in ``NETLINK_ROUTE``.”h]”(hŒŸNetlink refers to subsystems as families. This is a remnant of using sockets and the concept of protocol families, which are part of message demultiplexing in ”…”�”}”(hjŸh²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_ROUTE``”h]”hŒ NETLINK_ROUTE”…”�”}”(hj§h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjŸubhŒ.”…”�”}”(hjŸh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M,hjŽh²hubhÞ)�”}”(hŒySadly every layer of encapsulation likes to refer to whatever it's carrying as "families" making the term very confusing:”h]”hŒSadly every layer of encapsulation likes to refer to whatever it’s carrying as “familiesâ€� making the term very confusing:”…”�”}”(hj¿h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M0hjŽh²hubj)�”}”(hX91. AF_NETLINK is a bona fide socket protocol family 2. AF_NETLINK's documentation refers to what comes after its own header (struct nlmsghdr) in a message as a "Family Header" 3. Generic Netlink is a family for AF_NETLINK (struct genlmsghdr follows struct nlmsghdr), yet it also calls its users "Families". ”h]”hŒenumerated_list”“”)�”}”(hhh]”(j)�”}”(hŒ0AF_NETLINK is a bona fide socket protocol family”h]”hÞ)�”}”(hjØh]”hŒ0AF_NETLINK is a bona fide socket protocol family”…”�”}”(hjÚh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M3hjÖubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÓubj)�”}”(hŒxAF_NETLINK's documentation refers to what comes after its own header (struct nlmsghdr) in a message as a "Family Header"”h]”hÞ)�”}”(hŒxAF_NETLINK's documentation refers to what comes after its own header (struct nlmsghdr) in a message as a "Family Header"”h]”hŒ~AF_NETLINK’s documentation refers to what comes after its own header (struct nlmsghdr) in a message as a “Family Headerâ€�”…”�”}”(hjñh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M4hjíubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÓubj)�”}”(hŒ€Generic Netlink is a family for AF_NETLINK (struct genlmsghdr follows struct nlmsghdr), yet it also calls its users "Families". ”h]”hÞ)�”}”(hŒGeneric Netlink is a family for AF_NETLINK (struct genlmsghdr follows struct nlmsghdr), yet it also calls its users "Families".”h]”hŒƒGeneric Netlink is a family for AF_NETLINK (struct genlmsghdr follows struct nlmsghdr), yet it also calls its users “Familiesâ€�.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M6hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÓubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œarabic”Œprefix”hŒsuffix”Œ.”uh1jÑhjÍubah}”(h]”h ]”h"]”h$]”h&]”uh1j h³hÇh´M3hjŽh²hubhÞ)�”}”(hXNote that the Generic Netlink Family IDs are in a different "ID space" and overlap with Classic Netlink protocol numbers (e.g. ``NETLINK_CRYPTO`` has the Classic Netlink protocol ID of 21 which Generic Netlink will happily allocate to one of its families as well).”h]”(hŒƒNote that the Generic Netlink Family IDs are in a different “ID spaceâ€� and overlap with Classic Netlink protocol numbers (e.g. ”…”�”}”(hj.h²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_CRYPTO``”h]”hŒNETLINK_CRYPTO”…”�”}”(hj6h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj.ubhŒw has the Classic Netlink protocol ID of 21 which Generic Netlink will happily allocate to one of its families as well).”…”�”}”(hj.h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M9hjŽh²hubeh}”(h]”Œfamilies”ah ]”h"]”Œfamilies”ah$]”h&]”uh1hÈhjOh²hh³hÇh´M*ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒStrict checking”h]”hŒStrict checking”…”�”}”(hjYh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjVh²hh³hÇh´M?ubhÞ)�”}”(hX_The ``NETLINK_GET_STRICT_CHK`` socket option enables strict input checking in ``NETLINK_ROUTE``. It was needed because historically kernel did not validate the fields of structures it didn't process. This made it impossible to start using those fields later without risking regressions in applications which initialized them incorrectly or not at all.”h]”(hŒThe ”…”�”}”(hjgh²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_GET_STRICT_CHK``”h]”hŒNETLINK_GET_STRICT_CHK”…”�”}”(hjoh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjgubhŒ0 socket option enables strict input checking in ”…”�”}”(hjgh²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_ROUTE``”h]”hŒ NETLINK_ROUTE”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjgubhX. It was needed because historically kernel did not validate the fields of structures it didn’t process. This made it impossible to start using those fields later without risking regressions in applications which initialized them incorrectly or not at all.”…”�”}”(hjgh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MAhjVh²hubhÞ)�”}”(hX``NETLINK_GET_STRICT_CHK`` declares that the application is initializing all fields correctly. It also opts into validating that message does not contain trailing data and requests that kernel rejects attributes with type higher than largest attribute type known to the kernel.”h]”(jÁ)�”}”(hŒ``NETLINK_GET_STRICT_CHK``”h]”hŒNETLINK_GET_STRICT_CHK”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj™ubhŒû declares that the application is initializing all fields correctly. It also opts into validating that message does not contain trailing data and requests that kernel rejects attributes with type higher than largest attribute type known to the kernel.”…”�”}”(hj™h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MGhjVh²hubhÞ)�”}”(hŒD``NETLINK_GET_STRICT_CHK`` is not used outside of ``NETLINK_ROUTE``.”h]”(jÁ)�”}”(hŒ``NETLINK_GET_STRICT_CHK``”h]”hŒNETLINK_GET_STRICT_CHK”…”�”}”(hj¹h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjµubhŒ is not used outside of ”…”�”}”(hjµh²hh³Nh´NubjÁ)�”}”(hŒ``NETLINK_ROUTE``”h]”hŒ NETLINK_ROUTE”…”�”}”(hjËh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjµubhŒ.”…”�”}”(hjµh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MLhjVh²hubeh}”(h]”Œstrict-checking”ah ]”h"]”Œstrict checking”ah$]”h&]”uh1hÈhjOh²hh³hÇh´M?ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒUnknown attributes”h]”hŒUnknown attributes”…”�”}”(hjîh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjëh²hh³hÇh´MOubhÞ)�”}”(hŒúHistorically Netlink ignored all unknown attributes. The thinking was that it would free the application from having to probe what kernel supports. The application could make a request to change the state and check which parts of the request "stuck".”h]”hŒþHistorically Netlink ignored all unknown attributes. The thinking was that it would free the application from having to probe what kernel supports. The application could make a request to change the state and check which parts of the request “stuckâ€�.”…”�”}”(hjüh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MQhjëh²hubhÞ)�”}”(hŒŸThis is no longer the case for new Generic Netlink families and those opting in to strict checking. See enum netlink_validation for validation types performed.”h]”hŒŸThis is no longer the case for new Generic Netlink families and those opting in to strict checking. See enum netlink_validation for validation types performed.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MVhjëh²hubeh}”(h]”Œunknown-attributes”ah ]”h"]”Œunknown attributes”ah$]”h&]”uh1hÈhjOh²hh³hÇh´MOubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒFixed metadata and structures”h]”hŒFixed metadata and structures”…”�”}”(hj#h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj h²hh³hÇh´M[ubhÞ)�”}”(hX>Classic Netlink made liberal use of fixed-format structures within the messages. Messages would commonly have a structure with a considerable number of fields after struct nlmsghdr. It was also common to put structures with multiple members inside attributes, without breaking each member into an attribute of its own.”h]”hX>Classic Netlink made liberal use of fixed-format structures within the messages. Messages would commonly have a structure with a considerable number of fields after struct nlmsghdr. It was also common to put structures with multiple members inside attributes, without breaking each member into an attribute of its own.”…”�”}”(hj1h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M]hj h²hubhÞ)�”}”(hŒŒThis has caused problems with validation and extensibility and therefore using binary structures is actively discouraged for new attributes.”h]”hŒŒThis has caused problems with validation and extensibility and therefore using binary structures is actively discouraged for new attributes.”…”�”}”(hj?h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mchj h²hubeh}”(h]”Œfixed-metadata-and-structures”ah ]”h"]”Œfixed metadata and structures”ah$]”h&]”uh1hÈhjOh²hh³hÇh´M[ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ Request types”h]”hŒ Request types”…”�”}”(hjXh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjUh²hh³hÇh´MhubhÞ)�”}”(hXT``NETLINK_ROUTE`` categorized requests into 4 types ``NEW``, ``DEL``, ``GET``, and ``SET``. Each object can handle all or some of those requests (objects being netdevs, routes, addresses, qdiscs etc.) Request type is defined by the 2 lowest bits of the message type, so commands for new objects would always be allocated with a stride of 4.”h]”(jÁ)�”}”(hŒ``NETLINK_ROUTE``”h]”hŒ NETLINK_ROUTE”…”�”}”(hjjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒ# categorized requests into 4 types ”…”�”}”(hjfh²hh³Nh´NubjÁ)�”}”(hŒ``NEW``”h]”hŒNEW”…”�”}”(hj|h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒ, ”…”�”}”(hjfh²hh³Nh´NubjÁ)�”}”(hŒ``DEL``”h]”hŒDEL”…”�”}”(hjŽh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒ, ”…”�”}”hjfsbjÁ)�”}”(hŒ``GET``”h]”hŒGET”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒ, and ”…”�”}”(hjfh²hh³Nh´NubjÁ)�”}”(hŒ``SET``”h]”hŒSET”…”�”}”(hj²h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒú. Each object can handle all or some of those requests (objects being netdevs, routes, addresses, qdiscs etc.) Request type is defined by the 2 lowest bits of the message type, so commands for new objects would always be allocated with a stride of 4.”…”�”}”(hjfh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MjhjUh²hubhÞ)�”}”(hŒÃEach object would also have its own fixed metadata shared by all request types (e.g. struct ifinfomsg for netdev requests, struct ifaddrmsg for address requests, struct tcmsg for qdisc requests).”h]”hŒÃEach object would also have its own fixed metadata shared by all request types (e.g. struct ifinfomsg for netdev requests, struct ifaddrmsg for address requests, struct tcmsg for qdisc requests).”…”�”}”(hjÊh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MphjUh²hubhÞ)�”}”(hŒµEven though other protocols and Generic Netlink commands often use the same verbs in their message names (``GET``, ``SET``) the concept of request types did not find wider adoption.”h]”(hŒjEven though other protocols and Generic Netlink commands often use the same verbs in their message names (”…”�”}”(hjØh²hh³Nh´NubjÁ)�”}”(hŒ``GET``”h]”hŒGET”…”�”}”(hjàh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjØubhŒ, ”…”�”}”(hjØh²hh³Nh´NubjÁ)�”}”(hŒ``SET``”h]”hŒSET”…”�”}”(hjòh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjØubhŒ;) the concept of request types did not find wider adoption.”…”�”}”(hjØh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MthjUh²hubeh}”(h]”Œ request-types”ah ]”h"]”Œ request types”ah$]”h&]”uh1hÈhjOh²hh³hÇh´MhubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒNotification echo”h]”hŒNotification echo”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjh²hh³hÇh´MyubhÞ)�”}”(hŒ£``NLM_F_ECHO`` requests for notifications resulting from the request to be queued onto the requesting socket. This is useful to discover the impact of the request.”h]”(jÁ)�”}”(hŒ``NLM_F_ECHO``”h]”hŒ NLM_F_ECHO”…”�”}”(hj'h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj#ubhŒ• requests for notifications resulting from the request to be queued onto the requesting socket. This is useful to discover the impact of the request.”…”�”}”(hj#h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M{hjh²hubhÞ)�”}”(hŒ6Note that this feature is not universally implemented.”h]”hŒ6Note that this feature is not universally implemented.”…”�”}”(hj?h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Mhjh²hubeh}”(h]”Œnotification-echo”ah ]”h"]”Œnotification echo”ah$]”h&]”uh1hÈhjOh²hh³hÇh´MyubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ!Other request-type-specific flags”h]”hŒ!Other request-type-specific flags”…”�”}”(hjXh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjUh²hh³hÇh´M‚ubhÞ)�”}”(hXClassic Netlink defined various flags for its ``GET``, ``NEW`` and ``DEL`` requests in the upper byte of nlmsg_flags in struct nlmsghdr. Since request types have not been generalized the request type specific flags are rarely used (and considered deprecated for new families).”h]”(hŒ.Classic Netlink defined various flags for its ”…”�”}”(hjfh²hh³Nh´NubjÁ)�”}”(hŒ``GET``”h]”hŒGET”…”�”}”(hjnh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒ, ”…”�”}”(hjfh²hh³Nh´NubjÁ)�”}”(hŒ``NEW``”h]”hŒNEW”…”�”}”(hj€h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒ and ”…”�”}”(hjfh²hh³Nh´NubjÁ)�”}”(hŒ``DEL``”h]”hŒDEL”…”�”}”(hj’h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒÊ requests in the upper byte of nlmsg_flags in struct nlmsghdr. Since request types have not been generalized the request type specific flags are rarely used (and considered deprecated for new families).”…”�”}”(hjfh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M„hjUh²hubhÞ)�”}”(hŒ‹For ``GET`` - ``NLM_F_ROOT`` and ``NLM_F_MATCH`` are combined into ``NLM_F_DUMP``, and not used separately. ``NLM_F_ATOMIC`` is never used.”h]”(hŒFor ”…”�”}”(hjªh²hh³Nh´NubjÁ)�”}”(hŒ``GET``”h]”hŒGET”…”�”}”(hj²h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjªubhŒ - ”…”�”}”(hjªh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_ROOT``”h]”hŒ NLM_F_ROOT”…”�”}”(hjÄh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjªubhŒ and ”…”�”}”(hjªh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_MATCH``”h]”hŒ NLM_F_MATCH”…”�”}”(hjÖh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjªubhŒ are combined into ”…”�”}”(hjªh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_DUMP``”h]”hŒ NLM_F_DUMP”…”�”}”(hjèh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjªubhŒ, and not used separately. ”…”�”}”(hjªh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_ATOMIC``”h]”hŒ NLM_F_ATOMIC”…”�”}”(hjúh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjªubhŒ is never used.”…”�”}”(hjªh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M‰hjUh²hubhÞ)�”}”(hŒgFor ``DEL`` - ``NLM_F_NONREC`` is only used by nftables and ``NLM_F_BULK`` only by FDB some operations.”h]”(hŒFor ”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``DEL``”h]”hŒDEL”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ - ”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_NONREC``”h]”hŒ NLM_F_NONREC”…”�”}”(hj,h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ is only used by nftables and ”…”�”}”(hjh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_BULK``”h]”hŒ NLM_F_BULK”…”�”}”(hj>h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubhŒ only by FDB some operations.”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´MŒhjUh²hubhÞ)�”}”(hXUThe flags for ``NEW`` are used most commonly in classic Netlink. Unfortunately, the meaning is not crystal clear. The following description is based on the best guess of the intention of the authors, and in practice all families stray from it in one way or another. ``NLM_F_REPLACE`` asks to replace an existing object, if no matching object exists the operation should fail. ``NLM_F_EXCL`` has the opposite semantics and only succeeds if object already existed. ``NLM_F_CREATE`` asks for the object to be created if it does not exist, it can be combined with ``NLM_F_REPLACE`` and ``NLM_F_EXCL``.”h]”(hŒThe flags for ”…”�”}”(hjVh²hh³Nh´NubjÁ)�”}”(hŒ``NEW``”h]”hŒNEW”…”�”}”(hj^h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjVubhŒõ are used most commonly in classic Netlink. Unfortunately, the meaning is not crystal clear. The following description is based on the best guess of the intention of the authors, and in practice all families stray from it in one way or another. ”…”�”}”(hjVh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_REPLACE``”h]”hŒ NLM_F_REPLACE”…”�”}”(hjph²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjVubhŒ] asks to replace an existing object, if no matching object exists the operation should fail. ”…”�”}”(hjVh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_EXCL``”h]”hŒ NLM_F_EXCL”…”�”}”(hj‚h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjVubhŒI has the opposite semantics and only succeeds if object already existed. ”…”�”}”(hjVh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_CREATE``”h]”hŒ NLM_F_CREATE”…”�”}”(hj”h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjVubhŒQ asks for the object to be created if it does not exist, it can be combined with ”…”�”}”(hjVh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_REPLACE``”h]”hŒ NLM_F_REPLACE”…”�”}”(hj¦h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjVubhŒ and ”…”�”}”(hjVh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_EXCL``”h]”hŒ NLM_F_EXCL”…”�”}”(hj¸h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjVubhŒ.”…”�”}”(hjVh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M�hjUh²hubhÞ)�”}”(hŒ2A comment in the main Netlink uAPI header states::”h]”hŒ1A comment in the main Netlink uAPI header states:”…”�”}”(hjÐh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M™hjUh²hubj))�”}”(hŒÂ4.4BSD ADD NLM_F_CREATE|NLM_F_EXCL 4.4BSD CHANGE NLM_F_REPLACE True CHANGE NLM_F_CREATE|NLM_F_REPLACE Append NLM_F_CREATE Check NLM_F_EXCL”h]”hŒÂ4.4BSD ADD NLM_F_CREATE|NLM_F_EXCL 4.4BSD CHANGE NLM_F_REPLACE True CHANGE NLM_F_CREATE|NLM_F_REPLACE Append NLM_F_CREATE Check NLM_F_EXCL”…”�”}”hjÞsbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³hÇh´M›hjUh²hubhÞ)�”}”(hX!which seems to indicate that those flags predate request types. ``NLM_F_REPLACE`` without ``NLM_F_CREATE`` was initially used instead of ``SET`` commands. ``NLM_F_EXCL`` without ``NLM_F_CREATE`` was used to check if object exists without creating it, presumably predating ``GET`` commands.”h]”(hŒ@which seems to indicate that those flags predate request types. ”…”�”}”(hjìh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_REPLACE``”h]”hŒ NLM_F_REPLACE”…”�”}”(hjôh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjìubhŒ without ”…”�”}”(hjìh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_CREATE``”h]”hŒ NLM_F_CREATE”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjìubhŒ was initially used instead of ”…”�”}”(hjìh²hh³Nh´NubjÁ)�”}”(hŒ``SET``”h]”hŒSET”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjìubhŒ commands. ”…”�”}”(hjìh²hh³Nh´NubjÁ)�”}”(hŒ``NLM_F_EXCL``”h]”hŒ NLM_F_EXCL”…”�”}”(hj*h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjìubhŒ without ”…”�”}”hjìsbjÁ)�”}”(hŒ``NLM_F_CREATE``”h]”hŒ NLM_F_CREATE”…”�”}”(hj<h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjìubhŒN was used to check if object exists without creating it, presumably predating ”…”�”}”(hjìh²hh³Nh´NubjÁ)�”}”(hŒ``GET``”h]”hŒGET”…”�”}”(hjNh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjìubhŒ commands.”…”�”}”(hjìh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M¢hjUh²hubhÞ)�”}”(hŒÖ``NLM_F_APPEND`` indicates that if one key can have multiple objects associated with it (e.g. multiple next-hop objects for a route) the new object should be added to the list rather than replacing the entire list.”h]”(jÁ)�”}”(hŒ``NLM_F_APPEND``”h]”hŒ NLM_F_APPEND”…”�”}”(hjjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjfubhŒÆ indicates that if one key can have multiple objects associated with it (e.g. multiple next-hop objects for a route) the new object should be added to the list rather than replacing the entire list.”…”�”}”(hjfh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´M¨hjUh²hubeh}”(h]”Œ!other-request-type-specific-flags”ah ]”h"]”Œ!other request-type-specific flags”ah$]”h&]”uh1hÈhjOh²hh³hÇh´M‚ubeh}”(h]”(j>Œid2”eh ]”h"]”(Œclassic netlink”Œclassic_netlink”eh$]”h&]”uh1hÈhhÊh²hh³hÇh´Mj½}”j�j4sj¿}”j>j4subhÉ)�”}”(hhh]”(hÎ)�”}”(hŒuAPI reference”h]”hŒuAPI reference”…”�”}”(hj˜h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj•h²hh³hÇh´M­ubhŒindex”“”)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œentries”]”(Œsingle”Œnlmsghdr (C struct)”Œ c.nlmsghdr”hNt”auh1j¦hj•h²hh³Nh´NubhŒdesc”“”)�”}”(hhh]”(hŒdesc_signature”“”)�”}”(hŒnlmsghdr”h]”hŒdesc_signature_line”“”)�”}”(hŒstruct nlmsghdr”h]”(hŒdesc_sig_keyword”“”)�”}”(hŒstruct”h]”hŒstruct”…”�”}”(hjÊh²hh³Nh´Nubah}”(h]”h ]”Œk”ah"]”h$]”h&]”uh1jÈhjÄh²hh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´KubhŒdesc_sig_space”“”)�”}”(hŒ ”h]”hŒ ”…”�”}”(hjÜh²hh³Nh´Nubah}”(h]”h ]”Œw”ah"]”h$]”h&]”uh1jÚhjÄh²hh³jÙh´KubhŒ desc_name”“”)�”}”(hŒnlmsghdr”h]”hŒ desc_sig_name”“”)�”}”(hjÀh]”hŒnlmsghdr”…”�”}”(hjóh²hh³Nh´Nubah}”(h]”h ]”Œn”ah"]”h$]”h&]”uh1jñhjíubah}”(h]”h ]”(Œsig-name”Œdescname”eh"]”h$]”h&]”hÅhÆuh1jëhjÄh²hh³jÙh´Kubeh}”(h]”h ]”h"]”h$]”h&]”hÅhÆŒ add_permalink”ˆuh1jÂŒsphinx_line_type”Œ declarator”hj¾h²hh³jÙh´Kubah}”(h]”jµah ]”(Œsig”Œ sig-object”eh"]”h$]”h&]”Œ is_multiline”ˆŒ _toc_parts”)Œ _toc_name”huh1j¼h³jÙh´Khj¹h²hubhŒ desc_content”“”)�”}”(hhh]”hÞ)�”}”(hŒ0fixed format metadata header of Netlink messages”h]”hŒ0fixed format metadata header of Netlink messages”…”�”}”(hj"h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K-hjh²hubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj¹h²hh³jÙh´Kubeh}”(h]”h ]”(j:Œstruct”eh"]”h$]”h&]”Œdomain”j:Œobjtype”j:Œdesctype”j:Œnoindex”‰Œ noindexentry”‰Œnocontentsentry”‰uh1j·h²hhj•h³Nh´NubhŒ container”“”)�”}”(hXv**Definition**:: struct nlmsghdr { __u32 nlmsg_len; __u16 nlmsg_type; __u16 nlmsg_flags; __u32 nlmsg_seq; __u32 nlmsg_pid; }; **Members** ``nlmsg_len`` Length of message including header ``nlmsg_type`` Message content type ``nlmsg_flags`` Additional flags ``nlmsg_seq`` Sequence number ``nlmsg_pid`` Sending process port ID”h]”(hÞ)�”}”(hŒ**Definition**::”h]”(j­)�”}”(hŒ**Definition**”h]”hŒ Definition”…”�”}”(hjNh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hjJubhŒ:”…”�”}”(hjJh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K1hjFubj))�”}”(hŒ€struct nlmsghdr { __u32 nlmsg_len; __u16 nlmsg_type; __u16 nlmsg_flags; __u32 nlmsg_seq; __u32 nlmsg_pid; };”h]”hŒ€struct nlmsghdr { __u32 nlmsg_len; __u16 nlmsg_type; __u16 nlmsg_flags; __u32 nlmsg_seq; __u32 nlmsg_pid; };”…”�”}”hjgsbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1j(h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K3hjFubhÞ)�”}”(hŒ **Members**”h]”j­)�”}”(hjxh]”hŒMembers”…”�”}”(hjzh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hjvubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K;hjFubhŒdefinition_list”“”)�”}”(hhh]”(hŒdefinition_list_item”“”)�”}”(hŒ1``nlmsg_len`` Length of message including header ”h]”(hŒterm”“”)�”}”(hŒ ``nlmsg_len``”h]”jÁ)�”}”(hj�h]”hŒ nlmsg_len”…”�”}”(hjŸh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj›ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K/hj•ubhŒ definition”“”)�”}”(hhh]”hÞ)�”}”(hŒ"Length of message including header”h]”hŒ"Length of message including header”…”�”}”(hj¸h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j²h´K/hjµubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj•ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j²h´K/hj�ubj”)�”}”(hŒ$``nlmsg_type`` Message content type ”h]”(jš)�”}”(hŒ``nlmsg_type``”h]”jÁ)�”}”(hjØh]”hŒ nlmsg_type”…”�”}”(hjÚh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÖubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K0hjÒubj´)�”}”(hhh]”hÞ)�”}”(hŒMessage content type”h]”hŒMessage content type”…”�”}”(hjñh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jíh´K0hjîubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÒubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jíh´K0hj�ubj”)�”}”(hŒ!``nlmsg_flags`` Additional flags ”h]”(jš)�”}”(hŒ``nlmsg_flags``”h]”jÁ)�”}”(hjh]”hŒ nlmsg_flags”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K1hj ubj´)�”}”(hhh]”hÞ)�”}”(hŒAdditional flags”h]”hŒAdditional flags”…”�”}”(hj*h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j&h´K1hj'ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j&h´K1hj�ubj”)�”}”(hŒ``nlmsg_seq`` Sequence number ”h]”(jš)�”}”(hŒ ``nlmsg_seq``”h]”jÁ)�”}”(hjJh]”hŒ nlmsg_seq”…”�”}”(hjLh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjHubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K2hjDubj´)�”}”(hhh]”hÞ)�”}”(hŒSequence number”h]”hŒSequence number”…”�”}”(hjch²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j_h´K2hj`ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjDubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j_h´K2hj�ubj”)�”}”(hŒ%``nlmsg_pid`` Sending process port ID”h]”(jš)�”}”(hŒ ``nlmsg_pid``”h]”jÁ)�”}”(hjƒh]”hŒ nlmsg_pid”…”�”}”(hj…h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj�ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K2hj}ubj´)�”}”(hhh]”hÞ)�”}”(hŒSending process port ID”h]”hŒSending process port ID”…”�”}”(hjœh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K3hj™ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj}ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j˜h´K2hj�ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjFubeh}”(h]”h ]”Œ kernelindent”ah"]”h$]”h&]”uh1jDhj•h²hh³Nh´Nubj§)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œentries”]”(j³Œnlmsgerr_attrs (C enum)”Œc.nlmsgerr_attrs”hNt”auh1j¦hj•h²hh³Nh´Nubj¸)�”}”(hhh]”(j½)�”}”(hŒnlmsgerr_attrs”h]”jÃ)�”}”(hŒenum nlmsgerr_attrs”h]”(jÉ)�”}”(hŒenum”h]”hŒenum”…”�”}”(hjÝh²hh³Nh´Nubah}”(h]”h ]”jÕah"]”h$]”h&]”uh1jÈhjÙh²hh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K9ubjÛ)�”}”(hŒ ”h]”hŒ ”…”�”}”(hjìh²hh³Nh´Nubah}”(h]”h ]”jçah"]”h$]”h&]”uh1jÚhjÙh²hh³jëh´K9ubjì)�”}”(hŒnlmsgerr_attrs”h]”jò)�”}”(hj×h]”hŒnlmsgerr_attrs”…”�”}”(hjþh²hh³Nh´Nubah}”(h]”h ]”jýah"]”h$]”h&]”uh1jñhjúubah}”(h]”h ]”(jjeh"]”h$]”h&]”hÅhÆuh1jëhjÙh²hh³jëh´K9ubeh}”(h]”h ]”h"]”h$]”h&]”hÅhÆjˆuh1jÂjjhjÕh²hh³jëh´K9ubah}”(h]”jÐah ]”(jjeh"]”h$]”h&]”jˆj)jhuh1j¼h³jëh´K9hjÒh²hubj)�”}”(hhh]”hÞ)�”}”(hŒnlmsgerr attributes”h]”hŒnlmsgerr attributes”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K†hjh²hubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÒh²hh³jëh´K9ubeh}”(h]”h ]”(j:Œenum”eh"]”h$]”h&]”j>j:j?j8j@j8jA‰jB‰jC‰uh1j·h²hhj•h³Nh´NubjE)�”}”(hX(**Constants** ``NLMSGERR_ATTR_UNUSED`` unused ``NLMSGERR_ATTR_MSG`` error message string (string) ``NLMSGERR_ATTR_OFFS`` offset of the invalid attribute in the original message, counting from the beginning of the header (u32) ``NLMSGERR_ATTR_COOKIE`` arbitrary subsystem specific cookie to be used - in the success case - to identify a created object or operation or similar (binary) ``NLMSGERR_ATTR_POLICY`` policy for a rejected attribute ``NLMSGERR_ATTR_MISS_TYPE`` type of a missing required attribute, ``NLMSGERR_ATTR_MISS_NEST`` will not be present if the attribute was missing at the message level ``NLMSGERR_ATTR_MISS_NEST`` offset of the nest where attribute was missing ``__NLMSGERR_ATTR_MAX`` number of attributes ``NLMSGERR_ATTR_MAX`` highest attribute number”h]”(hÞ)�”}”(hŒ **Constants**”h]”j­)�”}”(hjBh]”hŒ Constants”…”�”}”(hjDh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hj@ubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´KŠhj<ubj�)�”}”(hhh]”(j”)�”}”(hŒ ``NLMSGERR_ATTR_UNUSED`` unused ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_UNUSED``”h]”jÁ)�”}”(hjah]”hŒNLMSGERR_ATTR_UNUSED”…”�”}”(hjch²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj_ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K�hj[ubj´)�”}”(hhh]”hÞ)�”}”(hŒunused”h]”hŒunused”…”�”}”(hjzh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jvh´K�hjwubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj[ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jvh´K�hjXubj”)�”}”(hŒ4``NLMSGERR_ATTR_MSG`` error message string (string) ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_MSG``”h]”jÁ)�”}”(hjšh]”hŒNLMSGERR_ATTR_MSG”…”�”}”(hjœh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj˜ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K�hj”ubj´)�”}”(hhh]”hÞ)�”}”(hŒerror message string (string)”h]”hŒerror message string (string)”…”�”}”(hj³h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j¯h´K�hj°ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj”ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j¯h´K�hjXubj”)�”}”(hŒ€``NLMSGERR_ATTR_OFFS`` offset of the invalid attribute in the original message, counting from the beginning of the header (u32) ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_OFFS``”h]”jÁ)�”}”(hjÓh]”hŒNLMSGERR_ATTR_OFFS”…”�”}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÑubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K”hjÍubj´)�”}”(hhh]”hÞ)�”}”(hŒhoffset of the invalid attribute in the original message, counting from the beginning of the header (u32)”h]”hŒhoffset of the invalid attribute in the original message, counting from the beginning of the header (u32)”…”�”}”(hjìh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K“hjéubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÍubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jèh´K”hjXubj”)�”}”(hŒž``NLMSGERR_ATTR_COOKIE`` arbitrary subsystem specific cookie to be used - in the success case - to identify a created object or operation or similar (binary) ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_COOKIE``”h]”jÁ)�”}”(hj h]”hŒNLMSGERR_ATTR_COOKIE”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K™hjubj´)�”}”(hhh]”hÞ)�”}”(hŒ„arbitrary subsystem specific cookie to be used - in the success case - to identify a created object or operation or similar (binary)”h]”hŒ„arbitrary subsystem specific cookie to be used - in the success case - to identify a created object or operation or similar (binary)”…”�”}”(hj&h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K—hj#ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j"h´K™hjXubj”)�”}”(hŒ9``NLMSGERR_ATTR_POLICY`` policy for a rejected attribute ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_POLICY``”h]”jÁ)�”}”(hjGh]”hŒNLMSGERR_ATTR_POLICY”…”�”}”(hjIh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjEubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´KœhjAubj´)�”}”(hhh]”hÞ)�”}”(hŒpolicy for a rejected attribute”h]”hŒpolicy for a rejected attribute”…”�”}”(hj`h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j\h´Kœhj]ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjAubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j\h´KœhjXubj”)�”}”(hŒ¤``NLMSGERR_ATTR_MISS_TYPE`` type of a missing required attribute, ``NLMSGERR_ATTR_MISS_NEST`` will not be present if the attribute was missing at the message level ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_MISS_TYPE``”h]”jÁ)�”}”(hj€h]”hŒNLMSGERR_ATTR_MISS_TYPE”…”�”}”(hj‚h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj~ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K¡hjzubj´)�”}”(hhh]”hÞ)�”}”(hŒ‡type of a missing required attribute, ``NLMSGERR_ATTR_MISS_NEST`` will not be present if the attribute was missing at the message level”h]”(hŒ&type of a missing required attribute, ”…”�”}”(hj™h²hh³Nh´NubjÁ)�”}”(hŒ``NLMSGERR_ATTR_MISS_NEST``”h]”hŒNLMSGERR_ATTR_MISS_NEST”…”�”}”(hj¡h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj™ubhŒF will not be present if the attribute was missing at the message level”…”�”}”(hj™h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´KŸhj–ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjzubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j•h´K¡hjXubj”)�”}”(hŒK``NLMSGERR_ATTR_MISS_NEST`` offset of the nest where attribute was missing ”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_MISS_NEST``”h]”jÁ)�”}”(hjÌh]”hŒNLMSGERR_ATTR_MISS_NEST”…”�”}”(hjÎh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÊubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K¤hjÆubj´)�”}”(hhh]”hÞ)�”}”(hŒ.offset of the nest where attribute was missing”h]”hŒ.offset of the nest where attribute was missing”…”�”}”(hjåh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jáh´K¤hjâubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÆubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jáh´K¤hjXubj”)�”}”(hŒ-``__NLMSGERR_ATTR_MAX`` number of attributes ”h]”(jš)�”}”(hŒ``__NLMSGERR_ATTR_MAX``”h]”jÁ)�”}”(hjh]”hŒ__NLMSGERR_ATTR_MAX”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K§hjÿubj´)�”}”(hhh]”hÞ)�”}”(hŒnumber of attributes”h]”hŒnumber of attributes”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jh´K§hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÿubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jh´K§hjXubj”)�”}”(hŒ.``NLMSGERR_ATTR_MAX`` highest attribute number”h]”(jš)�”}”(hŒ``NLMSGERR_ATTR_MAX``”h]”jÁ)�”}”(hj>h]”hŒNLMSGERR_ATTR_MAX”…”�”}”(hj@h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj<ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K©hj8ubj´)�”}”(hhh]”hÞ)�”}”(hŒhighest attribute number”h]”hŒhighest attribute number”…”�”}”(hjWh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´KªhjTubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj8ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jSh´K©hjXubeh}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj<ubeh}”(h]”h ]”Œ kernelindent”ah"]”h$]”h&]”uh1jDhj•h²hh³Nh´Nubj§)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œentries”]”(j³Œnetlink_attribute_type (C enum)”Œc.netlink_attribute_type”hNt”auh1j¦hj•h²hh³Nh´Nubj¸)�”}”(hhh]”(j½)�”}”(hŒnetlink_attribute_type”h]”jÃ)�”}”(hŒenum netlink_attribute_type”h]”(jÉ)�”}”(hjßh]”hŒenum”…”�”}”(hj˜h²hh³Nh´Nubah}”(h]”h ]”jÕah"]”h$]”h&]”uh1jÈhj”h²hh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´K¯ubjÛ)�”}”(hŒ ”h]”hŒ ”…”�”}”(hj¦h²hh³Nh´Nubah}”(h]”h ]”jçah"]”h$]”h&]”uh1jÚhj”h²hh³j¥h´K¯ubjì)�”}”(hŒnetlink_attribute_type”h]”jò)�”}”(hj’h]”hŒnetlink_attribute_type”…”�”}”(hj¸h²hh³Nh´Nubah}”(h]”h ]”jýah"]”h$]”h&]”uh1jñhj´ubah}”(h]”h ]”(jjeh"]”h$]”h&]”hÅhÆuh1jëhj”h²hh³j¥h´K¯ubeh}”(h]”h ]”h"]”h$]”h&]”hÅhÆjˆuh1jÂjjhj�h²hh³j¥h´K¯ubah}”(h]”j‹ah ]”(jjeh"]”h$]”h&]”jˆj)jhuh1j¼h³j¥h´K¯hj�h²hubj)�”}”(hhh]”hÞ)�”}”(hŒtype of an attribute”h]”hŒtype of an attribute”…”�”}”(hjÚh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mhj×h²hubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj�h²hh³j¥h´K¯ubeh}”(h]”h ]”(j:Œenum”eh"]”h$]”h&]”j>j:j?jòj@jòjA‰jB‰jC‰uh1j·h²hhj•h³Nh´NubjE)�”}”(hX—**Constants** ``NL_ATTR_TYPE_INVALID`` unused ``NL_ATTR_TYPE_FLAG`` flag attribute (present/not present) ``NL_ATTR_TYPE_U8`` 8-bit unsigned attribute ``NL_ATTR_TYPE_U16`` 16-bit unsigned attribute ``NL_ATTR_TYPE_U32`` 32-bit unsigned attribute ``NL_ATTR_TYPE_U64`` 64-bit unsigned attribute ``NL_ATTR_TYPE_S8`` 8-bit signed attribute ``NL_ATTR_TYPE_S16`` 16-bit signed attribute ``NL_ATTR_TYPE_S32`` 32-bit signed attribute ``NL_ATTR_TYPE_S64`` 64-bit signed attribute ``NL_ATTR_TYPE_BINARY`` binary data, min/max length may be specified ``NL_ATTR_TYPE_STRING`` string, min/max length may be specified ``NL_ATTR_TYPE_NUL_STRING`` NUL-terminated string, min/max length may be specified ``NL_ATTR_TYPE_NESTED`` nested, i.e. the content of this attribute consists of sub-attributes. The nested policy and maxtype inside may be specified. ``NL_ATTR_TYPE_NESTED_ARRAY`` nested array, i.e. the content of this attribute contains sub-attributes whose type is irrelevant (just used to separate the array entries) and each such array entry has attributes again, the policy for those inner ones and the corresponding maxtype may be specified. ``NL_ATTR_TYPE_BITFIELD32`` :c:type:`struct nla_bitfield32 ` attribute ``NL_ATTR_TYPE_SINT`` 32-bit or 64-bit signed attribute, aligned to 4B ``NL_ATTR_TYPE_UINT`` 32-bit or 64-bit unsigned attribute, aligned to 4B”h]”(hÞ)�”}”(hŒ **Constants**”h]”j­)�”}”(hjüh]”hŒ Constants”…”�”}”(hjþh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hjúubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mhjöubj�)�”}”(hhh]”(j”)�”}”(hŒ ``NL_ATTR_TYPE_INVALID`` unused ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_INVALID``”h]”jÁ)�”}”(hjh]”hŒNL_ATTR_TYPE_INVALID”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mhjubj´)�”}”(hhh]”hÞ)�”}”(hŒunused”h]”hŒunused”…”�”}”(hj4h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j0h´Mhj1ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j0h´Mhjubj”)�”}”(hŒ;``NL_ATTR_TYPE_FLAG`` flag attribute (present/not present) ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_FLAG``”h]”jÁ)�”}”(hjTh]”hŒNL_ATTR_TYPE_FLAG”…”�”}”(hjVh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjRubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MhjNubj´)�”}”(hhh]”hÞ)�”}”(hŒ$flag attribute (present/not present)”h]”hŒ$flag attribute (present/not present)”…”�”}”(hjmh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jih´Mhjjubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjNubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jih´Mhjubj”)�”}”(hŒ-``NL_ATTR_TYPE_U8`` 8-bit unsigned attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_U8``”h]”jÁ)�”}”(hj�h]”hŒNL_ATTR_TYPE_U8”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj‹ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M"hj‡ubj´)�”}”(hhh]”hÞ)�”}”(hŒ8-bit unsigned attribute”h]”hŒ8-bit unsigned attribute”…”�”}”(hj¦h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j¢h´M"hj£ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj‡ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j¢h´M"hjubj”)�”}”(hŒ/``NL_ATTR_TYPE_U16`` 16-bit unsigned attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_U16``”h]”jÁ)�”}”(hjÆh]”hŒNL_ATTR_TYPE_U16”…”�”}”(hjÈh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÄubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M%hjÀubj´)�”}”(hhh]”hÞ)�”}”(hŒ16-bit unsigned attribute”h]”hŒ16-bit unsigned attribute”…”�”}”(hjßh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jÛh´M%hjÜubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÀubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jÛh´M%hjubj”)�”}”(hŒ/``NL_ATTR_TYPE_U32`` 32-bit unsigned attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_U32``”h]”jÁ)�”}”(hjÿh]”hŒNL_ATTR_TYPE_U32”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjýubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M(hjùubj´)�”}”(hhh]”hÞ)�”}”(hŒ32-bit unsigned attribute”h]”hŒ32-bit unsigned attribute”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jh´M(hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjùubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jh´M(hjubj”)�”}”(hŒ/``NL_ATTR_TYPE_U64`` 64-bit unsigned attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_U64``”h]”jÁ)�”}”(hj8h]”hŒNL_ATTR_TYPE_U64”…”�”}”(hj:h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj6ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M+hj2ubj´)�”}”(hhh]”hÞ)�”}”(hŒ64-bit unsigned attribute”h]”hŒ64-bit unsigned attribute”…”�”}”(hjQh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jMh´M+hjNubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj2ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jMh´M+hjubj”)�”}”(hŒ+``NL_ATTR_TYPE_S8`` 8-bit signed attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_S8``”h]”jÁ)�”}”(hjqh]”hŒNL_ATTR_TYPE_S8”…”�”}”(hjsh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjoubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M.hjkubj´)�”}”(hhh]”hÞ)�”}”(hŒ8-bit signed attribute”h]”hŒ8-bit signed attribute”…”�”}”(hjŠh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j†h´M.hj‡ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjkubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j†h´M.hjubj”)�”}”(hŒ-``NL_ATTR_TYPE_S16`` 16-bit signed attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_S16``”h]”jÁ)�”}”(hjªh]”hŒNL_ATTR_TYPE_S16”…”�”}”(hj¬h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj¨ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M1hj¤ubj´)�”}”(hhh]”hÞ)�”}”(hŒ16-bit signed attribute”h]”hŒ16-bit signed attribute”…”�”}”(hjÃh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j¿h´M1hjÀubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj¤ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j¿h´M1hjubj”)�”}”(hŒ-``NL_ATTR_TYPE_S32`` 32-bit signed attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_S32``”h]”jÁ)�”}”(hjãh]”hŒNL_ATTR_TYPE_S32”…”�”}”(hjåh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjáubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M4hjÝubj´)�”}”(hhh]”hÞ)�”}”(hŒ32-bit signed attribute”h]”hŒ32-bit signed attribute”…”�”}”(hjüh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jøh´M4hjùubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÝubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jøh´M4hjubj”)�”}”(hŒ-``NL_ATTR_TYPE_S64`` 64-bit signed attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_S64``”h]”jÁ)�”}”(hjh]”hŒNL_ATTR_TYPE_S64”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M7hjubj´)�”}”(hhh]”hÞ)�”}”(hŒ64-bit signed attribute”h]”hŒ64-bit signed attribute”…”�”}”(hj5h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j1h´M7hj2ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j1h´M7hjubj”)�”}”(hŒE``NL_ATTR_TYPE_BINARY`` binary data, min/max length may be specified ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_BINARY``”h]”jÁ)�”}”(hjUh]”hŒNL_ATTR_TYPE_BINARY”…”�”}”(hjWh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjSubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M:hjOubj´)�”}”(hhh]”hÞ)�”}”(hŒ,binary data, min/max length may be specified”h]”hŒ,binary data, min/max length may be specified”…”�”}”(hjnh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jjh´M:hjkubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjOubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jjh´M:hjubj”)�”}”(hŒ@``NL_ATTR_TYPE_STRING`` string, min/max length may be specified ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_STRING``”h]”jÁ)�”}”(hjŽh]”hŒNL_ATTR_TYPE_STRING”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjŒubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M=hjˆubj´)�”}”(hhh]”hÞ)�”}”(hŒ'string, min/max length may be specified”h]”hŒ'string, min/max length may be specified”…”�”}”(hj§h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j£h´M=hj¤ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjˆubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j£h´M=hjubj”)�”}”(hŒS``NL_ATTR_TYPE_NUL_STRING`` NUL-terminated string, min/max length may be specified ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_NUL_STRING``”h]”jÁ)�”}”(hjÇh]”hŒNL_ATTR_TYPE_NUL_STRING”…”�”}”(hjÉh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÅubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MAhjÁubj´)�”}”(hhh]”hÞ)�”}”(hŒ6NUL-terminated string, min/max length may be specified”h]”hŒ6NUL-terminated string, min/max length may be specified”…”�”}”(hjàh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M@hjÝubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÁubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jÜh´MAhjubj”)�”}”(hŒ–``NL_ATTR_TYPE_NESTED`` nested, i.e. the content of this attribute consists of sub-attributes. The nested policy and maxtype inside may be specified. ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_NESTED``”h]”jÁ)�”}”(hjh]”hŒNL_ATTR_TYPE_NESTED”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÿubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MFhjûubj´)�”}”(hhh]”hÞ)�”}”(hŒ}nested, i.e. the content of this attribute consists of sub-attributes. The nested policy and maxtype inside may be specified.”h]”hŒ}nested, i.e. the content of this attribute consists of sub-attributes. The nested policy and maxtype inside may be specified.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MDhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjûubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jh´MFhjubj”)�”}”(hX*``NL_ATTR_TYPE_NESTED_ARRAY`` nested array, i.e. the content of this attribute contains sub-attributes whose type is irrelevant (just used to separate the array entries) and each such array entry has attributes again, the policy for those inner ones and the corresponding maxtype may be specified. ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_NESTED_ARRAY``”h]”jÁ)�”}”(hj;h]”hŒNL_ATTR_TYPE_NESTED_ARRAY”…”�”}”(hj=h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj9ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MMhj5ubj´)�”}”(hhh]”hÞ)�”}”(hX nested array, i.e. the content of this attribute contains sub-attributes whose type is irrelevant (just used to separate the array entries) and each such array entry has attributes again, the policy for those inner ones and the corresponding maxtype may be specified.”h]”hX nested array, i.e. the content of this attribute contains sub-attributes whose type is irrelevant (just used to separate the array entries) and each such array entry has attributes again, the policy for those inner ones and the corresponding maxtype may be specified.”…”�”}”(hjTh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MIhjQubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj5ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jPh´MMhjubj”)�”}”(hŒW``NL_ATTR_TYPE_BITFIELD32`` :c:type:`struct nla_bitfield32 ` attribute ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_BITFIELD32``”h]”jÁ)�”}”(hjuh]”hŒNL_ATTR_TYPE_BITFIELD32”…”�”}”(hjwh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjsubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MPhjoubj´)�”}”(hhh]”hÞ)�”}”(hŒ::c:type:`struct nla_bitfield32 ` attribute”h]”(h)�”}”(hŒ0:c:type:`struct nla_bitfield32 `”h]”jÁ)�”}”(hj”h]”hŒstruct nla_bitfield32”…”�”}”(hj–h²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-type”eh"]”h$]”h&]”uh1jÀhj’ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œtype”Œ refexplicit”ˆŒrefwarn”‰Œ c:parent_key”Œsphinx.domains.c”Œ LookupKey”“”)�”}”Œdata”]”sbj†Œnla_bitfield32”uh1hh³jŠh´MPhjŽubhŒ attribute”…”�”}”(hjŽh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jŠh´MPhj‹ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjoubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jŠh´MPhjubj”)�”}”(hŒG``NL_ATTR_TYPE_SINT`` 32-bit or 64-bit signed attribute, aligned to 4B ”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_SINT``”h]”jÁ)�”}”(hjÕh]”hŒNL_ATTR_TYPE_SINT”…”�”}”(hj×h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÓubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MShjÏubj´)�”}”(hhh]”hÞ)�”}”(hŒ032-bit or 64-bit signed attribute, aligned to 4B”h]”hŒ032-bit or 64-bit signed attribute, aligned to 4B”…”�”}”(hjîh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jêh´MShjëubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjÏubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jêh´MShjubj”)�”}”(hŒH``NL_ATTR_TYPE_UINT`` 32-bit or 64-bit unsigned attribute, aligned to 4B”h]”(jš)�”}”(hŒ``NL_ATTR_TYPE_UINT``”h]”jÁ)�”}”(hjh]”hŒNL_ATTR_TYPE_UINT”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MUhjubj´)�”}”(hhh]”hÞ)�”}”(hŒ232-bit or 64-bit unsigned attribute, aligned to 4B”h]”hŒ232-bit or 64-bit unsigned attribute, aligned to 4B”…”�”}”(hj'h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MVhj$ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j#h´MUhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjöubeh}”(h]”h ]”Œ kernelindent”ah"]”h$]”h&]”uh1jDhj•h²hh³Nh´Nubj§)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œentries”]”(j³Œ!netlink_policy_type_attr (C enum)”Œc.netlink_policy_type_attr”hNt”auh1j¦hj•h²hh³Nh´Nubj¸)�”}”(hhh]”(j½)�”}”(hŒnetlink_policy_type_attr”h]”jÃ)�”}”(hŒenum netlink_policy_type_attr”h]”(jÉ)�”}”(hjßh]”hŒenum”…”�”}”(hjhh²hh³Nh´Nubah}”(h]”h ]”jÕah"]”h$]”h&]”uh1jÈhjdh²hh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M[ubjÛ)�”}”(hŒ ”h]”hŒ ”…”�”}”(hjvh²hh³Nh´Nubah}”(h]”h ]”jçah"]”h$]”h&]”uh1jÚhjdh²hh³juh´M[ubjì)�”}”(hŒnetlink_policy_type_attr”h]”jò)�”}”(hjbh]”hŒnetlink_policy_type_attr”…”�”}”(hjˆh²hh³Nh´Nubah}”(h]”h ]”jýah"]”h$]”h&]”uh1jñhj„ubah}”(h]”h ]”(jjeh"]”h$]”h&]”hÅhÆuh1jëhjdh²hh³juh´M[ubeh}”(h]”h ]”h"]”h$]”h&]”hÅhÆjˆuh1jÂjjhj`h²hh³juh´M[ubah}”(h]”j[ah ]”(jjeh"]”h$]”h&]”jˆj)jhuh1j¼h³juh´M[hj]h²hubj)�”}”(hhh]”hÞ)�”}”(hŒpolicy type attributes”h]”hŒpolicy type attributes”…”�”}”(hjªh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MMhj§h²hubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj]h²hh³juh´M[ubeh}”(h]”h ]”(j:Œenum”eh"]”h$]”h&]”j>j:j?jÂj@jÂjA‰jB‰jC‰uh1j·h²hhj•h³Nh´NubjE)�”}”(hX`**Constants** ``NL_POLICY_TYPE_ATTR_UNSPEC`` unused ``NL_POLICY_TYPE_ATTR_TYPE`` type of the attribute, :c:type:`enum netlink_attribute_type ` (U32) ``NL_POLICY_TYPE_ATTR_MIN_VALUE_S`` minimum value for signed integers (S64) ``NL_POLICY_TYPE_ATTR_MAX_VALUE_S`` maximum value for signed integers (S64) ``NL_POLICY_TYPE_ATTR_MIN_VALUE_U`` minimum value for unsigned integers (U64) ``NL_POLICY_TYPE_ATTR_MAX_VALUE_U`` maximum value for unsigned integers (U64) ``NL_POLICY_TYPE_ATTR_MIN_LENGTH`` minimum length for binary attributes, no minimum if not given (U32) ``NL_POLICY_TYPE_ATTR_MAX_LENGTH`` maximum length for binary attributes, no maximum if not given (U32) ``NL_POLICY_TYPE_ATTR_POLICY_IDX`` sub policy for nested and nested array types (U32) ``NL_POLICY_TYPE_ATTR_POLICY_MAXTYPE`` maximum sub policy attribute for nested and nested array types, this can in theory be < the size of the policy pointed to by the index, if limited inside the nesting (U32) ``NL_POLICY_TYPE_ATTR_BITFIELD32_MASK`` valid mask for the bitfield32 type (U32) ``NL_POLICY_TYPE_ATTR_PAD`` pad attribute for 64-bit alignment ``NL_POLICY_TYPE_ATTR_MASK`` mask of valid bits for unsigned integers (U64) ``__NL_POLICY_TYPE_ATTR_MAX`` number of attributes ``NL_POLICY_TYPE_ATTR_MAX`` highest attribute number”•BEh]”(hÞ)�”}”(hŒ **Constants**”h]”j­)�”}”(hjÌh]”hŒ Constants”…”�”}”(hjÎh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¬hjÊubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MQhjÆubj�)�”}”(hhh]”(j”)�”}”(hŒ&``NL_POLICY_TYPE_ATTR_UNSPEC`` unused ”h]”(jš)�”}”(hŒ``NL_POLICY_TYPE_ATTR_UNSPEC``”h]”jÁ)�”}”(hjëh]”hŒNL_POLICY_TYPE_ATTR_UNSPEC”…”�”}”(hjíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjéubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MThjåubj´)�”}”(hhh]”hÞ)�”}”(hŒunused”h]”hŒunused”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jh´MThjubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjåubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jh´MThjâubj”)�”}”(hŒy``NL_POLICY_TYPE_ATTR_TYPE`` type of the attribute, :c:type:`enum netlink_attribute_type ` (U32) ”h]”(jš)�”}”(hŒ``NL_POLICY_TYPE_ATTR_TYPE``”h]”jÁ)�”}”(hj$h]”hŒNL_POLICY_TYPE_ATTR_TYPE”…”�”}”(hj&h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj"ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MXhjubj´)�”}”(hhh]”hÞ)�”}”(hŒ[type of the attribute, :c:type:`enum netlink_attribute_type ` (U32)”h]”(hŒtype of the attribute, ”…”�”}”(hj=h²hh³Nh´Nubh)�”}”(hŒ>:c:type:`enum netlink_attribute_type `”h]”jÁ)�”}”(hjGh]”hŒenum netlink_attribute_type”…”�”}”(hjIh²hh³Nh´Nubah}”(h]”h ]”(jtj:Œc-type”eh"]”h$]”h&]”uh1jÀhjEubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j€Œ refdomain”j:Œreftype”Œtype”Œ refexplicit”ˆŒrefwarn”‰j°j´j†Œnetlink_attribute_type”uh1hh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MWhj=ubhŒ (U32)”…”�”}”(hj=h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jdh´MWhj:ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j9h´MXhjâubj”)�”}”(hŒL``NL_POLICY_TYPE_ATTR_MIN_VALUE_S`` minimum value for signed integers (S64) ”h]”(jš)�”}”(hŒ#``NL_POLICY_TYPE_ATTR_MIN_VALUE_S``”h]”jÁ)�”}”(hj�h]”hŒNL_POLICY_TYPE_ATTR_MIN_VALUE_S”…”�”}”(hjƒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M\hj{ubj´)�”}”(hhh]”hÞ)�”}”(hŒ'minimum value for signed integers (S64)”h]”hŒ'minimum value for signed integers (S64)”…”�”}”(hjšh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M[hj—ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj{ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j–h´M\hjâubj”)�”}”(hŒL``NL_POLICY_TYPE_ATTR_MAX_VALUE_S`` maximum value for signed integers (S64) ”h]”(jš)�”}”(hŒ#``NL_POLICY_TYPE_ATTR_MAX_VALUE_S``”h]”jÁ)�”}”(hj»h]”hŒNL_POLICY_TYPE_ATTR_MAX_VALUE_S”…”�”}”(hj½h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj¹ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M`hjµubj´)�”}”(hhh]”hÞ)�”}”(hŒ'maximum value for signed integers (S64)”h]”hŒ'maximum value for signed integers (S64)”…”�”}”(hjÔh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M_hjÑubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjµubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jÐh´M`hjâubj”)�”}”(hŒN``NL_POLICY_TYPE_ATTR_MIN_VALUE_U`` minimum value for unsigned integers (U64) ”h]”(jš)�”}”(hŒ#``NL_POLICY_TYPE_ATTR_MIN_VALUE_U``”h]”jÁ)�”}”(hjõh]”hŒNL_POLICY_TYPE_ATTR_MIN_VALUE_U”…”�”}”(hj÷h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjóubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mdhjïubj´)�”}”(hhh]”hÞ)�”}”(hŒ)minimum value for unsigned integers (U64)”h]”hŒ)minimum value for unsigned integers (U64)”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mchj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjïubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j h´Mdhjâubj”)�”}”(hŒN``NL_POLICY_TYPE_ATTR_MAX_VALUE_U`` maximum value for unsigned integers (U64) ”h]”(jš)�”}”(hŒ#``NL_POLICY_TYPE_ATTR_MAX_VALUE_U``”h]”jÁ)�”}”(hj/ h]”hŒNL_POLICY_TYPE_ATTR_MAX_VALUE_U”…”�”}”(hj1 h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj- ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mhhj) ubj´)�”}”(hhh]”hÞ)�”}”(hŒ)maximum value for unsigned integers (U64)”h]”hŒ)maximum value for unsigned integers (U64)”…”�”}”(hjH h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MghjE ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj) ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jD h´Mhhjâubj”)�”}”(hŒg``NL_POLICY_TYPE_ATTR_MIN_LENGTH`` minimum length for binary attributes, no minimum if not given (U32) ”h]”(jš)�”}”(hŒ"``NL_POLICY_TYPE_ATTR_MIN_LENGTH``”h]”jÁ)�”}”(hji h]”hŒNL_POLICY_TYPE_ATTR_MIN_LENGTH”…”�”}”(hjk h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjg ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mlhjc ubj´)�”}”(hhh]”hÞ)�”}”(hŒCminimum length for binary attributes, no minimum if not given (U32)”h]”hŒCminimum length for binary attributes, no minimum if not given (U32)”…”�”}”(hj‚ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mkhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjc ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j~ h´Mlhjâubj”)�”}”(hŒg``NL_POLICY_TYPE_ATTR_MAX_LENGTH`` maximum length for binary attributes, no maximum if not given (U32) ”h]”(jš)�”}”(hŒ"``NL_POLICY_TYPE_ATTR_MAX_LENGTH``”h]”jÁ)�”}”(hj£ h]”hŒNL_POLICY_TYPE_ATTR_MAX_LENGTH”…”�”}”(hj¥ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj¡ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mphj� ubj´)�”}”(hhh]”hÞ)�”}”(hŒCmaximum length for binary attributes, no maximum if not given (U32)”h]”hŒCmaximum length for binary attributes, no maximum if not given (U32)”…”�”}”(hj¼ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mohj¹ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj� ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j¸ h´Mphjâubj”)�”}”(hŒV``NL_POLICY_TYPE_ATTR_POLICY_IDX`` sub policy for nested and nested array types (U32) ”h]”(jš)�”}”(hŒ"``NL_POLICY_TYPE_ATTR_POLICY_IDX``”h]”jÁ)�”}”(hjÝ h]”hŒNL_POLICY_TYPE_ATTR_POLICY_IDX”…”�”}”(hjß h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÛ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mthj× ubj´)�”}”(hhh]”hÞ)�”}”(hŒ2sub policy for nested and nested array types (U32)”h]”hŒ2sub policy for nested and nested array types (U32)”…”�”}”(hjö h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mshjó ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj× ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jò h´Mthjâubj”)�”}”(hŒÓ``NL_POLICY_TYPE_ATTR_POLICY_MAXTYPE`` maximum sub policy attribute for nested and nested array types, this can in theory be < the size of the policy pointed to by the index, if limited inside the nesting (U32) ”h]”(jš)�”}”(hŒ&``NL_POLICY_TYPE_ATTR_POLICY_MAXTYPE``”h]”jÁ)�”}”(hj!h]”hŒ"NL_POLICY_TYPE_ATTR_POLICY_MAXTYPE”…”�”}”(hj!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mzhj!ubj´)�”}”(hhh]”hÞ)�”}”(hŒ«maximum sub policy attribute for nested and nested array types, this can in theory be < the size of the policy pointed to by the index, if limited inside the nesting (U32)”h]”hŒ«maximum sub policy attribute for nested and nested array types, this can in theory be < the size of the policy pointed to by the index, if limited inside the nesting (U32)”…”�”}”(hj0!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´Mwhj-!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj!ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j,!h´Mzhjâubj”)�”}”(hŒQ``NL_POLICY_TYPE_ATTR_BITFIELD32_MASK`` valid mask for the bitfield32 type (U32) ”h]”(jš)�”}”(hŒ'``NL_POLICY_TYPE_ATTR_BITFIELD32_MASK``”h]”jÁ)�”}”(hjQ!h]”hŒ#NL_POLICY_TYPE_ATTR_BITFIELD32_MASK”…”�”}”(hjS!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjO!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M~hjK!ubj´)�”}”(hhh]”hÞ)�”}”(hŒ(valid mask for the bitfield32 type (U32)”h]”hŒ(valid mask for the bitfield32 type (U32)”…”�”}”(hjj!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M}hjg!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hjK!ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jf!h´M~hjâubj”)�”}”(hŒ?``NL_POLICY_TYPE_ATTR_PAD`` pad attribute for 64-bit alignment ”h]”(jš)�”}”(hŒ``NL_POLICY_TYPE_ATTR_PAD``”h]”jÁ)�”}”(hj‹!h]”hŒNL_POLICY_TYPE_ATTR_PAD”…”�”}”(hj�!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj‰!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M�hj…!ubj´)�”}”(hhh]”hÞ)�”}”(hŒ"pad attribute for 64-bit alignment”h]”hŒ"pad attribute for 64-bit alignment”…”�”}”(hj¤!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j !h´M�hj¡!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj…!ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j !h´M�hjâubj”)�”}”(hŒL``NL_POLICY_TYPE_ATTR_MASK`` mask of valid bits for unsigned integers (U64) ”h]”(jš)�”}”(hŒ``NL_POLICY_TYPE_ATTR_MASK``”h]”jÁ)�”}”(hjÄ!h]”hŒNL_POLICY_TYPE_ATTR_MASK”…”�”}”(hjÆ!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjÂ!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M„hj¾!ubj´)�”}”(hhh]”hÞ)�”}”(hŒ.mask of valid bits for unsigned integers (U64)”h]”hŒ.mask of valid bits for unsigned integers (U64)”…”�”}”(hjÝ!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³jÙ!h´M„hjÚ!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj¾!ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jÙ!h´M„hjâubj”)�”}”(hŒ3``__NL_POLICY_TYPE_ATTR_MAX`` number of attributes ”h]”(jš)�”}”(hŒ``__NL_POLICY_TYPE_ATTR_MAX``”h]”jÁ)�”}”(hjý!h]”hŒ__NL_POLICY_TYPE_ATTR_MAX”…”�”}”(hjÿ!h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhjû!ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M‡hj÷!ubj´)�”}”(hhh]”hÞ)�”}”(hŒnumber of attributes”h]”hŒnumber of attributes”…”�”}”(hj"h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³j"h´M‡hj"ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj÷!ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³j"h´M‡hjâubj”)�”}”(hŒ4``NL_POLICY_TYPE_ATTR_MAX`` highest attribute number”h]”(jš)�”}”(hŒ``NL_POLICY_TYPE_ATTR_MAX``”h]”jÁ)�”}”(hj6"h]”hŒNL_POLICY_TYPE_ATTR_MAX”…”�”}”(hj8"h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÀhj4"ubah}”(h]”h ]”h"]”h$]”h&]”uh1j™h³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´M‰hj0"ubj´)�”}”(hhh]”hÞ)�”}”(hŒhighest attribute number”h]”hŒhighest attribute number”…”�”}”(hjO"h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³Œi/var/lib/git/docbuild/linux/Documentation/userspace-api/netlink/intro:687: ./include/uapi/linux/netlink.h”h´MŠhjL"ubah}”(h]”h ]”h"]”h$]”h&]”uh1j³hj0"ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j“h³jK"h´M‰hjâubeh}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjÆubeh}”(h]”h ]”Œ kernelindent”ah"]”h$]”h&]”uh1jDhj•h²hh³Nh´Nubeh}”(h]”Œuapi-reference”ah ]”h"]”Œuapi reference”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´M­ubeh}”(h]”Œintroduction-to-netlink”ah ]”h"]”Œintroduction to netlink”ah$]”h&]”uh1hÈhhh²hh³hÇh´Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”hÇuh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)�”}”(hÍNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”jª"Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”hÇŒ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”(jž]”j“aj³]”j©ajË ]”jÁ ajî ]”jä aj>]”j4auŒnameids”}”(j„"j�"jjj jj j jºjžj¹j¶jÒ j³jÑ jÎ j jË j j jLjIj~ j{ jô jñ j™ jî jÒjÏjDjAj�j>j�jŒjSjPjèjåjjjRjOjj jRjOj‡j„j|"jy"uŒ nametypes”}”(j„"‰j‰j ‰j ‰jºˆj¹‰jÒ ˆjÑ ‰j ˆj ‰jL‰j~ ‰jô ‰j™ ˆjÒ‰jD‰j�ˆj�‰jS‰jè‰j‰jR‰j‰jR‰j‡‰j|"‰uh}”(j�"hÊjj jj“j jjžjŸj¶jŸj³jÁjÎ jÁjË j× j j× jIj j{ j( jñ j� jî j÷ j– j÷ jÏj  jAjÕj>jOjŒjOjPjŽjåjVjjëjOj j jUjOjj„jUjy"j•jµj¾jÐjÕj‹j�j[j`uŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”j¸"Ks…”R”Œparse_messages”]”hŒsystem_message”“”)�”}”(hhh]”hÞ)�”}”(hŒ,Duplicate implicit target name: "nlmsg_pid".”h]”hŒ0Duplicate implicit target name: “nlmsg_pidâ€�.”…”�”}”(hj#h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝhj#ubah}”(h]”h ]”h"]”h$]”h&]”j– aŒlevel”KŒtype”ŒINFO”Œsource”hÇŒline”M¡uh1j#hj÷ h²hh³hÇh´M¡ubaŒtransform_messages”]”(j#)�”}”(hhh]”hÞ)�”}”(hhh]”hŒ1Hyperlink target "nl-msg-type" is not referenced.”…”�”}”hj4#sbah}”(h]”h ]”h"]”h$]”h&]”uh1hÝhj1#ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”j,#Œsource”hÇŒline”K«uh1j#ubj#)�”}”(hhh]”hÞ)�”}”(hhh]”hŒ-Hyperlink target "res-fam" is not referenced.”…”�”}”hjN#sbah}”(h]”h ]”h"]”h$]”h&]”uh1hÝhjK#ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”j,#Œsource”hÇŒline”Kñuh1j#ubj#)�”}”(hhh]”hÞ)�”}”(hhh]”hŒ-Hyperlink target "ext-ack" is not referenced.”…”�”}”hjh#sbah}”(h]”h ]”h"]”h$]”h&]”uh1hÝhje#ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”j,#Œsource”hÇŒline”Mcuh1j#ubj#)�”}”(hhh]”hÞ)�”}”(hhh]”hŒ/Hyperlink target "nlmsg-pid" is not referenced.”…”�”}”hj‚#sbah}”(h]”h ]”h"]”h$]”h&]”uh1hÝhj#ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”j,#Œsource”hÇŒline”Mžuh1j#ubj#)�”}”(hhh]”hÞ)�”}”(hhh]”hŒ5Hyperlink target "classic-netlink" is not referenced.”…”�”}”hjœ#sbah}”(h]”h ]”h"]”h$]”h&]”uh1hÝhj™#ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”j,#Œsource”hÇŒline”Muh1j#ubeŒ transformer”NŒ include_log”]”Œ decoration”Nh²hub.