From 0b135cfc2e524dc249b75057b55dd4cc09842e27 Mon Sep 17 00:00:00 2001 From: Nobuhiro Iwamatsu Date: Sun, 13 May 2007 20:58:00 +0900 Subject: sh: First support code of SuperH. Signed-off-by: Nobuhiro Iwamatsu --- include/asm-sh/cpu_sh4.h | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 include/asm-sh/cpu_sh4.h (limited to 'include/asm-sh/cpu_sh4.h') diff --git a/include/asm-sh/cpu_sh4.h b/include/asm-sh/cpu_sh4.h new file mode 100644 index 0000000..e0275f3 --- /dev/null +++ b/include/asm-sh/cpu_sh4.h @@ -0,0 +1,10 @@ +#ifndef _ASM_CPU_SH4_H_ +#define _ASM_CPU_SH4_H_ +#if defined (CONFIG_CPU_SH7750) +#include +#elif defined (CONFIG_CPU_SH7780) +#include +#else +#error "Unknown SH4 variant" +#endif +#endif -- cgit v1.1 From b02bad128669e567fce87d8df823b06a0144b8db Mon Sep 17 00:00:00 2001 From: Nobuhiro Iwamatsu Date: Sun, 23 Sep 2007 02:12:30 +0900 Subject: sh: Update core code of SuperH. Signed-off-by: Nobuhiro Iwamatsu --- include/asm-sh/cpu_sh4.h | 44 +++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 41 insertions(+), 3 deletions(-) (limited to 'include/asm-sh/cpu_sh4.h') diff --git a/include/asm-sh/cpu_sh4.h b/include/asm-sh/cpu_sh4.h index e0275f3..dca61ca 100644 --- a/include/asm-sh/cpu_sh4.h +++ b/include/asm-sh/cpu_sh4.h @@ -1,10 +1,48 @@ +/* + * (C) Copyright 2007 Nobuhiro Iwamatsu + * + * 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., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + */ + #ifndef _ASM_CPU_SH4_H_ #define _ASM_CPU_SH4_H_ + +/* cache control */ +#define CCR_CACHE_STOP 0x00000808 +#define CCR_CACHE_ENABLE 0x00000101 +#define CCR_CACHE_ICI 0x00000800 + +#define CACHE_OC_ADDRESS_ARRAY 0xf4000000 +#define CACHE_OC_WAY_SHIFT 14 +#define CACHE_OC_NUM_ENTRIES 512 +#define CACHE_OC_ENTRY_SHIFT 5 +//#define CACHE_OC_NUM_WAYS 1 + #if defined (CONFIG_CPU_SH7750) #include -#elif defined (CONFIG_CPU_SH7780) -#include +//#ifdef CONFIG_CPU_TYPE_R +//#define CCR_CACHE_INIT 0x8000090d /* EMODE,ICI,ICE(16k),OCI,P1-wb,OCE(32k) */ +//#else +//#define CCR_CACHE_INIT 0x0000090b +//#endif +#elif defined (CONFIG_CPU_SH7722) +#include +//#define CCR_CACHE_INIT 0x0000090d #else #error "Unknown SH4 variant" #endif -#endif + +#endif /* _ASM_CPU_SH4_H_ */ -- cgit v1.1 From 516ad760db3553766267ada01b7d5d727faa4bbd Mon Sep 17 00:00:00 2001 From: Nobuhiro Iwamatsu Date: Sun, 23 Sep 2007 02:17:08 +0900 Subject: sh: Remove comment out code from include/asm-sh/cpu_sh4.h Signed-off-by: Nobuhiro Iwamatsu --- include/asm-sh/cpu_sh4.h | 7 ------- 1 file changed, 7 deletions(-) (limited to 'include/asm-sh/cpu_sh4.h') diff --git a/include/asm-sh/cpu_sh4.h b/include/asm-sh/cpu_sh4.h index dca61ca..2658039 100644 --- a/include/asm-sh/cpu_sh4.h +++ b/include/asm-sh/cpu_sh4.h @@ -29,18 +29,11 @@ #define CACHE_OC_WAY_SHIFT 14 #define CACHE_OC_NUM_ENTRIES 512 #define CACHE_OC_ENTRY_SHIFT 5 -//#define CACHE_OC_NUM_WAYS 1 #if defined (CONFIG_CPU_SH7750) #include -//#ifdef CONFIG_CPU_TYPE_R -//#define CCR_CACHE_INIT 0x8000090d /* EMODE,ICI,ICE(16k),OCI,P1-wb,OCE(32k) */ -//#else -//#define CCR_CACHE_INIT 0x0000090b -//#endif #elif defined (CONFIG_CPU_SH7722) #include -//#define CCR_CACHE_INIT 0x0000090d #else #error "Unknown SH4 variant" #endif -- cgit v1.1