Subject: Re: [PATCH v3 4/7] power: supply: max8997_charger: Set CHARGER current limit

From: Krzysztof Kozlowski <[email-masked]>
Date: Wed, 23 Dec 2020 09:27:18 +0100

On Wed, Dec 23, 2020 at 08:09:55AM +0000, Timon Baetz wrote:
> On Tue, 22 Dec 2020 09:40:04 +0100, Krzysztof Kozlowski wrote:

(...)
> > >  	.name		= "max8997_pmic",
> > >  	.type		= POWER_SUPPLY_TYPE_BATTERY,
> > > @@ -170,6 +237,33 @@ static int max8997_battery_probe(struct platform_device *pdev)
> > >  		return PTR_ERR(charger->battery);
> > >  	}
> > >
> > > +	charger->reg = devm_regulator_get(&pdev->dev, "charger");  
> > 
> > The code looks good but isn't it breaking all existing platforms?
> 
> So there is 2 other DTS in the kernel sources that are using MAX8997
> pmic:
>  - Insignal Origen evaluation board
>  - Samsung Trats
> Non of them have charging regulators.

But still the power supply was probing on them (if not the error you
mentioned).  Now, the charger will fail.

> Also probing of the charger has been failing for long time because of 
> https://lore.kernel.org/lkml/[email-masked]/
> but that seems to land in 5.11.

That's a good argument supporting introduced breakage. Use it in commit
message. Don't hide such information.

> That being said, I guess I could make extcon and charger-supply
> optional if you prefer.

Since at least two boards will loose now power supply, I don't think you
have a choice.

Best regards,
Krzysztof

_______________________________________________
linux-arm-kernel mailing list
[email-masked]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel