[linux-sunxi] [PATCH 1/5] spi: sunxi: fix transfer timeout
maxime.ripard at free-electrons.com
Wed Jun 1 11:20:00 PDT 2016
On Mon, May 30, 2016 at 12:23:50PM +0100, Mark Brown wrote:
> On Fri, May 27, 2016 at 03:10:11PM +1000, Julian Calaby wrote:
> > On Fri, May 27, 2016 at 3:05 PM, Michal Suchanek <hramrach at gmail.com> wrote:
> > >> Also, should the changes for the drivers be in two separate patches also?
> > > That's basically the same driver with different constants so I guess not.
> > Fair enough, I withdraw my comment then.
> If it's the same driver with different constants it should really
> actually be the same driver - I did ask this when the drivers were
> originally merged...
I think we already had this discussion a few times :)
The thing is that the SPI framework now deals pretty well with the SPI
controllers, and you basically only have the probe function and how to
start a transfer. Which is nice.
However, the sun4i and sun6i SPI controllers have very significant
register layout differences: the registers offset are different, some
registers in the sun4i have been split in several in the sun6i. So
while I concur that they look alike, merging the two in a single
driver would complicate a lot the code, while we would not be able to
share most of the code, so I am really not sure it's worth it.
Where the issue really lies is that they've been both written at the
same time, and share the same flaws, especially in their probe
method. But that's not really related to the controller itself, but
more because the code has been close to copy/pasted.
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 819 bytes
Desc: not available
More information about the linux-arm-kernel