aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/generic')
-rw-r--r--target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch75
-rw-r--r--target/linux/generic/patches-3.18/081-01-pppoe-Use-workqueue-to-die-properly-when-a-PADT-is-r.patch6
-rw-r--r--target/linux/generic/patches-3.18/081-02-pppoe-Lacks-DST-MAC-address-check.patch2
-rw-r--r--target/linux/generic/patches-3.18/081-03-pppoe-drop-pppoe-device-in-pppoe_unbind_sock_work.patch2
-rw-r--r--target/linux/generic/patches-3.18/081-04-ppp-don-t-override-sk-sk_state-in-pppoe_flush_dev.patch68
-rw-r--r--target/linux/generic/patches-3.18/081-05-ppp-fix-pppoe_dev-deletion-condition-in-pppoe_releas.patch29
-rw-r--r--target/linux/generic/patches-3.18/090-overlayfs-fallback-to-readonly-when-full.patch2
-rw-r--r--target/linux/generic/patches-3.18/099-module_arch_freeing_init-new-hook-for-archs-before-m.patch8
-rw-r--r--target/linux/generic/patches-3.18/141-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch2
-rw-r--r--target/linux/generic/patches-3.18/142-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch15
-rw-r--r--target/linux/generic/patches-3.18/204-module_strip.patch4
-rw-r--r--target/linux/generic/patches-3.18/431-mtd-bcm47xxpart-check-for-bad-blocks-when-calculatin.patch8
-rw-r--r--target/linux/generic/patches-3.18/630-packet_socket_type.patch16
-rw-r--r--target/linux/generic/patches-3.18/643-bridge_remove_ipv6_dependency.patch8
-rw-r--r--target/linux/generic/patches-3.18/662-use_fq_codel_by_default.patch2
-rw-r--r--target/linux/generic/patches-3.18/810-pci_disable_common_quirks.patch6
-rw-r--r--target/linux/generic/patches-3.18/902-debloat_proc.patch4
-rw-r--r--target/linux/generic/patches-3.18/903-debloat_direct_io.patch2
18 files changed, 41 insertions, 218 deletions
diff --git a/target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch b/target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch
deleted file mode 100644
index 9c6a969738..0000000000
--- a/target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-From 7ca88764d45c209791e8813131c1457c2e9e51e7 Mon Sep 17 00:00:00 2001
-From: Yevgeny Pats <yevgeny@perception-point.io>
-Date: Mon, 11 Jan 2016 12:05:28 +0000
-Subject: KEYS: Fix keyring ref leak in join_session_keyring()
-
-If a thread is asked to join as a session keyring the keyring that's already
-set as its session, we leak a keyring reference.
-
-This can be tested with the following program:
-
- #include <stddef.h>
- #include <stdio.h>
- #include <sys/types.h>
- #include <keyutils.h>
-
- int main(int argc, const char *argv[])
- {
- int i = 0;
- key_serial_t serial;
-
- serial = keyctl(KEYCTL_JOIN_SESSION_KEYRING,
- "leaked-keyring");
- if (serial < 0) {
- perror("keyctl");
- return -1;
- }
-
- if (keyctl(KEYCTL_SETPERM, serial,
- KEY_POS_ALL | KEY_USR_ALL) < 0) {
- perror("keyctl");
- return -1;
- }
-
- for (i = 0; i < 100; i++) {
- serial = keyctl(KEYCTL_JOIN_SESSION_KEYRING,
- "leaked-keyring");
- if (serial < 0) {
- perror("keyctl");
- return -1;
- }
- }
-
- return 0;
- }
-
-If, after the program has run, there something like the following line in
-/proc/keys:
-
-3f3d898f I--Q--- 100 perm 3f3f0000 0 0 keyring leaked-keyring: empty
-
-with a usage count of 100 * the number of times the program has been run,
-then the kernel is malfunctioning. If leaked-keyring has zero usages or
-has been garbage collected, then the problem is fixed.
-
-Reported-by: Yevgeny Pats <yevgeny@perception-point.io>
-Signed-off-by: David Howells <dhowells@redhat.com>
----
- security/keys/process_keys.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/security/keys/process_keys.c b/security/keys/process_keys.c
-index a3f85d2..e6d50172 100644
---- a/security/keys/process_keys.c
-+++ b/security/keys/process_keys.c
-@@ -794,6 +794,7 @@ long join_session_keyring(const char *name)
- ret = PTR_ERR(keyring);
- goto error2;
- } else if (keyring == new->session_keyring) {
-+ key_put(keyring);
- ret = 0;
- goto error2;
- }
---
-2.7.0.rc3
-
diff --git a/target/linux/generic/patches-3.18/081-01-pppoe-Use-workqueue-to-die-properly-when-a-PADT-is-r.patch b/target/linux/generic/patches-3.18/081-01-pppoe-Use-workqueue-to-die-properly-when-a-PADT-is-r.patch
index de8583058f..347049a924 100644
--- a/target/linux/generic/patches-3.18/081-01-pppoe-Use-workqueue-to-die-properly-when-a-PADT-is-r.patch
+++ b/target/linux/generic/patches-3.18/081-01-pppoe-Use-workqueue-to-die-properly-when-a-PADT-is-r.patch
@@ -31,7 +31,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ppp/pppoe.c
+++ b/drivers/net/ppp/pppoe.c
-@@ -455,6 +455,18 @@ out:
+@@ -454,6 +454,18 @@ out:
return NET_RX_DROP;
}
@@ -50,7 +50,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
/************************************************************************
*
* Receive a PPPoE Discovery frame.
-@@ -500,7 +512,8 @@ static int pppoe_disc_rcv(struct sk_buff
+@@ -499,7 +511,8 @@ static int pppoe_disc_rcv(struct sk_buff
}
bh_unlock_sock(sk);
@@ -60,7 +60,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
}
abort:
-@@ -613,6 +626,8 @@ static int pppoe_connect(struct socket *
+@@ -612,6 +625,8 @@ static int pppoe_connect(struct socket *
lock_sock(sk);
diff --git a/target/linux/generic/patches-3.18/081-02-pppoe-Lacks-DST-MAC-address-check.patch b/target/linux/generic/patches-3.18/081-02-pppoe-Lacks-DST-MAC-address-check.patch
index 3ce778e301..f592929b3e 100644
--- a/target/linux/generic/patches-3.18/081-02-pppoe-Lacks-DST-MAC-address-check.patch
+++ b/target/linux/generic/patches-3.18/081-02-pppoe-Lacks-DST-MAC-address-check.patch
@@ -13,7 +13,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ppp/pppoe.c
+++ b/drivers/net/ppp/pppoe.c
-@@ -380,6 +380,9 @@ static int pppoe_rcv_core(struct sock *s
+@@ -379,6 +379,9 @@ static int pppoe_rcv_core(struct sock *s
* can't change.
*/
diff --git a/target/linux/generic/patches-3.18/081-03-pppoe-drop-pppoe-device-in-pppoe_unbind_sock_work.patch b/target/linux/generic/patches-3.18/081-03-pppoe-drop-pppoe-device-in-pppoe_unbind_sock_work.patch
index f672c67b90..fc26b8ffaf 100644
--- a/target/linux/generic/patches-3.18/081-03-pppoe-drop-pppoe-device-in-pppoe_unbind_sock_work.patch
+++ b/target/linux/generic/patches-3.18/081-03-pppoe-drop-pppoe-device-in-pppoe_unbind_sock_work.patch
@@ -15,7 +15,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ppp/pppoe.c
+++ b/drivers/net/ppp/pppoe.c
-@@ -465,6 +465,10 @@ static void pppoe_unbind_sock_work(struc
+@@ -464,6 +464,10 @@ static void pppoe_unbind_sock_work(struc
struct sock *sk = sk_pppox(po);
lock_sock(sk);
diff --git a/target/linux/generic/patches-3.18/081-04-ppp-don-t-override-sk-sk_state-in-pppoe_flush_dev.patch b/target/linux/generic/patches-3.18/081-04-ppp-don-t-override-sk-sk_state-in-pppoe_flush_dev.patch
deleted file mode 100644
index 73f2e3d47a..0000000000
--- a/target/linux/generic/patches-3.18/081-04-ppp-don-t-override-sk-sk_state-in-pppoe_flush_dev.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From: Guillaume Nault <g.nault@alphalink.fr>
-Date: Wed, 30 Sep 2015 11:45:33 +0200
-Subject: [PATCH] ppp: don't override sk->sk_state in pppoe_flush_dev()
-
-Since commit 2b018d57ff18 ("pppoe: drop PPPOX_ZOMBIEs in pppoe_release"),
-pppoe_release() calls dev_put(po->pppoe_dev) if sk is in the
-PPPOX_ZOMBIE state. But pppoe_flush_dev() can set sk->sk_state to
-PPPOX_ZOMBIE _and_ reset po->pppoe_dev to NULL. This leads to the
-following oops:
-
-[ 570.140800] BUG: unable to handle kernel NULL pointer dereference at 00000000000004e0
-[ 570.142931] IP: [<ffffffffa018c701>] pppoe_release+0x50/0x101 [pppoe]
-[ 570.144601] PGD 3d119067 PUD 3dbc1067 PMD 0
-[ 570.144601] Oops: 0000 [#1] SMP
-[ 570.144601] Modules linked in: l2tp_ppp l2tp_netlink l2tp_core ip6_udp_tunnel udp_tunnel pppoe pppox ppp_generic slhc loop crc32c_intel ghash_clmulni_intel jitterentropy_rng sha256_generic hmac drbg ansi_cprng aesni_intel aes_x86_64 ablk_helper cryptd lrw gf128mul glue_helper acpi_cpufreq evdev serio_raw processor button ext4 crc16 mbcache jbd2 virtio_net virtio_blk virtio_pci virtio_ring virtio
-[ 570.144601] CPU: 1 PID: 15738 Comm: ppp-apitest Not tainted 4.2.0 #1
-[ 570.144601] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Debian-1.8.2-1 04/01/2014
-[ 570.144601] task: ffff88003d30d600 ti: ffff880036b60000 task.ti: ffff880036b60000
-[ 570.144601] RIP: 0010:[<ffffffffa018c701>] [<ffffffffa018c701>] pppoe_release+0x50/0x101 [pppoe]
-[ 570.144601] RSP: 0018:ffff880036b63e08 EFLAGS: 00010202
-[ 570.144601] RAX: 0000000000000000 RBX: ffff880034340000 RCX: 0000000000000206
-[ 570.144601] RDX: 0000000000000006 RSI: ffff88003d30dd20 RDI: ffff88003d30dd20
-[ 570.144601] RBP: ffff880036b63e28 R08: 0000000000000001 R09: 0000000000000000
-[ 570.144601] R10: 00007ffee9b50420 R11: ffff880034340078 R12: ffff8800387ec780
-[ 570.144601] R13: ffff8800387ec7b0 R14: ffff88003e222aa0 R15: ffff8800387ec7b0
-[ 570.144601] FS: 00007f5672f48700(0000) GS:ffff88003fc80000(0000) knlGS:0000000000000000
-[ 570.144601] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
-[ 570.144601] CR2: 00000000000004e0 CR3: 0000000037f7e000 CR4: 00000000000406a0
-[ 570.144601] Stack:
-[ 570.144601] ffffffffa018f240 ffff8800387ec780 ffffffffa018f240 ffff8800387ec7b0
-[ 570.144601] ffff880036b63e48 ffffffff812caabe ffff880039e4e000 0000000000000008
-[ 570.144601] ffff880036b63e58 ffffffff812cabad ffff880036b63ea8 ffffffff811347f5
-[ 570.144601] Call Trace:
-[ 570.144601] [<ffffffff812caabe>] sock_release+0x1a/0x75
-[ 570.144601] [<ffffffff812cabad>] sock_close+0xd/0x11
-[ 570.144601] [<ffffffff811347f5>] __fput+0xff/0x1a5
-[ 570.144601] [<ffffffff811348cb>] ____fput+0x9/0xb
-[ 570.144601] [<ffffffff81056682>] task_work_run+0x66/0x90
-[ 570.144601] [<ffffffff8100189e>] prepare_exit_to_usermode+0x8c/0xa7
-[ 570.144601] [<ffffffff81001a26>] syscall_return_slowpath+0x16d/0x19b
-[ 570.144601] [<ffffffff813babb1>] int_ret_from_sys_call+0x25/0x9f
-[ 570.144601] Code: 48 8b 83 c8 01 00 00 a8 01 74 12 48 89 df e8 8b 27 14 e1 b8 f7 ff ff ff e9 b7 00 00 00 8a 43 12 a8 0b 74 1c 48 8b 83 a8 04 00 00 <48> 8b 80 e0 04 00 00 65 ff 08 48 c7 83 a8 04 00 00 00 00 00 00
-[ 570.144601] RIP [<ffffffffa018c701>] pppoe_release+0x50/0x101 [pppoe]
-[ 570.144601] RSP <ffff880036b63e08>
-[ 570.144601] CR2: 00000000000004e0
-[ 570.200518] ---[ end trace 46956baf17349563 ]---
-
-pppoe_flush_dev() has no reason to override sk->sk_state with
-PPPOX_ZOMBIE. pppox_unbind_sock() already sets sk->sk_state to
-PPPOX_DEAD, which is the correct state given that sk is unbound and
-po->pppoe_dev is NULL.
-
-Fixes: 2b018d57ff18 ("pppoe: drop PPPOX_ZOMBIEs in pppoe_release")
-Tested-by: Oleksii Berezhniak <core@irc.lg.ua>
-Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
-Signed-off-by: David S. Miller <davem@davemloft.net>
----
-
---- a/drivers/net/ppp/pppoe.c
-+++ b/drivers/net/ppp/pppoe.c
-@@ -313,7 +313,6 @@ static void pppoe_flush_dev(struct net_d
- if (po->pppoe_dev == dev &&
- sk->sk_state & (PPPOX_CONNECTED | PPPOX_BOUND | PPPOX_ZOMBIE)) {
- pppox_unbind_sock(sk);
-- sk->sk_state = PPPOX_ZOMBIE;
- sk->sk_state_change(sk);
- po->pppoe_dev = NULL;
- dev_put(dev);
diff --git a/target/linux/generic/patches-3.18/081-05-ppp-fix-pppoe_dev-deletion-condition-in-pppoe_releas.patch b/target/linux/generic/patches-3.18/081-05-ppp-fix-pppoe_dev-deletion-condition-in-pppoe_releas.patch
deleted file mode 100644
index b1ae60b028..0000000000
--- a/target/linux/generic/patches-3.18/081-05-ppp-fix-pppoe_dev-deletion-condition-in-pppoe_releas.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From: Guillaume Nault <g.nault@alphalink.fr>
-Date: Thu, 22 Oct 2015 16:57:10 +0200
-Subject: [PATCH] ppp: fix pppoe_dev deletion condition in pppoe_release()
-
-We can't rely on PPPOX_ZOMBIE to decide whether to clear po->pppoe_dev.
-PPPOX_ZOMBIE can be set by pppoe_disc_rcv() even when po->pppoe_dev is
-NULL. So we have no guarantee that (sk->sk_state & PPPOX_ZOMBIE) implies
-(po->pppoe_dev != NULL).
-Since we're releasing a PPPoE socket, we want to release the pppoe_dev
-if it exists and reset sk_state to PPPOX_DEAD, no matter the previous
-value of sk_state. So we can just check for po->pppoe_dev and avoid any
-assumption on sk->sk_state.
-
-Fixes: 2b018d57ff18 ("pppoe: drop PPPOX_ZOMBIEs in pppoe_release")
-Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
-Signed-off-by: David S. Miller <davem@davemloft.net>
----
-
---- a/drivers/net/ppp/pppoe.c
-+++ b/drivers/net/ppp/pppoe.c
-@@ -589,7 +589,7 @@ static int pppoe_release(struct socket *
-
- po = pppox_sk(sk);
-
-- if (sk->sk_state & (PPPOX_CONNECTED | PPPOX_BOUND | PPPOX_ZOMBIE)) {
-+ if (po->pppoe_dev) {
- dev_put(po->pppoe_dev);
- po->pppoe_dev = NULL;
- }
diff --git a/target/linux/generic/patches-3.18/090-overlayfs-fallback-to-readonly-when-full.patch b/target/linux/generic/patches-3.18/090-overlayfs-fallback-to-readonly-when-full.patch
index 6fbbc25ae0..1bcd5159db 100644
--- a/target/linux/generic/patches-3.18/090-overlayfs-fallback-to-readonly-when-full.patch
+++ b/target/linux/generic/patches-3.18/090-overlayfs-fallback-to-readonly-when-full.patch
@@ -44,7 +44,7 @@ Miklos
--- a/fs/overlayfs/copy_up.c
+++ b/fs/overlayfs/copy_up.c
-@@ -300,6 +300,9 @@ int ovl_copy_up_one(struct dentry *paren
+@@ -311,6 +311,9 @@ int ovl_copy_up_one(struct dentry *paren
struct cred *override_cred;
char *link = NULL;
diff --git a/target/linux/generic/patches-3.18/099-module_arch_freeing_init-new-hook-for-archs-before-m.patch b/target/linux/generic/patches-3.18/099-module_arch_freeing_init-new-hook-for-archs-before-m.patch
index d00f751cdc..a6310c625c 100644
--- a/target/linux/generic/patches-3.18/099-module_arch_freeing_init-new-hook-for-archs-before-m.patch
+++ b/target/linux/generic/patches-3.18/099-module_arch_freeing_init-new-hook-for-archs-before-m.patch
@@ -145,7 +145,7 @@ Origin: backport, https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.gi
#endif
--- a/kernel/module.c
+++ b/kernel/module.c
-@@ -1833,6 +1833,10 @@ void __weak module_arch_cleanup(struct m
+@@ -1837,6 +1837,10 @@ void __weak module_arch_cleanup(struct m
{
}
@@ -156,7 +156,7 @@ Origin: backport, https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.gi
/* Free a module, remove from lists, etc. */
static void free_module(struct module *mod)
{
-@@ -1865,6 +1869,7 @@ static void free_module(struct module *m
+@@ -1869,6 +1873,7 @@ static void free_module(struct module *m
/* This may be NULL, but that's OK */
unset_module_init_ro_nx(mod);
@@ -164,7 +164,7 @@ Origin: backport, https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.gi
module_free(mod, mod->module_init);
kfree(mod->args);
percpu_modfree(mod);
-@@ -2954,6 +2959,7 @@ static struct module *layout_and_allocat
+@@ -2958,6 +2963,7 @@ static struct module *layout_and_allocat
static void module_deallocate(struct module *mod, struct load_info *info)
{
percpu_modfree(mod);
@@ -172,7 +172,7 @@ Origin: backport, https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.gi
module_free(mod, mod->module_init);
module_free(mod, mod->module_core);
}
-@@ -3077,6 +3083,7 @@ static int do_init_module(struct module
+@@ -3081,6 +3087,7 @@ static int do_init_module(struct module
mod->strtab = mod->core_strtab;
#endif
unset_module_init_ro_nx(mod);
diff --git a/target/linux/generic/patches-3.18/141-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch b/target/linux/generic/patches-3.18/141-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch
index aa315143fe..761cff316d 100644
--- a/target/linux/generic/patches-3.18/141-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch
+++ b/target/linux/generic/patches-3.18/141-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch
@@ -20,7 +20,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
--- a/drivers/mtd/bcm47xxpart.c
+++ b/drivers/mtd/bcm47xxpart.c
-@@ -118,8 +118,8 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -118,8 +118,8 @@ static int bcm47xxpart_parse(struct mtd_
/* Parse block by block looking for magics */
for (offset = 0; offset <= master->size - blocksize;
offset += blocksize) {
diff --git a/target/linux/generic/patches-3.18/142-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch b/target/linux/generic/patches-3.18/142-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch
index f9e81f9395..9073f795e2 100644
--- a/target/linux/generic/patches-3.18/142-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch
+++ b/target/linux/generic/patches-3.18/142-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch
@@ -14,11 +14,9 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
drivers/mtd/bcm47xxpart.c | 38 ++++++++++++++++++++++----------------
1 file changed, 22 insertions(+), 16 deletions(-)
-diff --git a/drivers/mtd/bcm47xxpart.c b/drivers/mtd/bcm47xxpart.c
-index 4450e74..1ab3451 100644
--- a/drivers/mtd/bcm47xxpart.c
+++ b/drivers/mtd/bcm47xxpart.c
-@@ -66,11 +66,13 @@ static const char *bcm47xxpart_trx_data_part_name(struct mtd_info *master,
+@@ -66,11 +66,13 @@ static const char *bcm47xxpart_trx_data_
{
uint32_t buf;
size_t bytes_read;
@@ -36,7 +34,7 @@ index 4450e74..1ab3451 100644
goto out_default;
}
-@@ -95,6 +97,7 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -95,6 +97,7 @@ static int bcm47xxpart_parse(struct mtd_
int trx_part = -1;
int last_trx_part = -1;
int possible_nvram_sizes[] = { 0x8000, 0xF000, 0x10000, };
@@ -44,7 +42,7 @@ index 4450e74..1ab3451 100644
/*
* Some really old flashes (like AT45DB*) had smaller erasesize-s, but
-@@ -128,10 +131,11 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -128,10 +131,11 @@ static int bcm47xxpart_parse(struct mtd_
}
/* Read beginning of the block */
@@ -60,7 +58,7 @@ index 4450e74..1ab3451 100644
continue;
}
-@@ -254,10 +258,11 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -254,10 +258,11 @@ static int bcm47xxpart_parse(struct mtd_
}
/* Read middle of the block */
@@ -76,7 +74,7 @@ index 4450e74..1ab3451 100644
continue;
}
-@@ -277,10 +282,11 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -277,10 +282,11 @@ static int bcm47xxpart_parse(struct mtd_
}
offset = master->size - possible_nvram_sizes[i];
@@ -92,6 +90,3 @@ index 4450e74..1ab3451 100644
continue;
}
---
-1.8.4.5
-
diff --git a/target/linux/generic/patches-3.18/204-module_strip.patch b/target/linux/generic/patches-3.18/204-module_strip.patch
index 09bffe0673..deef6b0c9a 100644
--- a/target/linux/generic/patches-3.18/204-module_strip.patch
+++ b/target/linux/generic/patches-3.18/204-module_strip.patch
@@ -109,7 +109,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
config INIT_ALL_POSSIBLE
--- a/kernel/module.c
+++ b/kernel/module.c
-@@ -2670,6 +2670,7 @@ static struct module *setup_load_info(st
+@@ -2674,6 +2674,7 @@ static struct module *setup_load_info(st
static int check_modinfo(struct module *mod, struct load_info *info, int flags)
{
@@ -117,7 +117,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
const char *modmagic = get_modinfo(info, "vermagic");
int err;
-@@ -2695,6 +2696,7 @@ static int check_modinfo(struct module *
+@@ -2699,6 +2700,7 @@ static int check_modinfo(struct module *
pr_warn("%s: module is from the staging directory, the quality "
"is unknown, you have been warned.\n", mod->name);
}
diff --git a/target/linux/generic/patches-3.18/431-mtd-bcm47xxpart-check-for-bad-blocks-when-calculatin.patch b/target/linux/generic/patches-3.18/431-mtd-bcm47xxpart-check-for-bad-blocks-when-calculatin.patch
index 6adac77669..5ad82f1f51 100644
--- a/target/linux/generic/patches-3.18/431-mtd-bcm47xxpart-check-for-bad-blocks-when-calculatin.patch
+++ b/target/linux/generic/patches-3.18/431-mtd-bcm47xxpart-check-for-bad-blocks-when-calculatin.patch
@@ -13,7 +13,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
--- a/drivers/mtd/bcm47xxpart.c
+++ b/drivers/mtd/bcm47xxpart.c
-@@ -61,6 +61,34 @@ static void bcm47xxpart_add_part(struct mtd_partition *part, const char *name,
+@@ -61,6 +61,34 @@ static void bcm47xxpart_add_part(struct
part->mask_flags = mask_flags;
}
@@ -48,7 +48,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
static const char *bcm47xxpart_trx_data_part_name(struct mtd_info *master,
size_t offset)
{
-@@ -182,6 +210,8 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -182,6 +210,8 @@ static int bcm47xxpart_parse(struct mtd_
/* TRX */
if (buf[0x000 / 4] == TRX_MAGIC) {
@@ -57,7 +57,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
if (BCM47XXPART_MAX_PARTS - curr_part < 4) {
pr_warn("Not enough partitions left to register trx, scanning stopped!\n");
break;
-@@ -196,18 +226,18 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -196,18 +226,18 @@ static int bcm47xxpart_parse(struct mtd_
i = 0;
/* We have LZMA loader if offset[2] points to sth */
if (trx->offset[2]) {
@@ -82,7 +82,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
i++;
}
-@@ -219,11 +249,11 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -219,11 +249,11 @@ static int bcm47xxpart_parse(struct mtd_
if (trx->offset[i]) {
const char *name;
diff --git a/target/linux/generic/patches-3.18/630-packet_socket_type.patch b/target/linux/generic/patches-3.18/630-packet_socket_type.patch
index 31f4bca2a0..c3c0fe4664 100644
--- a/target/linux/generic/patches-3.18/630-packet_socket_type.patch
+++ b/target/linux/generic/patches-3.18/630-packet_socket_type.patch
@@ -26,7 +26,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
#define PACKET_FANOUT_LB 1
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
-@@ -1516,6 +1516,7 @@ static int packet_rcv_spkt(struct sk_buf
+@@ -1530,6 +1530,7 @@ static int packet_rcv_spkt(struct sk_buf
{
struct sock *sk;
struct sockaddr_pkt *spkt;
@@ -34,7 +34,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
/*
* When we registered the protocol we saved the socket in the data
-@@ -1523,6 +1524,7 @@ static int packet_rcv_spkt(struct sk_buf
+@@ -1537,6 +1538,7 @@ static int packet_rcv_spkt(struct sk_buf
*/
sk = pt->af_packet_priv;
@@ -42,7 +42,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
/*
* Yank back the headers [hope the device set this
-@@ -1535,7 +1537,7 @@ static int packet_rcv_spkt(struct sk_buf
+@@ -1549,7 +1551,7 @@ static int packet_rcv_spkt(struct sk_buf
* so that this procedure is noop.
*/
@@ -51,7 +51,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
goto out;
if (!net_eq(dev_net(dev), sock_net(sk)))
-@@ -1742,12 +1744,12 @@ static int packet_rcv(struct sk_buff *sk
+@@ -1748,12 +1750,12 @@ static int packet_rcv(struct sk_buff *sk
int skb_len = skb->len;
unsigned int snaplen, res;
@@ -67,7 +67,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
if (!net_eq(dev_net(dev), sock_net(sk)))
goto drop;
-@@ -1867,12 +1869,12 @@ static int tpacket_rcv(struct sk_buff *s
+@@ -1873,12 +1875,12 @@ static int tpacket_rcv(struct sk_buff *s
BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h2)) != 32);
BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h3)) != 48);
@@ -83,7 +83,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
if (!net_eq(dev_net(dev), sock_net(sk)))
goto drop;
-@@ -2807,6 +2809,7 @@ static int packet_create(struct net *net
+@@ -2828,6 +2830,7 @@ static int packet_create(struct net *net
spin_lock_init(&po->bind_lock);
mutex_init(&po->pg_vec_lock);
po->prot_hook.func = packet_rcv;
@@ -91,7 +91,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
if (sock->type == SOCK_PACKET)
po->prot_hook.func = packet_rcv_spkt;
-@@ -3387,6 +3390,16 @@ packet_setsockopt(struct socket *sock, i
+@@ -3408,6 +3411,16 @@ packet_setsockopt(struct socket *sock, i
po->xmit = val ? packet_direct_xmit : dev_queue_xmit;
return 0;
}
@@ -108,7 +108,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
default:
return -ENOPROTOOPT;
}
-@@ -3438,6 +3451,13 @@ static int packet_getsockopt(struct sock
+@@ -3459,6 +3472,13 @@ static int packet_getsockopt(struct sock
case PACKET_VNET_HDR:
val = po->has_vnet_hdr;
break;
diff --git a/target/linux/generic/patches-3.18/643-bridge_remove_ipv6_dependency.patch b/target/linux/generic/patches-3.18/643-bridge_remove_ipv6_dependency.patch
index 3f0dcd3ae2..aef3832b0f 100644
--- a/target/linux/generic/patches-3.18/643-bridge_remove_ipv6_dependency.patch
+++ b/target/linux/generic/patches-3.18/643-bridge_remove_ipv6_dependency.patch
@@ -35,7 +35,7 @@
obj-$(CONFIG_NET_UDP_TUNNEL) += ip6_udp_tunnel.o
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
-@@ -1317,7 +1317,7 @@ out:
+@@ -1318,7 +1318,7 @@ out:
return ret;
}
@@ -44,7 +44,7 @@
const struct in6_addr *daddr, unsigned int prefs,
struct in6_addr *saddr)
{
-@@ -1442,7 +1442,6 @@ try_nextdev:
+@@ -1443,7 +1443,6 @@ try_nextdev:
in6_ifa_put(hiscore->ifa);
return 0;
}
@@ -52,7 +52,7 @@
int __ipv6_get_lladdr(struct inet6_dev *idev, struct in6_addr *addr,
u32 banned_flags)
-@@ -5451,6 +5450,9 @@ int __init addrconf_init(void)
+@@ -5467,6 +5466,9 @@ int __init addrconf_init(void)
ipv6_addr_label_rtnl_register();
@@ -62,7 +62,7 @@
return 0;
errout:
rtnl_af_unregister(&inet6_ops);
-@@ -5470,6 +5472,9 @@ void addrconf_cleanup(void)
+@@ -5486,6 +5488,9 @@ void addrconf_cleanup(void)
struct net_device *dev;
int i;
diff --git a/target/linux/generic/patches-3.18/662-use_fq_codel_by_default.patch b/target/linux/generic/patches-3.18/662-use_fq_codel_by_default.patch
index ba7c384ad2..5caf933764 100644
--- a/target/linux/generic/patches-3.18/662-use_fq_codel_by_default.patch
+++ b/target/linux/generic/patches-3.18/662-use_fq_codel_by_default.patch
@@ -51,7 +51,7 @@
EXPORT_SYMBOL(default_qdisc_ops);
/* Main transmission queue. */
-@@ -737,7 +737,7 @@ static void attach_one_default_qdisc(str
+@@ -739,7 +739,7 @@ static void attach_one_default_qdisc(str
if (dev->tx_queue_len) {
qdisc = qdisc_create_dflt(dev_queue,
diff --git a/target/linux/generic/patches-3.18/810-pci_disable_common_quirks.patch b/target/linux/generic/patches-3.18/810-pci_disable_common_quirks.patch
index b9b3e0aba8..1b7bead486 100644
--- a/target/linux/generic/patches-3.18/810-pci_disable_common_quirks.patch
+++ b/target/linux/generic/patches-3.18/810-pci_disable_common_quirks.patch
@@ -23,7 +23,7 @@
/* The Mellanox Tavor device gives false positive parity errors
* Mark this device with a broken_parity_status, to allow
* PCI scanning code to "skip" this now blacklisted device.
-@@ -2908,6 +2909,7 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_I
+@@ -2917,6 +2918,7 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_I
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x65f9, quirk_intel_mc_errata);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x65fa, quirk_intel_mc_errata);
@@ -31,7 +31,7 @@
/*
* Ivytown NTB BAR sizes are misreported by the hardware due to an erratum. To
-@@ -2964,6 +2966,8 @@ static void fixup_debug_report(struct pc
+@@ -2973,6 +2975,8 @@ static void fixup_debug_report(struct pc
}
}
@@ -40,7 +40,7 @@
/*
* Some BIOS implementations leave the Intel GPU interrupts enabled,
* even though no one is handling them (f.e. i915 driver is never loaded).
-@@ -2998,6 +3002,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_IN
+@@ -3007,6 +3011,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_IN
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x010a, disable_igfx_irq);
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0152, disable_igfx_irq);
diff --git a/target/linux/generic/patches-3.18/902-debloat_proc.patch b/target/linux/generic/patches-3.18/902-debloat_proc.patch
index 5cecd1e677..79cecf90d4 100644
--- a/target/linux/generic/patches-3.18/902-debloat_proc.patch
+++ b/target/linux/generic/patches-3.18/902-debloat_proc.patch
@@ -1,6 +1,6 @@
--- a/fs/locks.c
+++ b/fs/locks.c
-@@ -2611,6 +2611,8 @@ static const struct file_operations proc
+@@ -2620,6 +2620,8 @@ static const struct file_operations proc
static int __init proc_locks_init(void)
{
@@ -173,7 +173,7 @@
goto err;
--- a/net/core/sock.c
+++ b/net/core/sock.c
-@@ -2934,6 +2934,8 @@ static __net_initdata struct pernet_oper
+@@ -2933,6 +2933,8 @@ static __net_initdata struct pernet_oper
static int __init proto_init(void)
{
diff --git a/target/linux/generic/patches-3.18/903-debloat_direct_io.patch b/target/linux/generic/patches-3.18/903-debloat_direct_io.patch
index 92190e47a9..dbb08ca4e7 100644
--- a/target/linux/generic/patches-3.18/903-debloat_direct_io.patch
+++ b/target/linux/generic/patches-3.18/903-debloat_direct_io.patch
@@ -26,7 +26,7 @@
endif
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
-@@ -2528,12 +2528,25 @@ enum {
+@@ -2529,12 +2529,25 @@ enum {
DIO_ASYNC_EXTEND = 0x04,
};