Skip to contentSkip to conversation

Patch "pinctrl: mediatek: fix dual-edge code defect" has been added to the 4.6-stable tree

PATCH [email protected] 1 participant 1 message Jun 18, 2016

Subsystems (4)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

pinctrl: mediatek: fix dual-edge code defect

to the 4.6-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
pinctrl-mediatek-fix-dual-edge-code-defect.patch
and it can be found in the queue-4.6 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From 5edf673d07fdcb6498be24914f3f38f8d8843199 Mon Sep 17 00:00:00 2001

From: "hongkun.cao" <[email protected]>
Date: Sat, 21 May 2016 15:23:39 +0800
Subject: pinctrl: mediatek: fix dual-edge code defect

From: hongkun.cao <[email protected]>

commit 5edf673d07fdcb6498be24914f3f38f8d8843199 upstream.

When a dual-edge irq is triggered, an incorrect irq will be reported on condition that the external signal is not stable and this incorrect irq has been registered.
Correct the register offset.

---
 drivers/pinctrl/mediatek/pinctrl-mtk-common.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/pinctrl/mediatek/pinctrl-mtk-common.c +3 -2
@@ -1256,9 +1256,10 @@ static void mtk_eint_irq_handler(struct
 	const struct mtk_desc_pin *pin;
 
 	chained_irq_enter(chip, desc);
-	for (eint_num = 0; eint_num < pctl->devdata->ap_num; eint_num += 32) {
+	for (eint_num = 0;
+	     eint_num < pctl->devdata->ap_num;
+	     eint_num += 32, reg += 4) {
 		status = readl(reg);
-		reg += 4;
 		while (status) {
 			offset = __ffs(status);
 			index = eint_num + offset;

Patches currently in stable-queue which might be from [email protected] are

queue-4.6/pinctrl-mediatek-fix-dual-edge-code-defect.patch