[PATCH 3/4] spi: omap2-mcspi: Fix GPIO chip select support

2015-05-23 Thread Michael Welling
The OMAP2_MCSPI_CHCONF_FORCE must be toggled even when using GPIO chip selects. This patch conditionally calls the omap2_mcspi_set_cs function to do so when using GPIO chip selects. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c |6 ++ 1 file changed, 6 insertions

[PATCH 2/4] spi: omap2-mcspi: Fix set_cs function for active high

2015-05-23 Thread Michael Welling
of the OMAP2_MCSPI_CHCONF_FORCE bit in omap2_mcspi_set_cs. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c index 304b427..502db29 100644 --- a/drivers/spi/spi-omap2

[PATCH 1/4] spi: omap2-mcspi: Remove unnecessary delay

2015-05-23 Thread Michael Welling
The core spi driver handles the delay between transactions. This is a remanant from the transfer_one conversion. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c |3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2

[PATCH 4/4] spi: omap2-mcspi: Handle error on gpio_request

2015-05-23 Thread Michael Welling
If a valid GPIO is specified but cannot be requested by the driver, print a message and error out of omap2_mcspi_setup. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c |9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/spi/spi-omap2-mcspi.c

[PATCH 0/4] spi: omap2-mcspi: Fixes for recent updates

2015-05-23 Thread Michael Welling
The recent update of the OMAP2 McSPI driver left some unresolved issues. These patches should take care them and again allow for GPIO chip selects and native chip selects. Michael Welling (4): spi: omap2-mcspi: Remove unnecessary delay spi: omap2-mcspi: Fix set_cs function for active high

[PATCH 0/4] spi: omap2-mcspi: Fixes for recent updates

2015-05-23 Thread Michael Welling
The recent update of the OMAP2 McSPI driver left some unresolved issues. These patches should take care them and again allow for GPIO chip selects and native chip selects. Michael Welling (4): spi: omap2-mcspi: Remove unnecessary delay spi: omap2-mcspi: Fix set_cs function for active high

[PATCH 2/4] spi: omap2-mcspi: Fix set_cs function for active high

2015-05-23 Thread Michael Welling
of the OMAP2_MCSPI_CHCONF_FORCE bit in omap2_mcspi_set_cs. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c index 304b427..502db29 100644 --- a/drivers/spi

[PATCH 1/4] spi: omap2-mcspi: Remove unnecessary delay

2015-05-23 Thread Michael Welling
The core spi driver handles the delay between transactions. This is a remanant from the transfer_one conversion. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c |3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi

[PATCH 3/4] spi: omap2-mcspi: Fix GPIO chip select support

2015-05-23 Thread Michael Welling
The OMAP2_MCSPI_CHCONF_FORCE must be toggled even when using GPIO chip selects. This patch conditionally calls the omap2_mcspi_set_cs function to do so when using GPIO chip selects. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c |6 ++ 1 file changed

[PATCH 4/4] spi: omap2-mcspi: Handle error on gpio_request

2015-05-23 Thread Michael Welling
If a valid GPIO is specified but cannot be requested by the driver, print a message and error out of omap2_mcspi_setup. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c |9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/spi

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-22 Thread Michael Welling
On Fri, May 22, 2015 at 01:25:44PM +0100, Mark Brown wrote: > On Thu, May 21, 2015 at 06:48:33PM -0500, Michael Welling wrote: > > > So after reverting this patch I found there is a issue in that it is > > difficult > > to determine when a transfer is complete to prope

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-22 Thread Michael Welling
On Fri, May 22, 2015 at 01:25:44PM +0100, Mark Brown wrote: On Thu, May 21, 2015 at 06:48:33PM -0500, Michael Welling wrote: So after reverting this patch I found there is a issue in that it is difficult to determine when a transfer is complete to properly drive the chipselect from

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-21 Thread Michael Welling
On Thu, May 21, 2015 at 10:16:38PM +0100, Mark Brown wrote: > On Thu, May 21, 2015 at 04:04:11PM -0500, Michael Welling wrote: > > > Do you want to revert the patch and apply a new one or should I provide a > > patch that reverts the changes and fixes it all in one? > >

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-21 Thread Michael Welling
On Thu, May 21, 2015 at 11:18:57AM +0100, Mark Brown wrote: > On Wed, May 20, 2015 at 09:07:09PM -0500, Michael Welling wrote: > > > My guess is that the set_cs needs to be called even when toggling as GPIO. > > > How should I handle this? > > It shouldn't be p

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-21 Thread Michael Welling
On Thu, May 21, 2015 at 11:18:57AM +0100, Mark Brown wrote: On Wed, May 20, 2015 at 09:07:09PM -0500, Michael Welling wrote: My guess is that the set_cs needs to be called even when toggling as GPIO. How should I handle this? It shouldn't be part of a set_cs() operation but rather part

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-21 Thread Michael Welling
On Thu, May 21, 2015 at 10:16:38PM +0100, Mark Brown wrote: On Thu, May 21, 2015 at 04:04:11PM -0500, Michael Welling wrote: Do you want to revert the patch and apply a new one or should I provide a patch that reverts the changes and fixes it all in one? Can you please send me separate

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-20 Thread Michael Welling
On Tue, May 12, 2015 at 08:17:58PM +0100, Mark Brown wrote: > On Tue, May 12, 2015 at 12:38:57PM -0500, Michael Welling wrote: > > GPIO chip select patch series appears to have broken the native chip select > > support. This patch pulls the manual native chip sele

Re: [PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-20 Thread Michael Welling
On Tue, May 12, 2015 at 08:17:58PM +0100, Mark Brown wrote: On Tue, May 12, 2015 at 12:38:57PM -0500, Michael Welling wrote: GPIO chip select patch series appears to have broken the native chip select support. This patch pulls the manual native chip select toggling out of the transfer_one

[PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-12 Thread Michael Welling
GPIO chip select patch series appears to have broken the native chip select support. This patch pulls the manual native chip select toggling out of the transfer_one routine and adds a set_cs routine. Tested natively on AM3354 with SPI serial flash on spi0cs0. Signed-off-by: Michael Welling

[PATCH] spi: omap2-mcspi: Fix native cs with new set_cs

2015-05-12 Thread Michael Welling
GPIO chip select patch series appears to have broken the native chip select support. This patch pulls the manual native chip select toggling out of the transfer_one routine and adds a set_cs routine. Tested natively on AM3354 with SPI serial flash on spi0cs0. Signed-off-by: Michael Welling mwell

[PATCH v2] spi: omap2-mcspi: Add gpio_request and init CS

2015-05-08 Thread Michael Welling
If GPIO chip select is specified, request the GPIO in the setup function and release it in the cleanup function. Signed-off-by: Michael Welling --- v2: Adds gpio_free to cleanup function. Broken out of patch series because the other patch in the series was applied. commit

Re: [PATCH v4 2/2] spi: omap2-mcspi: Add gpio_request and init CS

2015-05-08 Thread Michael Welling
On Fri, May 08, 2015 at 06:09:16PM +0100, Mark Brown wrote: > On Thu, May 07, 2015 at 06:36:54PM -0500, Michael Welling wrote: > > > + if (gpio_is_valid(spi->cs_gpio)) { > > + if (gpio_request(spi->cs_gpio, dev_name(>dev)) == 0) > > +

Re: [PATCH v4 2/2] spi: omap2-mcspi: Add gpio_request and init CS

2015-05-08 Thread Michael Welling
On Fri, May 08, 2015 at 06:09:16PM +0100, Mark Brown wrote: On Thu, May 07, 2015 at 06:36:54PM -0500, Michael Welling wrote: + if (gpio_is_valid(spi-cs_gpio)) { + if (gpio_request(spi-cs_gpio, dev_name(spi-dev)) == 0) + gpio_direction_output(spi-cs_gpio

[PATCH v2] spi: omap2-mcspi: Add gpio_request and init CS

2015-05-08 Thread Michael Welling
If GPIO chip select is specified, request the GPIO in the setup function and release it in the cleanup function. Signed-off-by: Michael Welling mwell...@ieee.org --- v2: Adds gpio_free to cleanup function. Broken out of patch series because the other patch in the series was applied. commit

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-05-07 Thread Michael Welling
On Fri, May 01, 2015 at 10:17:35AM +0200, Sebastian Hesselbarth wrote: > On 01.05.2015 00:36, Michael Welling wrote: > >On Fri, May 01, 2015 at 12:21:20AM +0200, Sebastian Hesselbarth wrote: > >>On 30.04.2015 23:20, Michael Welling wrote: > >>>On Thu, Apr 30, 2015

Re: [PATCH v2] iio: mcp320x: Fix occasional incorrect readings

2015-05-07 Thread Michael Welling
On Thu, May 07, 2015 at 11:13:15AM +0100, Jonathan Cameron wrote: > On 06/05/15 17:49, Michael Welling wrote: > > Without the cacheline alignment, the readings will occasionally incorrectly > > return 0. > > > > Signed-off-by: Michael Welling > Applied to the

[PATCH v4 2/2] spi: omap2-mcspi: Add gpio_request and init CS

2015-05-07 Thread Michael Welling
If GPIO chipselects are specified initialise the GPIO in the setup function. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c index 3ac06ad..370c333 100644

[PATCH v4 1/2] spi: omap2-mcspi: Switch driver to use transfer_one

2015-05-07 Thread Michael Welling
Switches from transfer_one_message to transfer_one to prepare driver for use of GPIO chip selects. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c | 244 +++-- 1 file changed, 110 insertions(+), 134 deletions(-) diff --git a/drivers/spi/spi

[PATCH v4 0/2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-07 Thread Michael Welling
selects if specified. v2: Considers the possible use of SPI_CS_HIGH during chip select activation. Michael Welling (2): spi: omap2-mcspi: Switch driver to use transfer_one spi: omap2-mcspi: Add gpio_request and init CS drivers/spi/spi-omap2-mcspi.c | 251

Re: [PATCH v3] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-07 Thread Michael Welling
On Thu, May 07, 2015 at 08:27:58PM +0100, Mark Brown wrote: > On Thu, May 07, 2015 at 02:20:19PM -0500, Michael Welling wrote: > > On Thu, May 07, 2015 at 07:58:31PM +0100, Mark Brown wrote: > > > > makes things easier to review and helps people trying to understand the &

Re: [PATCH v3] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-07 Thread Michael Welling
On Thu, May 07, 2015 at 07:58:31PM +0100, Mark Brown wrote: > On Wed, May 06, 2015 at 06:37:52PM -0500, Michael Welling wrote: > > This patch allows for GPIOs specified in the devicetree to be used as SPI > > chipselects on TI OMAP2 SoCs. > > > > Tested on the

Re: [PATCH v3] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-07 Thread Michael Welling
On Thu, May 07, 2015 at 07:58:31PM +0100, Mark Brown wrote: On Wed, May 06, 2015 at 06:37:52PM -0500, Michael Welling wrote: This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling

Re: [PATCH v3] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-07 Thread Michael Welling
On Thu, May 07, 2015 at 08:27:58PM +0100, Mark Brown wrote: On Thu, May 07, 2015 at 02:20:19PM -0500, Michael Welling wrote: On Thu, May 07, 2015 at 07:58:31PM +0100, Mark Brown wrote: makes things easier to review and helps people trying to understand the Do you have any other

[PATCH v4 0/2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-07 Thread Michael Welling
selects if specified. v2: Considers the possible use of SPI_CS_HIGH during chip select activation. Michael Welling (2): spi: omap2-mcspi: Switch driver to use transfer_one spi: omap2-mcspi: Add gpio_request and init CS drivers/spi/spi-omap2-mcspi.c | 251

[PATCH v4 1/2] spi: omap2-mcspi: Switch driver to use transfer_one

2015-05-07 Thread Michael Welling
Switches from transfer_one_message to transfer_one to prepare driver for use of GPIO chip selects. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c | 244 +++-- 1 file changed, 110 insertions(+), 134 deletions(-) diff --git

[PATCH v4 2/2] spi: omap2-mcspi: Add gpio_request and init CS

2015-05-07 Thread Michael Welling
If GPIO chipselects are specified initialise the GPIO in the setup function. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c index

Re: [PATCH v2] iio: mcp320x: Fix occasional incorrect readings

2015-05-07 Thread Michael Welling
On Thu, May 07, 2015 at 11:13:15AM +0100, Jonathan Cameron wrote: On 06/05/15 17:49, Michael Welling wrote: Without the cacheline alignment, the readings will occasionally incorrectly return 0. Signed-off-by: Michael Welling mwell...@ieee.org Applied to the fixes-togreg branch

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-05-07 Thread Michael Welling
On Fri, May 01, 2015 at 10:17:35AM +0200, Sebastian Hesselbarth wrote: On 01.05.2015 00:36, Michael Welling wrote: On Fri, May 01, 2015 at 12:21:20AM +0200, Sebastian Hesselbarth wrote: On 30.04.2015 23:20, Michael Welling wrote: On Thu, Apr 30, 2015 at 10:44:07PM +0200, Sebastian Hesselbarth

[PATCH v3] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-06 Thread Michael Welling
This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling --- v3: Switches driver to use transfer_one instead of transfer_one_message allowing the spi core to handle toggling GPIO chip selects

[PATCH v2] iio: mcp320x: Fix occasional incorrect readings

2015-05-06 Thread Michael Welling
Without the cacheline alignment, the readings will occasionally incorrectly return 0. Signed-off-by: Michael Welling --- v2: Moved buffers to the end of the mcp320x struct per suggestion to keep them on their own cacheline. drivers/iio/adc/mcp320x.c |6 +++--- 1 file changed, 3 insertions

[PATCH v3] spi: omap2-mcspi: Add support for GPIO chipselects

2015-05-06 Thread Michael Welling
This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling mwell...@ieee.org --- v3: Switches driver to use transfer_one instead of transfer_one_message allowing the spi core to handle toggling GPIO

[PATCH v2] iio: mcp320x: Fix occasional incorrect readings

2015-05-06 Thread Michael Welling
Without the cacheline alignment, the readings will occasionally incorrectly return 0. Signed-off-by: Michael Welling mwell...@ieee.org --- v2: Moved buffers to the end of the mcp320x struct per suggestion to keep them on their own cacheline. drivers/iio/adc/mcp320x.c |6 +++--- 1 file

[PATCH] iio: mcp320x: Fix occasional incorrect readings

2015-05-05 Thread Michael Welling
Without the cacheline alignment, the readings will occasionally incorrectly return 0. Signed-off-by: Michael Welling --- drivers/iio/adc/mcp320x.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/adc/mcp320x.c b/drivers/iio/adc/mcp320x.c index efbfd12..46b98cf

[PATCH] iio: mcp320x: Fix occasional incorrect readings

2015-05-05 Thread Michael Welling
Without the cacheline alignment, the readings will occasionally incorrectly return 0. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/iio/adc/mcp320x.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/adc/mcp320x.c b/drivers/iio/adc/mcp320x.c index

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Fri, May 01, 2015 at 12:21:20AM +0200, Sebastian Hesselbarth wrote: > On 30.04.2015 23:20, Michael Welling wrote: > >On Thu, Apr 30, 2015 at 10:44:07PM +0200, Sebastian Hesselbarth wrote: > [...] > >>What I noticed about your clk2 that you always measure as 0 Hz is > &g

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 10:44:07PM +0200, Sebastian Hesselbarth wrote: > On 30.04.2015 21:33, Michael Welling wrote: > >On Thu, Apr 30, 2015 at 07:45:50PM +0200, Sebastian Hesselbarth wrote: > >>For Si5351 clock driver, Michael Welling and Jean-Francois Moine reported > >

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 07:45:50PM +0200, Sebastian Hesselbarth wrote: > For Si5351 clock driver, Michael Welling and Jean-Francois Moine reported > issues with recent v4.x kernels due to broken/missing/wrong parent clock > claming. This patch set now deals with the issues reported. >

Re: [PATCH 4/4] clk: si5351: Reset PLL after rate change

2015-04-30 Thread Michael Welling
c: Stephen Boyd > Cc: Jean-Francois Moine > Cc: Michael Welling > Cc: Russell King > Cc: devicet...@vger.kernel.org > Cc: linux-...@vger.kernel.org > Cc: linux-arm-ker...@lists.infradead.org > Cc: linux-kernel@vger.kernel.org > --- > drivers/clk/clk-si5351.c | 29 +++

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 07:45:50PM +0200, Sebastian Hesselbarth wrote: > For Si5351 clock driver, Michael Welling and Jean-Francois Moine reported > issues with recent v4.x kernels due to broken/missing/wrong parent clock > claming. This patch set now deals with the issues reported. >

Re: [PATCH 3/4] clk: si5351: Do not pass struct clk in platform_data

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 03:20:38PM -0300, Fabio Estevam wrote: > On Thu, Apr 30, 2015 at 2:45 PM, Sebastian Hesselbarth > wrote: > > > * property silabs,pll-source : , [<..>] > > * allow to selectively set pll source > > @@ -1328,8 +1321,17 @@ static int si5351_i2c_probe(struct

Re: [PATCH 3/4] clk: si5351: Do not pass struct clk in platform_data

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 03:20:38PM -0300, Fabio Estevam wrote: On Thu, Apr 30, 2015 at 2:45 PM, Sebastian Hesselbarth sebastian.hesselba...@gmail.com wrote: * property silabs,pll-source : num src, [..] * allow to selectively set pll source @@ -1328,8 +1321,17 @@ static

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 10:44:07PM +0200, Sebastian Hesselbarth wrote: On 30.04.2015 21:33, Michael Welling wrote: On Thu, Apr 30, 2015 at 07:45:50PM +0200, Sebastian Hesselbarth wrote: For Si5351 clock driver, Michael Welling and Jean-Francois Moine reported issues with recent v4.x kernels

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 07:45:50PM +0200, Sebastian Hesselbarth wrote: For Si5351 clock driver, Michael Welling and Jean-Francois Moine reported issues with recent v4.x kernels due to broken/missing/wrong parent clock claming. This patch set now deals with the issues reported. Patch 1 amends

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Thu, Apr 30, 2015 at 07:45:50PM +0200, Sebastian Hesselbarth wrote: For Si5351 clock driver, Michael Welling and Jean-Francois Moine reported issues with recent v4.x kernels due to broken/missing/wrong parent clock claming. This patch set now deals with the issues reported. Patch 1 amends

Re: [PATCH 4/4] clk: si5351: Reset PLL after rate change

2015-04-30 Thread Michael Welling
mturque...@linaro.org Cc: Stephen Boyd sb...@codeaurora.org Cc: Jean-Francois Moine moin...@free.fr Cc: Michael Welling mwell...@ieee.org Cc: Russell King rmk+li...@arm.linux.org.uk Cc: devicet...@vger.kernel.org Cc: linux-...@vger.kernel.org Cc: linux-arm-ker...@lists.infradead.org Cc: linux

Re: [PATCH 0/4] clk: si5351: Some fixes

2015-04-30 Thread Michael Welling
On Fri, May 01, 2015 at 12:21:20AM +0200, Sebastian Hesselbarth wrote: On 30.04.2015 23:20, Michael Welling wrote: On Thu, Apr 30, 2015 at 10:44:07PM +0200, Sebastian Hesselbarth wrote: [...] What I noticed about your clk2 that you always measure as 0 Hz is that none of your clocks

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-28 Thread Michael Welling
On Tue, Apr 28, 2015 at 03:34:25PM +0100, Mark Brown wrote: > On Mon, Apr 27, 2015 at 08:21:50PM -0500, Michael Welling wrote: > > > Before I send another patch how does this look? > > > if (gpio_is_valid(spi->cs_gpio)) { > > if (cs_active) > >

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-28 Thread Michael Welling
On Tue, Apr 28, 2015 at 11:04:09AM -0300, Ezequiel Garcia wrote: > On 04/27/2015 10:21 PM, Michael Welling wrote: > > On Mon, Apr 27, 2015 at 08:55:50PM +0100, Mark Brown wrote: > >> On Sun, Apr 26, 2015 at 10:44:30PM -0500, Michael Welling wrote: > >> > >&g

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-28 Thread Michael Welling
On Tue, Apr 28, 2015 at 07:32:21AM +0200, Martin Sperl wrote: > > > On 28.04.2015, at 03:21, Michael Welling wrote: > > If I were to attempt to convert the driver to use the core chipselect > > support, > > how would I go about doing it? > > > >

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-28 Thread Michael Welling
On Tue, Apr 28, 2015 at 07:32:21AM +0200, Martin Sperl wrote: On 28.04.2015, at 03:21, Michael Welling mwell...@ieee.org wrote: If I were to attempt to convert the driver to use the core chipselect support, how would I go about doing it? Is there another driver that I can use

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-28 Thread Michael Welling
On Tue, Apr 28, 2015 at 11:04:09AM -0300, Ezequiel Garcia wrote: On 04/27/2015 10:21 PM, Michael Welling wrote: On Mon, Apr 27, 2015 at 08:55:50PM +0100, Mark Brown wrote: On Sun, Apr 26, 2015 at 10:44:30PM -0500, Michael Welling wrote: + if (gpio_is_valid(spi-cs_gpio

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-28 Thread Michael Welling
On Tue, Apr 28, 2015 at 03:34:25PM +0100, Mark Brown wrote: On Mon, Apr 27, 2015 at 08:21:50PM -0500, Michael Welling wrote: Before I send another patch how does this look? if (gpio_is_valid(spi-cs_gpio)) { if (cs_active) gpio_set_value(spi-cs_gpio

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-27 Thread Michael Welling
On Mon, Apr 27, 2015 at 08:55:50PM +0100, Mark Brown wrote: > On Sun, Apr 26, 2015 at 10:44:30PM -0500, Michael Welling wrote: > > > + if (gpio_is_valid(spi->cs_gpio)) { > > + gpio_set_value(spi->cs_gpio, (cs_active) ? > > +

Re: [PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-27 Thread Michael Welling
On Mon, Apr 27, 2015 at 08:55:50PM +0100, Mark Brown wrote: On Sun, Apr 26, 2015 at 10:44:30PM -0500, Michael Welling wrote: + if (gpio_is_valid(spi-cs_gpio)) { + gpio_set_value(spi-cs_gpio, (cs_active) ? + !!(spi-mode SPI_CS_HIGH

[PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-26 Thread Michael Welling
This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling --- v2: Considers the possible use of SPI_CS_HIGH during chip select activation. drivers/spi/spi-omap2-mcspi.c | 13 + 1

[PATCH v2] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-26 Thread Michael Welling
This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling mwell...@ieee.org --- v2: Considers the possible use of SPI_CS_HIGH during chip select activation. drivers/spi/spi-omap2-mcspi.c | 13

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-17 Thread Michael Welling
On Fri, Apr 17, 2015 at 11:18:33AM +0100, Russell King - ARM Linux wrote: > On Fri, Apr 17, 2015 at 11:12:03AM +0200, Sebastian Hesselbarth wrote: > > On 17.04.2015 04:00, Michael Welling wrote: > > >On Fri, Apr 17, 2015 at 01:23:50AM +0200, Sebastian Hesselbarth wrote: > &g

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-17 Thread Michael Welling
On Fri, Apr 17, 2015 at 11:12:03AM +0200, Sebastian Hesselbarth wrote: > On 17.04.2015 04:00, Michael Welling wrote: > >On Fri, Apr 17, 2015 at 01:23:50AM +0200, Sebastian Hesselbarth wrote: > >>On 17.04.2015 00:09, Michael Welling wrote: > >>>On Thu, Apr 16, 2015

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-17 Thread Michael Welling
On Fri, Apr 17, 2015 at 11:12:03AM +0200, Sebastian Hesselbarth wrote: On 17.04.2015 04:00, Michael Welling wrote: On Fri, Apr 17, 2015 at 01:23:50AM +0200, Sebastian Hesselbarth wrote: On 17.04.2015 00:09, Michael Welling wrote: On Thu, Apr 16, 2015 at 10:37:19PM +0200, Sebastian Hesselbarth

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-17 Thread Michael Welling
On Fri, Apr 17, 2015 at 11:18:33AM +0100, Russell King - ARM Linux wrote: On Fri, Apr 17, 2015 at 11:12:03AM +0200, Sebastian Hesselbarth wrote: On 17.04.2015 04:00, Michael Welling wrote: On Fri, Apr 17, 2015 at 01:23:50AM +0200, Sebastian Hesselbarth wrote: On 17.04.2015 00:09, Michael

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-16 Thread Michael Welling
On Fri, Apr 17, 2015 at 01:23:50AM +0200, Sebastian Hesselbarth wrote: > On 17.04.2015 00:09, Michael Welling wrote: > >On Thu, Apr 16, 2015 at 10:37:19PM +0200, Sebastian Hesselbarth wrote: > >>On 16.04.2015 18:17, Michael Welling wrote: > >>>On Thu, Apr 16, 2015 at

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-16 Thread Michael Welling
On Thu, Apr 16, 2015 at 10:37:19PM +0200, Sebastian Hesselbarth wrote: > On 16.04.2015 18:17, Michael Welling wrote: > >On Thu, Apr 16, 2015 at 07:32:32AM +0300, Tero Kristo wrote: > >>On 04/15/2015 11:51 PM, Michael Welling wrote: > >>>On Wed, Apr 15, 2015 at 01

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-16 Thread Michael Welling
On Thu, Apr 16, 2015 at 07:32:32AM +0300, Tero Kristo wrote: > On 04/15/2015 11:51 PM, Michael Welling wrote: > >On Wed, Apr 15, 2015 at 01:45:53PM -0700, Mike Turquette wrote: > >>On Wed, Apr 15, 2015 at 12:47 PM, Michael Welling wrote: > >>>On Wed, Apr 15, 2015 at

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-16 Thread Michael Welling
On Thu, Apr 16, 2015 at 07:32:32AM +0300, Tero Kristo wrote: On 04/15/2015 11:51 PM, Michael Welling wrote: On Wed, Apr 15, 2015 at 01:45:53PM -0700, Mike Turquette wrote: On Wed, Apr 15, 2015 at 12:47 PM, Michael Welling mwell...@ieee.org wrote: On Wed, Apr 15, 2015 at 09:43:30PM +0300, Tero

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-16 Thread Michael Welling
On Fri, Apr 17, 2015 at 01:23:50AM +0200, Sebastian Hesselbarth wrote: On 17.04.2015 00:09, Michael Welling wrote: On Thu, Apr 16, 2015 at 10:37:19PM +0200, Sebastian Hesselbarth wrote: On 16.04.2015 18:17, Michael Welling wrote: On Thu, Apr 16, 2015 at 07:32:32AM +0300, Tero Kristo wrote

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-16 Thread Michael Welling
On Thu, Apr 16, 2015 at 10:37:19PM +0200, Sebastian Hesselbarth wrote: On 16.04.2015 18:17, Michael Welling wrote: On Thu, Apr 16, 2015 at 07:32:32AM +0300, Tero Kristo wrote: On 04/15/2015 11:51 PM, Michael Welling wrote: On Wed, Apr 15, 2015 at 01:45:53PM -0700, Mike Turquette wrote: On Wed

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-15 Thread Michael Welling
On Wed, Apr 15, 2015 at 01:45:53PM -0700, Mike Turquette wrote: > On Wed, Apr 15, 2015 at 12:47 PM, Michael Welling wrote: > > On Wed, Apr 15, 2015 at 09:43:30PM +0300, Tero Kristo wrote: > >> On 04/15/2015 05:09 PM, Michael Welling wrote: > >> >On Wed, Apr 15,

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-15 Thread Michael Welling
On Wed, Apr 15, 2015 at 09:43:30PM +0300, Tero Kristo wrote: > On 04/15/2015 05:09 PM, Michael Welling wrote: > >On Wed, Apr 15, 2015 at 09:34:48AM +0300, Tero Kristo wrote: > >>On 04/15/2015 12:17 AM, Michael Welling wrote: > >>>Greetings, > >>>

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-15 Thread Michael Welling
On Wed, Apr 15, 2015 at 09:34:48AM +0300, Tero Kristo wrote: > On 04/15/2015 12:17 AM, Michael Welling wrote: > >Greetings, > > > >I have developed an AM3354 based SoM and it uses an external SI5351 clock > >generator to drive the clock inputs for an external duart an

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-15 Thread Michael Welling
On Wed, Apr 15, 2015 at 09:34:48AM +0300, Tero Kristo wrote: On 04/15/2015 12:17 AM, Michael Welling wrote: Greetings, I have developed an AM3354 based SoM and it uses an external SI5351 clock generator to drive the clock inputs for an external duart and I2S audio master clock

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-15 Thread Michael Welling
On Wed, Apr 15, 2015 at 01:45:53PM -0700, Mike Turquette wrote: On Wed, Apr 15, 2015 at 12:47 PM, Michael Welling mwell...@ieee.org wrote: On Wed, Apr 15, 2015 at 09:43:30PM +0300, Tero Kristo wrote: On 04/15/2015 05:09 PM, Michael Welling wrote: On Wed, Apr 15, 2015 at 09:34:48AM +0300

Re: AM335x OMAP2 common clock external fixed-clock registration

2015-04-15 Thread Michael Welling
On Wed, Apr 15, 2015 at 09:43:30PM +0300, Tero Kristo wrote: On 04/15/2015 05:09 PM, Michael Welling wrote: On Wed, Apr 15, 2015 at 09:34:48AM +0300, Tero Kristo wrote: On 04/15/2015 12:17 AM, Michael Welling wrote: Greetings, I have developed an AM3354 based SoM and it uses an external

AM335x OMAP2 common clock external fixed-clock registration

2015-04-14 Thread Michael Welling
Greetings, I have developed an AM3354 based SoM and it uses an external SI5351 clock generator to drive the clock inputs for an external duart and I2S audio master clock. With the registration according to the documentation the reference clock is not being detected and hence the clock generator

AM335x OMAP2 common clock external fixed-clock registration

2015-04-14 Thread Michael Welling
Greetings, I have developed an AM3354 based SoM and it uses an external SI5351 clock generator to drive the clock inputs for an external duart and I2S audio master clock. With the registration according to the documentation the reference clock is not being detected and hence the clock generator

Re: [PATCH] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-13 Thread Michael Welling
is initialized to -ENOENT in spi_alloc_device: http://lxr.free-electrons.com/source/drivers/spi/spi.c#L353 If there are GPIOs specified in the devicetree the value is updated: http://lxr.free-electrons.com/source/drivers/spi/spi.c#L440 On Wed, Apr 08, 2015 at 04:36:01PM -0500, Michael Welling wrote

Re: [PATCH] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-13 Thread Michael Welling
is initialized to -ENOENT in spi_alloc_device: http://lxr.free-electrons.com/source/drivers/spi/spi.c#L353 If there are GPIOs specified in the devicetree the value is updated: http://lxr.free-electrons.com/source/drivers/spi/spi.c#L440 On Wed, Apr 08, 2015 at 04:36:01PM -0500, Michael Welling wrote

[PATCH] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-08 Thread Michael Welling
This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling --- drivers/spi/spi-omap2-mcspi.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/drivers/spi/spi-omap2-mcspi.c b

[PATCH] spi: omap2-mcspi: Add support for GPIO chipselects

2015-04-08 Thread Michael Welling
This patch allows for GPIOs specified in the devicetree to be used as SPI chipselects on TI OMAP2 SoCs. Tested on the AM3354. Signed-off-by: Michael Welling mwell...@ieee.org --- drivers/spi/spi-omap2-mcspi.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/drivers/spi/spi

Re: [Patch v6 0/2] gpio: add GPIO hogging mechanism

2015-02-19 Thread Michael Welling
On Wed, Feb 18, 2015 at 11:23:42AM -0600, Benoit Parrot wrote: > Gentle ping. > > Is there any chance this will make it in 3.21? > > Benoit > Is there a reason that the pin has to be "hogged"? Couldn't the pin be released after configuration for eventual use in the userspace? > Parrot,

Re: [Patch v6 0/2] gpio: add GPIO hogging mechanism

2015-02-19 Thread Michael Welling
On Wed, Feb 18, 2015 at 11:23:42AM -0600, Benoit Parrot wrote: Gentle ping. Is there any chance this will make it in 3.21? Benoit Is there a reason that the pin has to be hogged? Couldn't the pin be released after configuration for eventual use in the userspace? Parrot, Benoit

Re: Linux GPIO internals

2015-01-05 Thread Michael Welling
On Sat, Jan 03, 2015 at 02:12:06PM +0100, Alexandre Courbot wrote: > Hi Michael, sorry for the delayed reply on this interesting issue. > > On Wed, Dec 24, 2014 at 10:53 PM, Michael Welling > wrote: > > All, > > > > For years now EMAC has provided an out-o

Re: Linux GPIO internals

2015-01-05 Thread Michael Welling
On Sat, Jan 03, 2015 at 02:12:06PM +0100, Alexandre Courbot wrote: Hi Michael, sorry for the delayed reply on this interesting issue. On Wed, Dec 24, 2014 at 10:53 PM, Michael Welling mwell...@emacinc.com wrote: All, For years now EMAC has provided an out-of-tree series of class

Linux GPIO internals

2014-12-24 Thread Michael Welling
All, For years now EMAC has provided an out-of-tree series of class drivers for accessing various devices. The EMAC GPIO class and character interfaces predate the introduction of the gpiolib interface and have been ported across several kernel versions.

Linux GPIO internals

2014-12-24 Thread Michael Welling
All, For years now EMAC has provided an out-of-tree series of class drivers for accessing various devices. The EMAC GPIO class and character interfaces predate the introduction of the gpiolib interface and have been ported across several kernel versions.

Re: GPIO registration for external Ethernet PHY oscillator enable/disable

2014-10-07 Thread Michael Welling
On Tue, Oct 07, 2014 at 04:09:45PM +0200, Linus Walleij wrote: > On Fri, Sep 26, 2014 at 10:04 PM, Michael Welling > wrote: > > On Fri, Sep 26, 2014 at 10:16:51AM -0700, Florian Fainelli wrote: > >> > >> Yes and no, this might feel like the wrong place, but ult

Re: GPIO registration for external Ethernet PHY oscillator enable/disable

2014-10-07 Thread Michael Welling
On Tue, Oct 07, 2014 at 04:04:27PM +0200, Linus Walleij wrote: > On Thu, Sep 25, 2014 at 9:17 PM, Michael Welling wrote: > > > How do I register a GPIO for use in the PHY suspend and resume code? > > Can it be handled outside of the PHY driver? > > Nominally these day

Re: GPIO registration for external Ethernet PHY oscillator enable/disable

2014-10-07 Thread Michael Welling
On Tue, Oct 07, 2014 at 04:04:27PM +0200, Linus Walleij wrote: On Thu, Sep 25, 2014 at 9:17 PM, Michael Welling mwell...@emacinc.com wrote: How do I register a GPIO for use in the PHY suspend and resume code? Can it be handled outside of the PHY driver? Nominally these days you should

Re: GPIO registration for external Ethernet PHY oscillator enable/disable

2014-10-07 Thread Michael Welling
On Tue, Oct 07, 2014 at 04:09:45PM +0200, Linus Walleij wrote: On Fri, Sep 26, 2014 at 10:04 PM, Michael Welling mwell...@emacinc.com wrote: On Fri, Sep 26, 2014 at 10:16:51AM -0700, Florian Fainelli wrote: Yes and no, this might feel like the wrong place, but ultimately, the Ethernet

Re: [RESEND PATCH] iio: light: add support for TI's opt3001 light sensor

2014-10-03 Thread Michael Welling
On Thu, Oct 02, 2014 at 01:05:53PM -0500, Felipe Balbi wrote: > Hi, > > On Tue, Sep 30, 2014 at 04:22:04PM -0500, Felipe Balbi wrote: > > On Mon, Sep 29, 2014 at 06:41:59PM -0500, Michael Welling wrote: > > > On Mon, Sep 29, 2014 at 05:46:38PM -0500, Felipe

Re: [PATCH] drivers:ethernet:davinci_emac.c:Fixes flaw in mac address handling.

2014-10-03 Thread Michael Welling
On Fri, Oct 03, 2014 at 01:03:05PM -0700, David Miller wrote: > From: Michael Welling > Date: Wed, 1 Oct 2014 21:32:05 -0500 > > > The code currently checks the mac_addr variable that is clearly > > zero'd out during allocation. > > > > Further code is

<    1   2   3   4   >