1 /***************************************************************************/
4 * linux/arch/m68knommu/platform/523x/config.c
6 * Sub-architcture dependent initialization code for the Freescale
9 * Copyright (C) 1999-2005, Greg Ungerer (gerg@snapgear.com)
10 * Copyright (C) 2001-2003, SnapGear Inc. (www.snapgear.com)
13 /***************************************************************************/
15 #include <linux/kernel.h>
16 #include <linux/param.h>
17 #include <linux/init.h>
19 #include <asm/machdep.h>
20 #include <asm/coldfire.h>
21 #include <asm/mcfsim.h>
23 /***************************************************************************/
25 #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI)
27 static void __init
m523x_qspi_init(void)
31 /* setup QSPS pins for QSPI with gpio CS control */
32 writeb(0x1f, MCFGPIO_PAR_QSPI
);
33 /* and CS2 & CS3 as gpio */
34 par
= readw(MCFGPIO_PAR_TIMER
);
36 writew(par
, MCFGPIO_PAR_TIMER
);
39 #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */
41 /***************************************************************************/
43 static void __init
m523x_fec_init(void)
48 /* Set multi-function pins to ethernet use */
49 par
= readw(MCF_IPSBAR
+ 0x100082);
50 writew(par
| 0xf00, MCF_IPSBAR
+ 0x100082);
51 v
= readb(MCF_IPSBAR
+ 0x100078);
52 writeb(v
| 0xc0, MCF_IPSBAR
+ 0x100078);
55 /***************************************************************************/
57 void __init
config_BSP(char *commandp
, int size
)
59 mach_sched_init
= hw_timer_init
;
61 #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI)
66 /***************************************************************************/