Intracom platform patch
PATCH 1/1 Intracom platform patch
Hi all
The following patch adds platform support for the netta2 board.
It's main attraction however is as an example on how to do the fec_8xx platform driver initialization.
Regards
Pantelis
P.S. This and the previous patches are
Signed-off-by Pantelis Antoniou <[email protected]>
arch/ppc/platforms/Makefile +1 -0
@@ -46,6 +46,7 @@ obj-$(CONFIG_SBC82xx) += sbc82xx.o obj-$(CONFIG_SPRUCE) += spruce.o obj-$(CONFIG_LITE5200) += lite5200.o +obj-$(CONFIG_NETTA2) += netta2_setup.o ifeq ($(CONFIG_SMP),y) obj-$(CONFIG_PPC_PMAC) += pmac_smp.o
arch/ppc/platforms/intracom_common.h +92 -0
92 lines not on this page · raw message
arch/ppc/platforms/intracom_common_82xx.h +4 -0
@@ -0,0 +1,4 @@ +#ifndef INTRACOM_COMMON_82XX_H +#define INTRACOM_COMMON_82XX_H + +#endif
arch/ppc/platforms/intracom_common_8xx.h +224 -0
224 lines not on this page · raw message
arch/ppc/platforms/intracom_swspi.h +35 -0
@@ -0,0 +1,35 @@ +#ifndef INTRACOM_SWSPI_H +#define INTRACOM_SWSPI_H + +#ifndef __ASSEMBLY__ + +#include "intracom_common.h" + +#ifdef CONFIG_NETTA +#include "netta.h" +#endif + +static inline unsigned int spi_transfer (unsigned int tx) +{ +unsigned int rx; +int b; + + rx =0 ; b =8 ; +while (--b >=0 ) { +PIN_SET (SPI_TXD , tx &0x80 ); + tx <<=1 ; +PIN_TGL (SPI_CLK ); +SPI_DELAY (); + rx <<=1 ; + rx |=PIN_GET (SPI_RXD ); +PIN_TGL (SPI_CLK ); +SPI_DELAY (); + } + +return rx; +} + +#endif + +#endif +
arch/ppc/platforms/netta2.h +279 -0
279 lines not on this page · raw message
arch/ppc/platforms/netta2_setup.c +359 -0
359 lines not on this page · raw message