blob: 09a6e4cc19a31cc3cbff45c6a600a0d07e5425fd [file] [log] [blame]
lh9ed821d2023-04-07 01:36:19 -07001/*******************************************************************************
2 * Copyright (C) 2016, ZXIC Corporation.
3 *
4 * File Name:
5 * File Mark:
6 * Description:
7 * Others:
8 * Version: v1.0
9 * Author: zhouqi
10 * Date: 2013-8-21
11 * History 1:
12 * Date:
13 * Version:
14 * Author:
15 * Modification:
16 * History 2:
17 ********************************************************************************/
18
19#ifndef _ZX297510_DDR_H_
20#define _ZX297510_DDR_H_
21
22
23//#define DDR_FFC
24typedef unsigned int UINT32;
25typedef unsigned char UINT8;
26#if 0
27/*ddr É豸¼Ä´æÆ÷½á¹¹Ìå*/
28struct ddr_device_para
29{
30 unsigned int reg_0x12030f4; /* ¼Ä´æÆ÷ 0x12030f4 */
31};
32#endif
33
34
35typedef enum
36{
37 DDR_156M = 0,
38 DDR_208M = 1,
39 DDR_312M = 2,
40 DDR_400M = 3,
41 DDR_CLKEND
42}T_zDrvPow_DDRCLK;
43
44
45/*DDR*/
46#define DDR_CTRL_BASE (0x00150000)
47#define DDR_PHY_BASE (0x00154000)
48#define DDR_FFC_ADDR_BASE (0x00155000)
49
50
51#define STD_CRM_REG_BASE (0x01306000)
52
53#define CRTL_PWRCTL (DDR_CTRL_BASE+0x030)
54
55/*DDR CTRL MP*/
56
57#define CTRL_STAT (DDR_CTRL_BASE+0x004)
58
59#define MOD_CLK_SEL (STD_CRM_REG_BASE+0x50)
60
61#define SELFREF_SW (5)
62
63#define CHIP_DDR_IS_32M 0
64#define CHIP_DDR_IS_64M 1
65#define CHIP_DDR_IS_128M 2
66#define CHIP_DDR_IS_256M 3
lh758261d2023-07-13 05:52:04 -070067#define CHIP_DDR_IS_512M 4
lh9ed821d2023-04-07 01:36:19 -070068
69
70int ddr_init(int flag);
71
72
73#endif/*_ZX297510_DDR_H_*/
74
75