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] [day] [month] [year] [list]
Message-ID: <CAA+hA=RB_va3TRhjFBSofVqDEpj_LxLfUM84ead5D2LLZ3KRwA@mail.gmail.com>
Date:   Fri, 18 Jun 2021 20:47:57 +0800
From:   Dong Aisheng <dongas86@...il.com>
To:     Ezequiel Garcia <ezequiel@...labora.com>
Cc:     Mirela Rabulea <mirela.rabulea@....com>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>,
        "mchehab@...nel.org" <mchehab@...nel.org>,
        "shawnguo@...nel.org" <shawnguo@...nel.org>,
        "robh+dt@...nel.org" <robh+dt@...nel.org>,
        Aisheng Dong <aisheng.dong@....com>,
        "G.n. Zhou" <guoniu.zhou@....com>,
        dl-linux-imx <linux-imx@....com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Laurentiu Palcu <laurentiu.palcu@....com>,
        "linux-media@...r.kernel.org" <linux-media@...r.kernel.org>,
        "paul.kocialkowski@...tlin.com" <paul.kocialkowski@...tlin.com>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        Robert Chiras <robert.chiras@....com>,
        "p.zabel@...gutronix.de" <p.zabel@...gutronix.de>,
        Peng Fan <peng.fan@....com>,
        "hverkuil-cisco@...all.nl" <hverkuil-cisco@...all.nl>,
        Daniel Baluta <daniel.baluta@....com>,
        "kernel@...gutronix.de" <kernel@...gutronix.de>,
        "s.hauer@...gutronix.de" <s.hauer@...gutronix.de>
Subject: Re: [PATCH v13 2/2] arm64: dts: imx: Add jpeg encoder/decoder nodes

On Fri, Jun 11, 2021 at 11:01 PM Ezequiel Garcia <ezequiel@...labora.com> wrote:
>
> On Fri, 2021-06-11 at 21:33 +0800, Dong Aisheng wrote:
> > [...]
> >
> > > > > +img_subsys: bus@...00000 {
> > > > > +   compatible = "simple-bus";
> > > > > +   #address-cells = <1>;
> > > > > +   #size-cells = <1>;
> > > > > +   ranges = <0x58000000 0x0 0x58000000 0x1000000>;
> > > > > +
> > > > > +   img_ipg_clk: clock-img-ipg {
> > > > > +           compatible = "fixed-clock";
> > > > > +           #clock-cells = <0>;
> > > > > +           clock-frequency = <200000000>;
> > > > > +           clock-output-names = "img_ipg_clk";
> > > > > +   };
> > > > > +
> > > > > +   jpegdec: jpegdec@...00000 {
> > > >
> > > > Node should be disabled by default.
> > > > And enable it in board dts including LPCG.
> > >
> > > At version v5 of this patch, the node was disabled by default, and I
> > > received this feedback from Ezequiel Garcia:
> > >
> > > "Pure memory-to-memory are typically not enabled per-board, but just
> > > per-platform.
> > > So you can drop the disabled status here."
> > >
> > > So, in v6 I made it enabled by default.
> > >
> > > Any strong reasons for enabled/disabled per platform?
> >
> > AFAIK we usually only enable system basic features and let other
> > user selectable features disabled by default in dts.
> > Even for device LPCG clocks, if it's enabled by default and later
> > enter runtime suspend if no users, it still consumes power.
> >
>
> Well-written drivers shouldn't draw any power if not used.
>

LPCG won't draw power when not used. But the power domain used by LPCG
will still draw power when enter idle state.

> And DT is about hardware-description, not about usage-description.
> Which means, at the soc.dtsi level you disable devices that need
> some board-level hardware thing to be enabled (e.g. a physical
> connected, a regulator, etc.).
> A pure memory-to-memory should be enabled by default, because
> in practice you can't predict what the users a board will want
> to use, nor the DT is the place for that.

It makes sense to me. Thanks

Mirela,
Please follow up with Ezequiel's suggestion.
For LPCGS used by jpeg, you can keep it enabled by default.

Regards
Aisheng

>
> Sticking to hardware description is the best way to get DT right :-)
>
> Cheers,
> Ezequiel
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ