summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO2
-rw-r--r--0001-e1000e-Fix-tight-loop-implementation-of-systime-read.patch65
-rw-r--r--0001-fix-bridge-regression.patch25
-rw-r--r--0001-make_flush_workqueue_non_gpl.patch34
-rw-r--r--0001-netfilter-conntrack-use-nf_ct_tmpl_free-in-CT-synpro.patch103
-rw-r--r--PKGBUILD7
-rw-r--r--thunderbolt.patch75
7 files changed, 2 insertions, 309 deletions
diff --git a/.SRCINFO b/.SRCINFO
index cbed7945f2f3..9fc61b248292 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -19,7 +19,6 @@ pkgbase = linux-macbook
source = config.x86_64
source = linux.preset
source = bluetooth.patch
- source = thunderbolt.patch
source = change-default-console-loglevel.patch
sha256sums = cf20e044f17588d2a42c8f2a450b0fd84dfdbd579b489d93e9ab7d0e8b45dbeb
sha256sums = SKIP
@@ -29,7 +28,6 @@ pkgbase = linux-macbook
sha256sums = 6f2cf8449aeda3473e0577ef13e8cd7b0bd2fc2dee8d6d830eeb73e485279f2d
sha256sums = f0d90e756f14533ee67afda280500511a62465b4f76adcc5effa95a40045179c
sha256sums = dcbed1ae73c4e1383210bad6f1f446bdd13f8b1c24d89bcf0483acc5e178c379
- sha256sums = 4909b37856f4b2374e54e44d656971a1f1027900444ac494f4dd1bb113dc9c97
sha256sums = 1256b241cd477b265a3c2d64bdc19ffe3c9bbcee82ea3994c590c2c76e767d99
pkgname = linux-macbook
diff --git a/0001-e1000e-Fix-tight-loop-implementation-of-systime-read.patch b/0001-e1000e-Fix-tight-loop-implementation-of-systime-read.patch
deleted file mode 100644
index 0bea7fe08cd4..000000000000
--- a/0001-e1000e-Fix-tight-loop-implementation-of-systime-read.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From 37b12910dd11d9ab969f2c310dc9160b7f3e3405 Mon Sep 17 00:00:00 2001
-From: Raanan Avargil <raanan.avargil@intel.com>
-Date: Sun, 19 Jul 2015 16:33:20 +0300
-Subject: [PATCH] e1000e: Fix tight loop implementation of systime read
- algorithm
-
-Change the algorithm. Read systimel twice and check for overflow.
-If there was no overflow, use the first value.
-If there was an overflow, read systimeh again and use the second
-systimel value.
-
-Signed-off-by: Raanan Avargil <raanan.avargil@intel.com>
-Tested-by: Aaron Brown <aaron.f.brown@intel.com>
-Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
----
- drivers/net/ethernet/intel/e1000e/netdev.c | 31 ++++++++++++++++++++----------
- 1 file changed, 21 insertions(+), 10 deletions(-)
-
-diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c
-index 24b7269..96a8166 100644
---- a/drivers/net/ethernet/intel/e1000e/netdev.c
-+++ b/drivers/net/ethernet/intel/e1000e/netdev.c
-@@ -4280,18 +4280,29 @@ static cycle_t e1000e_cyclecounter_read(const struct cyclecounter *cc)
- struct e1000_adapter *adapter = container_of(cc, struct e1000_adapter,
- cc);
- struct e1000_hw *hw = &adapter->hw;
-+ u32 systimel_1, systimel_2, systimeh;
- cycle_t systim, systim_next;
-- /* SYSTIMH latching upon SYSTIML read does not work well. To fix that
-- * we don't want to allow overflow of SYSTIML and a change to SYSTIMH
-- * to occur between reads, so if we read a vale close to overflow, we
-- * wait for overflow to occur and read both registers when its safe.
-+ /* SYSTIMH latching upon SYSTIML read does not work well.
-+ * This means that if SYSTIML overflows after we read it but before
-+ * we read SYSTIMH, the value of SYSTIMH has been incremented and we
-+ * will experience a huge non linear increment in the systime value
-+ * to fix that we test for overflow and if true, we re-read systime.
- */
-- u32 systim_overflow_latch_fix = 0x3FFFFFFF;
--
-- do {
-- systim = (cycle_t)er32(SYSTIML);
-- } while (systim > systim_overflow_latch_fix);
-- systim |= (cycle_t)er32(SYSTIMH) << 32;
-+ systimel_1 = er32(SYSTIML);
-+ systimeh = er32(SYSTIMH);
-+ systimel_2 = er32(SYSTIML);
-+ /* Check for overflow. If there was no overflow, use the values */
-+ if (systimel_1 < systimel_2) {
-+ systim = (cycle_t)systimel_1;
-+ systim |= (cycle_t)systimeh << 32;
-+ } else {
-+ /* There was an overflow, read again SYSTIMH, and use
-+ * systimel_2
-+ */
-+ systimeh = er32(SYSTIMH);
-+ systim = (cycle_t)systimel_2;
-+ systim |= (cycle_t)systimeh << 32;
-+ }
-
- if ((hw->mac.type == e1000_82574) || (hw->mac.type == e1000_82583)) {
- u64 incvalue, time_delta, rem, temp;
---
-2.5.1
-
diff --git a/0001-fix-bridge-regression.patch b/0001-fix-bridge-regression.patch
deleted file mode 100644
index 250dfcbcfbf8..000000000000
--- a/0001-fix-bridge-regression.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-@@ -, +, @@
----
- net/bridge/br_multicast.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
---- a/net/bridge/br_multicast.c
-+++ a/net/bridge/br_multicast.c
-@@ -991,7 +991,7 @@ static int br_ip4_multicast_igmp3_report(struct net_bridge *br,
-
- ih = igmpv3_report_hdr(skb);
- num = ntohs(ih->ngrec);
-- len = sizeof(*ih);
-+ len = skb_transport_offset(skb) + sizeof(*ih);
-
- for (i = 0; i < num; i++) {
- len += sizeof(*grec);
-@@ -1052,7 +1052,7 @@ static int br_ip6_multicast_mld2_report(struct net_bridge *br,
-
- icmp6h = icmp6_hdr(skb);
- num = ntohs(icmp6h->icmp6_dataun.un_data16[1]);
-- len = sizeof(*icmp6h);
-+ len = skb_transport_offset(skb) + sizeof(*icmp6h);
-
- for (i = 0; i < num; i++) {
- __be16 *nsrcs, _nsrcs;
---
diff --git a/0001-make_flush_workqueue_non_gpl.patch b/0001-make_flush_workqueue_non_gpl.patch
deleted file mode 100644
index 1ba8cb9b3de0..000000000000
--- a/0001-make_flush_workqueue_non_gpl.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 1dadafa86a779884f14a6e7a3ddde1a57b0a0a65 Mon Sep 17 00:00:00 2001
-From: Tim Gardner <tim.gardner@canonical.com>
-Date: Tue, 4 Aug 2015 11:26:04 -0600
-Subject: workqueue: Make flush_workqueue() available again to non GPL modules
-
-Commit 37b1ef31a568fc02e53587620226e5f3c66454c8 ("workqueue: move
-flush_scheduled_work() to workqueue.h") moved the exported non GPL
-flush_scheduled_work() from a function to an inline wrapper.
-Unfortunately, it directly calls flush_workqueue() which is a GPL function.
-This has the effect of changing the licensing requirement for this function
-and makes it unavailable to non GPL modules.
-
-See commit ad7b1f841f8a54c6d61ff181451f55b68175e15a ("workqueue: Make
-schedule_work() available again to non GPL modules") for precedent.
-
-Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
-Signed-off-by: Tejun Heo <tj@kernel.org>
-
-diff --git a/kernel/workqueue.c b/kernel/workqueue.c
-index 4c4f061..a413acb 100644
---- a/kernel/workqueue.c
-+++ b/kernel/workqueue.c
-@@ -2614,7 +2614,7 @@ void flush_workqueue(struct workqueue_struct *wq)
- out_unlock:
- mutex_unlock(&wq->mutex);
- }
--EXPORT_SYMBOL_GPL(flush_workqueue);
-+EXPORT_SYMBOL(flush_workqueue);
-
- /**
- * drain_workqueue - drain a workqueue
---
-cgit v0.10.2
-
diff --git a/0001-netfilter-conntrack-use-nf_ct_tmpl_free-in-CT-synpro.patch b/0001-netfilter-conntrack-use-nf_ct_tmpl_free-in-CT-synpro.patch
deleted file mode 100644
index 0918357e1f8d..000000000000
--- a/0001-netfilter-conntrack-use-nf_ct_tmpl_free-in-CT-synpro.patch
+++ /dev/null
@@ -1,103 +0,0 @@
-From 9cf94eab8b309e8bcc78b41dd1561c75b537dd0b Mon Sep 17 00:00:00 2001
-From: Daniel Borkmann <daniel@iogearbox.net>
-Date: Mon, 31 Aug 2015 19:11:02 +0200
-Subject: [PATCH] netfilter: conntrack: use nf_ct_tmpl_free in CT/synproxy
- error paths
-
-Commit 0838aa7fcfcd ("netfilter: fix netns dependencies with conntrack
-templates") migrated templates to the new allocator api, but forgot to
-update error paths for them in CT and synproxy to use nf_ct_tmpl_free()
-instead of nf_conntrack_free().
-
-Due to that, memory is being freed into the wrong kmemcache, but also
-we drop the per net reference count of ct objects causing an imbalance.
-
-In Brad's case, this leads to a wrap-around of net->ct.count and thus
-lets __nf_conntrack_alloc() refuse to create a new ct object:
-
- [ 10.340913] xt_addrtype: ipv6 does not support BROADCAST matching
- [ 10.810168] nf_conntrack: table full, dropping packet
- [ 11.917416] r8169 0000:07:00.0 eth0: link up
- [ 11.917438] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
- [ 12.815902] nf_conntrack: table full, dropping packet
- [ 15.688561] nf_conntrack: table full, dropping packet
- [ 15.689365] nf_conntrack: table full, dropping packet
- [ 15.690169] nf_conntrack: table full, dropping packet
- [ 15.690967] nf_conntrack: table full, dropping packet
- [...]
-
-With slab debugging, it also reports the wrong kmemcache (kmalloc-512 vs.
-nf_conntrack_ffffffff81ce75c0) and reports poison overwrites, etc. Thus,
-to fix the problem, export and use nf_ct_tmpl_free() instead.
-
-Fixes: 0838aa7fcfcd ("netfilter: fix netns dependencies with conntrack templates")
-Reported-by: Brad Jackson <bjackson0971@gmail.com>
-Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
-Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
----
- include/net/netfilter/nf_conntrack.h | 1 +
- net/netfilter/nf_conntrack_core.c | 3 ++-
- net/netfilter/nf_synproxy_core.c | 2 +-
- net/netfilter/xt_CT.c | 2 +-
- 4 files changed, 5 insertions(+), 3 deletions(-)
-
-diff --git a/include/net/netfilter/nf_conntrack.h b/include/net/netfilter/nf_conntrack.h
-index 37cd391..4023c4c 100644
---- a/include/net/netfilter/nf_conntrack.h
-+++ b/include/net/netfilter/nf_conntrack.h
-@@ -292,6 +292,7 @@ extern unsigned int nf_conntrack_hash_rnd;
- void init_nf_conntrack_hash_rnd(void);
-
- struct nf_conn *nf_ct_tmpl_alloc(struct net *net, u16 zone, gfp_t flags);
-+void nf_ct_tmpl_free(struct nf_conn *tmpl);
-
- #define NF_CT_STAT_INC(net, count) __this_cpu_inc((net)->ct.stat->count)
- #define NF_CT_STAT_INC_ATOMIC(net, count) this_cpu_inc((net)->ct.stat->count)
-diff --git a/net/netfilter/nf_conntrack_core.c b/net/netfilter/nf_conntrack_core.c
-index 3c20d02..0625a42 100644
---- a/net/netfilter/nf_conntrack_core.c
-+++ b/net/netfilter/nf_conntrack_core.c
-@@ -320,12 +320,13 @@ out_free:
- }
- EXPORT_SYMBOL_GPL(nf_ct_tmpl_alloc);
-
--static void nf_ct_tmpl_free(struct nf_conn *tmpl)
-+void nf_ct_tmpl_free(struct nf_conn *tmpl)
- {
- nf_ct_ext_destroy(tmpl);
- nf_ct_ext_free(tmpl);
- kfree(tmpl);
- }
-+EXPORT_SYMBOL_GPL(nf_ct_tmpl_free);
-
- static void
- destroy_conntrack(struct nf_conntrack *nfct)
-diff --git a/net/netfilter/nf_synproxy_core.c b/net/netfilter/nf_synproxy_core.c
-index d7f1685..d6ee8f8 100644
---- a/net/netfilter/nf_synproxy_core.c
-+++ b/net/netfilter/nf_synproxy_core.c
-@@ -378,7 +378,7 @@ static int __net_init synproxy_net_init(struct net *net)
- err3:
- free_percpu(snet->stats);
- err2:
-- nf_conntrack_free(ct);
-+ nf_ct_tmpl_free(ct);
- err1:
- return err;
- }
-diff --git a/net/netfilter/xt_CT.c b/net/netfilter/xt_CT.c
-index 43ddeee..f3377ce 100644
---- a/net/netfilter/xt_CT.c
-+++ b/net/netfilter/xt_CT.c
-@@ -233,7 +233,7 @@ out:
- return 0;
-
- err3:
-- nf_conntrack_free(ct);
-+ nf_ct_tmpl_free(ct);
- err2:
- nf_ct_l3proto_module_put(par->family);
- err1:
---
-2.5.1
-
diff --git a/PKGBUILD b/PKGBUILD
index 8a9c887e962a..71ea16d4e346 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -21,7 +21,6 @@ source=("https://www.kernel.org/pub/linux/kernel/v4.x/${_srcname}.tar.xz"
# standard config files for mkinitcpio ramdisk
'linux.preset'
'bluetooth.patch'
- 'thunderbolt.patch'
'change-default-console-loglevel.patch')
sha256sums=('cf20e044f17588d2a42c8f2a450b0fd84dfdbd579b489d93e9ab7d0e8b45dbeb'
@@ -32,7 +31,6 @@ sha256sums=('cf20e044f17588d2a42c8f2a450b0fd84dfdbd579b489d93e9ab7d0e8b45dbeb'
'6f2cf8449aeda3473e0577ef13e8cd7b0bd2fc2dee8d6d830eeb73e485279f2d'
'f0d90e756f14533ee67afda280500511a62465b4f76adcc5effa95a40045179c'
'dcbed1ae73c4e1383210bad6f1f446bdd13f8b1c24d89bcf0483acc5e178c379'
- '4909b37856f4b2374e54e44d656971a1f1027900444ac494f4dd1bb113dc9c97'
'1256b241cd477b265a3c2d64bdc19ffe3c9bbcee82ea3994c590c2c76e767d99')
validpgpkeys=(
'ABAF11C65A2970B130ABE3C479BE3E4300411886' # Linus Torvalds
@@ -51,8 +49,7 @@ prepare() {
# http://git.kernel.org/?p=linux/kernel/git/stable/stable-queue.git
patch -p1 -i "${srcdir}/bluetooth.patch"
- patch -p1 -i "${srcdir}/thunderbolt.patch"
-
+
# set DEFAULT_CONSOLE_LOGLEVEL to 4 (same value as the 'quiet' kernel param)
# remove this when a Kconfig knob is made available by upstream
# (relevant patch sent upstream: https://lkml.org/lkml/2011/7/26/227)
@@ -152,7 +149,7 @@ _package() {
mv "${pkgdir}/lib" "${pkgdir}/usr/"
# add vmlinux
- install -D -m644 vmlinux "${pkgdir}/usr/lib/modules/${_kernver}/build/vmlinux"
+ install -D -m644 vmlinux "${pkgdir}/usr/lib/modules/${_kernver}/build/vmlinux"
}
_package-headers() {
diff --git a/thunderbolt.patch b/thunderbolt.patch
deleted file mode 100644
index 8cd490c0646f..000000000000
--- a/thunderbolt.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-diff --git a/drivers/extcon/extcon.c b/drivers/extcon/extcon.c
-index a07addd..8dd0af1 100644
---- a/drivers/extcon/extcon.c
-+++ b/drivers/extcon/extcon.c
-@@ -159,7 +159,7 @@ static int find_cable_index_by_name(struct extcon_dev *edev, const char *name)
- static bool is_extcon_changed(u32 prev, u32 new, int idx, bool *attached)
- {
- if (((prev >> idx) & 0x1) != ((new >> idx) & 0x1)) {
-- *attached = new ? true : false;
-+ *attached = ((new >> idx) & 0x1) ? true : false;
- return true;
- }
-
-diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c
-index 2f9aead..652afd1 100644
---- a/drivers/hv/channel_mgmt.c
-+++ b/drivers/hv/channel_mgmt.c
-@@ -204,6 +204,8 @@ void hv_process_channel_removal(struct vmbus_channel *channel, u32 relid)
- spin_lock_irqsave(&vmbus_connection.channel_lock, flags);
- list_del(&channel->listentry);
- spin_unlock_irqrestore(&vmbus_connection.channel_lock, flags);
-+
-+ primary_channel = channel;
- } else {
- primary_channel = channel->primary_channel;
- spin_lock_irqsave(&primary_channel->lock, flags);
-@@ -211,6 +213,14 @@ void hv_process_channel_removal(struct vmbus_channel *channel, u32 relid)
- primary_channel->num_sc--;
- spin_unlock_irqrestore(&primary_channel->lock, flags);
- }
-+
-+ /*
-+ * We need to free the bit for init_vp_index() to work in the case
-+ * of sub-channel, when we reload drivers like hv_netvsc.
-+ */
-+ cpumask_clear_cpu(channel->target_cpu,
-+ &primary_channel->alloced_cpus_in_node);
-+
- free_channel(channel);
- }
-
-diff --git a/drivers/misc/mei/debugfs.c b/drivers/misc/mei/debugfs.c
-index 4b469cf..8504dbe 100644
---- a/drivers/misc/mei/debugfs.c
-+++ b/drivers/misc/mei/debugfs.c
-@@ -204,6 +204,8 @@ int mei_dbgfs_register(struct mei_device *dev, const char *name)
- if (!dir)
- return -ENOMEM;
-
-+ dev->dbgfs_dir = dir;
-+
- f = debugfs_create_file("meclients", S_IRUSR, dir,
- dev, &mei_dbgfs_fops_meclients);
- if (!f) {
-@@ -228,7 +230,6 @@ int mei_dbgfs_register(struct mei_device *dev, const char *name)
- dev_err(dev->dev, "allow_fixed_address: registration failed\n");
- goto err;
- }
-- dev->dbgfs_dir = dir;
- return 0;
- err:
- mei_dbgfs_deregister(dev);
-diff --git a/drivers/thunderbolt/nhi.c b/drivers/thunderbolt/nhi.c
-index c68fe12..20a41f7 100644
---- a/drivers/thunderbolt/nhi.c
-+++ b/drivers/thunderbolt/nhi.c
-@@ -643,7 +643,7 @@ static struct pci_device_id nhi_ids[] = {
- {
- .class = PCI_CLASS_SYSTEM_OTHER << 8, .class_mask = ~0,
- .vendor = PCI_VENDOR_ID_INTEL, .device = 0x156c,
-- .subvendor = 0x2222, .subdevice = 0x1111,
-+ .subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID,
- },
- { 0,}
- };