linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] hwmon: move include files out of include/linux/i2c
@ 2017-05-21 20:34 Wolfram Sang
  2017-05-21 20:34 ` [PATCH 1/5] hwmon: ads1015: move header file out of I2C realm Wolfram Sang
  2017-05-22  3:02 ` [PATCH 0/5] hwmon: move include files out of include/linux/i2c Guenter Roeck
  0 siblings, 2 replies; 4+ messages in thread
From: Wolfram Sang @ 2017-05-21 20:34 UTC (permalink / raw)
  To: linux-i2c; +Cc: Wolfram Sang, linux-doc, linux-hwmon, linux-iio, linux-kernel

It doesn't make sense to use include/linux/i2c for client drivers which may in
fact rather be hwmon or input or whatever devices. As a result, I want to
deprecate include/linux/i2c for good. This series moves the include files to a
better location, largely include/platform_data because that is what most of the
moved include files contain. Note that some files don't seem to have upstream
users in board code, so they maybe could even be removed? I didn't check for
that now, but I did it for one i2c master driver recently. So, it may be
possible. pmbus.h got moved just one layer upwards, see the patch description
there.

I prefer the series to go upstream via the subsystem tree; if you prefer that I
take it via I2C, just let me know.

No runtime testing because of no HW, but buildbot is happy with this series at
least. A branch can be found here:

git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux.git i2c/platform_data

Thanks and kind regards,

   Wolfram


Wolfram Sang (5):
  hwmon: ads1015: move header file out of I2C realm
  hwmon: ds620: move header file out of I2C realm
  hwmon: ltc4245: move header file out of I2C realm
  hwmon: max6639: move header file out of I2C realm
  hwmon: pmbus: move header file out of I2C realm

 Documentation/hwmon/ads1015                    | 2 +-
 Documentation/hwmon/ltc4245                    | 2 +-
 Documentation/hwmon/pmbus-core                 | 2 +-
 MAINTAINERS                                    | 4 ++--
 drivers/hwmon/ads1015.c                        | 2 +-
 drivers/hwmon/ds620.c                          | 2 +-
 drivers/hwmon/ltc4245.c                        | 2 +-
 drivers/hwmon/max6639.c                        | 2 +-
 drivers/hwmon/pmbus/pmbus.c                    | 2 +-
 drivers/hwmon/pmbus/pmbus_core.c               | 2 +-
 drivers/hwmon/pmbus/ucd9000.c                  | 2 +-
 drivers/hwmon/pmbus/ucd9200.c                  | 2 +-
 drivers/iio/adc/ti-ads1015.c                   | 2 +-
 include/linux/{i2c => platform_data}/ads1015.h | 0
 include/linux/{i2c => platform_data}/ds620.h   | 0
 include/linux/{i2c => platform_data}/ltc4245.h | 0
 include/linux/{i2c => platform_data}/max6639.h | 0
 include/linux/{i2c => }/pmbus.h                | 0
 18 files changed, 14 insertions(+), 14 deletions(-)
 rename include/linux/{i2c => platform_data}/ads1015.h (100%)
 rename include/linux/{i2c => platform_data}/ds620.h (100%)
 rename include/linux/{i2c => platform_data}/ltc4245.h (100%)
 rename include/linux/{i2c => platform_data}/max6639.h (100%)
 rename include/linux/{i2c => }/pmbus.h (100%)

-- 
2.11.0


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

* [PATCH 1/5] hwmon: ads1015: move header file out of I2C realm
  2017-05-21 20:34 [PATCH 0/5] hwmon: move include files out of include/linux/i2c Wolfram Sang
@ 2017-05-21 20:34 ` Wolfram Sang
  2017-05-22  3:02 ` [PATCH 0/5] hwmon: move include files out of include/linux/i2c Guenter Roeck
  1 sibling, 0 replies; 4+ messages in thread
From: Wolfram Sang @ 2017-05-21 20:34 UTC (permalink / raw)
  To: linux-i2c
  Cc: Wolfram Sang, Dirk Eibach, Jean Delvare, Guenter Roeck,
	Jonathan Corbet, Jonathan Cameron, Hartmut Knaack,
	Lars-Peter Clausen, Peter Meerwald-Stadler, linux-hwmon,
	linux-doc, linux-kernel, linux-iio

include/linux/i2c is not for client devices. Move the header file to a
more appropriate location.

Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
---
 Documentation/hwmon/ads1015                    | 2 +-
 MAINTAINERS                                    | 2 +-
 drivers/hwmon/ads1015.c                        | 2 +-
 drivers/iio/adc/ti-ads1015.c                   | 2 +-
 include/linux/{i2c => platform_data}/ads1015.h | 0
 5 files changed, 4 insertions(+), 4 deletions(-)
 rename include/linux/{i2c => platform_data}/ads1015.h (100%)

diff --git a/Documentation/hwmon/ads1015 b/Documentation/hwmon/ads1015
index 063b80d857b1f8..02d2a459385f39 100644
--- a/Documentation/hwmon/ads1015
+++ b/Documentation/hwmon/ads1015
@@ -40,7 +40,7 @@ By default all inputs are exported.
 Platform Data
 -------------
 
-In linux/i2c/ads1015.h platform data is defined, channel_data contains
+In linux/platform_data/ads1015.h platform data is defined, channel_data contains
 configuration data for the used input combinations:
 - pga is the programmable gain amplifier (values are full scale)
   0: +/- 6.144 V
diff --git a/MAINTAINERS b/MAINTAINERS
index 9e984645c4b08b..33541336258e77 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -478,7 +478,7 @@ L:	linux-hwmon@vger.kernel.org
 S:	Maintained
 F:	Documentation/hwmon/ads1015
 F:	drivers/hwmon/ads1015.c
-F:	include/linux/i2c/ads1015.h
+F:	include/linux/platform_data/ads1015.h
 
 ADT746X FAN DRIVER
 M:	Colin Leroy <colin@colino.net>
diff --git a/drivers/hwmon/ads1015.c b/drivers/hwmon/ads1015.c
index 5140c27d16dd03..357b4260716404 100644
--- a/drivers/hwmon/ads1015.c
+++ b/drivers/hwmon/ads1015.c
@@ -34,7 +34,7 @@
 #include <linux/of_device.h>
 #include <linux/of.h>
 
-#include <linux/i2c/ads1015.h>
+#include <linux/platform_data/ads1015.h>
 
 /* ADS1015 registers */
 enum {
diff --git a/drivers/iio/adc/ti-ads1015.c b/drivers/iio/adc/ti-ads1015.c
index f76d979fb7e86e..884b8e461b1755 100644
--- a/drivers/iio/adc/ti-ads1015.c
+++ b/drivers/iio/adc/ti-ads1015.c
@@ -23,7 +23,7 @@
 #include <linux/mutex.h>
 #include <linux/delay.h>
 
-#include <linux/i2c/ads1015.h>
+#include <linux/platform_data/ads1015.h>
 
 #include <linux/iio/iio.h>
 #include <linux/iio/types.h>
diff --git a/include/linux/i2c/ads1015.h b/include/linux/platform_data/ads1015.h
similarity index 100%
rename from include/linux/i2c/ads1015.h
rename to include/linux/platform_data/ads1015.h
-- 
2.11.0


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

* Re: [PATCH 0/5] hwmon: move include files out of include/linux/i2c
  2017-05-21 20:34 [PATCH 0/5] hwmon: move include files out of include/linux/i2c Wolfram Sang
  2017-05-21 20:34 ` [PATCH 1/5] hwmon: ads1015: move header file out of I2C realm Wolfram Sang
@ 2017-05-22  3:02 ` Guenter Roeck
  2017-05-22  6:37   ` Wolfram Sang
  1 sibling, 1 reply; 4+ messages in thread
From: Guenter Roeck @ 2017-05-22  3:02 UTC (permalink / raw)
  To: Wolfram Sang, linux-i2c; +Cc: linux-doc, linux-hwmon, linux-iio, linux-kernel

On 05/21/2017 01:34 PM, Wolfram Sang wrote:
> It doesn't make sense to use include/linux/i2c for client drivers which may in
> fact rather be hwmon or input or whatever devices. As a result, I want to
> deprecate include/linux/i2c for good. This series moves the include files to a
> better location, largely include/platform_data because that is what most of th > moved include files contain. Note that some files don't seem to have upstream
> users in board code, so they maybe could even be removed? I didn't check for

While I understand where you are coming from, I am not typically that aggressive.
Such removals force vendors who are not really forthcoming with upstreaming to
deviate even further from upstream. It makes them even less likely to submit their
code upstream, and it may result in enforcing their belief that upstream doesn't
really care about vendors struggling to release boards and systems to their
customers.

> that now, but I did it for one i2c master driver recently. So, it may be
> possible. pmbus.h got moved just one layer upwards, see the patch description
> there.
> 
> I prefer the series to go upstream via the subsystem tree; if you prefer that I
> take it via I2C, just let me know.
> 
Series applied to hwmon-next.

Thanks,
Guenter

> No runtime testing because of no HW, but buildbot is happy with this series at
> least. A branch can be found here:
> 
> git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux.git i2c/platform_data
> 
> Thanks and kind regards,
> 
>     Wolfram
> 
> 
> Wolfram Sang (5):
>    hwmon: ads1015: move header file out of I2C realm
>    hwmon: ds620: move header file out of I2C realm
>    hwmon: ltc4245: move header file out of I2C realm
>    hwmon: max6639: move header file out of I2C realm
>    hwmon: pmbus: move header file out of I2C realm
> 
>   Documentation/hwmon/ads1015                    | 2 +-
>   Documentation/hwmon/ltc4245                    | 2 +-
>   Documentation/hwmon/pmbus-core                 | 2 +-
>   MAINTAINERS                                    | 4 ++--
>   drivers/hwmon/ads1015.c                        | 2 +-
>   drivers/hwmon/ds620.c                          | 2 +-
>   drivers/hwmon/ltc4245.c                        | 2 +-
>   drivers/hwmon/max6639.c                        | 2 +-
>   drivers/hwmon/pmbus/pmbus.c                    | 2 +-
>   drivers/hwmon/pmbus/pmbus_core.c               | 2 +-
>   drivers/hwmon/pmbus/ucd9000.c                  | 2 +-
>   drivers/hwmon/pmbus/ucd9200.c                  | 2 +-
>   drivers/iio/adc/ti-ads1015.c                   | 2 +-
>   include/linux/{i2c => platform_data}/ads1015.h | 0
>   include/linux/{i2c => platform_data}/ds620.h   | 0
>   include/linux/{i2c => platform_data}/ltc4245.h | 0
>   include/linux/{i2c => platform_data}/max6639.h | 0
>   include/linux/{i2c => }/pmbus.h                | 0
>   18 files changed, 14 insertions(+), 14 deletions(-)
>   rename include/linux/{i2c => platform_data}/ads1015.h (100%)
>   rename include/linux/{i2c => platform_data}/ds620.h (100%)
>   rename include/linux/{i2c => platform_data}/ltc4245.h (100%)
>   rename include/linux/{i2c => platform_data}/max6639.h (100%)
>   rename include/linux/{i2c => }/pmbus.h (100%)
> 


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

* Re: [PATCH 0/5] hwmon: move include files out of include/linux/i2c
  2017-05-22  3:02 ` [PATCH 0/5] hwmon: move include files out of include/linux/i2c Guenter Roeck
@ 2017-05-22  6:37   ` Wolfram Sang
  0 siblings, 0 replies; 4+ messages in thread
From: Wolfram Sang @ 2017-05-22  6:37 UTC (permalink / raw)
  To: Guenter Roeck; +Cc: linux-i2c, linux-doc, linux-hwmon, linux-iio, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1118 bytes --]

Hi Guenter,

> > Note that some files don't seem to have upstream
> > users in board code, so they maybe could even be removed? I didn't check for
> 
> While I understand where you are coming from, I am not typically that aggressive.
> Such removals force vendors who are not really forthcoming with upstreaming to
> deviate even further from upstream. It makes them even less likely to submit their
> code upstream, and it may result in enforcing their belief that upstream doesn't
> really care about vendors struggling to release boards and systems to their
> customers.

I clearly see your point. I meant more the case where platform_data
became cruft because platforms moved to DT. I agree this is not so much
the case for HWMON but it was true for the I2C master driver where I
could remove the platform data and could save the include file and some
code. That was just a nice cleanup.

> >I prefer the series to go upstream via the subsystem tree; if you prefer that I
> >take it via I2C, just let me know.
> >
> Series applied to hwmon-next.

Super, thanks!

Regards,

   Wolfram


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

end of thread, other threads:[~2017-05-22  6:37 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-21 20:34 [PATCH 0/5] hwmon: move include files out of include/linux/i2c Wolfram Sang
2017-05-21 20:34 ` [PATCH 1/5] hwmon: ads1015: move header file out of I2C realm Wolfram Sang
2017-05-22  3:02 ` [PATCH 0/5] hwmon: move include files out of include/linux/i2c Guenter Roeck
2017-05-22  6:37   ` Wolfram Sang

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