Patch "pinctrl: qcom: Use return value from irq_set_wake() call" has been added to the 5.9-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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

    pinctrl: qcom: Use return value from irq_set_wake() call

to the 5.9-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-qcom-use-return-value-from-irq_set_wake-call.patch
and it can be found in the queue-5.9 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 0fc9ff7e0bc76fd98b2656eee66a182eaab0d37b
Author: Maulik Shah <mkshah@xxxxxxxxxxxxxx>
Date:   Mon Sep 28 10:02:00 2020 +0530

    pinctrl: qcom: Use return value from irq_set_wake() call
    
    [ Upstream commit f41aaca593377a4fe3984459fd4539481263b4cd ]
    
    msmgpio irqchip was not using return value of irq_set_irq_wake() callback
    since previously GIC-v3 irqchip neither had IRQCHIP_SKIP_SET_WAKE flag nor
    it implemented .irq_set_wake callback. This lead to irq_set_irq_wake()
    return error -ENXIO.
    
    However from 'commit 4110b5cbb014 ("irqchip/gic-v3: Allow interrupt to be
    configured as wake-up sources")' GIC irqchip has IRQCHIP_SKIP_SET_WAKE
    flag.
    
    Use return value from irq_set_irq_wake() and irq_chip_set_wake_parent()
    instead of always returning success.
    
    Fixes: e35a6ae0eb3a ("pinctrl/msm: Setup GPIO chip in hierarchy")
    Signed-off-by: Maulik Shah <mkshah@xxxxxxxxxxxxxx>
    Signed-off-by: Marc Zyngier <maz@xxxxxxxxxx>
    Tested-by: Stephen Boyd <swboyd@xxxxxxxxxxxx>
    Reviewed-by: Douglas Anderson <dianders@xxxxxxxxxxxx>
    Reviewed-by: Stephen Boyd <swboyd@xxxxxxxxxxxx>
    Acked-by: Bjorn Andersson <bjorn.andersson@xxxxxxxxxx>
    Acked-by: Linus Walleij <linus.walleij@xxxxxxxxxx>
    Link: https://lore.kernel.org/r/1601267524-20199-3-git-send-email-mkshah@xxxxxxxxxxxxxx
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/pinctrl/qcom/pinctrl-msm.c b/drivers/pinctrl/qcom/pinctrl-msm.c
index 1c23f5c88fdd4..1df232266f63a 100644
--- a/drivers/pinctrl/qcom/pinctrl-msm.c
+++ b/drivers/pinctrl/qcom/pinctrl-msm.c
@@ -1077,12 +1077,10 @@ static int msm_gpio_irq_set_wake(struct irq_data *d, unsigned int on)
 	 * when TLMM is powered on. To allow that, enable the GPIO
 	 * summary line to be wakeup capable at GIC.
 	 */
-	if (d->parent_data)
-		irq_chip_set_wake_parent(d, on);
-
-	irq_set_irq_wake(pctrl->irq, on);
+	if (d->parent_data && test_bit(d->hwirq, pctrl->skip_wake_irqs))
+		return irq_chip_set_wake_parent(d, on);
 
-	return 0;
+	return irq_set_irq_wake(pctrl->irq, on);
 }
 
 static int msm_gpio_irq_reqres(struct irq_data *d)



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux