diff options
author | Khem Raj <raj.khem@gmail.com> | 2015-12-17 07:06:42 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-01-24 09:40:32 +0000 |
commit | a9dfcedd21a5fe212d237633f40e2efcdfb34690 (patch) | |
tree | 5f4e861edc8930ca6d11da03e5abd7856be0638e /meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch | |
parent | 3cffa6da39b88d845208cd0d7f5186b247067d6c (diff) | |
download | poky-a9dfcedd21a5fe212d237633f40e2efcdfb34690.tar.gz |
linux-libc-headers: Port patches for linux-headers for musl
These patches have revealed issues with linux kernel headers which has
been proposed upstream but hasnt been applied yet
(From OE-Core rev: 8d760bd9df101a03f148205e7d79b555b4dfd8c7)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch')
-rw-r--r-- | meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch | 89 |
1 files changed, 89 insertions, 0 deletions
diff --git a/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch b/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch new file mode 100644 index 0000000000..6ad479863e --- /dev/null +++ b/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch | |||
@@ -0,0 +1,89 @@ | |||
1 | From 2872f5d8bcef84e62b15b37ba4ffeccfb6402dad Mon Sep 17 00:00:00 2001 | ||
2 | From: rofl0r <retnyg@gmx.net> | ||
3 | Date: Wed, 22 Jan 2014 00:48:28 +0100 | ||
4 | Subject: [PATCH 1/3] libc-compat.h: fix some issues arising from in6.h | ||
5 | |||
6 | namely redefinition of some structs provided by netinet/in.h. | ||
7 | --- | ||
8 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
9 | Upstream-Status: Submitted | ||
10 | |||
11 | include/uapi/linux/libc-compat.h | 25 ++++++++----------------- | ||
12 | 1 file changed, 8 insertions(+), 17 deletions(-) | ||
13 | |||
14 | Index: linux-4.4/include/uapi/linux/libc-compat.h | ||
15 | =================================================================== | ||
16 | --- linux-4.4.orig/include/uapi/linux/libc-compat.h | ||
17 | +++ linux-4.4/include/uapi/linux/libc-compat.h | ||
18 | @@ -48,13 +48,12 @@ | ||
19 | #ifndef _UAPI_LIBC_COMPAT_H | ||
20 | #define _UAPI_LIBC_COMPAT_H | ||
21 | |||
22 | -/* We have included glibc headers... */ | ||
23 | -#if defined(__GLIBC__) | ||
24 | +#ifndef __KERNEL__ /* we're used from userspace */ | ||
25 | |||
26 | -/* Coordinate with glibc netinet/in.h header. */ | ||
27 | +/* Coordinate with libc netinet/in.h header. */ | ||
28 | #if defined(_NETINET_IN_H) | ||
29 | |||
30 | -/* GLIBC headers included first so don't define anything | ||
31 | +/* LIBC headers included first so don't define anything | ||
32 | * that would already be defined. */ | ||
33 | #define __UAPI_DEF_IN_ADDR 0 | ||
34 | #define __UAPI_DEF_IN_IPPROTO 0 | ||
35 | @@ -64,15 +63,7 @@ | ||
36 | #define __UAPI_DEF_IN_CLASS 0 | ||
37 | |||
38 | #define __UAPI_DEF_IN6_ADDR 0 | ||
39 | -/* The exception is the in6_addr macros which must be defined | ||
40 | - * if the glibc code didn't define them. This guard matches | ||
41 | - * the guard in glibc/inet/netinet/in.h which defines the | ||
42 | - * additional in6_addr macros e.g. s6_addr16, and s6_addr32. */ | ||
43 | -#if defined(__USE_MISC) || defined (__USE_GNU) | ||
44 | #define __UAPI_DEF_IN6_ADDR_ALT 0 | ||
45 | -#else | ||
46 | -#define __UAPI_DEF_IN6_ADDR_ALT 1 | ||
47 | -#endif | ||
48 | #define __UAPI_DEF_SOCKADDR_IN6 0 | ||
49 | #define __UAPI_DEF_IPV6_MREQ 0 | ||
50 | #define __UAPI_DEF_IPPROTO_V6 0 | ||
51 | @@ -80,10 +71,10 @@ | ||
52 | #define __UAPI_DEF_IN6_PKTINFO 0 | ||
53 | #define __UAPI_DEF_IP6_MTUINFO 0 | ||
54 | |||
55 | -#else | ||
56 | +#else /* defined(_NETINET_IN_H) */ | ||
57 | |||
58 | /* Linux headers included first, and we must define everything | ||
59 | - * we need. The expectation is that glibc will check the | ||
60 | + * we need. The expectation is that libc will check the | ||
61 | * __UAPI_DEF_* defines and adjust appropriately. */ | ||
62 | #define __UAPI_DEF_IN_ADDR 1 | ||
63 | #define __UAPI_DEF_IN_IPPROTO 1 | ||
64 | @@ -93,7 +84,7 @@ | ||
65 | #define __UAPI_DEF_IN_CLASS 1 | ||
66 | |||
67 | #define __UAPI_DEF_IN6_ADDR 1 | ||
68 | -/* We unconditionally define the in6_addr macros and glibc must | ||
69 | +/* We unconditionally define the in6_addr macros and libc must | ||
70 | * coordinate. */ | ||
71 | #define __UAPI_DEF_IN6_ADDR_ALT 1 | ||
72 | #define __UAPI_DEF_SOCKADDR_IN6 1 | ||
73 | @@ -115,7 +106,7 @@ | ||
74 | /* If we did not see any headers from any supported C libraries, | ||
75 | * or we are being included in the kernel, then define everything | ||
76 | * that we need. */ | ||
77 | -#else /* !defined(__GLIBC__) */ | ||
78 | +#else /* __KERNEL__ */ | ||
79 | |||
80 | /* Definitions for in.h */ | ||
81 | #define __UAPI_DEF_IN_ADDR 1 | ||
82 | @@ -138,6 +129,6 @@ | ||
83 | /* Definitions for xattr.h */ | ||
84 | #define __UAPI_DEF_XATTR 1 | ||
85 | |||
86 | -#endif /* __GLIBC__ */ | ||
87 | +#endif /* __KERNEL__ */ | ||
88 | |||
89 | #endif /* _UAPI_LIBC_COMPAT_H */ | ||