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: <ZsiU81fYfy8WTk_5@smile.fi.intel.com>
Date: Fri, 23 Aug 2024 16:56:03 +0300
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Chen-Yu Tsai <wenst@...omium.org>
Cc: Rob Herring <robh@...nel.org>, Saravana Kannan <saravanak@...gle.com>,
	Matthias Brugger <matthias.bgg@...il.com>,
	AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>,
	Wolfram Sang <wsa@...nel.org>, Benson Leung <bleung@...omium.org>,
	Tzung-Bi Shih <tzungbi@...nel.org>, Mark Brown <broonie@...nel.org>,
	Liam Girdwood <lgirdwood@...il.com>,
	chrome-platform@...ts.linux.dev, devicetree@...r.kernel.org,
	linux-arm-kernel@...ts.infradead.org,
	linux-mediatek@...ts.infradead.org, linux-kernel@...r.kernel.org,
	Douglas Anderson <dianders@...omium.org>,
	Johan Hovold <johan@...nel.org>, Jiri Kosina <jikos@...nel.org>,
	linux-i2c@...r.kernel.org
Subject: Re: [PATCH v5 07/10] i2c: of-prober: Add regulator support

On Fri, Aug 23, 2024 at 05:35:59PM +0800, Chen-Yu Tsai wrote:
> On Thu, Aug 22, 2024 at 10:09 PM Andy Shevchenko
> <andriy.shevchenko@...ux.intel.com> wrote:
> > On Thu, Aug 22, 2024 at 05:20:00PM +0800, Chen-Yu Tsai wrote:

...

> > Hmm... why not
> >
> > static int i2c_of_probe_get_res(struct device *dev, struct device_node *node,
> >                                 struct i2c_of_probe_data *data)
> > {
> >         struct property *prop;
> >         int ret;
> >
> >         ret = i2c_of_probe_get_regulator(dev, node, data);
> >         if (ret < 0) {
> >                 i2c_of_probe_free_res(data);
> >                 return dev_err_probe(dev, ret, "Failed to get regulator supplies from %pOF\n", node);
> >         }
> >
> >         return 0;
> > }
> 
> That would be more churn in the next patch, which introduces another
> error condition requiring the same cleanup.

OK!

...

> > > +     /* largest post-power-on pre-reset-deassert delay seen among drivers */
> > > +     msleep(500);
> >
> > How would we monitor if any [new] driver wants to use bigger timeout?
> 
> The assumption is that the person doing the integration should test for
> this. This prober doesn't get called everywhere. It needs a driver to
> call it, and that driver is written by someone for some specific platform.
> Maybe I should explicitly spell that out in the function description?
> Or even make it a parameter?
> 
> Also, having an arbitrarily large number here doesn't help platforms that
> want to minimize boot time. On that front I'm also thinking about whether
> it is possible to do a handover to the actual driver so that the latter
> doesn't have to go through the whole power sequence again.

Yeah, I think the best effort is to have a parameter.

-- 
With Best Regards,
Andy Shevchenko



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ