linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v11 5/5] pm: Remove to_power_supply impl in ds278*
@ 2017-12-31 14:17 Ognjen Galic
  2018-01-01  9:56 ` Andy Shevchenko
  0 siblings, 1 reply; 2+ messages in thread
From: Ognjen Galic @ 2017-12-31 14:17 UTC (permalink / raw)
  To: Andy Shevchenko, Rafael J. Wysocki, Ognjen Galić,
	Rafael J. Wysocki, Len Brown, Robert Moore, Lv Zheng,
	ACPI Devel Maling List, devel, Darren Hart, Andy Shevchenko,
	Henrique de Moraes Holschuh, Sebastian Reichel, Platform Driver,
	ibm-acpi-devel, Linux PM, Christoph Böhmwalder, Kevin Locke

This patch fixes a issue introduced by patch:
pm: add to_power_supply macro to the API

In that patch a new macro has been defined in the
power_supply.h header with the same name as the private
function name in the ds278* battery modules that does the
same thing, thus clashing and producing build errors.

This patch removes that private implementation.

Signed-off-by: Ognjen Galic <smclt30p@gmail.com>

v11:
* Fix build error pointed out by the Intel automated
kernel build daemon/bot
---
 drivers/power/supply/ds2780_battery.c | 5 -----
 drivers/power/supply/ds2781_battery.c | 5 -----
 2 files changed, 10 deletions(-)

diff --git a/drivers/power/supply/ds2780_battery.c b/drivers/power/supply/ds2780_battery.c
index e5d81b4..370e910 100644
--- a/drivers/power/supply/ds2780_battery.c
+++ b/drivers/power/supply/ds2780_battery.c
@@ -56,11 +56,6 @@ to_ds2780_device_info(struct power_supply *psy)
 	return power_supply_get_drvdata(psy);
 }
 
-static inline struct power_supply *to_power_supply(struct device *dev)
-{
-	return dev_get_drvdata(dev);
-}
-
 static inline int ds2780_battery_io(struct ds2780_device_info *dev_info,
 	char *buf, int addr, size_t count, int io)
 {
diff --git a/drivers/power/supply/ds2781_battery.c b/drivers/power/supply/ds2781_battery.c
index efe83ef..d1b5a19 100644
--- a/drivers/power/supply/ds2781_battery.c
+++ b/drivers/power/supply/ds2781_battery.c
@@ -54,11 +54,6 @@ to_ds2781_device_info(struct power_supply *psy)
 	return power_supply_get_drvdata(psy);
 }
 
-static inline struct power_supply *to_power_supply(struct device *dev)
-{
-	return dev_get_drvdata(dev);
-}
-
 static inline int ds2781_battery_io(struct ds2781_device_info *dev_info,
 	char *buf, int addr, size_t count, int io)
 {
-- 
2.7.4

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

* Re: [PATCH v11 5/5] pm: Remove to_power_supply impl in ds278*
  2017-12-31 14:17 [PATCH v11 5/5] pm: Remove to_power_supply impl in ds278* Ognjen Galic
@ 2018-01-01  9:56 ` Andy Shevchenko
  0 siblings, 0 replies; 2+ messages in thread
From: Andy Shevchenko @ 2018-01-01  9:56 UTC (permalink / raw)
  To: Ognjen Galic
  Cc: Rafael J. Wysocki, Rafael J. Wysocki, Len Brown, Robert Moore,
	Lv Zheng, ACPI Devel Maling List, devel, Darren Hart,
	Andy Shevchenko, Henrique de Moraes Holschuh, Sebastian Reichel,
	Platform Driver, ibm-acpi-devel, Linux PM,
	Christoph Böhmwalder, Kevin Locke

On Sun, Dec 31, 2017 at 4:17 PM, Ognjen Galic <smclt30p@gmail.com> wrote:
> This patch fixes a issue introduced by patch:
> pm: add to_power_supply macro to the API
>
> In that patch a new macro has been defined in the
> power_supply.h header with the same name as the private
> function name in the ds278* battery modules that does the
> same thing, thus clashing and producing build errors.
>
> This patch removes that private implementation.

Must be folded into patch 2.

-- 
With Best Regards,
Andy Shevchenko

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

end of thread, other threads:[~2018-01-01  9:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-31 14:17 [PATCH v11 5/5] pm: Remove to_power_supply impl in ds278* Ognjen Galic
2018-01-01  9:56 ` Andy Shevchenko

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).