Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (C) 2013 Suriyan Ramasami <suriyan.r@gmail.com> |
| 4 | * |
| 5 | * Based on dockstar.h originally written by |
| 6 | * Copyright (C) 2010 Eric C. Cooper <ecc@cmu.edu> |
| 7 | * |
| 8 | * Based on sheevaplug.h originally written by |
| 9 | * Prafulla Wadaskar <prafulla@marvell.com> |
| 10 | * (C) Copyright 2009 |
| 11 | * Marvell Semiconductor <www.marvell.com> |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 12 | */ |
| 13 | |
| 14 | #ifndef _CONFIG_GOFLEXHOME_H |
| 15 | #define _CONFIG_GOFLEXHOME_H |
| 16 | |
| 17 | /* |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 18 | * High Level Configuration Options (easy to change) |
| 19 | */ |
| 20 | #define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 21 | #define CONFIG_KW88F6281 1 /* SOC Name */ |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 22 | #define CONFIG_SKIP_LOWLEVEL_INIT /* disable board lowlevel_init */ |
| 23 | |
| 24 | /* |
| 25 | * Default GPIO configuration and LED status |
| 26 | */ |
| 27 | #define GOFLEXHOME_OE_LOW (~(0)) |
| 28 | #define GOFLEXHOME_OE_HIGH (~(0)) |
| 29 | #define GOFLEXHOME_OE_VAL_LOW (1 << 29) /* USB_PWEN low */ |
| 30 | #define GOFLEXHOME_OE_VAL_HIGH (1 << 17) /* LED pin high */ |
| 31 | |
| 32 | /* PHY related */ |
| 33 | #define MV88E1116_LED_FCTRL_REG 10 |
| 34 | #define MV88E1116_CPRSP_CR3_REG 21 |
| 35 | #define MV88E1116_MAC_CTRL_REG 21 |
| 36 | #define MV88E1116_PGADR_REG 22 |
| 37 | #define MV88E1116_RGMII_TXTM_CTRL (1 << 4) |
| 38 | #define MV88E1116_RGMII_RXTM_CTRL (1 << 5) |
| 39 | |
| 40 | /* |
| 41 | * Commands configuration |
| 42 | */ |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 43 | |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 44 | #define CONFIG_SYS_MVFS /* Picks up Filesystem from mv-common.h */ |
| 45 | |
| 46 | /* |
| 47 | * mv-common.h should be defined after CMD configs since it used them |
| 48 | * to enable certain macros |
| 49 | */ |
| 50 | #include "mv-common.h" |
| 51 | |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 52 | /* |
| 53 | * Environment variables configurations |
| 54 | */ |
| 55 | #ifdef CONFIG_CMD_NAND |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 56 | #define CONFIG_ENV_SECT_SIZE 0x20000 /* 128K */ |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 57 | #endif |
| 58 | /* |
| 59 | * max 4k env size is enough, but in case of nand |
| 60 | * it has to be rounded to sector size |
| 61 | */ |
| 62 | #define CONFIG_ENV_SIZE 0x20000 /* 128k */ |
| 63 | #define CONFIG_ENV_ADDR 0xC0000 |
| 64 | #define CONFIG_ENV_OFFSET 0xC0000 /* env starts here */ |
| 65 | |
| 66 | /* |
| 67 | * Default environment variables |
| 68 | */ |
| 69 | #define CONFIG_BOOTCOMMAND \ |
| 70 | "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ |
| 71 | "ubi part root; " \ |
| 72 | "ubifsmount ubi:root; " \ |
| 73 | "ubifsload 0x800000 ${kernel}; " \ |
| 74 | "bootm 0x800000" |
| 75 | |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 76 | #define CONFIG_EXTRA_ENV_SETTINGS \ |
| 77 | "console=console=ttyS0,115200\0" \ |
| 78 | "mtdids=nand0=orion_nand\0" \ |
Tom Rini | 5ad8e11 | 2017-10-22 17:55:07 -0400 | [diff] [blame] | 79 | "mtdparts="CONFIG_MTDPARTS_DEFAULT \ |
Suriyan Ramasami | f0ec8af | 2013-04-11 07:17:25 +0000 | [diff] [blame] | 80 | "kernel=/boot/uImage\0" \ |
| 81 | "bootargs_root=ubi.mtd=root root=ubi0:root rootfstype=ubifs ro\0" |
| 82 | |
| 83 | /* |
| 84 | * Ethernet Driver configuration |
| 85 | */ |
| 86 | #ifdef CONFIG_CMD_NET |
| 87 | #define CONFIG_MVGBE_PORTS {1, 0} /* enable port 0 only */ |
| 88 | #define CONFIG_PHY_BASE_ADR 0 |
| 89 | #endif /* CONFIG_CMD_NET */ |
| 90 | |
| 91 | /* |
| 92 | * * SATA Driver configuration |
| 93 | * */ |
| 94 | #ifdef CONFIG_MVSATA_IDE |
| 95 | #define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET |
| 96 | #endif /*CONFIG_MVSATA_IDE*/ |
| 97 | |
| 98 | /* |
| 99 | * * RTC driver configuration |
| 100 | * */ |
| 101 | #ifdef CONFIG_CMD_DATE |
| 102 | #define CONFIG_RTC_MV |
| 103 | #endif /* CONFIG_CMD_DATE */ |
| 104 | |
| 105 | #endif /* _CONFIG_GOFLEXHOME_H */ |