stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: gregkh@linuxfoundation.org
Cc: linus.walleij@linaro.org, bjorn.andersson@linaro.org,
	david@ixit.cz, ilina@codeaurora.org, maz@kernel.org,
	swboyd@chromium.org, stable@vger.kernel.org
Subject: Re: FAILED: patch "[PATCH] pinctrl: qcom: Assign irq_eoi conditionally" failed to apply to 5.4-stable tree
Date: Wed, 18 Mar 2020 12:40:23 -0400	[thread overview]
Message-ID: <20200318164023.GG4189@sasha-vm> (raw)
In-Reply-To: <1584358449195216@kroah.com>

On Mon, Mar 16, 2020 at 12:34:09PM +0100, gregkh@linuxfoundation.org wrote:
>
>The patch below does not apply to the 5.4-stable tree.
>If someone wants it applied there, or to any other stable or longterm
>tree, then please email the backport, including the original git commit
>id to <stable@vger.kernel.org>.
>
>thanks,
>
>greg k-h
>
>------------------ original commit in Linus's tree ------------------
>
>From 1cada2f307665e208a486d7ac2294ed9a6f74a6f Mon Sep 17 00:00:00 2001
>From: Linus Walleij <linus.walleij@linaro.org>
>Date: Mon, 9 Mar 2020 16:26:04 +0100
>Subject: [PATCH] pinctrl: qcom: Assign irq_eoi conditionally
>
>The hierarchical parts of MSM pinctrl/GPIO is only
>used when the device tree has a "wakeup-parent" as
>a phandle, but the .irq_eoi is anyway assigned leading
>to semantic problems on elder Qualcomm chipsets.
>
>When the drivers/mfd/qcom-pm8xxx.c driver calls
>chained_irq_exit() that call will in turn call chip->irq_eoi()
>which is set to irq_chip_eoi_parent() by default on a
>hierachical IRQ chip, and the parent is pinctrl-msm.c
>so that will in turn unconditionally call
>irq_chip_eoi_parent() again, but its parent is invalid
>so we get the following crash:
>
> Unnable to handle kernel NULL pointer dereference at
> virtual address 00000010
> pgd = (ptrval)
> [00000010] *pgd=00000000
> Internal error: Oops: 5 [#1] PREEMPT SMP ARM
> (...)
> PC is at irq_chip_eoi_parent+0x4/0x10
> LR is at pm8xxx_irq_handler+0x1b4/0x2d8
>
>If we solve this crash by avoiding to call up to
>irq_chip_eoi_parent(), the machine will hang and get
>reset by the watchdog, because of semantic issues,
>probably inside irq_chip.
>
>As a solution, just assign the .irq_eoi conditionally if
>we are actually using a wakeup parent.
>
>Cc: David Heidelberg <david@ixit.cz>
>Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
>Cc: Lina Iyer <ilina@codeaurora.org>
>Cc: Stephen Boyd <swboyd@chromium.org>
>Cc: stable@vger.kernel.org
>Fixes: e35a6ae0eb3a ("pinctrl/msm: Setup GPIO chip in hierarchy")

This shouldn't go in 5.4, e35a6ae0eb3a is not there.

-- 
Thanks,
Sasha

  reply	other threads:[~2020-03-18 16:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-16 11:34 FAILED: patch "[PATCH] pinctrl: qcom: Assign irq_eoi conditionally" failed to apply to 5.4-stable tree gregkh
2020-03-18 16:40 ` Sasha Levin [this message]
2020-03-18 16:53   ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200318164023.GG4189@sasha-vm \
    --to=sashal@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=david@ixit.cz \
    --cc=gregkh@linuxfoundation.org \
    --cc=ilina@codeaurora.org \
    --cc=linus.walleij@linaro.org \
    --cc=maz@kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=swboyd@chromium.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).