]>
git.ipfire.org Git - people/ms/u-boot.git/blob - board/pxa255_idp/pxa_idp.c
3 * Kyle Harris, Nexus Technologies, Inc. kharris@nexus-tech.net
6 * Sysgo Real-Time Solutions, GmbH <www.elinos.com>
7 * Marius Groeger <mgroeger@sysgo.de>
10 * BEC Systems <http://bec-systems.com>
11 * Cliff Brake <cliff.brake@gmail.com>
12 * Support for Accelent/Vibren PXA255 IDP
14 * SPDX-License-Identifier: GPL-2.0+
21 #include <asm/arch/pxa.h>
22 #include <asm/arch/regs-mmc.h>
24 DECLARE_GLOBAL_DATA_PTR
;
27 * Miscelaneous platform dependent initialisations
32 /* We have RAM, disable cache */
36 /* arch number of Lubbock-Board */
37 gd
->bd
->bi_arch_number
= MACH_TYPE_PXA_IDP
;
39 /* adress of boot parameters */
40 gd
->bd
->bi_boot_params
= 0xa0000100;
42 /* turn on serial ports */
43 *(volatile unsigned int *)(PXA_CS5_PHYS
+ 0x03C0002c) = 0x13;
46 /* a value that works is 60Hz, 77% duty cycle */
47 writel(readl(CKEN
) | CKEN0_PWM0
, CKEN
);
48 writel(0x3f, PWM_CTRL0
);
49 writel(0x3ff, PWM_PERVAL0
);
50 writel(792, PWM_PWDUTY0
);
52 /* clear reset to AC97 codec */
53 writel(readl(CKEN
) | CKEN2_AC97
, CKEN
);
54 writel(GCR_COLD_RST
, GCR
);
56 /* enable LCD backlight */
57 /* *(volatile unsigned int *)(PXA_CS5_PHYS + 0x03C00030) = 0x7; */
60 /* lcd_puts("This is a test\nTest #2\n"); */
66 int board_mmc_init(bd_t
*bis
)
73 int board_late_init(void)
75 setenv("stdout", "serial");
76 setenv("stderr", "serial");
83 gd
->ram_size
= PHYS_SDRAM_1_SIZE
;
87 void dram_init_banksize(void)
89 gd
->bd
->bi_dram
[0].start
= PHYS_SDRAM_1
;
90 gd
->bd
->bi_dram
[0].size
= PHYS_SDRAM_1_SIZE
;
93 #ifdef DEBUG_BLINKC_ENABLE
99 while (readl(OSCR
) > 0x10000)
102 while (readl(OSCR
) < 0xd4000)
108 int led_bit
= (1<<10);
110 writel(led_bit
, GPDR0
);
111 writel(led_bit
, GPCR0
);
113 writel(led_bit
, GPSR0
);
115 writel(led_bit
, GPCR0
);
118 int do_idpcmd(cmd_tbl_t
*cmdtp
, int flag
, int argc
, char * const argv
[])
120 printf("IDPCMD started\n");
124 U_BOOT_CMD(idpcmd
, CONFIG_SYS_MAXARGS
, 0, do_idpcmd
,
125 "custom IDP command",
126 "no args at this time"
131 #ifdef CONFIG_CMD_NET
132 int board_eth_init(bd_t
*bis
)
135 #ifdef CONFIG_SMC91111
136 rc
= smc91111_initialize(0, CONFIG_SMC91111_BASE
);