Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-31 Thread Jean-Christophe PLAGNIOL-VILLARD
On Aug 1, 2014, at 12:48 AM, Alexandre Belloni wrote: > > On 01/08/2014 at 00:10:05 +0800, Jean-Christophe PLAGNIOL-VILLARD wrote : > While this solves the particular issue Jiří is seeing, this will not > solve the case where PA14 (CS0) is not used by the spi driver at all. It > wi

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-31 Thread Alexandre Belloni
On 01/08/2014 at 00:10:05 +0800, Jean-Christophe PLAGNIOL-VILLARD wrote : > >>> While this solves the particular issue Jiří is seeing, this will not > >>> solve the case where PA14 (CS0) is not used by the spi driver at all. It > >>> will remained muxed as CS0 and toggle when the spi master needs t

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-31 Thread Jean-Christophe PLAGNIOL-VILLARD
On Jul 31, 2014, at 11:59 PM, Alexandre Belloni wrote: > On 29/07/2014 at 10:00:17 +0200, Boris Brezillon wrote : >> Hi Alexandre, >> >>> While this solves the particular issue Jiří is seeing, this will not >>> solve the case where PA14 (CS0) is not used by the spi driver at all. It >>> will r

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-31 Thread Alexandre Belloni
On 29/07/2014 at 10:00:17 +0200, Boris Brezillon wrote : > Hi Alexandre, > > > While this solves the particular issue Jiří is seeing, this will not > > solve the case where PA14 (CS0) is not used by the spi driver at all. It > > will remained muxed as CS0 and toggle when the spi master needs to >

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-29 Thread Mark Brown
On Tue, Jul 29, 2014 at 12:38:59AM +0200, Alexandre Belloni wrote: > Mark: maybe it would make sense to do devm_gpio_request_one() in > of_spi_register_master(), after of_get_named_gpio. You need to transition all the drivers doing things manually but yes. As I keep saying all the GPIO handling n

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-29 Thread Boris BREZILLON
Hi Alexandre, On Tue, 29 Jul 2014 00:38:59 +0200 Alexandre Belloni wrote: > > > >>+ if (ret < 0) { > > >>+ dev_err(&pdev->dev, > > >>+ "failed to configure csgpio#%u (%d)\n", > > >>+ i, ret); > > >>+ goto ou

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-28 Thread Alexandre Belloni
(Adding Mark in Cc:) On 28/07/2014 at 15:06:34 +0200, Jiří Prchal wrote : > >>+#define DRIVER_NAME "atmel-spi" > >>+ > > > >This is not really related to the issue solved by that patch, maybe it > >could go in another patch ? > Probably yes, but is used for this patch, I based it upon spi-efm32. >

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-28 Thread Boris BREZILLON
Hello Jiri, The least you can do when someone helps you debugging something is to keep him in Cc of the following versions of your patch... On Mon, 28 Jul 2014 13:43:40 +0200 Jiri Prchal wrote: > This fix problem with PA14 set as periph A left from ROMBOOT and need it > to be set to gpio before

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-28 Thread Jiří Prchal
Hi, Dne 28.7.2014 v 14:21 Alexandre Belloni napsal(a): Hi, Thank you for that patch, a few questions/comments below. On 28/07/2014 at 13:43:40 +0200, Jiri Prchal wrote : This fix problem with PA14 set as periph A left from ROMBOOT and need it to be set to gpio before spi bus communicate with

Re: [PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-28 Thread Alexandre Belloni
Hi, Thank you for that patch, a few questions/comments below. On 28/07/2014 at 13:43:40 +0200, Jiri Prchal wrote : > This fix problem with PA14 set as periph A left from ROMBOOT and need it > to be set to gpio before spi bus communicate with chip on CS0 on other > gpio. As I reported a week ago.

[PATCH] ARM: at91: spi: request all csgpio in spi probe

2014-07-28 Thread Jiri Prchal
This fix problem with PA14 set as periph A left from ROMBOOT and need it to be set to gpio before spi bus communicate with chip on CS0 on other gpio. As I reported a week ago. Request all csgpios in spi_probe since cs depends on each other and must be all of them in right state before any communica