Thread (18 messages) 18 messages, 7 authors, 2007-02-17

RE: [PATCH] Adapt spi_mpc83xx SPI driver for 832x

From: Joakim Tjernlund <hidden>
Date: 2006-12-13 15:36:05

-----Original Message-----
From: Kumar Gala [mailto:galak@kernel.crashing.org] 
Sent: den 13 december 2006 15:46
To: joakim.tjernlund@transmode.se
Cc: linuxppc-dev Development; spi-devel-general@lists.sourceforge.net
Subject: Re: [PATCH] Adapt spi_mpc83xx SPI driver for 832x


On Dec 13, 2006, at 3:22 AM, Joakim Tjernlund wrote:
quoted
The MPC 832x has a different SPI controller i/f, probably due to
its QUICC engine support. This patch adapts the spi_mpx83xx 
driver to
quoted
be usable on QE based 83xx cpus.

 Jocke
One problem I have with this patch is the fact that it assumes the  
current driver for (mpc834x) and your mods to support mpc832x/QE are  
mutually exclusive.
I don't see that as a problem ATM. If that is added it should be optional.
We need to handle the case of having driver support for both the QE  
and MPC834x style in the same kernel.
Adding that will double the number RX_BUF/TX_BUF functions from 6 to 12
(possibly this can be reduced by adding more logic to the tx_buf/rx_buf functions)
not to mention what will happen when support for reversed bit order is added.

I would argue that the kernel lacks the possibility to remove complexity
I don't need. Example in this driver is that there is no way to remove
support for 16 and 32 bit SPI character sizes. The same goes for a lot of
the probing code in fsl-soc.c.

It would be nice if a board port could add a custom header file that
gets included by all .c automatically. Then one could add knobs
(read #defines) there to futher tune such things as SPI char size.
That way one don't have add Kconfig entries for all those small
tuning knobs.

 Jocke
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help