From: Greg Kroah-Hartman Date: Mon, 6 Apr 2015 19:01:32 +0000 (+0200) Subject: 3.14-stable patches X-Git-Tag: v3.10.74~8 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bc183cdf96b511a7954c991a0107939d2689c089;p=thirdparty%2Fkernel%2Fstable-queue.git 3.14-stable patches added patches: of-irq-fix-of_irq_parse_one-returned-error-codes.patch perf-fix-irq_work-tail-recursion.patch phy-find-the-right-match-in-devm_phy_destroy.patch staging-vt6656-vnt_rf_setpower-fix-missing-rate-rate_12m.patch vt6655-rfbsetpower-fix-missing-rate-rate_12m.patch --- diff --git a/queue-3.14/of-irq-fix-of_irq_parse_one-returned-error-codes.patch b/queue-3.14/of-irq-fix-of_irq_parse_one-returned-error-codes.patch new file mode 100644 index 00000000000..5d1fdcf9ba0 --- /dev/null +++ b/queue-3.14/of-irq-fix-of_irq_parse_one-returned-error-codes.patch @@ -0,0 +1,57 @@ +From d7c146053dd195b90c79b9b8131431f44541d015 Mon Sep 17 00:00:00 2001 +From: Laurent Pinchart +Date: Wed, 18 Mar 2015 00:21:32 +0200 +Subject: of/irq: Fix of_irq_parse_one() returned error codes + +From: Laurent Pinchart + +commit d7c146053dd195b90c79b9b8131431f44541d015 upstream. + +The error code paths that require cleanup use a goto to jump to the +cleanup code and return an error code. However, the error code variable +res, which is initialized to -EINVAL when declared, is then overwritten +with the return value of of_parse_phandle_with_args(), and reused as the +return code from of_irq_parse_one(). This leads to an undetermined error +being returned instead of the expected -EINVAL value. Fix it. + +Signed-off-by: Laurent Pinchart +Signed-off-by: Rob Herring +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/of/irq.c | 10 +++++++--- + 1 file changed, 7 insertions(+), 3 deletions(-) + +--- a/drivers/of/irq.c ++++ b/drivers/of/irq.c +@@ -290,7 +290,7 @@ int of_irq_parse_one(struct device_node + struct device_node *p; + const __be32 *intspec, *tmp, *addr; + u32 intsize, intlen; +- int i, res = -EINVAL; ++ int i, res; + + pr_debug("of_irq_parse_one: dev=%s, index=%d\n", of_node_full_name(device), index); + +@@ -323,15 +323,19 @@ int of_irq_parse_one(struct device_node + + /* Get size of interrupt specifier */ + tmp = of_get_property(p, "#interrupt-cells", NULL); +- if (tmp == NULL) ++ if (tmp == NULL) { ++ res = -EINVAL; + goto out; ++ } + intsize = be32_to_cpu(*tmp); + + pr_debug(" intsize=%d intlen=%d\n", intsize, intlen); + + /* Check index */ +- if ((index + 1) * intsize > intlen) ++ if ((index + 1) * intsize > intlen) { ++ res = -EINVAL; + goto out; ++ } + + /* Copy intspec into irq structure */ + intspec += index * intsize; diff --git a/queue-3.14/perf-fix-irq_work-tail-recursion.patch b/queue-3.14/perf-fix-irq_work-tail-recursion.patch new file mode 100644 index 00000000000..efef1089515 --- /dev/null +++ b/queue-3.14/perf-fix-irq_work-tail-recursion.patch @@ -0,0 +1,78 @@ +From d525211f9d1be8b523ec7633f080f2116f5ea536 Mon Sep 17 00:00:00 2001 +From: Peter Zijlstra +Date: Thu, 19 Feb 2015 18:03:11 +0100 +Subject: perf: Fix irq_work 'tail' recursion + +From: Peter Zijlstra + +commit d525211f9d1be8b523ec7633f080f2116f5ea536 upstream. + +Vince reported a watchdog lockup like: + + [] perf_tp_event+0xc4/0x210 + [] perf_trace_lock+0x12a/0x160 + [] lock_release+0x130/0x260 + [] _raw_spin_unlock_irqrestore+0x24/0x40 + [] do_send_sig_info+0x5d/0x80 + [] send_sigio_to_task+0x12f/0x1a0 + [] send_sigio+0xae/0x100 + [] kill_fasync+0x97/0xf0 + [] perf_event_wakeup+0xd4/0xf0 + [] perf_pending_event+0x33/0x60 + [] irq_work_run_list+0x4c/0x80 + [] irq_work_run+0x18/0x40 + [] smp_trace_irq_work_interrupt+0x3f/0xc0 + [] trace_irq_work_interrupt+0x6d/0x80 + +Which is caused by an irq_work generating new irq_work and therefore +not allowing forward progress. + +This happens because processing the perf irq_work triggers another +perf event (tracepoint stuff) which in turn generates an irq_work ad +infinitum. + +Avoid this by raising the recursion counter in the irq_work -- which +effectively disables all software events (including tracepoints) from +actually triggering again. + +Reported-by: Vince Weaver +Tested-by: Vince Weaver +Signed-off-by: Peter Zijlstra (Intel) +Cc: Arnaldo Carvalho de Melo +Cc: Jiri Olsa +Cc: Paul Mackerras +Cc: Steven Rostedt +Link: http://lkml.kernel.org/r/20150219170311.GH21418@twins.programming.kicks-ass.net +Signed-off-by: Ingo Molnar +Signed-off-by: Greg Kroah-Hartman + +--- + kernel/events/core.c | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +--- a/kernel/events/core.c ++++ b/kernel/events/core.c +@@ -4232,6 +4232,13 @@ static void perf_pending_event(struct ir + { + struct perf_event *event = container_of(entry, + struct perf_event, pending); ++ int rctx; ++ ++ rctx = perf_swevent_get_recursion_context(); ++ /* ++ * If we 'fail' here, that's OK, it means recursion is already disabled ++ * and we won't recurse 'further'. ++ */ + + if (event->pending_disable) { + event->pending_disable = 0; +@@ -4242,6 +4249,9 @@ static void perf_pending_event(struct ir + event->pending_wakeup = 0; + perf_event_wakeup(event); + } ++ ++ if (rctx >= 0) ++ perf_swevent_put_recursion_context(rctx); + } + + /* diff --git a/queue-3.14/phy-find-the-right-match-in-devm_phy_destroy.patch b/queue-3.14/phy-find-the-right-match-in-devm_phy_destroy.patch new file mode 100644 index 00000000000..4382efb7158 --- /dev/null +++ b/queue-3.14/phy-find-the-right-match-in-devm_phy_destroy.patch @@ -0,0 +1,36 @@ +From 2f1bce487cd0a02623cff3d877940f9a2026341c Mon Sep 17 00:00:00 2001 +From: Thierry Reding +Date: Wed, 25 Feb 2015 16:16:29 +0100 +Subject: phy: Find the right match in devm_phy_destroy() + +From: Thierry Reding + +commit 2f1bce487cd0a02623cff3d877940f9a2026341c upstream. + +devm_phy_create() stores the pointer to the new PHY at the address +returned by devres_alloc(). The res parameter passed to devm_phy_match() +is therefore the location where the pointer to the PHY is stored, hence +it needs to be dereferenced before comparing to the match data in order +to find the correct match. + +Signed-off-by: Thierry Reding +Signed-off-by: Kishon Vijay Abraham I +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/phy/phy-core.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +--- a/drivers/phy/phy-core.c ++++ b/drivers/phy/phy-core.c +@@ -50,7 +50,9 @@ static void devm_phy_consume(struct devi + + static int devm_phy_match(struct device *dev, void *res, void *match_data) + { +- return res == match_data; ++ struct phy **phy = res; ++ ++ return *phy == match_data; + } + + static struct phy *phy_lookup(struct device *device, const char *port) diff --git a/queue-3.14/series b/queue-3.14/series index 793f449fca9..31e1ff5e105 100644 --- a/queue-3.14/series +++ b/queue-3.14/series @@ -20,3 +20,8 @@ nl80211-ignore-ht-vht-capabilities-without-qos-wmm.patch mac80211-disable-u-apsd-queues-by-default.patch mac80211-drop-unencrypted-frames-in-mesh-fwding.patch revert-iwlwifi-mvm-fix-failure-path-when-power_update.patch +phy-find-the-right-match-in-devm_phy_destroy.patch +of-irq-fix-of_irq_parse_one-returned-error-codes.patch +perf-fix-irq_work-tail-recursion.patch +staging-vt6656-vnt_rf_setpower-fix-missing-rate-rate_12m.patch +vt6655-rfbsetpower-fix-missing-rate-rate_12m.patch diff --git a/queue-3.14/staging-vt6656-vnt_rf_setpower-fix-missing-rate-rate_12m.patch b/queue-3.14/staging-vt6656-vnt_rf_setpower-fix-missing-rate-rate_12m.patch new file mode 100644 index 00000000000..a6b3069aa05 --- /dev/null +++ b/queue-3.14/staging-vt6656-vnt_rf_setpower-fix-missing-rate-rate_12m.patch @@ -0,0 +1,29 @@ +From 163fe301b9f78b6de57d0014eafe504fd20c0cd4 Mon Sep 17 00:00:00 2001 +From: Malcolm Priestley +Date: Sat, 7 Mar 2015 16:36:37 +0000 +Subject: staging: vt6656: vnt_rf_setpower: fix missing rate RATE_12M + +From: Malcolm Priestley + +commit 163fe301b9f78b6de57d0014eafe504fd20c0cd4 upstream. + +When the driver sets this rate a power of zero value is set causing +data flow stoppage until another rate is tried. + +Signed-off-by: Malcolm Priestley +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/staging/vt6656/rf.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/staging/vt6656/rf.c ++++ b/drivers/staging/vt6656/rf.c +@@ -752,6 +752,7 @@ int RFbSetPower(struct vnt_private *priv + break; + case RATE_6M: + case RATE_9M: ++ case RATE_12M: + case RATE_18M: + case RATE_24M: + case RATE_36M: diff --git a/queue-3.14/vt6655-rfbsetpower-fix-missing-rate-rate_12m.patch b/queue-3.14/vt6655-rfbsetpower-fix-missing-rate-rate_12m.patch new file mode 100644 index 00000000000..726bbff00ce --- /dev/null +++ b/queue-3.14/vt6655-rfbsetpower-fix-missing-rate-rate_12m.patch @@ -0,0 +1,29 @@ +From 40c8790bcb7ac74f3038153cd09310e220c6a1df Mon Sep 17 00:00:00 2001 +From: Malcolm Priestley +Date: Sat, 7 Mar 2015 17:04:54 +0000 +Subject: vt6655: RFbSetPower fix missing rate RATE_12M + +From: Malcolm Priestley + +commit 40c8790bcb7ac74f3038153cd09310e220c6a1df upstream. + +When the driver sets this rate a power of zero value is set causing +data flow stoppage until another rate is tried. + +Signed-off-by: Malcolm Priestley +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/staging/vt6655/rf.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/staging/vt6655/rf.c ++++ b/drivers/staging/vt6655/rf.c +@@ -936,6 +936,7 @@ bool RFbSetPower( + break; + case RATE_6M: + case RATE_9M: ++ case RATE_12M: + case RATE_18M: + byPwr = pDevice->abyOFDMPwrTbl[uCH]; + if (pDevice->byRFType == RF_UW2452) {