blob: 662fce33557df609b7d5a8246290727e58967365 [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Ash Charles9cb110e2014-05-07 08:24:11 -07002/*
3 * Copyright (C) 2013 Gumstix, Inc. - http://www.gumstix.com/
Ash Charles9cb110e2014-05-07 08:24:11 -07004 */
5
6#ifndef __CONFIG_PEPPER_H
7#define __CONFIG_PEPPER_H
8
Ash Charles9cb110e2014-05-07 08:24:11 -07009#include <configs/ti_am335x_common.h>
10
Ash Charles9cb110e2014-05-07 08:24:11 -070011/* Clock defines */
12#define V_OSCK 24000000 /* Clock output from T2 */
13#define V_SCLK (V_OSCK)
14
Adam YH Lee3dc3c982015-06-01 14:29:09 -070015#define CONFIG_SYS_I2C_EEPROM_ADDR 0x50
16
Ash Charles9cb110e2014-05-07 08:24:11 -070017/* Mach type */
Ash Charles9cb110e2014-05-07 08:24:11 -070018#define CONFIG_MACH_TYPE MACH_TYPE_PEPPER
19
Ash Charles9cb110e2014-05-07 08:24:11 -070020#define CONFIG_EXTRA_ENV_SETTINGS \
21 DEFAULT_LINUX_BOOT_ENV \
22 "bootdir=/boot\0" \
23 "bootfile=zImage\0" \
24 "fdtfile=am335x-pepper.dtb\0" \
25 "console=ttyO0,115200n8\0" \
26 "optargs=\0" \
27 "mmcdev=0\0" \
28 "mmcroot=/dev/mmcblk0p2 rw\0" \
Adam YH Leebc08c762015-07-20 11:50:40 -070029 "mmcrootfstype=ext4 rootwait\0" \
Ash Charles9cb110e2014-05-07 08:24:11 -070030 "mmcargs=setenv bootargs console=${console} " \
31 "${optargs} " \
32 "root=${mmcroot} " \
33 "rootfstype=${mmcrootfstype}\0" \
34 "bootenv=uEnv.txt\0" \
35 "loadbootenv=load mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \
36 "importbootenv=echo Importing environment from mmc ...; " \
37 "env import -t ${loadaddr} ${filesize}\0" \
38 "mmcload=load mmc ${mmcdev}:2 ${loadaddr} ${bootdir}/${bootfile}; " \
39 "load mmc ${mmcdev}:2 ${fdtaddr} ${bootdir}/${fdtfile}\0" \
40 "loaduimage=fatload mmc ${mmcdev}:1 ${loadaddr} uImage\0" \
41 "uimageboot=echo Booting from mmc${mmcdev} ...; " \
42 "run mmcargs; " \
43 "bootm ${loadaddr}\0" \
44 "mmcboot=echo Booting from mmc ...; " \
45 "run mmcargs; " \
46 "bootz ${loadaddr} - ${fdtaddr}\0" \
47 "ubiboot=echo Booting from nand (ubifs) ...; " \
48 "run ubiargs; run ubiload; " \
49 "bootz ${loadaddr} - ${fdtaddr}\0" \
50
51#define CONFIG_BOOTCOMMAND \
52 "mmc dev ${mmcdev}; if mmc rescan; then " \
53 "echo SD/MMC found on device ${mmcdev};" \
54 "if run loadbootenv; then " \
55 "echo Loaded environment from ${bootenv};" \
56 "run importbootenv;" \
57 "fi;" \
58 "if test -n $uenvcmd; then " \
59 "echo Running uenvcmd ...;" \
60 "run uenvcmd;" \
61 "fi;" \
62 "if run mmcload; then " \
63 "run mmcboot;" \
64 "fi;" \
65 "if run loaduimage; then " \
66 "run uimageboot;" \
67 "fi;" \
68 "fi;" \
69
70/* Serial console configuration */
Ash Charles9cb110e2014-05-07 08:24:11 -070071#define CONFIG_SYS_NS16550_COM1 0x44e09000
72
73/* Ethernet support */
Ash Charles9cb110e2014-05-07 08:24:11 -070074#define CONFIG_PHY_RESET_DELAY 1000
75
76/* SPL */
Ash Charles9cb110e2014-05-07 08:24:11 -070077
78#endif /* __CONFIG_PEPPER_H */