Re: [PATCH v4 (staging-next) 2/5] staging:iio:hmc5843: Split hmc5843.c to multiple files

2014-07-20 Thread Jonathan Cameron
On 20/07/14 17:32, Jonathan Cameron wrote: On 16/07/14 14:07, Josef Gajdusek wrote: This patch splits hmc5843.c to multiple files - the interface-agnostic hmc5843_core.c, i2c specific hmc5843_i2c.c and header file hmc5843.h. This is another step to add support of SPI-enabled hmc5983. Signed

Re: [PATCH v5 (staging-next) 1/5] staging:iio:hmc5843: Added regmap support

2014-07-23 Thread Jonathan Cameron
On 22/07/14 16:00, Josef Gajdusek wrote: This patch changes hmc5843.c to use regmap. This provides transparent caching to the code as well as abstraction necessary to add support for SPI-based hmc5983. Signed-off-by: Josef Gajdusek Applied to the togreg branch of iio.git - initially pushed out

Re: [PATCH v5 (staging-next) 2/5] staging:iio:hmc5843: Split hmc5843.c to multiple files

2014-07-23 Thread Jonathan Cameron
On 22/07/14 16:01, Josef Gajdusek wrote: This patch splits hmc5843.c to multiple files - the interface-agnostic hmc5843_core.c, i2c specific hmc5843_i2c.c and header file hmc5843.h. This is another step to add support of SPI-enabled hmc5983. Signed-off-by: Josef Gajdusek Applied to the togreg

Re: [PATCH v5 (staging-next) 4/5] staging:iio:hmc5843: Add support for i2c hmc5983

2014-07-23 Thread Jonathan Cameron
On 22/07/14 16:02, Josef Gajdusek wrote: This patch adds support for the hmc5983 i2c interface. This chip is almost identical to the hmc5883. The difference being added temperature compensation, additional available sample rate (220Hz) and an SPI interface. Signed-off-by: Josef Gajdusek Applie

Re: [PATCH v5 (staging-next) 3/5] staging:iio:hmc5843: register <-> value arrays now can have different lengths

2014-07-23 Thread Jonathan Cameron
On 22/07/14 16:02, Josef Gajdusek wrote: Changed structure of struct hmc5843_chip_info to include length of translation arrays. Code previously using #defined constant has been changed accordingly. This allows to integrate devices which do have different amounts of available rates/scales. Signed

Re: [PATCH v5 (staging-next) 5/5] staging:iio:hmc5843: Add support for spi hmc5983

2014-07-23 Thread Jonathan Cameron
On 22/07/14 16:03, Josef Gajdusek wrote: This patch adds support for the hmc5983 spi interface. This chip is almost identical to the hmc5883. The difference being added temperature compensation, additional available sample rate (220Hz) and an SPI interface. Signed-off-by: Josef Gajdusek Applie

Re: questions regarding drivers/staging/iio/accel/sca3000_core.c

2014-07-27 Thread Jonathan Cameron
On 21/07/14 09:24, Himangi Saraogi wrote: Hi, I was looking at the possibility of using a managed interface for iio_device_register in sca3000_probe. But this will lead to the iio_device_unregister function being called after sca3000_unconfigure_ring in the remove function. I have a few queries:

Re: [PATCH] staging: iio: ad9832: Use devm_iio_device_register

2014-08-03 Thread Jonathan Cameron
On August 3, 2014 10:56:58 AM GMT+01:00, Himangi Saraogi wrote: >This patch introduces the use of devm_iio_device_register and does away >with the unregister in the remove function. > And changes the resulting ordering so the regulator disable occurs before the user space interface has been r

Re: [PATCH] staging: iio: ad9832: Use devm_iio_device_register

2014-08-03 Thread Jonathan Cameron
On August 3, 2014 11:45:00 AM GMT+01:00, Julia Lawall wrote: > > >On Sun, 3 Aug 2014, Jonathan Cameron wrote: > >> >> >> On August 3, 2014 10:56:58 AM GMT+01:00, Himangi Saraogi > wrote: >> >This patch introduces the use of devm_iio_device_register

Re: [PATCH v3 1/2] staging: iio: accel: Add blank lines between declarations and code

2014-08-07 Thread Jonathan Cameron
On 07/08/14 01:22, Murilo Opsfelder Araujo wrote: > This patch adds missing blank lines between declarations and code and > fixes lines starting by spaces, satisfying checkpatch.pl. > > Signed-off-by: Murilo Opsfelder Araujo Applied to the togreg branch of iio.git. Initially pushed out as testin

Re: [PATCH v3 2/2] staging: iio: accel: sca3000_core.c: Adjust code to fit 80-chars limit

2014-08-07 Thread Jonathan Cameron
On 07/08/14 01:22, Murilo Opsfelder Araujo wrote: > Signed-off-by: Murilo Opsfelder Araujo Applied to the togreg branch of iio.git. Thanks, Jonathan > --- > drivers/staging/iio/accel/sca3000_core.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/drivers/staging/iio/a

Re: [PATCH] staging: iio: adis16060: Fix coding style problem

2014-08-07 Thread Jonathan Cameron
On 06/08/14 18:06, Oussama Jabbari wrote: > This patch fixes a warning from checkpatch.pl script : > "WARNING: Missing a blank line after declarations" > > Signed-off-by: Oussama Jabbari Whilst I find it hard to care about this particular issue, I'm accepting this mainly to avoid getting the same

Re: [PATCH] staging: iio: ad9951: Use devm_iio_device_register

2014-08-07 Thread Jonathan Cameron
On 03/08/14 11:00, Himangi Saraogi wrote: > This patch introduces the use of devm_iio_device_register and does away > with the unregister in the remove function. The remove function is no > longer required and is completely removed. > > Signed-off-by: Himangi Saraogi > Acked-by: Julia Lawall App

Re: [PATCH] staging:iio:ad9852: Use devm_iio_device_register

2014-08-07 Thread Jonathan Cameron
On 03/08/14 10:58, Himangi Saraogi wrote: > This patch introduces the use of devm_iio_device_register and does away > with the unregister in the remove function. > > Signed-off-by: Himangi Saraogi > Acked-by: Julia Lawall Applied to the togreg branch of iio.git Thanks, J > --- > drivers/stagi

Re: [PATCH 1/2] staging: iio: Fix vendor name typo in isl290[12]8.c

2014-08-08 Thread Jonathan Cameron
On 27/07/14 18:56, Masanari Iida wrote: > This patch fix vendor name typo in isl29018.c and isl29028.c > The company name Intersil should be isl, instead of isil. > > Signed-off-by: Masanari Iida Hi Masanari, This dropped by the wayside because it wasn't cc'd to linux-...@vger.kernel.org Also,

Re: [PATCH 2/2] Documentation: bindings: Add ISL29018 and ISL29028 in trivial-devices.txt

2014-08-08 Thread Jonathan Cameron
On 27/07/14 18:56, Masanari Iida wrote: > This patch add entries for ISL29018 and ISL29028 into trivial-devices.txt. > This patch fix following error. > > ./isl29018.c:643: WARNING: DT compatible string "isl,isl29018" > appears un-documented -- check Documentation/devicetree/bindings/ > > ./isl29

Re: [PATCH] staging:iio: moved platform_data into include/linux/iio

2014-08-26 Thread Jonathan Cameron
On 26/08/14 12:33, Sharma, Sanjeev wrote: > -Original Message- > From: Lars-Peter Clausen [mailto:l...@metafoo.de] > Sent: Monday, August 25, 2014 7:03 PM > To: Sharma, Sanjeev; sanjeev sharma > Cc: ji...@kernel.org; gregkh; linux-...@vger.kernel.org; devel; linux-kernel > Subject: Re: [PA

Re: [PATCH 1/2] staging: iio: remove unnecessary parentheses

2017-12-29 Thread Jonathan Cameron
On Wed, 27 Dec 2017 18:47:18 -0800 Ji-Hun Kim wrote: > Clean up checkpatch warning: > CHECK: Unnecessary parentheses around 'st->devid != ID_AD7195' > > Signed-off-by: Ji-Hun Kim I've personally never really cared about this particular one as removing the brackets doesn't make the code easier t

Re: [PATCH 2/2] staging: iio: add spaces around '-' operator

2017-12-29 Thread Jonathan Cameron
On Thu, 28 Dec 2017 07:07:17 +0100 (CET) Julia Lawall wrote: > On Wed, 27 Dec 2017, Ji-Hun Kim wrote: > > > Clean up checkpatch warning: > > CHECK: spaces preferred around that '-' (ctx:VxV) > > > > Signed-off-by: Ji-Hun Kim > > --- > > drivers/staging/iio/adc/ad7192.c | 2 +- > > 1 file chang

Re: [PATCH] staging: iio: trigger: replace device_attr with device_attr_rw

2018-01-06 Thread Jonathan Cameron
On Thu, 4 Jan 2018 16:28:51 +0530 Aishwarya Pant wrote: > This is a clean-up patch which replaces DEVICE_ATTR() macro with the > file permission specific DEVICE_ATTR_RW() macro for compaction and > readability. Done using coccinelle. > > Signed-off-by: Aishwarya Pant Whilst this driver is in t

Re: [PATCH] Staging: iio: Prefer using BIT macro

2018-01-06 Thread Jonathan Cameron
On Thu, 4 Jan 2018 22:06:31 +0530 Sumit Pundir wrote: Patch title needs to mention the specific driver being changed. > This patch fixes the following checkpatch.pl error at multiple lines: > > CHECK: Prefer using the BIT macro > > Signed-off-by: Sumit Pundir The BIT Macros is just fine if

Re: [PATCH v2] Staging: iio: cdc: Prefer using BIT macro

2018-01-06 Thread Jonathan Cameron
On Sat, 6 Jan 2018 20:35:24 +0530 Sumit Pundir wrote: > This patch fixes the following checkpatch.pl issue at multiple lines: > > CHECK: Prefer using the BIT macro > > Signed-off-by: Sumit Pundir > --- > v2: > Added the specific driver being changed to the patch title Not that I can see. An

Re: [PATCH] staging: iio: light: Add breaks to lengthy lines

2018-01-07 Thread Jonathan Cameron
On Sun, 7 Jan 2018 15:08:01 + George Edward Bulmer wrote: > This fixes three instances of checkpatch warning: > WARNING: line over 80 characters > > Signed-off-by: George Edward Bulmer Applied, thanks, Jonathan > --- > drivers/staging/iio/light/tsl2x7x.c | 9 ++--- > 1 file changed,

Re: [PATCH] staging: iio: light: Add breaks to lengthy lines

2018-01-07 Thread Jonathan Cameron
On Sun, 07 Jan 2018 08:42:27 -0800 Joe Perches wrote: > On Sun, 2018-01-07 at 16:28 +0000, Jonathan Cameron wrote: > > On Sun, 7 Jan 2018 15:08:01 + > > George Edward Bulmer wrote: > > > > > This fixes three instances of checkpatch warning: > >

Re: [PATCH] Staging: iio: Prefer using BIT macro

2018-01-08 Thread Jonathan Cameron
On Mon, 8 Jan 2018 01:30:29 +0200 Andy Shevchenko wrote: > On Sat, Jan 6, 2018 at 2:42 PM, Jonathan Cameron wrote: > > On Thu, 4 Jan 2018 22:06:31 +0530 > > >> /* Setup Register Bit Designations (AD7152_REG_CHx_SETUP) */ > >> -#define AD7152_SETUP_CAPDIFF

Re: [PATCH] Staging: iio: ade7758: Replace mlock with buf_lock

2018-01-21 Thread Jonathan Cameron
On Sat, 20 Jan 2018 21:14:48 +0530 Shreeya Patel wrote: > iio_dev->mlock is to be used only by the IIO core for protecting > device mode changes between INDIO_DIRECT and INDIO_BUFFER. > > This patch replaces the use of mlock with the already established > buf_lock mutex. > > Signed-off-by: Shre

Re: [PATCH v2] Staging: iio: ade7758: expand buf_lock to cover both buffer and state protection

2018-01-28 Thread Jonathan Cameron
On Thu, 25 Jan 2018 22:10:08 +0530 Shreeya Patel wrote: > iio_dev->mlock is to be used only by the IIO core for protecting > device mode changes between INDIO_DIRECT and INDIO_BUFFER. > > This patch replaces the use of mlock with the already established > buf_lock mutex. > > Introducing 'unlock

Re: [PATCH v3] Staging: iio: ade7758: Expand buf_lock to cover both buffer and state protection

2018-02-01 Thread Jonathan Cameron
On Tue, 30 Jan 2018 23:30:17 +0530 Shreeya Patel wrote: > iio_dev->mlock is to be used only by the IIO core for protecting > device mode changes between INDIO_DIRECT and INDIO_BUFFER. > > This patch replaces the use of mlock with the already established > buf_lock mutex. > > Introducing 'unlock

Re: [PATCH v4] Staging: iio: ade7758: Expand buf_lock to cover both buffer and state protection

2018-02-04 Thread Jonathan Cameron
On Sat, 3 Feb 2018 21:01:32 +0530 Shreeya Patel wrote: > iio_dev->mlock is to be used only by the IIO core for protecting > device mode changes between INDIO_DIRECT and INDIO_BUFFER. > > This patch replaces the use of mlock with the already established > buf_lock mutex. > > Introducing 'unlock

Re: [PATCH v4] Staging: iio: ade7758: Expand buf_lock to cover both buffer and state protection

2018-02-04 Thread Jonathan Cameron
On 4 February 2018 21:03:05 GMT, Shreeya Patel wrote: >On Sun, 2018-02-04 at 11:10 +0000, Jonathan Cameron wrote: >> On Sat,  3 Feb 2018 21:01:32 +0530 >> Shreeya Patel wrote: >> >> > >> > iio_dev->mlock is to be used only by the IIO core for p

Re: [PATCH v6] Staging: iio: ade7758: Expand buf_lock to cover both buffer and state protection

2018-02-10 Thread Jonathan Cameron
On Tue, 6 Feb 2018 22:31:57 +0530 Shreeya Patel wrote: > iio_dev->mlock is to be used only by the IIO core for protecting > device mode changes between INDIO_DIRECT and INDIO_BUFFER. > > This patch replaces the use of mlock with the already established > buf_lock mutex. > > Introducing 'unlock

Re: [PATCH 2/4] staging: iio: accel: Remove unnecessary comments and add suitable suffix

2018-02-17 Thread Jonathan Cameron
On Mon, 12 Feb 2018 17:57:31 +0300 Dan Carpenter wrote: > On Mon, Feb 12, 2018 at 08:05:22PM +0530, Himanshu Jha wrote: > > But these should be done when we have *more* instances. > > > > For eg: > > I added a tab space in function static int adis16201_read_raw() argument > > to match open pare

Re: [PATCH 2/4] staging: iio: accel: Remove unnecessary comments and add suitable suffix

2018-02-17 Thread Jonathan Cameron
On Tue, 13 Feb 2018 01:16:05 +0530 Himanshu Jha wrote: > On Mon, Feb 12, 2018 at 05:57:31PM +0300, Dan Carpenter wrote: > > On Mon, Feb 12, 2018 at 08:05:22PM +0530, Himanshu Jha wrote: > > > But these should be done when we have *more* instances. > > > > > > For eg: > > > I added a tab space

Re: [PATCH 3/4] staging: iio: accel: Use sign_extend32 and adjust a switch statement

2018-02-17 Thread Jonathan Cameron
On Mon, 12 Feb 2018 16:10:01 +0300 Dan Carpenter wrote: > On Mon, Feb 12, 2018 at 05:24:58PM +0530, Himanshu Jha wrote: > > Use sign_extend32 function instead of manually coding it. Also, adjust a > ^ > > switch block to explicitly

Re: [PATCH 4/4] staging: iio: accel: Move adis16201 driver out of staging

2018-02-17 Thread Jonathan Cameron
On Mon, 12 Feb 2018 17:45:42 +0300 Dan Carpenter wrote: > On Mon, Feb 12, 2018 at 08:11:57PM +0530, Himanshu Jha wrote: > > On Mon, Feb 12, 2018 at 04:18:26PM +0300, Dan Carpenter wrote: > > > I think -M is prefered for these types of diffs? Not sure. > > > > I wrote about that in the cover

Re: [PATCH] staging: iio/meter: add name to function definition arguments

2018-02-17 Thread Jonathan Cameron
On Fri, 16 Feb 2018 11:16:58 -0200 Rodrigo Siqueira wrote: > Hi Daniel > > > Hi Rodrigo, > > > > I think this is a nice finding. One comment inline: > > > > On Vi, 2018-02-16 at 10:50 -0200, rodrigosiqueira wrote: > > > This patch fixes the checkpatch.pl warning: > > > > > > drivers/staging

Re: [PATCH 1/3] Staging: iio: adis16209: Use SPDX identifier

2018-02-18 Thread Jonathan Cameron
On Sun, 18 Feb 2018 17:07:57 +0530 Shreeya Patel wrote: > On Sun, 2018-02-18 at 17:01 +0530, Himanshu Jha wrote: > > Hi Shreeya, > > > Hi Himanshu, > > > On Sat, Feb 17, 2018 at 09:34:56PM +0530, Shreeya Patel wrote: > > > > > > Use SPDX identifier format instead of GPLv2. Also rearrange t

Re: [PATCH 1/3] Staging: iio: adis16209: Use SPDX identifier

2018-02-18 Thread Jonathan Cameron
On Sat, 17 Feb 2018 21:34:56 +0530 Shreeya Patel wrote: > Use SPDX identifier format instead of GPLv2. Also rearrange the > headers in alphabetical order. As Dan pointed out for the Himanshu Jha's patches, the moment we see the word 'also' in a patch it pretty much makes it obvious that the auth

Re: [PATCH 2/3] Staging: iio: adis16209: Remove unnecessary comments and add suitable suffix

2018-02-18 Thread Jonathan Cameron
On Sat, 17 Feb 2018 21:37:37 +0530 Shreeya Patel wrote: > Remove some unnecessary comments and therefore, add _REG suffix > for registers. Group the control register and register field > macros together. > Also, align function arguments to match open parentheses using > tabs. Lots of different c

Re: [PATCH 3/3] Staging: iio: adis16209: Use sign_extend32 and adjust a switch statement

2018-02-18 Thread Jonathan Cameron
On Sat, 17 Feb 2018 21:51:35 +0530 Shreeya Patel wrote: > Use sign_extend32 function instead of manually coding it. Also, adjust a > switch block to explicitly match channels and return -EINVAL as default > case which improves code readability. Two items, two patches please. The -EINVAL is a bit

Re: [PATCH 1/3] Staging: iio: adis16209: Use SPDX identifier

2018-02-18 Thread Jonathan Cameron
On Sun, 18 Feb 2018 13:14:27 +0100 Lars-Peter Clausen wrote: > On 02/18/2018 01:08 PM, Lars-Peter Clausen wrote: > > On 02/18/2018 01:02 PM, Jonathan Cameron wrote: > >> On Sun, 18 Feb 2018 17:07:57 +0530 > >> Shreeya Patel wrote: > >> > >>>

Re: [PATCH v3] staging:iio:meter: Add name to function definition arguments

2018-02-24 Thread Jonathan Cameron
On Wed, 21 Feb 2018 16:54:35 -0300 Rodrigo Siqueira wrote: > This patch fixes the checkpatch.pl warning: > > drivers/staging/iio/meter/ade7854.h:157: WARNING: function definition > argument 'struct device *' should also have an identifier name... > > This commit adds arguments names to the sign

Re: [PATCH v3] staging:iio:meter: Add name to function definition arguments

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 20:38:47 -0300 Rodrigo Siqueira wrote: > On 02/24, Jonathan Cameron wrote: > > On Wed, 21 Feb 2018 16:54:35 -0300 > > Rodrigo Siqueira wrote: > > > > > This patch fixes the checkpatch.pl warning: > > > > > > drivers/st

Re: [PATCH 1/6] Staging: iio: adis16209: Arrange headers in alphabetical order

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 18:49:23 +0530 Shreeya Patel wrote: > Arrange the headers in alphabetical order for cleanup > purpose. > > Signed-off-by: Shreeya Patel Applied to the togreg branch of iio.git and pushed out as testing (mostly to test other patches as I'd be really surprised if this one brok

Re: [PATCH 2/6] Staging: iio: adis16209: Change the definition name

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 18:53:41 +0530 Shreeya Patel wrote: > The change in the definition name makes it then obvious > what the units are throughout the driver and there will > be no need of the comment. > > Signed-off-by: Shreeya Patel Applied to the togreg branch of iio.git and pushed out as tes

Re: [PATCH 3/6] Staging: iio: adis16209: Add _REG postfix for registers

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 18:55:56 +0530 Shreeya Patel wrote: > The defined names for registers does not make it very > clear that they are registers and hence, add _REG postfix. > This improves the readability of the code. > > Signed-off-by: Shreeya Patel Applied to the togreg branch of iio.git and

Re: [PATCH 4/6] Staging: iio: adis16209: Remove unnecessary comments and group the definitions

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 18:58:55 +0530 Shreeya Patel wrote: > Remove some unnecessay comments and group the control > register and register field macros together. > > Signed-off-by: Shreeya Patel Hi Shreeya, Nice patch. As you have probably already seen comment removal (and addition) is always o

Re: [PATCH 5/6] Staging: iio: adis16209: Add some informatic comments

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 19:02:48 +0530 Shreeya Patel wrote: > Some of the register names does not make it's puporse > very clear and hence, add some comments for more > information. > Also there are certain unit based comments which are not > providing sufficient information, so expand those comments

Re: [PATCH 6/6] Staging: iio: adis16209: Use sign_extend32 and adjust a switch statement

2018-03-03 Thread Jonathan Cameron
On Fri, 2 Mar 2018 19:04:49 +0530 Shreeya Patel wrote: > Use sign_extend32 function instead of manually coding it. > Also, adjust a switch block to explicitly match channels > and return -EINVAL as default case which makes the code > semantically more clear. > > Signed-off-by: Shreeya Patel Ch

Re: [PATCH 6/6] Staging: iio: adis16209: Use sign_extend32 and adjust a switch statement

2018-03-03 Thread Jonathan Cameron
On Sat, 03 Mar 2018 21:07:53 +0530 Shreeya Patel wrote: > On Sat, 2018-03-03 at 16:05 +0000, Jonathan Cameron wrote: > > On Fri,  2 Mar 2018 19:04:49 +0530 > > Shreeya Patel wrote: > > > > > > > > Use sign_extend32 function instead of manually coding i

Re: [PATCH] staging: iio: Remove unnecessary cast on void pointer

2018-03-07 Thread Jonathan Cameron
On Wed, 7 Mar 2018 18:47:17 +0530 Arushi Singhal wrote: > The following Coccinelle script was used to detect this: > @r@ > expression x; > void* e; > type T; > identifier f; > @@ > ( > *((T *)e) > | > ((T *)x)[...] > | > ((T*)x)->f > | > > - (T*) > e > ) > > Signed-off-by: Arushi Singha

Re: [PATCH] staging: iio: meter: Remove reduntant __func__ from debug print

2018-03-07 Thread Jonathan Cameron
On Wed, 7 Mar 2018 11:08:04 +0530 hariprasath.ela...@gmail.com wrote: > From: HariPrasath Elango > > dev_dbg includes the function name & line number by default when dynamic > debugging is enabled. Hence__func__ is reduntant here and removed. > > Signed-off-by: HariPrasath Elango Applied to t

Re: [PATCH v2 1/3] staging:iio:meter: Replaces IIO_DEV_ATTR_CH_OFF by IIO_DEVICE_ATTR

2018-03-07 Thread Jonathan Cameron
On Tue, 6 Mar 2018 21:43:47 -0300 Rodrigo Siqueira wrote: > The macro IIO_DEV_ATTR_CH_OFF is a wrapper for IIO_DEVICE_ATTR, with a > tiny change in the name definition. This extra macro does not improve > the readability and also creates some checkpatch errors. > > This patch fixes the checkpatc

Re: [PATCH v2 2/3] staging:iio:meter: Remove unused macro IIO_DEV_ATTR_CH_OFF

2018-03-07 Thread Jonathan Cameron
On Tue, 6 Mar 2018 21:44:07 -0300 Rodrigo Siqueira wrote: > This patch removes the macro IIO_DEV_ATTR_CH_OFF. The macro > IIO_DEV_ATTR_CH_OFF is not required, due to the replace of it by the > direct use of IIO_DEVICE_ATTR in files staging/iio/meter/ade7759.c and > staging/iio/meter/ade7753.c. >

Re: [PATCH v2 3/3] staging:iio:meter: Aligns open parenthesis

2018-03-07 Thread Jonathan Cameron
On Tue, 6 Mar 2018 21:44:26 -0300 Rodrigo Siqueira wrote: > This patch fixes the checkpatch.pl checks: > > staging/iio/meter/ade7854-spi.c:19: CHECK: Alignment should match open > parenthesis > staging/iio/meter/ade7854-spi.c:44: CHECK: Alignment should match open > parenthesis > staging/iio/met

Re: [PATCH 01/11] Staging: iio: accel: Prefer alphabetical sequence of header files

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:20 +0530 Himanshu Jha wrote: > Arrange header files in alphabetical sequence to improve readability. > > Signed-off-by: Himanshu Jha One general comment - when naming a patch it will form the description in the git short log or on the various web interfaces etc. It's

Re: [PATCH 02/11] Staging: iio: accel: Add a blank space before returns

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:21 +0530 Himanshu Jha wrote: > Adding a blank space before/after some returns improves readability. > > Signed-off-by: Himanshu Jha Applied - patch title adjusted. Thanks, Jonathan > --- > drivers/staging/iio/accel/adis16201.c | 4 > 1 file changed, 4 insertion

Re: [PATCH 03/11] Staging: iio: accel: Remove unnecessary comments

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:22 +0530 Himanshu Jha wrote: > Remove unnecessary comments since the definitions are pretty clear > with their macro names. > > Signed-off-by: Himanshu Jha Hi, The art of commenting (and indeed removing comments) is never a clear one. I agree with the vast majority o

Re: [PATCH 04/11] Staging: iio: accel: Rename few macro definitions

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:23 +0530 Himanshu Jha wrote: > Rename few macros with appropriate names specifying their usage/function. Most of these are obviously good, but for one I didn't understand your reasoning. Given there are only a few of them, I'd put some more description here to explain w

Re: [PATCH 05/11] Staging: iio: accel: Add _REG suffix to registers

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:24 +0530 Himanshu Jha wrote: > Addition of _REG suffix to the register definitions allows a distinction > between registers and register fields. The various registers and its field > bits are grouped together to improve readability and easy indentification. > > Signed-o

Re: [PATCH 08/11] Staging: iio: accel: Use switch statement than if-else

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:27 +0530 Himanshu Jha wrote: > Use switch statement instead of if-else pair to explicitly match > the only two channels present. > > Signed-off-by: Himanshu Jha I think this is going to generate some warnings in the various static analysers as they will point out there

Re: [PATCH 10/11] Staging: iio: accel: Add comments about units in data read function

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:29 +0530 Himanshu Jha wrote: > Clarify the conversion and formation of resultant data in the > adis16201_read_raw() with sufficient comments. > > Signed-off-by: Himanshu Jha This is fine but it needs to be in the original comment changing patch rather than removing the

Re: [PATCH 11/11] Staging: iio: accel: Move adis16201 driver out of staging subsystem

2018-03-07 Thread Jonathan Cameron
On Mon, 5 Mar 2018 13:19:30 +0530 Himanshu Jha wrote: > Move the adis16201 driver out of staging directory and merge to the > mainline IIO subsystem. > > Signed-off-by: Himanshu Jha One comment inline (that I should have noticed in one of your earlier patches but missed). Michael, do you hav

Re: [PATCH v3 1/4] Staging: iio: adis16209: Remove and add some comments and group the definitions

2018-03-07 Thread Jonathan Cameron
On Sun, 04 Mar 2018 18:37:04 +0530 Shreeya Patel wrote: > On Sun, 2018-03-04 at 18:26 +0530, Himanshu Jha wrote: > > Hi Shreeya, > > > > On Sun, Mar 04, 2018 at 06:06:22PM +0530, Shreeya Patel wrote: > > > > > > Remove some unnecessay comments and group the control > > > register and register

Re: [PATCH v3 2/4] Staging: iio: adis16209: Change some macro names

2018-03-07 Thread Jonathan Cameron
On Sun, 4 Mar 2018 18:11:17 +0530 Shreeya Patel wrote: > Make some of the macro names according to the names > given in the datasheet of the adis16209 driver. > > Signed-off-by: Shreeya Patel A small comment inline which we should clear up in a follow up patch. > --- > > Changes in v3 > -In

Re: [PATCH v3 3/4] Staging: iio: adis16209: Adjust a switch statement

2018-03-07 Thread Jonathan Cameron
On Sun, 4 Mar 2018 18:13:12 +0530 Shreeya Patel wrote: > Adjust a switch block to explicitly match channels and > return -EINVAL as default case which makes the code > semantically more clear. > > Signed-off-by: Shreeya Patel Applied to the togreg branch of iio.git and pushed out as testing fo

Re: [PATCH v3 4/4] Staging: iio: adis16209: Use sign_extend32 function

2018-03-07 Thread Jonathan Cameron
On Sun, 4 Mar 2018 18:15:06 +0530 Shreeya Patel wrote: > Use sign_extend32 function instead of manually coding > it. > > Signed-off-by: Shreeya Patel Applied to the togreg branch of iio.git and pushed out as testing for the autobuilders to play with it. Thanks, Jonathan > --- > > Changes i

Re: [PATCH 01/12] staging: iio: tsl2x7x: remove power functions from tsl2X7X_platform_data

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:31 -0500 Brian Masney wrote: > The tsl2X7X_platform_data structure contains the platform_power, > power_on, and power_off function pointers. These power management > functions should not be in the platform data. These functions were > likely used before the regulator fra

Re: [PATCH 02/12] staging: iio: tsl2x7x: add common function for clearing interrupts

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:32 -0500 Brian Masney wrote: > There were three places where the same chunk of code was used to clear > interrupts. This patch creates a common function > tsl2x7x_clear_interrupts() to reduce duplicate code. > > Signed-off-by: Brian Masney Hmm. This one wasn't immediat

Re: [PATCH 03/12] staging: iio: tsl2x7x: add common function for reading chip status

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:33 -0500 Brian Masney wrote: > There were three places where the same chunk of code was used to read > the chip status. This patch creates a common function > tsl2x7x_read_status() to reduce duplicate code. This patch also corrects > tsl2x7x_event_handler() to properly c

Re: [PATCH 04/12] staging: iio: tsl2x7x: add common function for writing to the control register

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:34 -0500 Brian Masney wrote: > There were four places where the same chunk of code was used to write > to the control register. This patch creates a common function > tsl2x7x_write_control_reg() to reduce duplicate code. > > The function tsl2x7x_chip_off() did not corre

Re: [PATCH 05/12] staging: iio: tsl2x7x: convert mutex_trylock() to mutex_lock()

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:35 -0500 Brian Masney wrote: > The driver uses mutex_lock() and mutex_trylock() in several places. > Convert the mutex_trylock() to mutex_lock() for consistency with other > IIO light drivers in mainline. > > Signed-off-by: Brian Masney This was a little odd given we d

Re: [PATCH 06/12] staging: iio: tsl2x7x: correctly return errors in tsl2x7x_get_prox()

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:36 -0500 Brian Masney wrote: > Not all errors that occurred in tsl2x7x_get_prox() were correctly > reported in the return value. This patch changes the error handling > so that errors are now returned properly. > > Note that the ret variable is from the call to tsl2x7x_

Re: [PATCH 07/12] staging: iio: tsl2x7x: correct 'Avoid CamelCase' warning from checkpatch

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:37 -0500 Brian Masney wrote: > The statP and calP variables triggered an 'Avoid CamelCase' warning > from checkpatch.pl. This patch renames these variables to stat and cal > to fix this warning. > > Signed-off-by: Brian Masney Applied. > --- > drivers/staging/iio/ligh

Re: [PATCH 08/12] staging: iio: tsl2x7x: add error handling to tsl2x7x_prox_cal()

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:38 -0500 Brian Masney wrote: > tsl2x7x_prox_cal() did not have any error checks. This patch adds > the missing error handling and ensures that any errors are reported to > user space via in_proximity0_calibrate_store(). > > Signed-off-by: Brian Masney applied. Thanks,

Re: [PATCH 09/12] staging: iio: tsl2x7x: add missing error checks

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:39 -0500 Brian Masney wrote: > The functions in_illuminance0_calibrate_store() and > in_illuminance0_lux_table_store() did not have complete error handling > in place. This patch adds the missing error handling. > > Signed-off-by: Brian Masney Applied. Thanks, > --- >

Re: [PATCH 10/12] staging: iio: tsl2x7x: make logging consistent and correct newlines

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:40 -0500 Brian Masney wrote: > This patch updates all of the logging commands so that they are > consistent with the other messages, includes __func__ in the message, > and all of the messages include newlines. > > This patch also removes some debug log messages from ts

Re: [PATCH 11/12] staging: iio: tsl2x7x: remove unnecessary sysfs attribute

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:41 -0500 Brian Masney wrote: > The tsl2771 and tmd2771 devices create the > in_proximity0_calibscale_available sysfs attribute. These two particular > devices do not support changing the proximity gain value on the > chip so this patch removes that sysfs attribute. As ex

Re: [PATCH 12/12] staging: iio: tsl2x7x: make proximity sensor function correctly

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:42 -0500 Brian Masney wrote: > The bits for setting up the proximity diode were not setup correctly and > this was causing the proximity sensor to not function correctly. This > patch sets up the correct bit mask in tsl2x7x_chip_on() based on what > the data sheet expect

Re: [PATCH 10/11] Staging: iio: accel: Add comments about units in data read function

2018-03-10 Thread Jonathan Cameron
On Thu, 8 Mar 2018 12:58:19 +0530 Himanshu Jha wrote: > On Wed, Mar 07, 2018 at 08:50:30PM +0000, Jonathan Cameron wrote: > > On Mon, 5 Mar 2018 13:19:29 +0530 > > Himanshu Jha wrote: > > > > > Clarify the conversion and formation of resultant data in the &

Re: [PATCH v2 1/3] staging:iio:meter: Replaces IIO_DEV_ATTR_CH_OFF by IIO_DEVICE_ATTR

2018-03-10 Thread Jonathan Cameron
On Thu, 8 Mar 2018 21:37:33 -0300 Rodrigo Siqueira wrote: > On 03/07, Jonathan Cameron wrote: > > On Tue, 6 Mar 2018 21:43:47 -0300 > > Rodrigo Siqueira wrote: > > > > > The macro IIO_DEV_ATTR_CH_OFF is a wrapper for IIO_DEVICE_ATTR, with a > > > t

Re: [PATCH v5] Staging: iio: adis16209: Change some macro names

2018-03-10 Thread Jonathan Cameron
On Sat, 10 Mar 2018 15:40:14 +0530 Shreeya Patel wrote: > Make some of the macro names according to the names > given in the datasheet of the adis16209 driver and > have slight indentation in field definitions to make > them clearly different from the register addresses. > > Signed-off-by: Shree

Re: [PATCH v2] Staging: iio: adis16209: Move adis16209 driver out of staging

2018-03-10 Thread Jonathan Cameron
On Sat, 10 Mar 2018 15:50:23 +0530 Shreeya Patel wrote: > Move the adis16209 driver out of staging directory and merge to the > mainline IIO subsystem. > > Signed-off-by: Shreeya Patel As this has a clear dependency on the previous patch, please put them in the same series for the next version.

Re: [PATCH 1/4] staging:iio:ad2s1210: Remove end of line with '['

2018-03-10 Thread Jonathan Cameron
On Fri, 9 Mar 2018 20:45:50 -0300 Rodrigo Siqueira wrote: > This patch fixes the checkpatch.pl check: > > iio/resolver/ad2s1210.c:202: CHECK: Lines should not end with a '[' > > Signed-off-by: Rodrigo Siqueira Applied to the togreg branch of iio.git and pushed out as testing for the autobuilde

Re: [PATCH 2/4] staging:iio:ad2s1210: Remove unused #define directive

2018-03-10 Thread Jonathan Cameron
On Fri, 9 Mar 2018 20:46:05 -0300 Rodrigo Siqueira wrote: > This patch removes some #define directives not used in the code. > > Signed-off-by: Rodrigo Siqueira Applied. One comment inline. > --- > drivers/staging/iio/resolver/ad2s1210.c | 10 -- > 1 file changed, 10 deletions(-) > >

Re: [PATCH 3/4] staging:iio:ad2s1210: Remove old_data from ad2s1210_state

2018-03-10 Thread Jonathan Cameron
On Fri, 9 Mar 2018 20:46:25 -0300 Rodrigo Siqueira wrote: > The variable old_data is a bool type, which only receives the value > 'true' in the function ad2s1210_config_write and ad2s1210_config_read. > There is no other use for this variable. This patch removes old_data > from the ad2s1210_state

Re: [PATCH 4/4] staging:iio:ad2s1210: Add comments/documentation

2018-03-10 Thread Jonathan Cameron
On Fri, 9 Mar 2018 20:46:40 -0300 Rodrigo Siqueira wrote: > The original code of AD2S1210 does not have documentation for structs > and register configurations; this difficult the code comprehension. This > patch adds structs documentation, briefly comments some register > settings and acronyms,

Re: [PATCH 10/12] staging: iio: tsl2x7x: make logging consistent and correct newlines

2018-03-11 Thread Jonathan Cameron
On Sat, 10 Mar 2018 14:52:40 + Jonathan Cameron wrote: > On Sat, 3 Mar 2018 20:49:40 -0500 > Brian Masney wrote: > > > This patch updates all of the logging commands so that they are > > consistent with the other messages, includes __func__ in the message, > &

Re: [PATCH 47/47] staging: iio: remove iio-trig-bfin-timer driver

2018-03-14 Thread Jonathan Cameron
that we wouldn't feel comfortable cleaning them up without. One has been reprieved as a user, who was happy to test, came forward when I announced the intent to remove them. > > > Signed-off-by: Arnd Bergmann > > Acked-by: Greg Kroah-Hartman Acked-by: Jo

Re: [PATCH v2 08/21] iio: adc: Remove depends on HAS_DMA in case of platform dependency

2018-03-17 Thread Jonathan Cameron
. > > Signed-off-by: Geert Uytterhoeven > Reviewed-by: Mark Brown > Acked-by: Robin Murphy Great. Acked-by: Jonathan Cameron Thanks for doing this - this has been annoying for a long time :) > --- > v2: > - Add Reviewed-by, Acked-by, > - Drop RFC state, > - Split per s

Re: [PATCH v2 1/3] staging:iio:meter: Replaces IIO_DEV_ATTR_CH_OFF by IIO_DEVICE_ATTR

2018-03-17 Thread Jonathan Cameron
cated register > naming issues. Something to look forward to. Gah, I always hated power engineering though I taught it very briefly (I really pity those students :( Jonathan > > Regards, > John > > > > > > > On Mar 10, 2018, at 7:10 AM, Jonathan Cameron wrot

Re: [PATCH v2] Staging: iio: adis16209: Move adis16209 driver out of staging

2018-03-17 Thread Jonathan Cameron
On Fri, 16 Mar 2018 02:33:49 +0530 Shreeya Patel wrote: > On 16 March 2018 00:31:53 GMT+05:30, Shreeya Patel > wrote: > >On Sat, 2018-03-10 at 15:57 +0000, Jonathan Cameron wrote: > > > >Hi Jonathan, > > > >> On Sat, 10 Mar 2018 1

Re: [PATCH v2 1/3] staging:iio:ad2s1210: Add channel for fclkin and fexcit

2018-03-17 Thread Jonathan Cameron
On Tue, 13 Mar 2018 13:05:28 -0300 Rodrigo Siqueira wrote: > The ad2s1210 does not contain any channel for the fclkin and fexcit. As > a result, it uses IIO_DEVICE_ATTR to expose this information. This patch > adds one channel for fclkin and another for fexcit. It also adds an enum > to easily ad

Re: Plan to move cdc:ad7746 driver out of staging

2018-03-17 Thread Jonathan Cameron
On Mon, 12 Mar 2018 16:25:52 -0300 Hernán Gonzalez wrote: > Hi, > > This is my plan for moving out the ad7746 driver out of staging. I > have some specific questions that would be really helpful if someone > can point me in the right direction to go. > > 1. Pick up on David's clean-up patch. Fi

Re: [PATCH v2 1/9] Staging: iio: accel: adis16201: Rename few macro definitions

2018-03-18 Thread Jonathan Cameron
On Sat, 17 Mar 2018 01:36:18 +0530 Himanshu Jha wrote: > Rename the macro definitions with suitable names specifying their > purpose. > > * ADIS16201_STARTUP_DELAY_MS: Remove the comment specifying the delay in > microseconds and rename it with addtition of _MS suffix. > > * ADIS16201_MSC_CTR

Re: [PATCH v2 2/9] Staging: iio: accel: adis16201: Remove unnecessary comments

2018-03-18 Thread Jonathan Cameron
On Sat, 17 Mar 2018 01:36:19 +0530 Himanshu Jha wrote: > Remove few unnecessary comments since the macro definitions clearly > justify their purpose. > > Signed-off-by: Himanshu Jha Seems like a good balance between enough information and too much noise so applied to the togreg branch of iio.gi

Re: [PATCH v2 3/9] Staging: iio: accel: adis16201: Add _REG suffix to reisters

2018-03-18 Thread Jonathan Cameron
On Sat, 17 Mar 2018 01:36:20 +0530 Himanshu Jha wrote: > Add a _REG suffix to distinguish between registers and the register bit > fileds. > > Signed-off-by: Himanshu Jha Other than the typo in the patch title, this looks good (I fixed that up when applying). Applied. Jonathan > --- > v2: >

Re: [PATCH v2 4/9] Staging: iio: accel: adis16201: Group register definitions

2018-03-18 Thread Jonathan Cameron
On Sat, 17 Mar 2018 01:36:21 +0530 Himanshu Jha wrote: > Group register definitions with its register field bits to improve > readability and easy identification. A small comment is also added to > denote the purpose/functionality of the grouped register definitions. > > Signed-off-by: Himanshu

Re: [PATCH v2 5/9] Staging: iio: accel: adis16201: Add comments about units in read_raw()

2018-03-18 Thread Jonathan Cameron
On Sat, 17 Mar 2018 01:36:22 +0530 Himanshu Jha wrote: > Clarify the conversion and formation of resultant data in the > adis16201_read_raw() with sufficient comments and remove the unnecessary > comments. > > Signed-off-by: Himanshu Jha It is a little illogical to have comments for all but one

Re: [PATCH v2 6/9] Staging: iio: accel: adis16201: Use sign_extend32 function

2018-03-18 Thread Jonathan Cameron
On Sat, 17 Mar 2018 01:36:23 +0530 Himanshu Jha wrote: > Use sign_extned32() for 32 bit sign extending rather than hard coding. > > Signed-off-by: Himanshu Jha Great, applied. Thanks, Jonathan > --- > v2: >-no change in this patch. > > drivers/staging/iio/accel/adis16201.c | 5 ++--- >

<    5   6   7   8   9   10   11   >