linux-omap.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH 2/5] ARM: dts: add battery phandle to cpcap_charger
@ 2021-03-24 16:08 carl
  2021-03-24 23:35 ` Sebastian Reichel
  0 siblings, 1 reply; 7+ messages in thread
From: carl @ 2021-03-24 16:08 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: Pavel Machek, Arthur Demchenkov, Merlijn Wajer,
	Carl Philipp Klemm, devicetree, Tony Lindgren, linux-omap

> I think the patch is also wrong, since the information is already 
> described in DT - just the other way around: The battery references 
> the charger. This provides all required information to the kernel 
> for a 1:1 link. 
>
> -- Sebastian 

I added this so that cpcap_charger may become aware of the battery insertion state by querying the battery driver.
Would you thus recommend that instead of adding this phandle i should amend the series such that cpcap_charger walks the tree looking for a cpcap_battery compatible node and then determines if the charger phandle points to itself? Is there some recommended way performing this reverse search?

^ permalink raw reply	[flat|nested] 7+ messages in thread
* [PATCH 2/5] ARM: dts: add battery phandle to cpcap_charger
@ 2021-01-17 21:45 Carl Philipp Klemm
  2021-03-24 11:54 ` Tony Lindgren
  0 siblings, 1 reply; 7+ messages in thread
From: Carl Philipp Klemm @ 2021-01-17 21:45 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: devicetree, linux-omap, Arthur Demchenkov, Tony Lindgren,
	Merlijn Wajer, Pavel Machek

This is required for 
	power: supply: cpcap-charger: get the battery inserted 
		infomation from cpcap-battery

Signed-off-by: Carl Philipp Klemm <philipp@uvos.xyz>
---
 arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi b/arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi
index 08a7d3ce383f..842eaa7b89e5 100644
--- a/arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi
+++ b/arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi
@@ -61,6 +61,7 @@ &cpcap_adc 2 &cpcap_adc 5
 			io-channel-names = "battdetb", "battp",
 					   "vbus", "chg_isense",
 					   "batti";
+			battery = <&cpcap_battery>;
 		};
 
 		cpcap_regulator: regulator {
-- 
2.29.2

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-03-24 23:36 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-24 16:08 [PATCH 2/5] ARM: dts: add battery phandle to cpcap_charger carl
2021-03-24 23:35 ` Sebastian Reichel
  -- strict thread matches above, loose matches on Subject: below --
2021-01-17 21:45 Carl Philipp Klemm
2021-03-24 11:54 ` Tony Lindgren
2021-03-24 15:42   ` Sebastian Reichel
2021-03-24 16:29     ` Tony Lindgren
     [not found]     ` <C2FC7740-006A-430F-AA29-67572473D18B@goldelico.com>
2021-03-24 23:19       ` Sebastian Reichel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).