Re: [PATCH v4 6/8] power: supply: rt5033_charger: Add cable detection and USB OTG supply

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sebastian,

On 08.05.23 13:43, Sebastian Reichel wrote:
On Sat, May 06, 2023 at 05:54:33PM +0200, Jakob Hauser wrote:

...

diff --git a/include/linux/mfd/rt5033.h b/include/linux/mfd/rt5033.h
index e99e2ab0c1c1..d2c613764756 100644
--- a/include/linux/mfd/rt5033.h
+++ b/include/linux/mfd/rt5033.h
@@ -53,6 +53,14 @@ struct rt5033_charger {
  	struct rt5033_dev		*rt5033;
  	struct power_supply		*psy;
  	struct rt5033_charger_data	*chg;
+	struct extcon_dev		*edev;
+	struct notifier_block		extcon_nb;
+	struct work_struct		extcon_work;
+	struct mutex			lock;
+	bool online;
+	bool otg;
+	bool mivr_enabled;
+	u8 cv_regval;
  };

Please move 'struct rt5033_charger' and 'struct rt5033_charger_data'
to drivers/power/supply/rt5033_charger.c; they are not supposed to
be used directly by others. Making it private helps to avoid
cross-subsystem series for future maintanence patches.

Makes sense, I'll change that.

For completeness, I'll add an additional patch to move the 'struct rt5033_battery' [1] to drivers/power/supply/rt5033_battery.c.

[1] https://github.com/torvalds/linux/blob/v6.4-rc1/include/linux/mfd/rt5033.h#L35-L40

Kind regards,
Jakob



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux