aboutsummaryrefslogtreecommitdiff
path: root/libnl-tiny/nla_s8.patch
diff options
context:
space:
mode:
authorWoodpecker CI <emmett1.2miligrams@protonmail.com>2025-06-03 14:32:36 +0000
committerWoodpecker CI <emmett1.2miligrams@protonmail.com>2025-06-03 14:32:36 +0000
commit93a354611e38a6949add5c2e5ccc93ef79b9755f (patch)
tree7fee41752b1047d74c59f8ee046cd62735e7e934 /libnl-tiny/nla_s8.patch
parent35912580b66e9439f91ea441938828ad8aa33b0d (diff)
downloadalicelinux-93a354611e38a6949add5c2e5ccc93ef79b9755f.tar.gz
alicelinux-93a354611e38a6949add5c2e5ccc93ef79b9755f.zip
Woodpecker CI 5171f1fdd74e7137c305450dd69a29fa5be4143f [SKIP CI]
Diffstat (limited to 'libnl-tiny/nla_s8.patch')
-rw-r--r--libnl-tiny/nla_s8.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/libnl-tiny/nla_s8.patch b/libnl-tiny/nla_s8.patch
new file mode 100644
index 00000000..9a48b1f4
--- /dev/null
+++ b/libnl-tiny/nla_s8.patch
@@ -0,0 +1,30 @@
+diff --git a/include/netlink/attr.h b/include/netlink/attr.h
+index 3e3047f..789e8c2 100644
+--- a/include/netlink/attr.h
++++ b/include/netlink/attr.h
+@@ -45,6 +45,7 @@ enum {
+ NLA_FLAG, /**< Flag */
+ NLA_MSECS, /**< Micro seconds (64bit) */
+ NLA_NESTED, /**< Nested attributes */
++ NLA_S8,
+ __NLA_TYPE_MAX,
+ };
+
+@@ -248,6 +249,17 @@ static inline int nla_put_addr(struct nl_msg *msg, int attrtype, struct nl_addr
+ * @name Integer Attributes
+ */
+
++/**
++ * Return value of 8 bit signed integer attribute.
++ * @arg nla 8 bit integer attribute
++ *
++ * @return Payload as 8 bit integer
++ */
++static inline int8_t nla_get_s8(const struct nlattr *nla)
++{
++ return *(const int8_t *) nla_data(nla);
++}
++
+ /**
+ * Add 8 bit integer attribute to netlink message.
+ * @arg msg Netlink message.