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: <CAD=FV=Vpw0VeSucRBDdkT5g6N5DrJeecBuDT3fMhhzF8adVpGQ@mail.gmail.com>
Date:   Thu, 9 Jul 2020 07:35:35 -0700
From:   Doug Anderson <dianders@...omium.org>
To:     Akash Asthana <akashast@...eaurora.org>
Cc:     Mark Brown <broonie@...nel.org>, Andy Gross <agross@...nel.org>,
        Bjorn Andersson <bjorn.andersson@...aro.org>,
        linux-arm-msm <linux-arm-msm@...r.kernel.org>,
        Rajendra Nayak <rnayak@...eaurora.org>,
        Georgi Djakov <georgi.djakov@...aro.org>,
        Stephen Boyd <swboyd@...omium.org>,
        Maulik Shah <mkshah@...eaurora.org>, ctheegal@...eaurora.org,
        Matthias Kaehlcke <mka@...omium.org>,
        LKML <linux-kernel@...r.kernel.org>,
        linux-spi <linux-spi@...r.kernel.org>
Subject: Re: [PATCH] spi: spi-geni-qcom: Set the clock properly at runtime resume

Hi,

On Thu, Jul 9, 2020 at 12:30 AM Akash Asthana <akashast@...eaurora.org> wrote:
>
> Hi Doug,
>
> >
> > @@ -670,7 +674,13 @@ static int __maybe_unused spi_geni_runtime_resume(struct device *dev)
> >       if (ret)
> >               return ret;
> >
> > -     return geni_se_resources_on(&mas->se);
> > +     ret = geni_se_resources_on(&mas->se);
> > +     if (ret)
> > +             return ret;
> > +
> > +     dev_pm_opp_set_rate(mas->dev, mas->cur_sclk_hz);
> > +
> > +     return 0;
> >   }
>
> Should we fail to resume if error is returned from 'opp_set_rate'?
>
> 'spi_geni_prepare_message' use to fail for any error from
> 'opp_set_rate'  before patch series "Avoid clock setting if not needed".
>
> But now it's possible that 'prepare_message' can return success even
> when opp are not at desired state(from previous resume call).

I can.  I was following the spi_geni_runtime_suspend() example and
just calling it, but I suppose it makes sense that setting the clock
to 0 failing isn't as important as setting it to something non-zero.

I'll post a v2 real quick and keep Acks / Reviews.

-Doug

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ