[PATCH 10/18] staging: typec: fusb302: Add support for fcs,vbus-regulator-name device-property

Mark Brown broonie at kernel.org
Tue Aug 8 09:39:47 UTC 2017


On Mon, Aug 07, 2017 at 09:20:05PM +0200, Hans de Goede wrote:
> On 07-08-17 17:41, Mark Brown wrote:

> > I2C has a perfectly good platform_data pointer in the board info for
> > this stuff.

> True, so you are suggesting that I define a bq24190_platform_data
> struct with a regulator_init_data pointer in there I guess?

Yes.  

> I don't think the power-supply maintainers will be enthusiastic
> about this (hi Sebastian). But that does make sense and is
> actually a good idea for tackling the problem of regulator_init_data.

Why not?  This is just really standard usage of platform data.

> Would extending the struct regulator_map with a const char *provider_name:

> struct regulator_map {
>         struct list_head list;
>         const char *dev_name;   /* The dev_name() for the consumer */
>         const char *supply;
>         struct regulator_dev *regulator;
> 	const char *provider;	/* The dev_name() for the regulator parent-dev */
> };

Please don't invent new terminology like this.  Just call it a regulator
name.

> Alternatively the entry could additionally contain a provider_supply_name
> so that we can make arbitrary consumer-dev-name + consumer-supply-name
> provider-dev-name + provider-supply-name matches. That would probably
> be more flexible then requiring the supply name to match.

I'm sorry but I can't follow what you mean here.  What do you mean by
"provider_supply_name"?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://driverdev.linuxdriverproject.org/pipermail/driverdev-devel/attachments/20170808/28ff2872/attachment.asc>


More information about the devel mailing list