summaryrefslogtreecommitdiff
path: root/3.13
diff options
context:
space:
mode:
Diffstat (limited to '3.13')
-rw-r--r--3.13/00_all_0001-linux-stat.h-remove-__GLIBC__-checks.patch28
-rw-r--r--3.13/00_all_0002-uapi-dn-pull-in-ioctl.h-header.patch29
-rw-r--r--3.13/00_all_0003-netfilter-pull-in-limits.h.patch28
-rw-r--r--3.13/00_all_0004-convert-PAGE_SIZE-usage.patch54
-rw-r--r--3.13/00_all_0005-asm-generic-fcntl.h-namespace-kernel-file-structs.patch54
-rw-r--r--3.13/00_all_0006-unifdef-drop-unused-errno.h-include.patch32
-rw-r--r--3.13/00_all_0007-x86-make-stat-statfs-64-bit-for-x86_64-kernels.patch83
-rw-r--r--3.13/00_all_0008-uapi-convert-u64-to-__u64-in-exported-headers.patch43
-rw-r--r--3.13/00_all_0009-uapi-netfilter_arp-use-__u8-instead-of-u_int8_t.patch29
-rw-r--r--3.13/00_all_0010-uapi-ppp-ioctl.h-pull-in-ppp_defs.h.patch32
10 files changed, 412 insertions, 0 deletions
diff --git a/3.13/00_all_0001-linux-stat.h-remove-__GLIBC__-checks.patch b/3.13/00_all_0001-linux-stat.h-remove-__GLIBC__-checks.patch
new file mode 100644
index 0000000..e1d1f03
--- /dev/null
+++ b/3.13/00_all_0001-linux-stat.h-remove-__GLIBC__-checks.patch
@@ -0,0 +1,28 @@
+From 7b27049ffbc8c6ae398cd2096b1f5d565b49104a Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Mon, 29 Dec 2008 06:52:59 -0500
+Subject: [PATCH 01/10] linux/stat.h: remove __GLIBC__ checks
+
+Only check __KERNEL__ so we don't assume the C library is glibc.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/stat.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/uapi/linux/stat.h b/include/uapi/linux/stat.h
+index 7fec7e3..256ad24 100644
+--- a/include/uapi/linux/stat.h
++++ b/include/uapi/linux/stat.h
+@@ -2,7 +2,7 @@
+ #define _UAPI_LINUX_STAT_H
+
+
+-#if defined(__KERNEL__) || !defined(__GLIBC__) || (__GLIBC__ < 2)
++#if defined(__KERNEL__)
+
+ #define S_IFMT 00170000
+ #define S_IFSOCK 0140000
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0002-uapi-dn-pull-in-ioctl.h-header.patch b/3.13/00_all_0002-uapi-dn-pull-in-ioctl.h-header.patch
new file mode 100644
index 0000000..99fd1bf
--- /dev/null
+++ b/3.13/00_all_0002-uapi-dn-pull-in-ioctl.h-header.patch
@@ -0,0 +1,29 @@
+From 8d0275ae7c9c043c62f6b7481480e782024c9dee Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Mon, 29 Dec 2008 07:41:01 -0500
+Subject: [PATCH 02/10] uapi: dn: pull in ioctl.h header
+
+This header uses _IOW/_IOR defines but doesn't include ioctl.h for it.
+If you try to use this w/out including ioctl.h yourself, it can fail
+to build, so add the explicit include.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/dn.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/uapi/linux/dn.h b/include/uapi/linux/dn.h
+index 5fbdd3d..4295c74 100644
+--- a/include/uapi/linux/dn.h
++++ b/include/uapi/linux/dn.h
+@@ -1,6 +1,7 @@
+ #ifndef _LINUX_DN_H
+ #define _LINUX_DN_H
+
++#include <linux/ioctl.h>
+ #include <linux/types.h>
+ #include <linux/if_ether.h>
+
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0003-netfilter-pull-in-limits.h.patch b/3.13/00_all_0003-netfilter-pull-in-limits.h.patch
new file mode 100644
index 0000000..63439c1
--- /dev/null
+++ b/3.13/00_all_0003-netfilter-pull-in-limits.h.patch
@@ -0,0 +1,28 @@
+From 612f2f71194d3d87dd0bcb321671314e77d4faf6 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Sat, 9 May 2009 17:30:35 -0400
+Subject: [PATCH 03/10] netfilter: pull in limits.h
+
+A few netfilter sub-headers use INT_MAX which is in limits.h.
+
+URL: http://bugs.gentoo.org/246160
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/netfilter.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/uapi/linux/netfilter.h b/include/uapi/linux/netfilter.h
+index f7dc0eb..fcb9748 100644
+--- a/include/uapi/linux/netfilter.h
++++ b/include/uapi/linux/netfilter.h
+@@ -4,6 +4,7 @@
+ #include <linux/types.h>
+ #include <linux/compiler.h>
+ #include <linux/sysctl.h>
++#include <limits.h>
+
+
+ /* Responses from hook functions. */
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0004-convert-PAGE_SIZE-usage.patch b/3.13/00_all_0004-convert-PAGE_SIZE-usage.patch
new file mode 100644
index 0000000..e076f33
--- /dev/null
+++ b/3.13/00_all_0004-convert-PAGE_SIZE-usage.patch
@@ -0,0 +1,54 @@
+From 193986dd3340ae3f6a9447d2c3b4d9cee81087ed Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Sat, 13 Feb 2010 03:09:23 -0500
+Subject: [PATCH 04/10] convert PAGE_SIZE usage
+
+The size of a page may change at runtime or based on kernel settings, so
+a static value at compile time doesn't work. More importantly, no one
+exports PAGE_SIZE to user space anymore.
+
+URL: http://bugs.gentoo.org/301431
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/binfmts.h | 3 ++-
+ include/uapi/linux/resource.h | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/include/uapi/linux/binfmts.h b/include/uapi/linux/binfmts.h
+index 4eb5972..516bfcf 100644
+--- a/include/uapi/linux/binfmts.h
++++ b/include/uapi/linux/binfmts.h
+@@ -1,6 +1,7 @@
+ #ifndef _UAPI_LINUX_BINFMTS_H
+ #define _UAPI_LINUX_BINFMTS_H
+
++#include <unistd.h>
+ #include <linux/capability.h>
+
+ struct pt_regs;
+@@ -11,7 +12,7 @@ struct pt_regs;
+ * prevent the kernel from being unduly impacted by misaddressed pointers.
+ * MAX_ARG_STRINGS is chosen to fit in a signed 32-bit integer.
+ */
+-#define MAX_ARG_STRLEN (PAGE_SIZE * 32)
++#define MAX_ARG_STRLEN (sysconf(_SC_PAGESIZE) * 32)
+ #define MAX_ARG_STRINGS 0x7FFFFFFF
+
+ /* sizeof(linux_binprm->buf) */
+diff --git a/include/uapi/linux/resource.h b/include/uapi/linux/resource.h
+index e0ed284..db8acf3 100644
+--- a/include/uapi/linux/resource.h
++++ b/include/uapi/linux/resource.h
+@@ -68,7 +68,8 @@ struct rlimit64 {
+ * GPG2 wants 64kB of mlocked memory, to make sure pass phrases
+ * and other sensitive information are never written to disk.
+ */
+-#define MLOCK_LIMIT ((PAGE_SIZE > 64*1024) ? PAGE_SIZE : 64*1024)
++/* No one currently defines PAGE_SIZE bigger than 64kB */
++#define MLOCK_LIMIT (64 * 1024)
+
+ /*
+ * Due to binary compatibility, the actual resource numbers
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0005-asm-generic-fcntl.h-namespace-kernel-file-structs.patch b/3.13/00_all_0005-asm-generic-fcntl.h-namespace-kernel-file-structs.patch
new file mode 100644
index 0000000..08226e6
--- /dev/null
+++ b/3.13/00_all_0005-asm-generic-fcntl.h-namespace-kernel-file-structs.patch
@@ -0,0 +1,54 @@
+From 610819803c2db35f203e75d14272b04c0756ead6 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Mon, 29 Dec 2008 07:39:14 -0500
+Subject: [PATCH 05/10] asm-generic/fcntl.h: namespace kernel file structs
+
+No one should be using these structs, but just in case they are,
+keep them available in the __kernel_ namespace.
+
+Otherwise, trying to include something like:
+ #include <fcntl.h>
+ #include <linux/inotify.h>
+leads to horrible failure.
+
+URL: http://bugs.gentoo.org/244470
+URL: http://bugs.gentoo.org/388633
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/asm-generic/fcntl.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/include/uapi/asm-generic/fcntl.h b/include/uapi/asm-generic/fcntl.h
+index 95e46c8..92c2df2 100644
+--- a/include/uapi/asm-generic/fcntl.h
++++ b/include/uapi/asm-generic/fcntl.h
+@@ -136,7 +136,7 @@
+ #define F_OWNER_PID 1
+ #define F_OWNER_PGRP 2
+
+-struct f_owner_ex {
++struct __kernel_f_owner_ex {
+ int type;
+ __kernel_pid_t pid;
+ };
+@@ -176,7 +176,7 @@ struct f_owner_ex {
+ #define __ARCH_FLOCK_PAD
+ #endif
+
+-struct flock {
++struct __kernel_flock {
+ short l_type;
+ short l_whence;
+ __kernel_off_t l_start;
+@@ -193,7 +193,7 @@ struct flock {
+ #define __ARCH_FLOCK64_PAD
+ #endif
+
+-struct flock64 {
++struct __kernel_flock64 {
+ short l_type;
+ short l_whence;
+ __kernel_loff_t l_start;
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0006-unifdef-drop-unused-errno.h-include.patch b/3.13/00_all_0006-unifdef-drop-unused-errno.h-include.patch
new file mode 100644
index 0000000..f20e682
--- /dev/null
+++ b/3.13/00_all_0006-unifdef-drop-unused-errno.h-include.patch
@@ -0,0 +1,32 @@
+From 46da3e67a3d8fc565f98c535d44ab87bc4be9954 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Tue, 6 Dec 2011 17:22:42 -0500
+Subject: [PATCH 06/10] unifdef: drop unused errno.h include
+
+This is the only header on my system that ends up requiring kernel
+headers, so if the kernel headers aren't available, we end up being
+unable to install kernel headers :).
+
+Since this file doesn't actually use anything from errno.h, drop
+the include so it at least makes us a bit more robust on glibc.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ scripts/unifdef.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/scripts/unifdef.c b/scripts/unifdef.c
+index 7493c0e..c5dfae5 100644
+--- a/scripts/unifdef.c
++++ b/scripts/unifdef.c
+@@ -48,7 +48,6 @@
+
+ #include <ctype.h>
+ #include <err.h>
+-#include <errno.h>
+ #include <stdarg.h>
+ #include <stdbool.h>
+ #include <stdio.h>
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0007-x86-make-stat-statfs-64-bit-for-x86_64-kernels.patch b/3.13/00_all_0007-x86-make-stat-statfs-64-bit-for-x86_64-kernels.patch
new file mode 100644
index 0000000..7928373
--- /dev/null
+++ b/3.13/00_all_0007-x86-make-stat-statfs-64-bit-for-x86_64-kernels.patch
@@ -0,0 +1,83 @@
+From af585a67479b80336cf615fd563fcd1e56050cf2 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Mon, 25 Mar 2013 16:38:47 -0400
+Subject: [PATCH 07/10] x86: make stat/statfs 64-bit for x86_64 kernels
+
+When including these headers in the x32 ABI, the structs get declared
+with 32bit sizes which is incorrect. Use long long and such to make
+it work both with x32 and x86_64.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ arch/x86/include/uapi/asm/stat.h | 38 +++++++++++++++++++-------------------
+ arch/x86/include/uapi/asm/statfs.h | 5 +++++
+ 2 files changed, 24 insertions(+), 19 deletions(-)
+
+diff --git a/arch/x86/include/uapi/asm/stat.h b/arch/x86/include/uapi/asm/stat.h
+index 7b3ddc3..e9d6951 100644
+--- a/arch/x86/include/uapi/asm/stat.h
++++ b/arch/x86/include/uapi/asm/stat.h
+@@ -78,26 +78,26 @@ struct stat64 {
+ #else /* __i386__ */
+
+ struct stat {
+- unsigned long st_dev;
+- unsigned long st_ino;
+- unsigned long st_nlink;
+-
+- unsigned int st_mode;
+- unsigned int st_uid;
+- unsigned int st_gid;
+- unsigned int __pad0;
+- unsigned long st_rdev;
+- long st_size;
+- long st_blksize;
+- long st_blocks; /* Number 512-byte blocks allocated. */
++ unsigned long long st_dev;
++ unsigned long long st_ino;
++ unsigned long long st_nlink;
+
+- unsigned long st_atime;
+- unsigned long st_atime_nsec;
+- unsigned long st_mtime;
+- unsigned long st_mtime_nsec;
+- unsigned long st_ctime;
+- unsigned long st_ctime_nsec;
+- long __unused[3];
++ unsigned int st_mode;
++ unsigned int st_uid;
++ unsigned int st_gid;
++ unsigned int __pad0;
++ unsigned long long st_rdev;
++ long long st_size;
++ long long st_blksize;
++ long long st_blocks; /* Number 512-byte blocks allocated. */
++
++ unsigned long long st_atime;
++ unsigned long long st_atime_nsec;
++ unsigned long long st_mtime;
++ unsigned long long st_mtime_nsec;
++ unsigned long long st_ctime;
++ unsigned long long st_ctime_nsec;
++ long long __unused[3];
+ };
+
+ /* We don't need to memset the whole thing just to initialize the padding */
+diff --git a/arch/x86/include/uapi/asm/statfs.h b/arch/x86/include/uapi/asm/statfs.h
+index 2d0adbf..3cb5744 100644
+--- a/arch/x86/include/uapi/asm/statfs.h
++++ b/arch/x86/include/uapi/asm/statfs.h
+@@ -8,5 +8,10 @@
+ */
+ #define ARCH_PACK_COMPAT_STATFS64 __attribute__((packed,aligned(4)))
+
++/* For x86-64, both the 64bit and x32 ABIs have 64bit fields. */
++#ifdef __x86_64__
++#define __statfs_word __u64
++#endif
++
+ #include <asm-generic/statfs.h>
+ #endif /* _ASM_X86_STATFS_H */
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0008-uapi-convert-u64-to-__u64-in-exported-headers.patch b/3.13/00_all_0008-uapi-convert-u64-to-__u64-in-exported-headers.patch
new file mode 100644
index 0000000..ceba0df
--- /dev/null
+++ b/3.13/00_all_0008-uapi-convert-u64-to-__u64-in-exported-headers.patch
@@ -0,0 +1,43 @@
+From aee839248366d0735581c76eb4002cc9dcddac4e Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Tue, 21 Jan 2014 21:35:36 -0500
+Subject: [PATCH 08/10] uapi: convert u64 to __u64 in exported headers
+
+The u64 type is not defined in any exported kernel headers, so trying
+to use it will lead to build failures.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/nfs4.h | 2 +-
+ include/uapi/linux/perf_event.h | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/include/uapi/linux/nfs4.h b/include/uapi/linux/nfs4.h
+index 788128e..35f5f4c 100644
+--- a/include/uapi/linux/nfs4.h
++++ b/include/uapi/linux/nfs4.h
+@@ -150,7 +150,7 @@
+ #define NFS4_SECINFO_STYLE4_CURRENT_FH 0
+ #define NFS4_SECINFO_STYLE4_PARENT 1
+
+-#define NFS4_MAX_UINT64 (~(u64)0)
++#define NFS4_MAX_UINT64 (~(__u64)0)
+
+ /* An NFS4 sessions server must support at least NFS4_MAX_OPS operations.
+ * If a compound requires more operations, adjust NFS4_MAX_OPS accordingly.
+diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h
+index 959d454..7a3fed5 100644
+--- a/include/uapi/linux/perf_event.h
++++ b/include/uapi/linux/perf_event.h
+@@ -787,7 +787,7 @@ union perf_mem_data_src {
+ #define PERF_MEM_TLB_SHIFT 26
+
+ #define PERF_MEM_S(a, s) \
+- (((u64)PERF_MEM_##a##_##s) << PERF_MEM_##a##_SHIFT)
++ (((__u64)PERF_MEM_##a##_##s) << PERF_MEM_##a##_SHIFT)
+
+ /*
+ * single taken branch record layout:
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0009-uapi-netfilter_arp-use-__u8-instead-of-u_int8_t.patch b/3.13/00_all_0009-uapi-netfilter_arp-use-__u8-instead-of-u_int8_t.patch
new file mode 100644
index 0000000..49c2cd3
--- /dev/null
+++ b/3.13/00_all_0009-uapi-netfilter_arp-use-__u8-instead-of-u_int8_t.patch
@@ -0,0 +1,29 @@
+From 16a0678e4b3a39b1a73b7eb52b57f9d2fb17c6bc Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Tue, 21 Jan 2014 21:39:24 -0500
+Subject: [PATCH 09/10] uapi: netfilter_arp: use __u8 instead of u_int8_t
+
+Similarly, the u_int8_t type is non-standard and not defined. Change
+it to use __u8 like the rest of the netfilter headers.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/netfilter_arp/arpt_mangle.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/uapi/linux/netfilter_arp/arpt_mangle.h b/include/uapi/linux/netfilter_arp/arpt_mangle.h
+index 250f502..8c2b16a 100644
+--- a/include/uapi/linux/netfilter_arp/arpt_mangle.h
++++ b/include/uapi/linux/netfilter_arp/arpt_mangle.h
+@@ -13,7 +13,7 @@ struct arpt_mangle
+ union {
+ struct in_addr tgt_ip;
+ } u_t;
+- u_int8_t flags;
++ __u8 flags;
+ int target;
+ };
+
+--
+1.8.4.3
+
diff --git a/3.13/00_all_0010-uapi-ppp-ioctl.h-pull-in-ppp_defs.h.patch b/3.13/00_all_0010-uapi-ppp-ioctl.h-pull-in-ppp_defs.h.patch
new file mode 100644
index 0000000..b8b99f9
--- /dev/null
+++ b/3.13/00_all_0010-uapi-ppp-ioctl.h-pull-in-ppp_defs.h.patch
@@ -0,0 +1,32 @@
+From af0b5417dc16a45cb88e0046a61d28c0d89e9f73 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Tue, 21 Jan 2014 21:43:26 -0500
+Subject: [PATCH 10/10] uapi: ppp-ioctl.h: pull in ppp_defs.h
+
+This header uses enum NPmode but doesn't include ppp_defs.h. If you try
+to use this header w/out including the defs header first, it leads to a
+build failure. So add the explicit include to fix it.
+
+Don't know of any packages directly impacted, but noticed while building
+some ppp code by hand.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/uapi/linux/ppp-ioctl.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/uapi/linux/ppp-ioctl.h b/include/uapi/linux/ppp-ioctl.h
+index 2d9a885..63a23a3 100644
+--- a/include/uapi/linux/ppp-ioctl.h
++++ b/include/uapi/linux/ppp-ioctl.h
+@@ -12,6 +12,7 @@
+
+ #include <linux/types.h>
+ #include <linux/compiler.h>
++#include <linux/ppp_defs.h>
+
+ /*
+ * Bit definitions for flags argument to PPPIOCGFLAGS/PPPIOCSFLAGS.
+--
+1.8.4.3
+