The checkpatch.pl tool detected coding style problem:
CHECK: spaces preferred around that '-' (ctx:VxV)
in two files inside the adc directory. This patch will remove this
problem.
Signed-off-by: Slawomir Stepien
---
drivers/staging/iio/adc/ad7192.c | 2 +-
drivers/stagi
h/635994/
> for some discussion why this patch doesn't make sense
Oh...my mistake. Thank you for clarification. I should be more careful. Sorry!
> > in two files inside the adc directory. This patch will remove this
> > problem.
> >
> > Signed-off-by: Slawomir Ste
This series will fix simple style problem inside the ad7150 driver.
Slawomir Stepien (2):
staging: iio: cdc: ad7150: use pointer to shorten the line length
staging: iio: cdc: ad7150: fix misaligned lines
drivers/staging/iio/cdc/ad7150.c | 9 +
1 file changed, 5 insertions(+), 4
By using the pointer to channel attribute, we can now make the lines
short enough to eliminate the checkpatch.pl problem:
CHECK: Alignment should match open parenthesis
Signed-off-by: Slawomir Stepien
---
drivers/staging/iio/cdc/ad7150.c | 5 +++--
1 file changed, 3 insertions(+), 2
These lines were misaligned, but the checkpatch.pl didn't indicate them
as such.
Signed-off-by: Slawomir Stepien
---
drivers/staging/iio/cdc/ad7150.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/iio/cdc/ad7150.c b/drivers/staging/iio/cdc/ad7150.c
On paź 04, 2018 17:21, Lars-Peter Clausen wrote:
> On 10/01/2018 09:33 PM, Slawomir Stepien wrote:
> > drivers/staging/iio/cdc/ad7150.c | 5 +++--
> > 1 file changed, 3 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/staging/iio/cdc/ad7150.c
> > b
This series will fix simple style problems inside the ad7150 driver.
---
Changes since v1:
- Use channel value copy rather than pointer - for better readability
- Change "problem" -> "problems" in cover letter description
---
Slawomir Stepien (2):
staging: iio: cdc: ad
By using the copy of channel attribute, we can now make the lines short
enough to eliminate the checkpatch.pl problem:
CHECK: Alignment should match open parenthesis
Signed-off-by: Slawomir Stepien
---
drivers/staging/iio/cdc/ad7150.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions
These lines were misaligned, but the checkpatch.pl didn't indicate them
as such.
Signed-off-by: Slawomir Stepien
---
drivers/staging/iio/cdc/ad7150.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/iio/cdc/ad7150.c b/drivers/staging/iio/cdc/ad7150.c
ELL_UNDERVOLTAGE);
>
> static IIO_DEVICE_ATTR_NAMED(in_thresh_high_value,
> - in_voltage-voltage_thresh_high_value,
> + in_voltage - voltage_thresh_high_value,
> 0644,
> ad7280_read_channel_config,
>
On paź 11, 2018 10:32, Dan Carpenter wrote:
> On Sat, Oct 06, 2018 at 10:25:42PM +0200, Slawomir Stepien wrote:
> > On paź 06, 2018 13:27, Gabriel Capella wrote:
> > > This patch does not change the logic, it only
> > > corrects the checkpatch checks.
> > >
&g
stepien/linux-1/commit/1adc0428b496f44f6a931637084bb619ddd9992d
but I'm not that sure it is the best way to go.
What do you all think?
--
Slawomir Stepien
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
st->pdata = spi->dev.platform_data;
> - ret = ad2s1210_setup_gpios(st);
> + ret = ad2s1210_setup_gpios(spi, st);
> if (ret < 0)
> return ret;
>
> @@ -702,7 +734,7 @@ static int ad2s1210_probe(struct spi_device *spi)
> return 0;
>
> error_free_gpios:
> - ad2s1210_free_gpios(st);
> + ad2s1210_free_gpios(spi, st);
> return ret;
> }
>
> @@ -711,7 +743,7 @@ static int ad2s1210_remove(struct spi_device *spi)
> struct iio_dev *indio_dev = spi_get_drvdata(spi);
>
> iio_device_unregister(indio_dev);
> - ad2s1210_free_gpios(iio_priv(indio_dev));
> + ad2s1210_free_gpios(spi, iio_priv(indio_dev));
>
> return 0;
> }
> diff --git a/drivers/staging/iio/resolver/ad2s1210.h
> b/drivers/staging/iio/resolver/ad2s1210.h
> index e9b2147701fc..63d479b20a6c 100644
> --- a/drivers/staging/iio/resolver/ad2s1210.h
> +++ b/drivers/staging/iio/resolver/ad2s1210.h
> @@ -12,9 +12,6 @@
> #define _AD2S1210_H
>
> struct ad2s1210_platform_data {
> - unsigned intsample;
> - unsigned inta[2];
> - unsigned intres[2];
> boolgpioin;
> };
> #endif /* _AD2S1210_H */
--
Slawomir Stepien
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
On paź 21, 2018 10:31, Slawomir Stepien wrote:
> On paź 21, 2018 11:49, Nishad Kamdar wrote:
> > -static int ad2s1210_setup_gpios(struct ad2s1210_state *st)
> > +static int ad2s1210_setup_gpios(struct spi_device *spi,
> > + struct ad2s1210_state *st
gt;max_speed_hz;
> spi->mode = SPI_MODE_3;
> spi_setup(spi);
> ad2s1210_initial(st);
>
> return 0;
> -
> -error_free_gpios:
> - ad2s1210_free_gpios(st);
> - return ret;
> }
>
> static int ad2s1210_remove(struct spi_device *spi)
> @@ -711,7 +717,6 @@ static int ad2s1210_remove(struct spi_device *spi)
> struct iio_dev *indio_dev = spi_get_drvdata(spi);
>
> iio_device_unregister(indio_dev);
> - ad2s1210_free_gpios(iio_priv(indio_dev));
>
> return 0;
> }
> diff --git a/drivers/staging/iio/resolver/ad2s1210.h
> b/drivers/staging/iio/resolver/ad2s1210.h
> index e9b2147701fc..63d479b20a6c 100644
> --- a/drivers/staging/iio/resolver/ad2s1210.h
> +++ b/drivers/staging/iio/resolver/ad2s1210.h
> @@ -12,9 +12,6 @@
> #define _AD2S1210_H
>
> struct ad2s1210_platform_data {
> - unsigned intsample;
> - unsigned inta[2];
> - unsigned intres[2];
> boolgpioin;
> };
> #endif /* _AD2S1210_H */
--
Slawomir Stepien
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
o error_free_gpios;
> + return ret;
>
> st->fclkin = spi->max_speed_hz;
> spi->mode = SPI_MODE_3;
> @@ -700,10 +713,6 @@ static int ad2s1210_probe(struct spi_device *spi)
> ad2s1210_initial(st);
>
> return 0;
> -
> -error_free_gpios:
> - ad2s1210_free_gpios(st);
> - return ret;
> }
>
> static int ad2s1210_remove(struct spi_device *spi)
> @@ -711,7 +720,6 @@ static int ad2s1210_remove(struct spi_device *spi)
> struct iio_dev *indio_dev = spi_get_drvdata(spi);
>
> iio_device_unregister(indio_dev);
> - ad2s1210_free_gpios(iio_priv(indio_dev));
>
> return 0;
> }
> diff --git a/drivers/staging/iio/resolver/ad2s1210.h
> b/drivers/staging/iio/resolver/ad2s1210.h
> index e9b2147701fc..63d479b20a6c 100644
> --- a/drivers/staging/iio/resolver/ad2s1210.h
> +++ b/drivers/staging/iio/resolver/ad2s1210.h
> @@ -12,9 +12,6 @@
> #define _AD2S1210_H
>
> struct ad2s1210_platform_data {
> - unsigned intsample;
> - unsigned inta[2];
> - unsigned intres[2];
> boolgpioin;
> };
> #endif /* _AD2S1210_H */
--
Slawomir Stepien
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
ad2s1210_free_gpios() as devm API is being used.
> ---
> drivers/staging/iio/resolver/ad2s1210.c | 92 ++---
> drivers/staging/iio/resolver/ad2s1210.h | 3 -
> 2 files changed, 50 insertions(+), 45 deletions(-)
Looks good to me.
Reviewed-by: Slawomir Stepien
--
f_match[] = {
> + { .compatible = "adi,ad2s1210", },
> + { }
> +};
> +MODULE_DEVICE_TABLE(of, ad2s1210_of_match);
> +
> static const struct spi_device_id ad2s1210_id[] = {
> { "ad2s1210" },
> {}
> @@ -733,6 +773,7 @@ MODULE_DEVI
E(of, ad5933_of_match);
> +
> static struct i2c_driver ad5933_driver = {
> .driver = {
> .name = "ad5933",
> + .of_match_table = ad5933_of_match,
> },
> .probe = ad5933_probe,
> .remove = ad5933_remove,
--
Slawomir Stepien
___
the correct way to fix it is to
change the matching pattern: "IIO_DEV_ATTR_(?!CH_OFF)[A-Z_]+".
Or maybe the fix should be done in iio code - argument position inside this
macro?
--
Slawomir Stepien
___
devel mailing
On Feb 03, 2017 11:27, Greg KH wrote:
> On Fri, Feb 03, 2017 at 11:11:35AM +0100, Slawomir Stepien wrote:
> > Hi all
> >
> > There is a "false positive" error reported by checkpatch.pl:
> >
> > ERROR: Use 4 digit octal (0777) not decimal permission
On Feb 03, 2017 04:39, Joe Perches wrote:
> On Fri, 2017-02-03 at 13:10 +0100, Slawomir Stepien wrote:
> > On Feb 03, 2017 11:27, Greg KH wrote:
> > > On Fri, Feb 03, 2017 at 11:11:35AM +0100, Slawomir Stepien wrote:
> > > > Hi all
> > > >
> > &
22 matches
Mail list logo