blob: ae8ed035ef6ef6184bbcae7ddf395069de0eef37 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
/*
* Arm SCP/MCP Software
* Copyright (c) 2015-2020, Arm Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*
* Description:
* DDR-PHY500 driver
*/
#ifndef MOD_DDR_PHY500_H
#define MOD_DDR_PHY500_H
#include <stdbool.h>
#include <stdint.h>
#include <fwk_id.h>
#include <fwk_macros.h>
#include <fwk_module.h>
#include <mod_log.h>
/*!
* \addtogroup GroupModules Modules
* @{
*/
/*!
* \addtogroup GroupDDR DDR PHY500 Driver
* @{
*/
/*!
* \brief DDR PHY500 register definitions.
*/
struct mod_ddr_phy500_reg {
/*!
* \cond
* @{
*/
FWK_RW uint32_t INIT_COMPLETE;
FWK_RW uint32_t MEMORY_WIDTH;
FWK_RW uint32_t READ_DELAY;
FWK_RW uint32_t CAPTURE_MASK;
FWK_RW uint32_t CAS_LATENCY;
FWK_RW uint32_t T_CTRL_DELAY;
FWK_RW uint32_t T_WRLAT;
FWK_RW uint32_t T_RDDATA_EN;
FWK_RW uint32_t T_RDLAT;
FWK_RW uint32_t DFI_PHYUPD_REQ;
FWK_R uint32_t DFI_PHYUPD_ACK;
FWK_R uint32_t DFI_LP_REQ;
FWK_RW uint32_t DFI_LP_ACK;
FWK_RW uint32_t DFI_RDLVL_REQ;
FWK_R uint32_t DFI_RDLVL_EN;
FWK_RW uint32_t DFI_WRLVL_REQ;
FWK_R uint32_t DFI_WRLVL_EN;
FWK_RW uint32_t DFI_PHYMSTR_REQ;
FWK_RW uint32_t DFI_PHYMSTR_ACK;
FWK_RW uint32_t DFI_WR_PREMBL;
uint8_t RESERVED[0x820 - 0x50];
FWK_RW uint32_t DELAY_SEL;
FWK_RW uint32_t REF_EN;
FWK_RW uint32_t T_CTRL_UPD_MIN;
/*!
* \endcond
* @}
*/
};
/*!
* \brief Element configuration.
*/
struct mod_ddr_phy500_element_config {
/*! Base address of a device configuration register. */
uintptr_t ddr;
};
/*!
* \brief DDR PHY500 module configuration.
*/
struct mod_ddr_phy500_module_config {
/*!
* Pointer to a structure containing default values for a subset of the PHY's
* configuration registers. These values are common to all PHYs that are
* represented by elements in the module's element table.
*/
const struct mod_ddr_phy500_reg *ddr_reg_val;
/*!
* Indicate whether the \c INIT_COMPLETE register of the peripheral needs to
* be initialized.
*/
bool initialize_init_complete;
/*!
* Indicate whether the \c REF_EN register of the peripheral needs to be
* initialized.
*/
bool initialize_ref_en;
};
/*!
* @}
*/
/*!
* @}
*/
#endif /* MOD_DDR_PHY500_H */
|