Re: [alsa-devel] [PATCH v3 2/2] ASoC: imx-wm8962: Fix codec_clk cleanup

2017-03-29 Thread Daniel Baluta
On Tue, Mar 28, 2017 at 6:24 PM, Mark Brown wrote: > On Tue, Mar 28, 2017 at 12:53:06PM +0100, Charles Keepax wrote: >> On Tue, Mar 28, 2017 at 01:47:04PM +0300, Daniel Baluta wrote: > >> > >> - codec_clk = devm_clk_get(_dev->dev, NULL); >> > >&

Re: [alsa-devel] [PATCH v3 2/2] ASoC: imx-wm8962: Fix codec_clk cleanup

2017-03-28 Thread Daniel Baluta
On Tue, Mar 28, 2017 at 12:21 PM, Charles Keepax <ckee...@opensource.wolfsonmicro.com> wrote: > On Tue, Mar 28, 2017 at 11:58:52AM +0300, Daniel Baluta wrote: >> Resource managed devm_clk_get only works with platform's device dev. >> > > I feel like this could use an ex

Re: [alsa-devel] [PATCH v3 2/2] ASoC: imx-wm8962: Fix codec_clk cleanup

2017-03-28 Thread Daniel Baluta
On Tue, Mar 28, 2017 at 12:21 PM, Charles Keepax wrote: > On Tue, Mar 28, 2017 at 11:58:52AM +0300, Daniel Baluta wrote: >> Resource managed devm_clk_get only works with platform's device dev. >> > > I feel like this could use an explaination of why not using devm > is

[PATCH v3 1/2] ASoC: imx-wm8962: Let codec driver enable/disable its MCLK

2017-03-28 Thread Daniel Baluta
WM8962 needs its MCLK when powerup in wm8962_resume(). Thus it's better to control the MCLK in codec driver. Thus remove the clock enable in machine driver accordingly. While at it, get rid of imx_wm8962_remove function since it is now empty. Signed-off-by: Daniel Baluta <daniel.bal...@nxp.

[PATCH v3 2/2] ASoC: imx-wm8962: Fix codec_clk cleanup

2017-03-28 Thread Daniel Baluta
Resource managed devm_clk_get only works with platform's device dev. Reported-by: Nicolin Chen <nicoleots...@gmail.com> Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> --- sound/soc/fsl/imx-wm8962.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sound

[PATCH v3 1/2] ASoC: imx-wm8962: Let codec driver enable/disable its MCLK

2017-03-28 Thread Daniel Baluta
WM8962 needs its MCLK when powerup in wm8962_resume(). Thus it's better to control the MCLK in codec driver. Thus remove the clock enable in machine driver accordingly. While at it, get rid of imx_wm8962_remove function since it is now empty. Signed-off-by: Daniel Baluta --- sound/soc/fsl/imx

[PATCH v3 2/2] ASoC: imx-wm8962: Fix codec_clk cleanup

2017-03-28 Thread Daniel Baluta
Resource managed devm_clk_get only works with platform's device dev. Reported-by: Nicolin Chen Signed-off-by: Daniel Baluta --- sound/soc/fsl/imx-wm8962.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sound/soc/fsl/imx-wm8962.c b/sound/soc/fsl/imx-wm8962.c index 3d894d9

[PATCH v3 0/2] imx-wm8962: Let codec driver enable/disable its MCLK

2017-03-28 Thread Daniel Baluta
codec_clk cleanup * fixed prefix subject Daniel Baluta (2): ASoC: imx-wm8962: Let codec driver enable/disable its MCLK ASoC: imx-wm8962: Fix codec_clk cleanup sound/soc/fsl/imx-wm8962.c | 41 + 1 file changed, 9 insertions(+), 32 deletions

[PATCH v3 0/2] imx-wm8962: Let codec driver enable/disable its MCLK

2017-03-28 Thread Daniel Baluta
codec_clk cleanup * fixed prefix subject Daniel Baluta (2): ASoC: imx-wm8962: Let codec driver enable/disable its MCLK ASoC: imx-wm8962: Fix codec_clk cleanup sound/soc/fsl/imx-wm8962.c | 41 + 1 file changed, 9 insertions(+), 32 deletions

[PATCH v2] ASoC: imx-wm8960: Let codec driver enable/disable its MCLK

2017-03-24 Thread Daniel Baluta
From: Daniel Baluta <daniel.bal...@nxp.com> WM8962 needs its MCLK when powerup in wm8962_resume(). Thus it's better to control the MCLK in codec driver. Thus remove the clock enable in machine driver accordingly. While at it, get rid of imx_wm8962_remove function since it is now empty.

[PATCH v2] ASoC: imx-wm8960: Let codec driver enable/disable its MCLK

2017-03-24 Thread Daniel Baluta
From: Daniel Baluta WM8962 needs its MCLK when powerup in wm8962_resume(). Thus it's better to control the MCLK in codec driver. Thus remove the clock enable in machine driver accordingly. While at it, get rid of imx_wm8962_remove function since it is now empty. Signed-off-by: Daniel Baluta

Re: [PATCH] ASoC: WM8962: Let codec driver enable/disable its MCLK

2017-03-24 Thread Daniel Baluta
On Fri, Mar 24, 2017 at 6:58 AM, Nicolin Chen <nicoleots...@gmail.com> wrote: > On Thu, Mar 23, 2017 at 02:01:50PM +0200, Daniel Baluta wrote: >> From: Nicolin Chen <b42...@freescale.com> >> >> WM8962 needs its MCLK when powerup in wm8962_resume(). Thus it's bette

Re: [PATCH] ASoC: WM8962: Let codec driver enable/disable its MCLK

2017-03-24 Thread Daniel Baluta
On Fri, Mar 24, 2017 at 6:58 AM, Nicolin Chen wrote: > On Thu, Mar 23, 2017 at 02:01:50PM +0200, Daniel Baluta wrote: >> From: Nicolin Chen >> >> WM8962 needs its MCLK when powerup in wm8962_resume(). Thus it's better >> to control the MCLK in codec driver. T

[PATCH] ASoC: WM8962: Let codec driver enable/disable its MCLK

2017-03-23 Thread Daniel Baluta
ed-off-by: Nicolin Chen <b42...@freescale.com> Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> --- sound/soc/fsl/imx-wm8962.c | 40 1 file changed, 8 insertions(+), 32 deletions(-) diff --git a/sound/soc/fsl/imx-wm8962.c b/sound/soc/fsl/

[PATCH] ASoC: WM8962: Let codec driver enable/disable its MCLK

2017-03-23 Thread Daniel Baluta
Signed-off-by: Daniel Baluta --- sound/soc/fsl/imx-wm8962.c | 40 1 file changed, 8 insertions(+), 32 deletions(-) diff --git a/sound/soc/fsl/imx-wm8962.c b/sound/soc/fsl/imx-wm8962.c index 1b60958..3d894d9 100644 --- a/sound/soc/fsl/imx-wm8962.c +++ b/sound

[PATCH v3 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
driver fails to configure clocking and aplay fails to run. Fix this by relaxing bitclk computation, so that when no exact value can be derived from sysclk pick the closest value greater than expected bitclk. Suggested-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com> Signed-off-by:

[PATCH v3 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
driver fails to configure clocking and aplay fails to run. Fix this by relaxing bitclk computation, so that when no exact value can be derived from sysclk pick the closest value greater than expected bitclk. Suggested-by: Charles Keepax Signed-off-by: Daniel Baluta --- Changes since v2

[PATCH v3 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-21 Thread Daniel Baluta
Add a separate function for finding (sysclk, lrclk, bclk) when the clock is auto or mclk. This makes code easier to read and reduces the indentation level in wm8960_configure_clocking. Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> Acked-by: Charles Keepax

[PATCH v3 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-21 Thread Daniel Baluta
Add a separate function for finding (sysclk, lrclk, bclk) when the clock is auto or mclk. This makes code easier to read and reduces the indentation level in wm8960_configure_clocking. Signed-off-by: Daniel Baluta Acked-by: Charles Keepax --- Changes since v2: * none sound/soc/codecs

[PATCH v3 0/2] wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
couldn't be derived from sysclk it chooses the smalles available bitclk greater than the desired bitclk. Changes since v2: * do not differentiate between relaxed and exact match Changes since v1: * dropped the RFC tag * comments in each individual patch Daniel Baluta (2): ASoC

[PATCH v3 0/2] wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
couldn't be derived from sysclk it chooses the smalles available bitclk greater than the desired bitclk. Changes since v2: * do not differentiate between relaxed and exact match Changes since v1: * dropped the RFC tag * comments in each individual patch Daniel Baluta (2): ASoC

Re: [alsa-devel] [PATCH v2 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
On Tue, Mar 21, 2017 at 4:20 PM, Charles Keepax <ckee...@opensource.wolfsonmicro.com> wrote: > On Tue, Mar 21, 2017 at 04:05:15PM +0200, Daniel Baluta wrote: >> On Tue, Mar 21, 2017 at 2:52 PM, Charles Keepax >> <ckee...@opensource.wolfsonmicro.com> wrote: >> >

Re: [alsa-devel] [PATCH v2 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
On Tue, Mar 21, 2017 at 4:20 PM, Charles Keepax wrote: > On Tue, Mar 21, 2017 at 04:05:15PM +0200, Daniel Baluta wrote: >> On Tue, Mar 21, 2017 at 2:52 PM, Charles Keepax >> wrote: >> > On Tue, Mar 21, 2017 at 12:09:36PM +0200, Daniel Baluta wrote: >> >> WM

Re: [alsa-devel] [PATCH v2 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
On Tue, Mar 21, 2017 at 2:52 PM, Charles Keepax <ckee...@opensource.wolfsonmicro.com> wrote: > On Tue, Mar 21, 2017 at 12:09:36PM +0200, Daniel Baluta wrote: >> WM8960 derives bit clock from sysclock using BCLKDIV[3:0] of R8 >> clocking register (See WM8960 datasheet, page 71)

Re: [alsa-devel] [PATCH v2 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
On Tue, Mar 21, 2017 at 2:52 PM, Charles Keepax wrote: > On Tue, Mar 21, 2017 at 12:09:36PM +0200, Daniel Baluta wrote: >> WM8960 derives bit clock from sysclock using BCLKDIV[3:0] of R8 >> clocking register (See WM8960 datasheet, page 71). >> >> There are use cases, l

[PATCH v2 0/2] wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
couldn't be derived from sysclk it chooses the smalles available bitclk greater than the desired bitclk. Changes since v1: * dropped the RFC tag * comments in each individual patch Daniel Baluta (2): ASoC: codec: wm8960: Refactor sysclk freq search ASoC: codec: wm8960: Relax

[PATCH v2 0/2] wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
couldn't be derived from sysclk it chooses the smalles available bitclk greater than the desired bitclk. Changes since v1: * dropped the RFC tag * comments in each individual patch Daniel Baluta (2): ASoC: codec: wm8960: Refactor sysclk freq search ASoC: codec: wm8960: Relax

[PATCH v2 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-21 Thread Daniel Baluta
Add a separate function for finding (sysclk, lrclk, bclk) when the clock is auto or mclk. This makes code easier to read and reduces the indentation level in wm8960_configure_clocking. Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> --- Changes since v1:

[PATCH v2 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
driver fails to configure clocking and aplay fails to run. Fix this by relaxing bitclk computation, so that when no exact value can be derived from sysclk pick the closest value greater than expected bitclk. Suggested-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com> Signed-off-by:

[PATCH v2 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-21 Thread Daniel Baluta
Add a separate function for finding (sysclk, lrclk, bclk) when the clock is auto or mclk. This makes code easier to read and reduces the indentation level in wm8960_configure_clocking. Signed-off-by: Daniel Baluta --- Changes since v1: * made wm8960_configure_sysclk static

[PATCH v2 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-21 Thread Daniel Baluta
driver fails to configure clocking and aplay fails to run. Fix this by relaxing bitclk computation, so that when no exact value can be derived from sysclk pick the closest value greater than expected bitclk. Suggested-by: Charles Keepax Signed-off-by: Daniel Baluta --- Changes since v1

Re: [alsa-devel] [RFC PATCH 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-16 Thread Daniel Baluta
On Wed, Mar 15, 2017 at 7:17 PM, Charles Keepax <ckee...@opensource.wolfsonmicro.com> wrote: > On Wed, Mar 15, 2017 at 05:33:06PM +0200, Daniel Baluta wrote: >> WM8960 derives bit clock from sysclock using BCLKDIV[3:0] of R8 >> clocking register (See WM8960 datasheet, page 71)

Re: [alsa-devel] [RFC PATCH 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-16 Thread Daniel Baluta
On Wed, Mar 15, 2017 at 7:17 PM, Charles Keepax wrote: > On Wed, Mar 15, 2017 at 05:33:06PM +0200, Daniel Baluta wrote: >> WM8960 derives bit clock from sysclock using BCLKDIV[3:0] of R8 >> clocking register (See WM8960 datasheet, page 71). >> >> There are use cases, l

Re: [alsa-devel] [RFC PATCH 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-16 Thread Daniel Baluta
On Wed, Mar 15, 2017 at 6:22 PM, Charles Keepax <ckee...@opensource.wolfsonmicro.com> wrote: > On Wed, Mar 15, 2017 at 05:33:05PM +0200, Daniel Baluta wrote: >> Add a separate function for finding (sysclk, lrclk, bclk) >> when the clock is auto or mclk. This makes c

Re: [alsa-devel] [RFC PATCH 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-16 Thread Daniel Baluta
On Wed, Mar 15, 2017 at 6:22 PM, Charles Keepax wrote: > On Wed, Mar 15, 2017 at 05:33:05PM +0200, Daniel Baluta wrote: >> Add a separate function for finding (sysclk, lrclk, bclk) >> when the clock is auto or mclk. This makes code easier to >> read and reduces

[RFC PATCH 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-15 Thread Daniel Baluta
driver fails to configure clocking and aplay fails to run. Fix this by relaxing bitclk computation, so that when no exact value can be derived from sysclk pick the closest value greater than expected bitclk. Suggested-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com> Signed-off-by:

[RFC PATCH 2/2] ASoC: codec: wm8960: Relax bit clock computation

2017-03-15 Thread Daniel Baluta
driver fails to configure clocking and aplay fails to run. Fix this by relaxing bitclk computation, so that when no exact value can be derived from sysclk pick the closest value greater than expected bitclk. Suggested-by: Charles Keepax Signed-off-by: Daniel Baluta --- sound/soc/codecs/wm8960.c

[RFC PATCH 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-15 Thread Daniel Baluta
Add a separate function for finding (sysclk, lrclk, bclk) when the clock is auto or mclk. This makes code easier to read and reduces the indentation level in wm8960_configure_clocking. Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> --- sound/soc/codecs/wm8960.

[RFC PATCH 1/2] ASoC: codec: wm8960: Refactor sysclk freq search

2017-03-15 Thread Daniel Baluta
Add a separate function for finding (sysclk, lrclk, bclk) when the clock is auto or mclk. This makes code easier to read and reduces the indentation level in wm8960_configure_clocking. Signed-off-by: Daniel Baluta --- sound/soc/codecs/wm8960.c | 82

[RFC PATCH 0/2] wm8960: Relax bit clock computation

2017-03-15 Thread Daniel Baluta
width for bclk" discussion archived here: http://mailman.alsa-project.org/pipermail/alsa-devel/2017-March/118735.html Daniel Baluta (2): ASoC: codec: wm8960: Refactor sysclk freq search ASoC: codec: wm8960: Relax bit clock computation sound/soc/codecs/wm89

[RFC PATCH 0/2] wm8960: Relax bit clock computation

2017-03-15 Thread Daniel Baluta
width for bclk" discussion archived here: http://mailman.alsa-project.org/pipermail/alsa-devel/2017-March/118735.html Daniel Baluta (2): ASoC: codec: wm8960: Refactor sysclk freq search ASoC: codec: wm8960: Relax bit clock computation sound/soc/codecs/wm89

Re: [alsa-devel] [RFC PATCH] ASoC: wm8960: Use physical width for bclk

2017-03-15 Thread Daniel Baluta
On Wed, Mar 15, 2017 at 3:33 PM, Mark Brown <broo...@kernel.org> wrote: > On Wed, Mar 15, 2017 at 09:19:01AM +, Charles Keepax wrote: >> On Tue, Mar 14, 2017 at 06:57:02PM +0200, Daniel Baluta wrote: > >> > - wm8960->bclk = snd_soc_params_to_bclk(

Re: [alsa-devel] [RFC PATCH] ASoC: wm8960: Use physical width for bclk

2017-03-15 Thread Daniel Baluta
On Wed, Mar 15, 2017 at 3:33 PM, Mark Brown wrote: > On Wed, Mar 15, 2017 at 09:19:01AM +, Charles Keepax wrote: >> On Tue, Mar 14, 2017 at 06:57:02PM +0200, Daniel Baluta wrote: > >> > - wm8960->bclk = snd_soc_params_to_bclk(params); >> > + wm8960->

Re: [RFC PATCH] ASoC: wm8960: Use physical width for bclk

2017-03-15 Thread Daniel Baluta
On Mi, 2017-03-15 at 09:19 +, Charles Keepax wrote: > On Tue, Mar 14, 2017 at 06:57:02PM +0200, Daniel Baluta wrote: > > > > bclk is derived from sysclk with the help of bclk_divs. Anyhow, for > > S20_3LE format there is no bclk_divs that could be used to derive > >

Re: [RFC PATCH] ASoC: wm8960: Use physical width for bclk

2017-03-15 Thread Daniel Baluta
On Mi, 2017-03-15 at 09:19 +, Charles Keepax wrote: > On Tue, Mar 14, 2017 at 06:57:02PM +0200, Daniel Baluta wrote: > > > > bclk is derived from sysclk with the help of bclk_divs. Anyhow, for > > S20_3LE format there is no bclk_divs that could be used to derive > >

[RFC PATCH] ASoC: wm8960: Use physical width for bclk

2017-03-14 Thread Daniel Baluta
encoded files at the cost of some unused BCLK cycles for S20_3LE and S24_LE. Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> --- sound/soc/codecs/wm8960.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sound/soc/codecs/wm8960.c b/sound/soc/codecs/wm8960.c index e

[RFC PATCH] ASoC: wm8960: Use physical width for bclk

2017-03-14 Thread Daniel Baluta
encoded files at the cost of some unused BCLK cycles for S20_3LE and S24_LE. Signed-off-by: Daniel Baluta --- sound/soc/codecs/wm8960.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sound/soc/codecs/wm8960.c b/sound/soc/codecs/wm8960.c index e1429e3..18ca5fc 100644

Re: [RFC 0/4] iio: trigger: Add OF support and GPIO based trigger

2017-02-17 Thread Daniel Baluta
On Fri, Feb 17, 2017 at 6:03 PM, Fabrice Gasnier wrote: > Hi, > > I send this as an RFC, as I'm digging to try to get as generic > as possible GPIO based trigger support, as discussed earlier in > other patchset "Add EXTI GPIO trigger support to STM32 ADC": >

Re: [RFC 0/4] iio: trigger: Add OF support and GPIO based trigger

2017-02-17 Thread Daniel Baluta
On Fri, Feb 17, 2017 at 6:03 PM, Fabrice Gasnier wrote: > Hi, > > I send this as an RFC, as I'm digging to try to get as generic > as possible GPIO based trigger support, as discussed earlier in > other patchset "Add EXTI GPIO trigger support to STM32 ADC": >

[PATCH] ASoC: Drop unnecessary debugfs ifdef

2017-02-01 Thread Daniel Baluta
This is a relict of 6553bf06a369 ("ASoC: Don't try to register debugfs entries if the parent does not exist"). Signed-off-by: Daniel Baluta <daniel.bal...@nxp.com> --- sound/soc/soc-core.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sound/soc/soc-core.c b/sound/soc/

[PATCH] ASoC: Drop unnecessary debugfs ifdef

2017-02-01 Thread Daniel Baluta
This is a relict of 6553bf06a369 ("ASoC: Don't try to register debugfs entries if the parent does not exist"). Signed-off-by: Daniel Baluta --- sound/soc/soc-core.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 9b589d6..a110

Re: kernel 4.10-rcx iio helper question

2017-02-01 Thread Daniel Baluta
Could you paste your drivers/iio/pressure/mpl3115.c code into pastebin.com and send us the result? thanks, Daniel. On Wed, Feb 1, 2017 at 8:50 AM, Jonathan Cameron wrote: > > > On 1 February 2017 00:42:31 GMT+00:00, "Ken.Lin" > wrote: >> >>

Re: kernel 4.10-rcx iio helper question

2017-02-01 Thread Daniel Baluta
Could you paste your drivers/iio/pressure/mpl3115.c code into pastebin.com and send us the result? thanks, Daniel. On Wed, Feb 1, 2017 at 8:50 AM, Jonathan Cameron wrote: > > > On 1 February 2017 00:42:31 GMT+00:00, "Ken.Lin" > wrote: >> >> >>> -Original Message- >>> From: Peter Rosin

Re: kernel 4.10-rcx iio helper question

2017-01-31 Thread Daniel Baluta
On Tue, Jan 31, 2017 at 8:19 PM, Ken.Lin wrote: > Hi, > > I find the latest kernel introduces new iio sys attributes. > https://patchwork.kernel.org/patch/9391771/ > https://patchwork.kernel.org/patch/9391259/ > > Is there anyone has some ideas about how the new iio sys

Re: kernel 4.10-rcx iio helper question

2017-01-31 Thread Daniel Baluta
On Tue, Jan 31, 2017 at 8:19 PM, Ken.Lin wrote: > Hi, > > I find the latest kernel introduces new iio sys attributes. > https://patchwork.kernel.org/patch/9391771/ > https://patchwork.kernel.org/patch/9391259/ > > Is there anyone has some ideas about how the new iio sys attribute - >

Re: [PATCH v3 1/8] iio:core: add a callback to allow drivers to provide _available attributes

2016-11-07 Thread Daniel Baluta
On Mon, Nov 7, 2016 at 1:57 PM, Peter Rosin <p...@axentia.se> wrote: > On 2016-11-07 12:37, Daniel Baluta wrote: >> On Mon, Oct 24, 2016 at 1:39 AM, Peter Rosin <p...@axentia.se> wrote: >>> From: Jonathan Cameron <ji...@kernel.org> >>> >>> A la

Re: [PATCH v3 1/8] iio:core: add a callback to allow drivers to provide _available attributes

2016-11-07 Thread Daniel Baluta
On Mon, Nov 7, 2016 at 1:57 PM, Peter Rosin wrote: > On 2016-11-07 12:37, Daniel Baluta wrote: >> On Mon, Oct 24, 2016 at 1:39 AM, Peter Rosin wrote: >>> From: Jonathan Cameron >>> >>> A large number of attributes can only take a limited range of values.

Re: [PATCH v3 1/8] iio:core: add a callback to allow drivers to provide _available attributes

2016-11-07 Thread Daniel Baluta
On Mon, Oct 24, 2016 at 1:39 AM, Peter Rosin wrote: > From: Jonathan Cameron > > A large number of attributes can only take a limited range of values. > Currently in IIO this is handled by directly registering additional > *_available attributes thus providing

Re: [PATCH v3 1/8] iio:core: add a callback to allow drivers to provide _available attributes

2016-11-07 Thread Daniel Baluta
On Mon, Oct 24, 2016 at 1:39 AM, Peter Rosin wrote: > From: Jonathan Cameron > > A large number of attributes can only take a limited range of values. > Currently in IIO this is handled by directly registering additional > *_available attributes thus providing this information to userspace. > >

Re: [PATCH] iio: Use type header from kernel tree

2016-09-09 Thread Daniel Baluta
On Fri, Sep 9, 2016 at 6:24 PM, Laura Abbott wrote: > > The iio tools have been updated as new event types have been added to > the kernel. The tools currently use the standard system headers which > means that the system may not have the newest defintitions. This leads > to

Re: [PATCH] iio: Use type header from kernel tree

2016-09-09 Thread Daniel Baluta
On Fri, Sep 9, 2016 at 6:24 PM, Laura Abbott wrote: > > The iio tools have been updated as new event types have been added to > the kernel. The tools currently use the standard system headers which > means that the system may not have the newest defintitions. This leads > to build failures when

Re: [PATCH] tools/lguest: Don't bork the terminal in case of wrong args

2016-09-07 Thread Daniel Baluta
On Tue, Dec 8, 2015 at 4:35 PM, Daniel Baluta <daniel.bal...@intel.com> wrote: > Running lguest without arguments or with a wrong argument name > borks the terminal, because the cleanup handler is set up too late > in the initialization process. > > Signed-off-by: Dani

Re: [PATCH] tools/lguest: Don't bork the terminal in case of wrong args

2016-09-07 Thread Daniel Baluta
On Tue, Dec 8, 2015 at 4:35 PM, Daniel Baluta wrote: > Running lguest without arguments or with a wrong argument name > borks the terminal, because the cleanup handler is set up too late > in the initialization process. > > Signed-off-by: Daniel Baluta Hi Rusty, Any chance to pick this up?

Re: [PATCH 1/1] iio: fix config watermark initial value

2016-06-16 Thread Daniel Baluta
On Mon, Mar 28, 2016 at 1:02 PM, Jonathan Cameron wrote: > On 24/03/16 09:23, Lars-Peter Clausen wrote: >> On 03/24/2016 10:09 AM, Irina Tirdea wrote: >>> config structure is set to 0 when updating the buffers, so by >>> default config->watermark will be 0. When computing the

Re: [PATCH 1/1] iio: fix config watermark initial value

2016-06-16 Thread Daniel Baluta
On Mon, Mar 28, 2016 at 1:02 PM, Jonathan Cameron wrote: > On 24/03/16 09:23, Lars-Peter Clausen wrote: >> On 03/24/2016 10:09 AM, Irina Tirdea wrote: >>> config structure is set to 0 when updating the buffers, so by >>> default config->watermark will be 0. When computing the minimum >>> between

Re: [PATCH] iio: inv_mpu6050: Fix use-after-free in ACPI code

2016-06-06 Thread Daniel Baluta
ada <srinivas.pandruv...@linux.intel.com> > Signed-off-by: Crestez Dan Leonard <leonard.cres...@intel.com> Looks good to me. I had to look into the code to see that cpm is an alias for buffer.pointer, perhaps this should have been mentioned in the commit message. Acked-by: Da

Re: [PATCH] iio: inv_mpu6050: Fix use-after-free in ACPI code

2016-06-06 Thread Daniel Baluta
onard Looks good to me. I had to look into the code to see that cpm is an alias for buffer.pointer, perhaps this should have been mentioned in the commit message. Acked-by: Daniel Baluta > --- > drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c | 5 +++-- > 1 file changed, 3 insertions(+), 2

Re: [PATCH 3/3] iio: mma8452: update Freescale company information

2016-06-06 Thread Daniel Baluta
On Fri, Jun 3, 2016 at 3:51 PM, Martin Kepplinger wrote: > NXP took over Freescale, so add NXP to the driver descriptions > Is it worth to bother with these kind of changes? The part number still remains the same. We can add a new copyright notice from the new company and

Re: [PATCH 3/3] iio: mma8452: update Freescale company information

2016-06-06 Thread Daniel Baluta
On Fri, Jun 3, 2016 at 3:51 PM, Martin Kepplinger wrote: > NXP took over Freescale, so add NXP to the driver descriptions > Is it worth to bother with these kind of changes? The part number still remains the same. We can add a new copyright notice from the new company and that's all. Daniel. >

Re: [PATCH] Dyna-Image AL3320A update, add AL3010 driver

2016-06-03 Thread Daniel Baluta
t; + > + return ret; > +} > + > +static ssize_t al3320a_lux_show(struct device *dev, > + struct device_attribute *attr, > + char *buf) > +{ > + struct al3320a_data *data = iio_priv(dev_to_iio_dev(dev)); > + int val; > + >

Re: [PATCH] Dyna-Image AL3320A update, add AL3010 driver

2016-06-03 Thread Daniel Baluta
et64 = ret; > + ret64 = (ret64 * 32000) / 100; > + ret = ret64; > + > + return ret; > +} > + > +static ssize_t al3320a_lux_show(struct device *dev, > + struct device_attribute *attr, > + char *buf) > +{ > +

Re: [PATCH 7/7] iio: adc: ad799x: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:20 PM, Alison Schofield <amsfiel...@gmail.com> wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield <amsfiel...@gmail.com> > Cc

Re: [PATCH 7/7] iio: adc: ad799x: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:20 PM, Alison Schofield wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield > Cc: Daniel Baluta Acked-by: Daniel Baluta > ---

Re: [PATCH 6/7] iio: adc: ad7923: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:19 PM, Alison Schofield <amsfiel...@gmail.com> wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield <amsfiel...@gmail.com> > Cc

Re: [PATCH 6/7] iio: adc: ad7923: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:19 PM, Alison Schofield wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield > Cc: Daniel Baluta Acked-by: Daniel Baluta > --- > d

Re: [PATCH 5/7] iio: adc: ad7887: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:18 PM, Alison Schofield <amsfiel...@gmail.com> wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield <amsfiel...@gmail.com> > Cc

Re: [PATCH 5/7] iio: adc: ad7887: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:18 PM, Alison Schofield wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield > Cc: Daniel Baluta Acked-by: Daniel Baluta > --- > d

Re: [PATCH 4/7] iio: adc: ad7476: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:18 PM, Alison Schofield <amsfiel...@gmail.com> wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield <amsfiel...@gmail.com> > Cc

Re: [PATCH 4/7] iio: adc: ad7476: use iio helper function to guarantee direct mode

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:18 PM, Alison Schofield wrote: > Replace the code that guarantees the device stays in direct mode > with iio_device_claim_direct_mode() which does same. > > Signed-off-by: Alison Schofield > Cc: Daniel Baluta Acked-by: Daniel Baluta > --- > d

Re: [PATCH 3/7] iio: adc: ad7793: claim direct mode when writing frequency

2016-05-25 Thread Daniel Baluta
n > direct mode. > > Signed-off-by: Alison Schofield <amsfiel...@gmail.com> > Cc: Daniel Baluta <daniel.bal...@gmail.com> Acked-by: Daniel Baluta <daniel.bal...@gmail.com> > --- > drivers/iio/adc/ad7793.c | 13 - > 1 file changed, 4 insertions(+), 9 de

Re: [PATCH 3/7] iio: adc: ad7793: claim direct mode when writing frequency

2016-05-25 Thread Daniel Baluta
ned-off-by: Alison Schofield > Cc: Daniel Baluta Acked-by: Daniel Baluta > --- > drivers/iio/adc/ad7793.c | 13 - > 1 file changed, 4 insertions(+), 9 deletions(-) > > diff --git a/drivers/iio/adc/ad7793.c b/drivers/iio/adc/ad7793.c > index 7b07bb6..3f41cd8

Re: [PATCH 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-05-25 Thread Daniel Baluta
n > direct mode. > > Signed-off-by: Alison Schofield <amsfiel...@gmail.com> > Cc: Daniel Baluta <daniel.bal...@gmail.com> Looks good to me. We could use an Acked-by from Lars here. Acked-by: Daniel Baluta <daniel.bal...@gmail.com> > --- > drivers/iio/adc/ad7791.c |

Re: [PATCH 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-05-25 Thread Daniel Baluta
ned-off-by: Alison Schofield > Cc: Daniel Baluta Looks good to me. We could use an Acked-by from Lars here. Acked-by: Daniel Baluta > --- > drivers/iio/adc/ad7791.c | 15 --- > 1 file changed, 4 insertions(+), 11 deletions(-) > > diff --git a/drivers/iio/adc

Re: [PATCH 1/7] iio: adc: ad7266: claim direct mode during sensor read

2016-05-25 Thread Daniel Baluta
@gmail.com> > Cc: Daniel Baluta <daniel.bal...@gmail.com> Acked-by: Daniel Baluta <daniel.bal...@gmail.com> > --- > drivers/iio/adc/ad7266.c | 7 +++ > 1 file changed, 3 insertions(+), 4 deletions(-) > > diff --git a/drivers/iio/adc/ad7266.c b/drivers/iio/adc

Re: [PATCH 1/7] iio: adc: ad7266: claim direct mode during sensor read

2016-05-25 Thread Daniel Baluta
On Tue, May 24, 2016 at 10:16 PM, Alison Schofield wrote: > Driver was checking for direct mode but not locking it down. > Use iio_device_claim_direct_mode() to guarantee device stays > in direct mode. > > Signed-off-by: Alison Schofield > Cc: Daniel Baluta Acked

[RFC PATCH v2] tools: iio: Rename generic_buffer to iio_generic_buffer

2016-05-24 Thread Daniel Baluta
This makes it clear that generic_buffer is an IIO tool and also complies with filename conventions in tools/iio. Signed-off-by: Daniel Baluta <daniel.bal...@intel.com> --- Changes since v1: * use -M to detect renames and make the patch easier to review tools/iio/Ma

[RFC PATCH v2] tools: iio: Rename generic_buffer to iio_generic_buffer

2016-05-24 Thread Daniel Baluta
This makes it clear that generic_buffer is an IIO tool and also complies with filename conventions in tools/iio. Signed-off-by: Daniel Baluta --- Changes since v1: * use -M to detect renames and make the patch easier to review tools/iio/Makefile | 6

[RFC PATCH] tools:iio: Rename generic_buffer

2016-05-24 Thread Daniel Baluta
The new name is in agreement with convention for tools/iio programs. Signed-off-by: Daniel Baluta <daniel.bal...@intel.com> --- tools/iio/Makefile | 6 +- tools/iio/generic_buffer.c | 581 - tools/iio/iio_generic_buffer.c

[RFC PATCH] tools:iio: Rename generic_buffer

2016-05-24 Thread Daniel Baluta
The new name is in agreement with convention for tools/iio programs. Signed-off-by: Daniel Baluta --- tools/iio/Makefile | 6 +- tools/iio/generic_buffer.c | 581 - tools/iio/iio_generic_buffer.c | 581

[PATCH] iio: magnetometer: bmc150: Document Bosch supported chips

2016-05-24 Thread Daniel Baluta
bmc150 driver supports also BMC156 and BMM150 chips. Signed-off-by: Daniel Baluta <daniel.bal...@intel.com> --- drivers/iio/magnetometer/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/iio/magnetometer/Kconfig b/drivers/iio/magnetometer/Kconfig index 84e6559..1f842ab

[PATCH] iio: magnetometer: bmc150: Document Bosch supported chips

2016-05-24 Thread Daniel Baluta
bmc150 driver supports also BMC156 and BMM150 chips. Signed-off-by: Daniel Baluta --- drivers/iio/magnetometer/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/iio/magnetometer/Kconfig b/drivers/iio/magnetometer/Kconfig index 84e6559..1f842ab 100644 --- a/drivers/iio

Re: [RFT PATCH] iio: magn: Add support for BMM150 magnetometer

2016-05-18 Thread Daniel Baluta
On Wed, May 4, 2016 at 1:26 PM, Jonathan Cameron <ji...@kernel.org> wrote: > On 27/04/16 15:55, Lucas De Marchi wrote: >> On Tue, Apr 26, 2016 at 9:39 AM, Daniel Baluta <daniel.bal...@intel.com> >> wrote: >>> BMM150 is register compatible with magnetometer p

Re: [RFT PATCH] iio: magn: Add support for BMM150 magnetometer

2016-05-18 Thread Daniel Baluta
On Wed, May 4, 2016 at 1:26 PM, Jonathan Cameron wrote: > On 27/04/16 15:55, Lucas De Marchi wrote: >> On Tue, Apr 26, 2016 at 9:39 AM, Daniel Baluta >> wrote: >>> BMM150 is register compatible with magnetometer part of >>> BMC156. >>> >>> Data

Re: [PATCH v3] iio: accel: Add support for Freescale MMA7660FC

2016-05-03 Thread Daniel Baluta
On Tue, May 3, 2016 at 1:43 PM, Jonathan Cameron <ji...@jic23.retrosnub.co.uk> wrote: > > > On 3 May 2016 09:29:26 CEST, Daniel Baluta <daniel.bal...@intel.com> wrote: >>On Sun, May 1, 2016 at 9:56 PM, Jonathan Cameron <ji...@kernel.org> >>wrote: >&g

Re: [PATCH v3] iio: accel: Add support for Freescale MMA7660FC

2016-05-03 Thread Daniel Baluta
On Tue, May 3, 2016 at 1:43 PM, Jonathan Cameron wrote: > > > On 3 May 2016 09:29:26 CEST, Daniel Baluta wrote: >>On Sun, May 1, 2016 at 9:56 PM, Jonathan Cameron >>wrote: >>> On 29/04/16 13:19, Constantin Musca wrote: >>>> Minimal impleme

Re: [PATCH v3] iio: accel: Add support for Freescale MMA7660FC

2016-05-03 Thread Daniel Baluta
On Sun, May 1, 2016 at 9:56 PM, Jonathan Cameron wrote: > On 29/04/16 13:19, Constantin Musca wrote: >> Minimal implementation of an IIO driver for the Freescale >> MMA7660FC 3-axis accelerometer. Datasheet: >>

Re: [PATCH v3] iio: accel: Add support for Freescale MMA7660FC

2016-05-03 Thread Daniel Baluta
On Sun, May 1, 2016 at 9:56 PM, Jonathan Cameron wrote: > On 29/04/16 13:19, Constantin Musca wrote: >> Minimal implementation of an IIO driver for the Freescale >> MMA7660FC 3-axis accelerometer. Datasheet: >> http://www.freescale.com.cn/files/sensors/doc/data_sheet/MMA7660FC.pdf >> >> Includes:

[PATCH 1/3] iio: bmi160: Fix output data rate for accel

2016-04-29 Thread Daniel Baluta
Format is INT_PLUS_MICRO and micro odr part of ODR should be parts of a micro. Also s/8000/800 this is obviously a typo. Fixes: 77c4ad2d6a9 ("iio: imu: Add initial support for Bosch BMI160") Signed-off-by: Daniel Baluta <daniel.bal...@intel.com> --- drivers/iio/imu/bmi160/bm

[PATCH 1/3] iio: bmi160: Fix output data rate for accel

2016-04-29 Thread Daniel Baluta
Format is INT_PLUS_MICRO and micro odr part of ODR should be parts of a micro. Also s/8000/800 this is obviously a typo. Fixes: 77c4ad2d6a9 ("iio: imu: Add initial support for Bosch BMI160") Signed-off-by: Daniel Baluta --- drivers/iio/imu/bmi160/bmi160_core.c | 12 ++-- 1 fi

[PATCH 0/3] Add available sampling frequency and scale attributes

2016-04-29 Thread Daniel Baluta
First two patches are bugfixes related to sampling frequency and the last one is adding support for exporting available sampling frequency and scale. Daniel Baluta (3): iio: bmi160: Fix output data rate for accel iio: bmi160: Fix ODR setting imu: bmi160: Add avail frequency and scale

<    1   2   3   4   5   6   7   8   9   10   >