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

From: Mark Brown
Date: Tue Jul 29 2014 - 07:33:11 EST


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 needs to be completely
refactored.

> 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
> access CS0 until another driver muxes it to something else. I still
> believe we should explicitly ask pinctrl to mux them as gpios.

I'm just guessing as to what the issue that he's seeing is but isn't
this just saying that the board pinmuxing is wrong? If the board
doesn't want the pin to be used by the SPI controller it shouldn't be
configuring it that way.

Attachment: signature.asc
Description: Digital signature