libnl: Update to 3.2.17
PATCH 1/1 libnl: Update to 3.2.17
* fix-build-using-flex.patch: removed, it was a backported fix from 3.2.17;
* fix-callback-segfault.patch: added; it is a backport from 3.2.18 in development;
* add-missing-header.patch: added to fix build with old kernel headers.
---
.../libnl/libnl/add-missing-header.patch | 129 ++++++++++++++++++++
.../libnl/libnl/fix-build-using-flex.patch | 55 ---------
.../libnl/libnl/fix-callback-segfault.patch | 35 ++++++
.../libnl/libnl/fix-pktloc_syntax_h-race.patch | 2 +-
.../libnl/{libnl_3.2.16.bb => libnl_3.2.17.bb} | 9 +-
5 files changed, 170 insertions(+), 60 deletions(-)
create mode 100644 meta/recipes-support/libnl/libnl/add-missing-header.patch
delete mode 100644 meta/recipes-support/libnl/libnl/fix-build-using-flex.patch
create mode 100644 meta/recipes-support/libnl/libnl/fix-callback-segfault.patch
rename meta/recipes-support/libnl/{libnl_3.2.16.bb => libnl_3.2.17.bb} (85%)meta/recipes-support/libnl/libnl/add-missing-header.patch new file +129 -0
@@ -0,0 +1,129 @@ +This includes a missing header which has not been distributed by +mistake in 3.2.16 and 3.2.17 release which allow build with old +kernels. + +Upstream-Status: Submitted [http://lists.infradead.org/pipermail/libnl/2013-January/000857.html] + +Signed-off-by: Otavio Salvador <[email protected]> + +diff -Nur a/include/linux/netfilter/nf_conntrack_common.h b/include/linux/netfilter/nf_conntrack_common.h +--- a/include/linux/netfilter/nf_conntrack_common.h 1969-12-31 21:00:00.000000000 -0300 ++++ b/include/linux/netfilter/nf_conntrack_common.h 2013-01-07 17:19:21.199246084 -0200 +@@ -0,0 +1,117 @@ ++#ifndef _UAPI_NF_CONNTRACK_COMMON_H ++#define _UAPI_NF_CONNTRACK_COMMON_H ++/* Connection state tracking for netfilter. This is separated from, ++ but required by, the NAT layer; it can also be used by an iptables ++ extension. */ ++enum ip_conntrack_info { ++ /* Part of an established connection (either direction). */ ++ IP_CT_ESTABLISHED, ++ ++ /* Like NEW, but related to an existing connection, or ICMP error ++ (in either direction). */ ++ IP_CT_RELATED, ++ ++ /* Started a new connection to track (only ++ IP_CT_DIR_ORIGINAL); may be a retransmission. */ ++ IP_CT_NEW, ++ ++ /* >= this indicates reply direction */ ++ IP_CT_IS_REPLY, ++ ++ IP_CT_ESTABLISHED_REPLY = IP_CT_ESTABLISHED + IP_CT_IS_REPLY, ++ IP_CT_RELATED_REPLY = IP_CT_RELATED + IP_CT_IS_REPLY, ++ IP_CT_NEW_REPLY = IP_CT_NEW + IP_CT_IS_REPLY, ++ /* Number of distinct IP_CT types (no NEW in reply dirn). */ ++ IP_CT_NUMBER = IP_CT_IS_REPLY * 2 - 1 ++}; ++ ++/* Bitset representing status of connection. */ ++enum ip_conntrack_status { ++ /* It's an expected connection: bit 0 set. This bit never changed */ ++ IPS_EXPECTED_BIT = 0, ++ IPS_EXPECTED = (1 << IPS_EXPECTED_BIT), ++ ++ /* We've seen packets both ways: bit 1 set. Can be set, not unset. */ ++ IPS_SEEN_REPLY_BIT = 1, ++ IPS_SEEN_REPLY = (1 << IPS_SEEN_REPLY_BIT), ++ ++ /* Conntrack should never be early-expired. */ ++ IPS_ASSURED_BIT = 2, ++ IPS_ASSURED = (1 << IPS_ASSURED_BIT), ++ ++ /* Connection is confirmed: originating packet has left box */ ++ IPS_CONFIRMED_BIT = 3, ++ IPS_CONFIRMED = (1 << IPS_CONFIRMED_BIT), ++ ++ /* Connection needs src nat in orig dir. This bit never changed. */ ++ IPS_SRC_NAT_BIT = 4, ++ IPS_SRC_NAT = (1 << IPS_SRC_NAT_BIT), ++ ++ /* Connection needs dst nat in orig dir. This bit never changed. */ ++ IPS_DST_NAT_BIT = 5, ++ IPS_DST_NAT = (1 << IPS_DST_NAT_BIT), ++ ++ /* Both together. */ ++ IPS_NAT_MASK = (IPS_DST_NAT | IPS_SRC_NAT), ++ ++ /* Connection needs TCP sequence adjusted. */ ++ IPS_SEQ_ADJUST_BIT = 6, ++ IPS_SEQ_ADJUST = (1 << IPS_SEQ_ADJUST_BIT), ++ ++ /* NAT initialization bits. */ ++ IPS_SRC_NAT_DONE_BIT = 7, ++ IPS_SRC_NAT_DONE = (1 << IPS_SRC_NAT_DONE_BIT), ++ ++ IPS_DST_NAT_DONE_BIT = 8, ++ IPS_DST_NAT_DONE = (1 << IPS_DST_NAT_DONE_BIT), ++ ++ /* Both together */ ++ IPS_NAT_DONE_MASK = (IPS_DST_NAT_DONE | IPS_SRC_NAT_DONE), ++ ++ /* Connection is dying (removed from lists), can not be unset. */ ++ IPS_DYING_BIT = 9, ++ IPS_DYING = (1 << IPS_DYING_BIT), ++ ++ /* Connection has fixed timeout. */ ++ IPS_FIXED_TIMEOUT_BIT = 10, ++ IPS_FIXED_TIMEOUT = (1 << IPS_FIXED_TIMEOUT_BIT), ++ ++ /* Conntrack is a template */ ++ IPS_TEMPLATE_BIT = 11, ++ IPS_TEMPLATE = (1 << IPS_TEMPLATE_BIT), ++ ++ /* Conntrack is a fake untracked entry */ ++ IPS_UNTRACKED_BIT = 12, ++ IPS_UNTRACKED = (1 << IPS_UNTRACKED_BIT), ++ ++ /* Conntrack got a helper explicitly attached via CT target. */ ++ IPS_HELPER_BIT = 13, ++ IPS_HELPER = (1 << IPS_HELPER_BIT), ++}; ++ ++/* Connection tracking event types */ ++enum ip_conntrack_events { ++ IPCT_NEW, /* new conntrack */ ++ IPCT_RELATED, /* related conntrack */ ++ IPCT_DESTROY, /* destroyed conntrack */ ++ IPCT_REPLY, /* connection has seen two-way traffic */ ++ IPCT_ASSURED, /* connection status has changed to assured */ ++ IPCT_PROTOINFO, /* protocol information has changed */ ++ IPCT_HELPER, /* new helper has been set */ ++ IPCT_MARK, /* new mark has been set */ ++ IPCT_NATSEQADJ, /* NAT is doing sequence adjustment */ ++ IPCT_SECMARK, /* new security mark has been set */ ++}; ++ ++enum ip_conntrack_expect_events { ++ IPEXP_NEW, /* new expectation */ ++ IPEXP_DESTROY, /* destroyed expectation */ ++}; ++ ++/* expectation flags */ ++#define NF_CT_EXPECT_PERMANENT 0x1 ++#define NF_CT_EXPECT_INACTIVE 0x2 ++#define NF_CT_EXPECT_USERSPACE 0x4 ++ ++ ++#endif /* _UAPI_NF_CONNTRACK_COMMON_H */
meta/recipes-support/libnl/libnl/fix-build-using-flex.patch deleted +0 -55
55 lines not on this page · raw message
meta/recipes-support/libnl/libnl/fix-callback-segfault.patch new file +35 -0
@@ -0,0 +1,35 @@ +From ba38f3919835c39d7bc1e939ef3ca89cfe31600d Mon Sep 17 00:00:00 2001 +From: "[email protected]" <[email protected]> +Date: Sun, 6 Jan 2013 07:07:02 +0200 +Subject: [PATCH] cache: make sure the user has specified a callback + +In cache_include(), the user callback is used even though one might not +have been specified, leading to a crash. This happens, for example, when +NetworkManager calls nl_cache_include() with the change_cb argument set +to NULL. Fix it by making sure the callback points to a valid address. + +Upstream-Status: Backport [3.2.18] + +Signed-off-by: Mihai Dontu <[email protected]> +Signed-off-by: Thomas Graf <[email protected]> +--- + lib/cache.c | 3 ++- + 1 files changed, 2 insertions(+), 1 deletions(-) + +diff --git a/lib/cache.c b/lib/cache.c +index 883aa51..42c0b5e 100644 +--- a/lib/cache.c ++++ b/lib/cache.c +@@ -752,7 +752,8 @@ static int cache_include(struct nl_cache *cache, struct nl_object *obj, + * Handle them first. + */ + if (nl_object_update(old, obj) == 0) { +- cb(cache, old, NL_ACT_CHANGE, data); ++ if (cb) ++ cb(cache, old, NL_ACT_CHANGE, data); + nl_object_put(old); + return 0; + } +-- +1.7.7.6 +
meta/recipes-support/libnl/libnl/fix-pktloc_syntax_h-race.patch +1 -1
@@ -17,7 +17,7 @@ Index: libnl-3.2.14/lib/Makefile.am +route/pktloc.lo: route/pktloc_syntax.h route/pktloc_grammar.h +route/pktloc_grammar.h: route/pktloc_grammar.c route/pktloc_grammar.c: route/pktloc_grammar.l - $(AM_V_GEN) $(LEX) --header-file=route/pktloc_grammar.h $(LFLAGS) -o $@ $^ + $(AM_V_GEN) $(FLEX) --header-file=route/pktloc_grammar.h $(LFLAGS) -o $@ $^ +route/pktloc_syntax.h: route/pktloc_syntax.c route/pktloc_syntax.c: route/pktloc_syntax.y
meta/recipes-support/libnl/libnl_3.2.17.bb renamed from meta/recipes-support/libnl/libnl_3.2.16.bb +5 -4
@@ -3,7 +3,7 @@ HOMEPAGE = "http://www.infradead.org/~tgr/libnl/" SECTION = "libs/network" PE = "1" -PR = "r1" +PR = "r0" LICENSE = "LGPLv2.1" LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
@@ -12,11 +12,12 @@ DEPENDS = "flex-native bison-native" SRC_URI = "http://www.infradead.org/~tgr/${BPN}/files/${BP}.tar.gz \ file://fix-pktloc_syntax_h-race.patch \ - file://fix-build-using-flex.patch \ + file://add-missing-header.patch \ + file://fix-callback-segfault.patch \ file://fix-pc-file.patch " -SRC_URI[md5sum] = "f06e6de102abb2cef71ed671957ee099" -SRC_URI[sha256sum] = "c43a42336c6a3cf559f390e202f8f029d165bd767da7cf7a32a815c570b31826" +SRC_URI[md5sum] = "2e57ef6ced666b0288a8a205b9a0ad00" +SRC_URI[sha256sum] = "000a721b6fbfd22190d668a487dfe5945cd1a903b326ac8570a6f20f2466d002" inherit autotools pkgconfig
Signature · 1 line
1.7.10.4
Quoted 9 lines · Otavio Salvador
* fix-build-using-flex.patch: removed, it was a backported fix from 3.2.17;
* fix-callback-segfault.patch: added; it is a backport from 3.2.18 in development;
* add-missing-header.patch: added to fix build with old kernel headers.
Signed-off-by Otavio Salvador <[email protected]>
Please ignore this patch as upstream has release 3.2.18 with thouse fixes. I am going to send a new patch very soon.
--
Otavio Salvador O.S. Systems
E-mail: [email protected] http://www.ossystems.com.br
Mobile: +55 53 9981-7854 http://projetos.ossystems.com.br