• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef    __HISOC_SYS_CTRL_H__
17 #define    __HISOC_SYS_CTRL_H__
18 
19 #include "asm/platform.h"
20 
21 #ifdef __cplusplus
22 #if __cplusplus
23 extern "C" {
24 #endif /* __cplusplus */
25 #endif /* __cplusplus */
26 
27 #define REG_SC_CTRL            0
28 #define REG_SC_SYSRES            0x4
29 #define PERIPHCTRL24            0x94
30 
31 #define REG_SC_GEN0            0x0138
32 #define REG_SC_GEN1            0x013c
33 #define REG_SC_GEN2            0x0140
34 #define REG_SC_GEN3            0x0144
35 #define REG_SC_GEN4            0x0148
36 
37 #define REG_SC_DDRT0            0x0090
38 #define NORMAL_BOOTMODE_OFFSET        9
39 #define NORMAL_BOOTMODE_MASK        3
40 
41 /********** Communication Register and flag used by bootrom *************/
42 #define REG_START_FLAG         (SYS_CTRL_REG_BASE + REG_SC_GEN1)
43 #define CONFIG_START_MAGIC     (0x444f574e)
44 
45 #ifdef __cplusplus
46 #if __cplusplus
47 }
48 #endif /* __cplusplus */
49 #endif /* __cplusplus */
50 
51 #endif
52 
53