lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200827101231.smqrhqu5da6jlz6i@vireshk-i7>
Date:   Thu, 27 Aug 2020 15:42:31 +0530
From:   Viresh Kumar <viresh.kumar@...aro.org>
To:     Arnd Bergmann <arnd@...db.de>
Cc:     Naresh Kamboju <naresh.kamboju@...aro.org>,
        Rajendra Nayak <rnayak@...eaurora.org>,
        open list <linux-kernel@...r.kernel.org>,
        Linux-Next Mailing List <linux-next@...r.kernel.org>,
        Stephen Rothwell <sfr@...b.auug.org.au>,
        linux-clk <linux-clk@...r.kernel.org>,
        linux-mmc <linux-mmc@...r.kernel.org>,
        lkft-triage@...ts.linaro.org, John Stultz <john.stultz@...aro.org>,
        Daniel Lezcano <daniel.lezcano@...aro.org>,
        Ulf Hansson <ulf.hansson@...aro.org>,
        Michael Turquette <mturquette@...libre.com>,
        Stephen Boyd <sboyd@...nel.org>,
        Lars Povlsen <lars.povlsen@...rochip.com>,
        madhuparnabhowmik10@...il.com
Subject: Re: Kernel panic : Unable to handle kernel paging request at virtual
 address - dead address between user and kernel address ranges

On 27-08-20, 11:48, Arnd Bergmann wrote:
> > > [    3.680477]  dev_pm_opp_put_clkname+0x30/0x58
> > > [    3.683431]  sdhci_msm_probe+0x284/0x9a0
> 
> dev_pm_opp_put_clkname() is part of the error handling in the
> probe function, so I would deduct there are two problems:
> 
> - something failed during the probe and the driver is trying
>   to unwind
> - the error handling it self is buggy and tries to undo something
>   again that has already been undone.

Right.

> This points to Viresh's
> d05a7238fe1c mmc: sdhci-msm: Unconditionally call dev_pm_opp_of_remove_table()

I completely forgot that Ulf already pushed this patch and I was
wondering on which of the OPP core changes I wrote have done this :(

> Most likely this is not the entire problem but it uncovered a preexisting
> bug.

I think this is.

Naresh: Can you please test with this diff ?

diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index b7e47107a31a..401839a97b57 100644
--- a/drivers/mmc/host/sdhci-msm.c
+++ b/drivers/mmc/host/sdhci-msm.c
@@ -2286,7 +2286,7 @@ static int sdhci_msm_probe(struct platform_device *pdev)
        ret = dev_pm_opp_of_add_table(&pdev->dev);
        if (ret != -ENODEV) {
                dev_err(&pdev->dev, "Invalid OPP table in Device tree\n");
-               goto opp_cleanup;
+               goto opp_put_clkname;
        }
 
        /* Vote for maximum clock rate for maximum performance */
@@ -2451,6 +2451,7 @@ static int sdhci_msm_probe(struct platform_device *pdev)
                                   msm_host->bulk_clks);
 opp_cleanup:
        dev_pm_opp_of_remove_table(&pdev->dev);
+opp_put_clkname:
        dev_pm_opp_put_clkname(msm_host->opp_table);
 bus_clk_disable:
        if (!IS_ERR(msm_host->bus_clk))

-- 
viresh

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ