Re: [PATCH] spi/rockchip: Make sure spi clk is on in rockchip_spi_set_cs

From: Mark Brown
Date: Thu Feb 25 2016 - 20:58:37 EST


On Wed, Feb 24, 2016 at 07:09:57PM +0800, Huang, Tao wrote:

Please don't top post, reply in line with needed context. This allows
readers to readily follow the flow of conversation and understand what
you are talking about and also helps ensure that everything in the
discussion is being addressed.

> Another way to solve this bug is add runtime PM support while spi setup.
> Some other chips may have some problem, for example mt65xx and orion,
> which access hardware register too.

No, this is telling you you're doing something wrong - setup() might be
called while another transfer is in progress so you shouldn't be
changing the hardware setup (see Documentation/spi/spi-summary). This
means that you normally shouldn't be writing to registers there. Moving
this to prepare_message() instead is probably what you want.

Attachment: signature.asc
Description: PGP signature