[U-Boot] [PATCH 6/6] sh: Remove shmin board
Joe Hershberger
joe.hershberger at ni.com
Sun May 10 22:23:14 CEST 2015
Removing this board because it does not build with any tool-chain that
we know of.
The board fails to build with the tool-chain available at kernel.org:
https://www.kernel.org/pub/tools/crosstool/files/bin/i686/4.6.3/i686-gcc-4.6.3-nolibc_sh4-linux.tar.xz
It fails with the following error:
sh4-linux-gcc: error: command line option '-m3' is not supported by this configuration
Signed-off-by: Joe Hershberger <joe.hershberger at ni.com>
Cc: Nobuhiro Iwamatsu <iwamatsu.nobuhiro at renesas.com>
Cc: Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
---
MAKEALL | 1 -
README | 1 -
arch/sh/Kconfig | 9 ----
arch/sh/cpu/sh3/Makefile | 15 ------
arch/sh/cpu/sh3/cache.c | 96 ----------------------------------
arch/sh/cpu/sh3/config.mk | 14 -----
arch/sh/cpu/sh3/cpu.c | 68 ------------------------
arch/sh/cpu/sh3/interrupts.c | 26 ---------
arch/sh/cpu/sh3/start.S | 64 -----------------------
arch/sh/cpu/sh3/watchdog.c | 27 ----------
arch/sh/include/asm/cpu_sh3.h | 29 -----------
arch/sh/include/asm/cpu_sh7706.h | 50 ------------------
arch/sh/include/asm/cpu_sh7710.h | 61 ----------------------
arch/sh/include/asm/processor.h | 4 +-
arch/sh/lib/Makefile | 1 -
board/shmin/Kconfig | 9 ----
board/shmin/MAINTAINERS | 7 ---
board/shmin/Makefile | 10 ----
board/shmin/lowlevel_init.S | 22 --------
board/shmin/shmin.c | 101 -----------------------------------
configs/shmin_defconfig | 2 -
drivers/serial/serial_sh.h | 28 ++--------
include/configs/shmin.h | 110 ---------------------------------------
include/sh_tmu.h | 22 --------
24 files changed, 5 insertions(+), 772 deletions(-)
delete mode 100644 arch/sh/cpu/sh3/Makefile
delete mode 100644 arch/sh/cpu/sh3/cache.c
delete mode 100644 arch/sh/cpu/sh3/config.mk
delete mode 100644 arch/sh/cpu/sh3/cpu.c
delete mode 100644 arch/sh/cpu/sh3/interrupts.c
delete mode 100644 arch/sh/cpu/sh3/start.S
delete mode 100644 arch/sh/cpu/sh3/watchdog.c
delete mode 100644 arch/sh/include/asm/cpu_sh3.h
delete mode 100644 arch/sh/include/asm/cpu_sh7706.h
delete mode 100644 arch/sh/include/asm/cpu_sh7710.h
delete mode 100644 board/shmin/Kconfig
delete mode 100644 board/shmin/MAINTAINERS
delete mode 100644 board/shmin/Makefile
delete mode 100644 board/shmin/lowlevel_init.S
delete mode 100644 board/shmin/shmin.c
delete mode 100644 configs/shmin_defconfig
delete mode 100644 include/configs/shmin.h
diff --git a/MAKEALL b/MAKEALL
index 06a7e93..6320e37 100755
--- a/MAKEALL
+++ b/MAKEALL
@@ -465,7 +465,6 @@ LIST_blackfin="$(targets_by_arch blackfin)"
## SH Systems
#########################################################################
-LIST_sh3="$(targets_by_cpu sh3)"
LIST_sh4="$(targets_by_cpu sh4)"
LIST_sh="$(targets_by_arch sh)"
diff --git a/README b/README
index 4553e64..587dff7 100644
--- a/README
+++ b/README
@@ -191,7 +191,6 @@ Directory Hierarchy:
/lib Architecture specific library files
/sh Files generic to SH architecture
/cpu CPU specific files
- /sh3 Files specific to sh3 CPUs
/sh4 Files specific to sh4 CPUs
/lib Architecture specific library files
/sparc Files generic to SPARC architecture
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
index a4a32b2..9960278 100644
--- a/arch/sh/Kconfig
+++ b/arch/sh/Kconfig
@@ -1,9 +1,6 @@
menu "SuperH architecture"
depends on SH
-config CPU_SH3
- bool
-
config CPU_SH4
bool
@@ -23,10 +20,6 @@ config SH_32BIT
choice
prompt "Target select"
-config TARGET_SHMIN
- bool "SHMIN"
- select CPU_SH3
-
config TARGET_ESPT
bool "Data Technology ESPT-GIGA board"
select CPU_SH4
@@ -93,7 +86,6 @@ config SYS_ARCH
default "sh"
config SYS_CPU
- default "sh3" if CPU_SH3
default "sh4" if CPU_SH4
config USE_PRIVATE_LIBGCC
@@ -114,6 +106,5 @@ source "board/renesas/sh7753evb/Kconfig"
source "board/renesas/sh7757lcr/Kconfig"
source "board/renesas/sh7763rdp/Kconfig"
source "board/renesas/sh7785lcr/Kconfig"
-source "board/shmin/Kconfig"
endmenu
diff --git a/arch/sh/cpu/sh3/Makefile b/arch/sh/cpu/sh3/Makefile
deleted file mode 100644
index 1dccaf9..0000000
--- a/arch/sh/cpu/sh3/Makefile
+++ /dev/null
@@ -1,15 +0,0 @@
-#
-# (C) Copyright 2000-2006
-# Wolfgang Denk, DENX Software Engineering, wd at denx.de.
-#
-# (C) Copyright 2007
-# Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
-#
-# (C) Copyright 2007
-# Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
-#
-# SPDX-License-Identifier: GPL-2.0+
-#
-
-extra-y = start.o
-obj-y = cpu.o interrupts.o watchdog.o cache.o
diff --git a/arch/sh/cpu/sh3/cache.c b/arch/sh/cpu/sh3/cache.c
deleted file mode 100644
index 34cbbff..0000000
--- a/arch/sh/cpu/sh3/cache.c
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * (C) Copyright 2007
- * Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
- *
- * (C) Copyright 2007
- * Nobobuhiro Iwamatsu <iwamatsu at nigauri.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <common.h>
-#include <command.h>
-#include <asm/processor.h>
-#include <asm/io.h>
-
-/*
- * Jump to P2 area.
- * When handling TLB or caches, we need to do it from P2 area.
- */
-#define jump_to_P2() \
- do { \
- unsigned long __dummy; \
- __asm__ __volatile__( \
- "mov.l 1f, %0\n\t" \
- "or %1, %0\n\t" \
- "jmp @%0\n\t" \
- " nop\n\t" \
- ".balign 4\n" \
- "1: .long 2f\n" \
- "2:" \
- : "=&r" (__dummy) \
- : "r" (0x20000000)); \
- } while (0)
-
-/*
- * Back to P1 area.
- */
-#define back_to_P1() \
- do { \
- unsigned long __dummy; \
- __asm__ __volatile__( \
- "nop;nop;nop;nop;nop;nop;nop\n\t" \
- "mov.l 1f, %0\n\t" \
- "jmp @%0\n\t" \
- " nop\n\t" \
- ".balign 4\n" \
- "1: .long 2f\n" \
- "2:" \
- : "=&r" (__dummy)); \
- } while (0)
-
-#define CACHE_VALID 1
-#define CACHE_UPDATED 2
-
-static inline void cache_wback_all(void)
-{
- unsigned long addr, data, i, j;
-
- jump_to_P2();
- for (i = 0; i < CACHE_OC_NUM_ENTRIES; i++) {
- for (j = 0; j < CACHE_OC_NUM_WAYS; j++) {
- addr = CACHE_OC_ADDRESS_ARRAY
- | (j << CACHE_OC_WAY_SHIFT)
- | (i << CACHE_OC_ENTRY_SHIFT);
- data = inl(addr);
- if (data & CACHE_UPDATED) {
- data &= ~CACHE_UPDATED;
- outl(data, addr);
- }
- }
- }
- back_to_P1();
-}
-
-
-#define CACHE_ENABLE 0
-#define CACHE_DISABLE 1
-
-int cache_control(unsigned int cmd)
-{
- unsigned long ccr;
-
- jump_to_P2();
- ccr = inl(CCR);
-
- if (ccr & CCR_CACHE_ENABLE)
- cache_wback_all();
-
- if (cmd == CACHE_DISABLE)
- outl(CCR_CACHE_STOP, CCR);
- else
- outl(CCR_CACHE_INIT, CCR);
- back_to_P1();
-
- return 0;
-}
diff --git a/arch/sh/cpu/sh3/config.mk b/arch/sh/cpu/sh3/config.mk
deleted file mode 100644
index dcafd19..0000000
--- a/arch/sh/cpu/sh3/config.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-#
-# (C) Copyright 2000-2004
-# Wolfgang Denk, DENX Software Engineering, wd at denx.de.
-#
-# (C) Copyright 2007
-# Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
-#
-# (C) Copyright 2007
-# Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
-#
-# SPDX-License-Identifier: GPL-2.0+
-#
-#
-PLATFORM_CPPFLAGS += -m3
diff --git a/arch/sh/cpu/sh3/cpu.c b/arch/sh/cpu/sh3/cpu.c
deleted file mode 100644
index ea0006a..0000000
--- a/arch/sh/cpu/sh3/cpu.c
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * (C) Copyright 2007
- * Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
- *
- * (C) Copyright 2007
- * Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <common.h>
-#include <command.h>
-#include <asm/processor.h>
-
-int checkcpu(void)
-{
- puts("CPU: SH3\n");
- return 0;
-}
-
-int cpu_init(void)
-{
- return 0;
-}
-
-int cleanup_before_linux(void)
-{
- disable_interrupts();
- return 0;
-}
-
-int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
-{
- disable_interrupts();
- reset_cpu(0);
- return 0;
-}
-
-void flush_cache(unsigned long addr, unsigned long size)
-{
-
-}
-
-void icache_enable(void)
-{
-}
-
-void icache_disable(void)
-{
-}
-
-int icache_status(void)
-{
- return 0;
-}
-
-void dcache_enable(void)
-{
-}
-
-void dcache_disable(void)
-{
-}
-
-int dcache_status(void)
-{
- return 0;
-}
diff --git a/arch/sh/cpu/sh3/interrupts.c b/arch/sh/cpu/sh3/interrupts.c
deleted file mode 100644
index 80a13e0..0000000
--- a/arch/sh/cpu/sh3/interrupts.c
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * (C) Copyright 2007
- * Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
- *
- * (C) Copyright 2007
- * Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <common.h>
-
-int interrupt_init(void)
-{
- return 0;
-}
-
-void enable_interrupts(void)
-{
-
-}
-
-int disable_interrupts(void)
-{
- return 0;
-}
diff --git a/arch/sh/cpu/sh3/start.S b/arch/sh/cpu/sh3/start.S
deleted file mode 100644
index 7a934e2..0000000
--- a/arch/sh/cpu/sh3/start.S
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * (C) Copyright 2007
- * Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
- *
- * (C) Copyright 2007
- * Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <asm-offsets.h>
-#include <config.h>
-
- .text
- .align 2
-
- .global _start
-_sh_start:
- mov.l ._lowlevel_init, r0
-100: bsrf r0
- nop
-
- bsr 1f
- nop
-1: sts pr, r5
- mov.l ._reloc_dst, r4
- add #(_sh_start-1b), r5
- mov.l ._reloc_dst_end, r6
-
-2: mov.l @r5+, r1
- mov.l r1, @r4
- add #4, r4
- cmp/hs r6, r4
- bf 2b
-
- mov.l ._bss_start, r4
- mov.l ._bss_end, r5
- mov #0, r1
-
-3: mov.l r1, @r4 /* bss clear */
- add #4, r4
- cmp/hs r5, r4
- bf 3b
-
- mov.l ._gd_init, r13 /* global data */
- mov.l ._stack_init, r15 /* stack */
-
- mov.l ._sh_generic_init, r0
- jsr @r0
- nop
-
-loop:
- bra loop
-
- .align 2
-
-._lowlevel_init: .long (lowlevel_init - (100b + 4))
-._reloc_dst: .long reloc_dst
-._reloc_dst_end: .long reloc_dst_end
-._bss_start: .long bss_start
-._bss_end: .long bss_end
-._gd_init: .long (_sh_start - GENERATED_GBL_DATA_SIZE)
-._stack_init: .long (_sh_start - GENERATED_GBL_DATA_SIZE - CONFIG_SYS_MALLOC_LEN - 16)
-._sh_generic_init: .long sh_generic_init
diff --git a/arch/sh/cpu/sh3/watchdog.c b/arch/sh/cpu/sh3/watchdog.c
deleted file mode 100644
index 45640ff..0000000
--- a/arch/sh/cpu/sh3/watchdog.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * (C) Copyright 2010
- * Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj at renesas.com>
- *
- * (C) Copyright 2007
- * Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <common.h>
-#include <asm/processor.h>
-#include <asm/system.h>
-
-int watchdog_init(void)
-{
- return 0;
-}
-
-void reset_cpu(unsigned long ignored)
-{
- /* Address error with SR.BL=1 first. */
- trigger_address_error();
-
- while (1)
- ;
-}
diff --git a/arch/sh/include/asm/cpu_sh3.h b/arch/sh/include/asm/cpu_sh3.h
deleted file mode 100644
index 443aaeb..0000000
--- a/arch/sh/include/asm/cpu_sh3.h
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * (C) Copyright 2007-2009 Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- * (C) Copyright 2007 Yoshihiro Shimoda <shimoda.yoshihiro at renesas.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#ifndef _ASM_CPU_SH3_H_
-#define _ASM_CPU_SH3_H_
-
-/* cache control */
-#define CCR_CACHE_STOP 0x00000008
-#define CCR_CACHE_ENABLE 0x00000005
-#define CCR_CACHE_ICI 0x00000008
-
-#define CACHE_OC_ADDRESS_ARRAY 0xf0000000
-#define CACHE_OC_WAY_SHIFT 13
-#define CACHE_OC_NUM_ENTRIES 256
-#define CACHE_OC_ENTRY_SHIFT 4
-
-#if defined(CONFIG_CPU_SH7706)
-#include <asm/cpu_sh7706.h>
-#elif defined(CONFIG_CPU_SH7710)
-#include <asm/cpu_sh7710.h>
-#else
-#error "Unknown SH3 variant"
-#endif
-
-#endif /* _ASM_CPU_SH3_H_ */
diff --git a/arch/sh/include/asm/cpu_sh7706.h b/arch/sh/include/asm/cpu_sh7706.h
deleted file mode 100644
index 8066ff7..0000000
--- a/arch/sh/include/asm/cpu_sh7706.h
+++ /dev/null
@@ -1,50 +0,0 @@
-#ifndef _ASM_CPU_SH7706_H_
-#define _ASM_CPU_SH7706_H_
-
-#define CACHE_OC_NUM_WAYS 4
-#define CCR_CACHE_INIT 0x0000000D
-
-/* MMU and Cache control */
-#define MMUCR 0xFFFFFFE0
-#define CCR 0xFFFFFFEC
-
-/* PFC */
-#define PACR 0xA4050100
-#define PBCR 0xA4050102
-#define PCCR 0xA4050104
-#define PETCR 0xA4050106
-
-/* Port Data Registers */
-#define PADR 0xA4050120
-#define PBDR 0xA4050122
-#define PCDR 0xA4050124
-
-/* BSC */
-#define FRQCR 0xffffff80
-#define BCR1 0xffffff60
-#define BCR2 0xffffff62
-#define WCR1 0xffffff64
-#define WCR2 0xffffff66
-#define MCR 0xffffff68
-
-/* SDRAM controller */
-#define DCR 0xffffff6a
-#define RTCSR 0xffffff6e
-#define RTCNT 0xffffff70
-#define RTCOR 0xffffff72
-#define RFCR 0xffffff74
-#define SDMR 0xFFFFD000
-#define CS3_R 0xFFFFE460
-
-/* SCIF */
-#define SCSMR_2 0xA4000150
-#define SCIF0_BASE SCSMR_2
-
-/* Timer */
-#define TMU_BASE 0xFFFFFE90
-
-/* On chip oscillator circuits */
-#define WTCNT 0xFFFFFF84
-#define WTCSR 0xFFFFFF86
-
-#endif /* _ASM_CPU_SH7706_H_ */
diff --git a/arch/sh/include/asm/cpu_sh7710.h b/arch/sh/include/asm/cpu_sh7710.h
deleted file mode 100644
index e4ecef7..0000000
--- a/arch/sh/include/asm/cpu_sh7710.h
+++ /dev/null
@@ -1,61 +0,0 @@
-#ifndef _ASM_CPU_SH7710_H_
-#define _ASM_CPU_SH7710_H_
-
-#define CACHE_OC_NUM_WAYS 4
-#define CCR_CACHE_INIT 0x0000000D
-
-/* MMU and Cache control */
-#define MMUCR 0xFFFFFFE0
-#define CCR 0xFFFFFFEC
-
-/* PFC */
-#define PACR 0xA4050100
-#define PBCR 0xA4050102
-#define PCCR 0xA4050104
-#define PETCR 0xA4050106
-
-/* Port Data Registers */
-#define PADR 0xA4050120
-#define PBDR 0xA4050122
-#define PCDR 0xA4050124
-
-/* BSC */
-#define CMNCR 0xA4FD0000
-#define CS0BCR 0xA4FD0004
-#define CS2BCR 0xA4FD0008
-#define CS3BCR 0xA4FD000C
-#define CS4BCR 0xA4FD0010
-#define CS5ABCR 0xA4FD0014
-#define CS5BBCR 0xA4FD0018
-#define CS6ABCR 0xA4FD001C
-#define CS6BBCR 0xA4FD0020
-#define CS0WCR 0xA4FD0024
-#define CS2WCR 0xA4FD0028
-#define CS3WCR 0xA4FD002C
-#define CS4WCR 0xA4FD0030
-#define CS5AWCR 0xA4FD0034
-#define CS5BWCR 0xA4FD0038
-#define CS6AWCR 0xA4FD003C
-#define CS6BWCR 0xA4FD0040
-
-/* SDRAM controller */
-#define SDCR 0xA4FD0044
-#define RTCSR 0xA4FD0048
-#define RTCNT 0xA4FD004C
-#define RTCOR 0xA4FD0050
-
-/* SCIF */
-#define SCSMR_0 0xA4400000
-#define SCIF0_BASE SCSMR_0
-#define SCSMR_0 0xA4410000
-#define SCIF1_BASE SCSMR_1
-
-/* Timer */
-#define TMU_BASE 0xA412FE90
-
-/* On chip oscillator circuits */
-#define FRQCR 0xA415FF80
-#define WTCNT 0xA415FF84
-#define WTCSR 0xA415FF86
-
-#endif /* _ASM_CPU_SH7710_H_ */
diff --git a/arch/sh/include/asm/processor.h b/arch/sh/include/asm/processor.h
index bdc1da6..ca2a81b 100644
--- a/arch/sh/include/asm/processor.h
+++ b/arch/sh/include/asm/processor.h
@@ -1,8 +1,6 @@
#ifndef _ASM_SH_PROCESSOR_H_
#define _ASM_SH_PROCESSOR_H_
-#if defined(CONFIG_CPU_SH3)
-# include <asm/cpu_sh3.h>
-#elif defined(CONFIG_CPU_SH4)
+#if defined(CONFIG_CPU_SH4)
# include <asm/cpu_sh4.h>
#endif
#endif
diff --git a/arch/sh/lib/Makefile b/arch/sh/lib/Makefile
index 0166f12..f5c300c 100644
--- a/arch/sh/lib/Makefile
+++ b/arch/sh/lib/Makefile
@@ -14,7 +14,6 @@ obj-$(CONFIG_CMD_SH_ZIMAGEBOOT) += zimageboot.o
udivsi3-y := udivsi3_i4i-Os.o
ifneq ($(CONFIG_CC_OPTIMIZE_FOR_SIZE),y)
-udivsi3-$(CONFIG_CPU_SH3) := udivsi3_i4i.o
udivsi3-$(CONFIG_CPU_SH4) := udivsi3_i4i.o
endif
udivsi3-y += udivsi3.o
diff --git a/board/shmin/Kconfig b/board/shmin/Kconfig
deleted file mode 100644
index 467580c..0000000
--- a/board/shmin/Kconfig
+++ /dev/null
@@ -1,9 +0,0 @@
-if TARGET_SHMIN
-
-config SYS_BOARD
- default "shmin"
-
-config SYS_CONFIG_NAME
- default "shmin"
-
-endif
diff --git a/board/shmin/MAINTAINERS b/board/shmin/MAINTAINERS
deleted file mode 100644
index 5dee37b..0000000
--- a/board/shmin/MAINTAINERS
+++ /dev/null
@@ -1,7 +0,0 @@
-SHMIN BOARD
-M: Nobuhiro Iwamatsu <iwamatsu.nobuhiro at renesas.com>
-M: Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
-S: Maintained
-F: board/shmin/
-F: include/configs/shmin.h
-F: configs/shmin_defconfig
diff --git a/board/shmin/Makefile b/board/shmin/Makefile
deleted file mode 100644
index daf36de..0000000
--- a/board/shmin/Makefile
+++ /dev/null
@@ -1,10 +0,0 @@
-#
-# Copyright (C) 2010 Nobuhiro Iwamatsu
-# Copyright (C) 2008 Renesas Solutions Corp.
-#
-# u-boot/board/shmin/Makefile
-#
-# SPDX-License-Identifier: GPL-2.0+
-
-obj-y := shmin.o
-obj-y += lowlevel_init.o
diff --git a/board/shmin/lowlevel_init.S b/board/shmin/lowlevel_init.S
deleted file mode 100644
index 53b3123..0000000
--- a/board/shmin/lowlevel_init.S
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * (C) Copyright 2008, 2010 Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <config.h>
-
-#include <asm/processor.h>
-#include <asm/macro.h>
-
-
- .global lowlevel_init
-
- .text
- .align 2
-
-lowlevel_init:
- /* Use setting of original bootloader */
- rts
- nop
- .align 2
diff --git a/board/shmin/shmin.c b/board/shmin/shmin.c
deleted file mode 100644
index 74d1e39..0000000
--- a/board/shmin/shmin.c
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (C) 2007 - 2010
- * Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- * (C) Copyright 2000-2003
- * Wolfgang Denk, DENX Software Engineering, wd at denx.de.
- * Copyright (C) 2004-2007 Freescale Semiconductor, Inc.
- *
- * board/shmin/shmin.c
- *
- * SPDX-License-Identifier: GPL-2.0+
- *
- * Copy board_flash_get_legacy() from board/freescale/m54455evb/m54455evb.c
- */
-
-#include <common.h>
-#include <asm/io.h>
-#include <asm/processor.h>
-#include <netdev.h>
-
-int checkboard(void)
-{
- puts("BOARD: T-SH7706LAN ");
- if(readb(0xb0008006) == 0xab)
- puts("v2\n");
- else
- puts("v1\n");
- return 0;
-}
-
-int board_init(void)
-{
- writew(0x2980, BCR2);
- return 0;
-}
-
-int dram_init(void)
-{
- DECLARE_GLOBAL_DATA_PTR;
-
- gd->bd->bi_memstart = CONFIG_SYS_SDRAM_BASE;
- gd->bd->bi_memsize = CONFIG_SYS_SDRAM_SIZE;
- printf("DRAM: %dMB\n", CONFIG_SYS_SDRAM_SIZE / (1024 * 1024));
- return 0;
-}
-
-int board_eth_init(bd_t *bis)
-{
- return ne2k_register();
-}
-
-void led_set_state(unsigned short value)
-{
-
-}
-
-#if defined(CONFIG_FLASH_CFI_LEGACY)
-#include <flash.h>
-ulong board_flash_get_legacy(ulong base, int banknum, flash_info_t *info)
-{
- int sect[] = CONFIG_SYS_ATMEL_SECT;
- int sectsz[] = CONFIG_SYS_ATMEL_SECTSZ;
- int i, j, k;
-
- if (base != CONFIG_SYS_ATMEL_BASE)
- return 0;
-
- info->flash_id = 0x01000000;
- info->portwidth = 1;
- info->chipwidth = 1;
- info->buffer_size = 1;
- info->erase_blk_tout = 16384;
- info->write_tout = 2;
- info->buffer_write_tout = 5;
- info->vendor = 0xFFF0; /* CFI_CMDSET_AMD_LEGACY */
- info->cmd_reset = 0x00F0;
- info->interface = FLASH_CFI_X8;
- info->legacy_unlock = 0;
- info->manufacturer_id = (u16) ATM_MANUFACT;
- info->device_id = ATM_ID_LV040;
- info->device_id2 = 0;
- info->ext_addr = 0;
- info->cfi_version = 0x3133;
- info->cfi_offset = 0x0000;
- info->addr_unlock1 = 0x00000555;
- info->addr_unlock2 = 0x000002AA;
- info->name = "CFI conformant";
- info->size = 0;
- info->sector_count = CONFIG_SYS_ATMEL_TOTALSECT;
- info->start[0] = base;
-
- for (k = 0, i = 0; i < CONFIG_SYS_ATMEL_REGION; i++) {
- info->size += sect[i] * sectsz[i];
- for (j = 0; j < sect[i]; j++, k++) {
- info->start[k + 1] = info->start[k] + sectsz[i];
- info->protect[k] = 0;
- }
- }
-
- return 1;
-}
-#endif /* CONFIG_FLASH_CFI_LEGACY */
diff --git a/configs/shmin_defconfig b/configs/shmin_defconfig
deleted file mode 100644
index 74c3550..0000000
--- a/configs/shmin_defconfig
+++ /dev/null
@@ -1,2 +0,0 @@
-CONFIG_SH=y
-CONFIG_TARGET_SHMIN=y
diff --git a/drivers/serial/serial_sh.h b/drivers/serial/serial_sh.h
index 5f3473f..4c2f2e9 100644
--- a/drivers/serial/serial_sh.h
+++ b/drivers/serial/serial_sh.h
@@ -19,8 +19,7 @@ struct uart_port {
#include <asm/regs267x.h>
#endif
-#if defined(CONFIG_CPU_SH7706) || \
- defined(CONFIG_CPU_SH7707) || \
+#if defined(CONFIG_CPU_SH7707) || \
defined(CONFIG_CPU_SH7708) || \
defined(CONFIG_CPU_SH7709)
# define SCPCR 0xA4000116 /* 16 bit SCI and SCIF */
@@ -72,12 +71,6 @@ struct uart_port {
# define SCSPTR2 0xfe620024 /* 16 bit SCIF */
# define SCIF_ORER 0x0001 /* overrun error bit */
# define SCSCR_INIT(port) 0x38 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */
-#elif defined(CONFIG_CPU_SH7710) || defined(CONFIG_CPU_SH7712)
-# define SCSPTR0 0xA4400000 /* 16 bit SCIF */
-# define SCIF_ORER 0x0001 /* overrun error bit */
-# define PACR 0xa4050100
-# define PBCR 0xa4050102
-# define SCSCR_INIT(port) 0x3B
#elif defined(CONFIG_CPU_SH7343)
# define SCSPTR0 0xffe00010 /* 16 bit SCIF */
# define SCSPTR1 0xffe10010 /* 16 bit SCIF */
@@ -428,24 +421,12 @@ static inline void sci_##name##_out(struct uart_port *port,\
SCI_OUT(sci_size, sci_offset, value);\
}
-#if defined(CONFIG_CPU_SH3) || \
- defined(CONFIG_ARCH_SH7367) || \
+#if defined(CONFIG_ARCH_SH7367) || \
defined(CONFIG_ARCH_SH7377) || \
defined(CONFIG_ARCH_SH7372) || \
defined(CONFIG_SH73A0) || \
defined(CONFIG_R8A7740)
-#if defined(CONFIG_CPU_SH7710) || defined(CONFIG_CPU_SH7712)
-#define SCIx_FNS(name, sh3_sci_offset, sh3_sci_size,\
- sh4_sci_offset, sh4_sci_size, \
- sh3_scif_offset, sh3_scif_size, \
- sh4_scif_offset, sh4_scif_size, \
- h8_sci_offset, h8_sci_size) \
- CPU_SCIx_FNS(name, sh4_sci_offset, sh4_sci_size,\
- sh4_scif_offset, sh4_scif_size)
-#define SCIF_FNS(name, sh3_scif_offset, sh3_scif_size,\
- sh4_scif_offset, sh4_scif_size) \
- CPU_SCIF_FNS(name, sh4_scif_offset, sh4_scif_size)
-#elif defined(CONFIG_CPU_SH7705) || \
+#if defined(CONFIG_CPU_SH7705) || \
defined(CONFIG_CPU_SH7721) || \
defined(CONFIG_ARCH_SH7367) || \
defined(CONFIG_ARCH_SH7377) || \
@@ -641,8 +622,7 @@ static const struct __attribute__((packed)) {
};
#endif
-#if defined(CONFIG_CPU_SH7706) || \
- defined(CONFIG_CPU_SH7707) || \
+#if defined(CONFIG_CPU_SH7707) || \
defined(CONFIG_CPU_SH7708) || \
defined(CONFIG_CPU_SH7709)
static inline int sci_rxd_in(struct uart_port *port)
diff --git a/include/configs/shmin.h b/include/configs/shmin.h
deleted file mode 100644
index 4d38f6c..0000000
--- a/include/configs/shmin.h
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Configuation settings for shmin (T-SH7706LAN, T-SH7706LSR)
- *
- * Copyright (C) 2010, 2011 Nobuhiro Iwamatsu <iwamatsu at nigauri.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#ifndef __SHMIN_H
-#define __SHMIN_H
-
-#define CONFIG_CPU_SH7706 1
-/* T-SH7706LAN */
-#define CONFIG_SHMIN 1
-/* T-SH7706LSR*/
-/* #define CONFIG_T_SH7706LSR 1 */
-
-#define CONFIG_CMD_FLASH
-#define CONFIG_CMD_MEMORY
-#define CONFIG_CMD_SDRAM
-#define CONFIG_CMD_NET
-#define CONFIG_CMD_PING
-#define CONFIG_CMD_NFS
-#define CONFIG_CMD_ENV
-#define CONFIG_CMD_SAVEENV
-
-#define CONFIG_BAUDRATE 115200
-#define CONFIG_BOOTARGS "console=ttySC0,115200"
-
-/*
- * This board has original boot loader. If you write u-boot to 0x0,
- * you should set undef.
- */
-#define CONFIG_VERSION_VARIABLE
-#undef CONFIG_SHOW_BOOT_PROGRESS
-
-/* system */
-#define SHMIN_SDRAM_BASE (0x8C000000)
-#define SHMIN_FLASH_BASE_1 (0xA0000000)
-
-#define CONFIG_SYS_TEXT_BASE 0x8DFB0000
-#define CONFIG_SYS_LONGHELP /* undef to save memory */
-#define CONFIG_SYS_CBSIZE 256 /* Buffer size for input from the Console */
-#define CONFIG_SYS_PBSIZE 256 /* Buffer size for Console output */
-#define CONFIG_SYS_MAXARGS 16 /* max args accepted for monitor commands */
-/* Buffer size for Boot Arguments passed to kernel */
-#define CONFIG_SYS_BARGSIZE 512
-/* List of legal baudrate settings for this board */
-#define CONFIG_SYS_BAUDRATE_TABLE { 9600,14400,19200,38400,57600,115200 }
-
-/* SCIF */
-#define CONFIG_SCIF_CONSOLE 1
-#define CONFIG_CONS_SCIF0 1
-
-/* memory */
-#define CONFIG_SYS_SDRAM_BASE SHMIN_SDRAM_BASE
-#define CONFIG_SYS_SDRAM_SIZE (32 * 1024 * 1024)
-#define CONFIG_SYS_MEMTEST_START SHMIN_SDRAM_BASE
-#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + CONFIG_SYS_SDRAM_SIZE - (256 * 1024))
-
-#define CONFIG_SYS_LOAD_ADDR (CONFIG_SYS_SDRAM_BASE + 1 * 1024 * 1024)
-#define CONFIG_SYS_MONITOR_BASE (SHMIN_FLASH_BASE_1 + CONFIG_ENV_SECT_SIZE)
-#define CONFIG_SYS_MONITOR_LEN (128 * 1024)
-#define CONFIG_SYS_MALLOC_LEN (256 * 1024)
-#define CONFIG_SYS_BOOTMAPSZ (8 * 1024 * 1024)
-
-/* FLASH */
-#define CONFIG_SYS_FLASH_CFI
-#define CONFIG_FLASH_CFI_DRIVER
-#undef CONFIG_SYS_FLASH_QUIET_TEST
-#define CONFIG_SYS_FLASH_EMPTY_INFO /* print 'E' for empty sector on flinfo */
-#define CONFIG_SYS_FLASH_BASE SHMIN_FLASH_BASE_1
-#define CONFIG_SYS_MAX_FLASH_SECT 11
-#define CONFIG_SYS_MAX_FLASH_BANKS 1
-
-#define CONFIG_FLASH_CFI_LEGACY
-#define CONFIG_SYS_ATMEL_BASE CONFIG_SYS_FLASH_BASE
-#define CONFIG_SYS_ATMEL_TOTALSECT CONFIG_SYS_MAX_FLASH_SECT
-#define CONFIG_SYS_ATMEL_REGION 4
-#define CONFIG_SYS_ATMEL_SECT {1, 2, 1, 7}
-#define CONFIG_SYS_ATMEL_SECTSZ {0x4000, 0x2000, 0x8000, 0x10000}
-
-#define CONFIG_ENV_IS_IN_FLASH
-#define CONFIG_ENV_SECT_SIZE (64 * 1024)
-#define CONFIG_ENV_SIZE CONFIG_ENV_SECT_SIZE
-
-#ifdef CONFIG_T_SH7706LSR
-#define CONFIG_ENV_ADDR (SHMIN_FLASH_BASE_1 + 70000)
-#else
-#define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE + CONFIG_SYS_MONITOR_LEN)
-#endif
-
-#define CONFIG_SYS_FLASH_ERASE_TOUT 120000
-#define CONFIG_SYS_FLASH_WRITE_TOUT 500
-
-/* Board Clock */
-#ifdef CONFIG_T_SH7706LSR
-#define CONFIG_SYS_CLK_FREQ 40000000
-#else
-#define CONFIG_SYS_CLK_FREQ 33333333
-#endif /* CONFIG_T_SH7706LSR */
-#define CONFIG_SH_TMU_CLK_FREQ CONFIG_SYS_CLK_FREQ
-#define CONFIG_SH_SCIF_CLK_FREQ CONFIG_SYS_CLK_FREQ
-#define CONFIG_SYS_TMU_CLK_DIV 4
-
-/* Network device */
-#define CONFIG_DRIVER_NE2000
-#define CONFIG_DRIVER_NE2000_BASE (0xb0000300)
-
-#endif /* __SHMIN_H */
diff --git a/include/sh_tmu.h b/include/sh_tmu.h
index 97d578d..f4e8c3e 100644
--- a/include/sh_tmu.h
+++ b/include/sh_tmu.h
@@ -25,28 +25,6 @@
#include <asm/types.h>
-#if defined(CONFIG_CPU_SH3)
-struct tmu_regs {
- u8 tocr;
- u8 reserved0;
- u8 tstr;
- u8 reserved1;
- u32 tcor0;
- u32 tcnt0;
- u16 tcr0;
- u16 reserved2;
- u32 tcor1;
- u32 tcnt1;
- u16 tcr1;
- u16 reserved3;
- u32 tcor2;
- u32 tcnt2;
- u16 tcr2;
- u16 reserved4;
- u32 tcpr2;
-};
-#endif /* CONFIG_CPU_SH3 */
-
#if defined(CONFIG_CPU_SH4) || defined(CONFIG_RMOBILE)
struct tmu_regs {
u32 reserved;
--
1.7.11.5
More information about the U-Boot
mailing list