]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - include/configs/lsxl.h
sniper: Pass serial number through ATAG
[karo-tx-uboot.git] / include / configs / lsxl.h
index 8097f28ccc54bd136404d14f58a8f4af0c4397c2..ddbf5cec67f14bb09e9a4f2b5ad47d10342228c1 100644 (file)
@@ -2,39 +2,25 @@
  * Copyright (c) 2012 Michael Walle
  * Michael Walle <michael@walle.cc>
  *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301 USA
+ * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #ifndef _CONFIG_LSXL_H
 #define _CONFIG_LSXL_H
 
+#define CONFIG_SYS_GENERIC_BOARD
+
 /*
  * Version number information
  */
 #if defined(CONFIG_LSCHLV2)
 #define CONFIG_IDENT_STRING " LS-CHLv2"
-#define CONFIG_SYS_KWD_CONFIG $(SRCTREE)/$(CONFIG_BOARDDIR)/kwbimage-lschl.cfg
+#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage-lschl.cfg
 #define CONFIG_MACH_TYPE 3006
 #define CONFIG_SYS_TCLK 166666667 /* 166 MHz */
 #elif defined(CONFIG_LSXHL)
 #define CONFIG_IDENT_STRING " LS-XHL"
-#define CONFIG_SYS_KWD_CONFIG $(SRCTREE)/$(CONFIG_BOARDDIR)/kwbimage-lsxhl.cfg
+#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage-lsxhl.cfg
 #define CONFIG_MACH_TYPE 2663
 /* CONFIG_SYS_TCLK is 200000000 by default */
 #else
  * General configuration options
  */
 #define CONFIG_FEROCEON_88FR131                /* CPU Core subversion */
-#define CONFIG_KIRKWOOD                        /* SOC Family Name */
 #define CONFIG_KW88F6281               /* SOC Name */
 
 #define CONFIG_SKIP_LOWLEVEL_INIT      /* disable board lowlevel_init */
 #define CONFIG_MISC_INIT_R
 #define CONFIG_SHOW_BOOT_PROGRESS
 
-#define CONFIG_RANDOM_MACADDR
 #define CONFIG_KIRKWOOD_GPIO
 #define CONFIG_OF_LIBFDT
 
@@ -69,7 +53,7 @@
 /*
  * Commands configuration
  */
-#include <config_cmd_default.h>
+#define CONFIG_CMD_BOOTZ
 #define CONFIG_CMD_DHCP
 #define CONFIG_CMD_ELF
 #define CONFIG_CMD_ENV
@@ -81,6 +65,7 @@
 #define CONFIG_CMD_SF
 #define CONFIG_CMD_SPI
 #define CONFIG_CMD_USB
+#define CONFIG_CMD_FS_GENERIC
 
 #define CONFIG_DOS_PARTITION
 #define CONFIG_EFI_PARTITION
@@ -91,6 +76,9 @@
  */
 #include "mv-common.h"
 
+/* loading initramfs images without uimage header */
+#define CONFIG_SUPPORT_RAW_INITRD
+
 /* ST M25P40 */
 #undef CONFIG_SPI_FLASH_MACRONIX
 #define CONFIG_SPI_FLASH_STMICRO
 
 
 #undef CONFIG_SYS_PROMPT
-#define CONFIG_SYS_PROMPT              "=> "
 #define CONFIG_SYS_PROMPT_HUSH_PS2     "> "
 
 /*
 #define CONFIG_LOADADDR                0x00800000
 #define CONFIG_BOOTCOMMAND     "run bootcmd_${bootsource}"
 #define CONFIG_BOOTARGS                "console=ttyS0,115200 root=/dev/sda2"
+
+#if defined(CONFIG_LSXHL)
+#define CONFIG_FDTFILE "kirkwood-lsxhl.dtb"
+#elif defined(CONFIG_LSCHLV2)
+#define CONFIG_FDTFILE "kirkwood-lschlv2.dtb"
+#else
+#error "Unsupported board"
+#endif
+
 #define CONFIG_EXTRA_ENV_SETTINGS                                      \
-       "bootsource=hdd\0"                                              \
+       "bootsource=legacy\0"                                           \
        "hdpart=0:1\0"                                                  \
-       "bootcmd_net=bootp 0x00100000 uImage "                          \
-               "&& tftpboot 0x00800000 uInitrd "                       \
-               "&& bootm 0x00100000 0x00800000\0"                      \
+       "kernel_addr=0x00800000\0"                                      \
+       "ramdisk_addr=0x01000000\0"                                     \
+       "fdt_addr=0x00ff0000\0"                                         \
+       "bootcmd_legacy=ide reset "                                     \
+               "&& load ide ${hdpart} ${kernel_addr} /uImage.buffalo " \
+               "&& load ide ${hdpart} ${ramdisk_addr} /initrd.buffalo "\
+               "&& bootm ${kernel_addr} ${ramdisk_addr}\0"             \
+       "bootcmd_net=bootp ${kernel_addr} vmlinuz "                     \
+               "&& tftpboot ${ramdisk_addr} initrd.img "               \
+               "&& setenv ramdisk_len ${filesize} "                    \
+               "&& tftpboot ${fdt_addr} " CONFIG_FDTFILE " "           \
+               "&& bootz ${kernel_addr} "                              \
+                       "${ramdisk_addr}:${ramdisk_len} ${fdt_addr}\0"  \
        "bootcmd_hdd=ide reset "                                        \
-               "&& ext2load ide ${hdpart} 0x00100000 /uImage "         \
-               "&& ext2load ide ${hdpart} 0x00800000 /uInitrd "        \
-               "&& bootm 0x00100000 0x00800000\0"                      \
+               "&& load ide ${hdpart} ${kernel_addr} /vmlinuz "        \
+               "&& load ide ${hdpart} ${ramdisk_addr} /initrd.img "    \
+               "&& setenv ramdisk_len ${filesize} "                    \
+               "&& load ide ${hdpart} ${fdt_addr} /dtb "               \
+               "&& bootz ${kernel_addr} "                              \
+                       "${ramdisk_addr}:${ramdisk_len} ${fdt_addr}\0"  \
        "bootcmd_usb=usb start "                                        \
-               "&& fatload usb 0:1 0x00100000 /uImage "                \
-               "&& fatload usb 0:1 0x00800000 /uInitrd "               \
-               "&& bootm 0x00100000 0x00800000\0"                      \
+               "&& load usb 0:1 ${kernel_addr} /vmlinuz "              \
+               "&& load usb 0:1 ${ramdisk_addr} /initrd.img "          \
+               "&& setenv ramdisk_len ${filesize} "                    \
+               "&& load usb 0:1 ${fdt_addr} " CONFIG_FDTFILE " "       \
+               "&& bootz ${kernel_addr} "                              \
+                       "${ramdisk_addr}:${ramdisk_len} ${fdt_addr}\0"  \
        "bootcmd_rescue=run config_nc_dhcp; run nc\0"                   \
        "eraseenv=sf probe 0 "                                          \
                "&& sf erase " __stringify(CONFIG_ENV_OFFSET)           \
        "config_nc_dhcp=setenv autoload_old ${autoload}; "              \
                "setenv autoload no "                                   \
                "&& bootp "                                             \
-               "&& setenv ncip ${serverip} "                           \
+               "&& setenv ncip "                                       \
                "&& setenv autoload ${autoload_old}; "                  \
                "setenv autoload_old\0"                                 \
        "standard_env=setenv ipaddr; setenv netmask; setenv serverip; " \
                "setenv ncip; setenv gatewayip; setenv ethact; "        \
                "setenv bootfile; setenv dnsip; "                       \
-               "setenv bootsource hdd; run ser\0"                      \
+               "setenv bootsource legacy; run ser\0"                   \
        "restore_env=run standard_env; saveenv; reset\0"                \
        "ser=setenv stdin serial; setenv stdout serial; "               \
                "setenv stderr serial\0"                                \
 #undef CONFIG_SYS_IDE_MAXDEVICE
 #define CONFIG_SYS_IDE_MAXDEVICE       1
 #define CONFIG_SYS_ATA_IDE0_OFFSET     MV_SATA_PORT0_OFFSET
+#define CONFIG_SYS_64BIT_LBA
 #endif
 
 #endif /* _CONFIG_LSXL_H */