AMC Initialization Sequence
This file was created using the following files on: Wed May 20 18:14:26 2015
AMC Version: Major Release: Minor Release:
AMP Version: 3 Major Release: 1 Minor Release: 3
AMC UM Init sourced from: //depot/ip_lib/apple/amcc/a0.malta/amcc/tb/cfg/static/maqstb_cfg.pl#16
AMP UM Init sourced from: //depot/ip_lib/apple/amp/a0.malta/amp/tb/cfg/phy_helper_fxns.pl#5
Change Log
* ------------------------------------------------------------------
* Version:1 - Files Edited: all
* Initial fiji checkin
* ------------------------------------------------------------------
* Version:6 - herb - Files Edited: maqstb_cfg.pl#8 -
* changes for updated amph V0013 and mcu init gen flow.
* ------------------------------------------------------------------
* Version:7 - rishah - Files Edited: maqs_gen_cfg.pl#7 - maqstb_cfg.pl#13 -
* Ported over changes from Maui B0 related to INIT Sequence.
* ------------------------------------------------------------------
* Version:8 - rishah - Files Edited: phy_helper_fxns.pl#15 -
* Updated MCU init sequence.
* ------------------------------------------------------------------
* Version:9 - cpolapra - Files Edited: maqs_gen_cfg_c.pl#6 -
* Ported over init and calibration changes from Maui A0/B0 and Elba
* ------------------------------------------------------------------
* Version:10 - rishah - Files Edited: phy_helper_fxns.pl#16 -
* Init sequence update for VrefSel for SW Calib.
* ------------------------------------------------------------------
0. AMC Prolog
Program SPLL registers
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Call custom API provided in mcu_helper_fxns.c for setting PLL3 frequency to 99Mhz. This call is only applicable to Cold boot.
FPGA: Skip this step
|
|
- | - | - |
|
Call custom API provided in mcu_helper_fxns.c for setting PLL3 frequency to 99Mhz. This call is only applicable to Cold boot.
FPGA: Skip this step
|
|
- | - | - |
1. AMC Initial Configuration
Perform the proper configurations of the AMC. Note that all the timing parameters should be programmed with respect to the normal clock, not the slow boot clock.
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
Setting up MCU registers and FSP for Freq change
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Configure DRAM timing parameters for default frequencyset. Example here shows LPDDR4-2667 8Gb DRAM die. See Section 3.2.2.4 for other value. Configure the PHY timing. These are determined by the design of the PHY and the interface between the PHY and AMC. |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Configure DRAM timing parameters for alternative frequency points. For the dynamic frequency change support, all frequency sets should be programmed. See Section 3.2.2.3 for details. The actual values should correspond to the desired frequency points and the actual device specifications. (N=1/2/3) *since mcu_clk freq1 = 200MHz and per-bank refresh is not enabled, mcusch.mifcassch_freq1. HiTempRefRnkAgeOut_freq1 =0x0 |
|
- | - | - |
|
|
- | - | - |
|
**IMPORTANT** : For power saving on SOC's using Samsung and Hynix DRAM's, it's mandatory to set autoref_freq1 to 0x1C480050. For SOC's using Micron DRAM, autoref_freq1 should be set to 0x20480050. |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Process act_freq3 for all platforms |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Turn off optional power- savingfeatures. This includes dynamic power down, auto self-refresh entry, and clock stopping. |
|
- | - | - |
|
Turn off optional power- savingfeatures. This includes dynamic power down, auto self-refresh entry, and clock stopping. |
|
- | - | - |
|
Turn off transaction scheduling for non- initialization commands |
|
- | - | - |
|
|
- | - | - |
|
Program AMC to - wait tXP+2tCK after actual clock changes before valid command - wait 2 cycles after all timing parameter are satisfied before actual clock change - wait indefinitely for AMP to complete handshake. |
|
- | - | - |
2. AMP Initial Configurations
Perform the proper configurations of the AMP. There are two separate AMP register blocks; the code below must be repeated on both AMP0 and AMP1. (N=0..1)
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Assert AMP enable |
|
- | - | - |
|
Assert AMP enable |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
ODTEnable_f0 |
|
- | - | - |
|
ODTEnable_f1 |
|
- | - | - |
|
ODTEnable_f3 |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
**IMPORTANT** : For power saving on SOC's these setings are mandatory. With Samsung DRAM, VRef_f1 should be set to 0x00F000F0. With Micron DRAM, VRef_f1 should be set to 0x00EE00EE. With Hynix DRAM, VRef_f1 should be set to 0x00E900E9. |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Poll ampsdqsdllctrl rd0sdllctrl |
|
- | - | - |
|
|
- | - | - |
|
Poll ampsdqsdllctrl WrDqDqsSDLLCtrl |
|
- | - | - |
|
|
- | - | - |
|
Poll ampscawrlvl ampcawrlvlsdllcode |
|
- | - | - |
|
Program DLL Init and Incr lock timers based on 24 MHz value
FPGA: Skip this step |
|
- | - | - |
|
Program DLL Init and Incr lock timers based on 24 MHz value
FPGA: Skip this step |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program capture latency and recapture latency |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program capture latency and recapture latency |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program capture latency and recapture latency |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program DLL scaling factors (assuming freq0/1/2/3 = 522/400/200/50MHz, FMCLK=522 MHz) |
|
- | - | - |
|
Program capture latency and recapture latency |
|
- | - | - |
|
Updating the programming of DLL*UpdtDur Fields
FPGA: Skip this step |
|
- | - | - |
|
Updating the programming of DLL*UpdtDur Fields
FPGA: Skip this step |
|
- | - | - |
|
FPGA: Skip this step |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Enable DLL |
|
- | - | - |
|
Enable DLL |
|
- | - | - |
|
Run impedance calibration and optionally enable periodic auto impedance calibration
FPGA: Skip this step |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Assert init_done |
|
- | - | - |
|
Assert init_done |
|
- | - | - |
3. Self-Refresh Exit
Prior to this step, the DRAM is assumed to be in the self-refresh state, and CKE has been kept low, either by retention circuitry in the PHY/IO, or, after SOC power is up and the reset is done, by the controller. This step will take DRAM out of the self-refresh mode. Software must guarantee that at least 50 us have passed since the de- assertion of AMC reset before self-refresh exit, in the resume-boot case.
The frequency change to 50MHz here is initiated by PMGR.
For ResumeBoot, the auto-refresh must be enabled before exiting self-refresh state.
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Wait 5us after Impedance Calibration in Step2. This is to avoid McPhyPending preventing the SRFSM from exiting SR. |
|
- | - | - |
|
radar #8707478 has been fixed. SetSRExitRefCnt to 2. |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
**IMPORTANT** : For power saving on SOC's using Samsung and Hynix DRAM's, it's mandatory to set autoref_freq1 to 0x1C480049. For SOC's using Micron DRAM, autoref_freq1 should be set to 0x20480049. |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
Enable auto refresh derating by setting TempDrtEn to 1. However, we do not enable ODTS interval until the end of the init. Setting TempDrtEn to 1 allows the chip to be in the hi-temp state and become more conservative. |
|
- | - | - |
|
set SRExtraRefCnt to correct value (which is 1) and set LongSRCnt to be tREFW/4 (32ms/4=8ms) If RefCntrHiWaterMark is changed from its default value, then LongSRExitRefCnt needs to be programmed to the same value. Palladium: LongSRCnt=0x1004 because Palladium uses 1Gb device. |
|
- | - | - |
|
|
- | - | - |
|
Call custom API provided by PMGR for changing mcu_clk to 55Mhz and mcu_fixed_clk to Mhz // TO BE COMPLETED
FPGA: Skip this step
|
|
- | - | - |
|
Wait 5us to avoid a race condition between frequency change to bucket 3 & MCU being enabled |
|
- | - | - |
|
Turn on enables for various AMC blocks MCU. |
|
- | - | - |
|
Run impedance calibration and optionally enable periodic auto impedance calibration
FPGA: Skip this step |
|
- | - | - |
|
Poll ampscaiocfg impcalcmd
FPGA: Skip this step |
|
- | - | - |
|
|
- | Yes | - |
|
|
- | Yes | - |
|
|
- | Yes | - |
|
Turn on auto refresh. |
|
- | Yes | - |
|
Wait 200us for tINIT1 in real init, which we have cooked down to 200ns for simulation. |
|
- | - | - |
|
Wait 2 ms for tINIT3 in real init, which we have cooked down to 200ns for simulation. |
|
- | - | - |
|
|
- | - | - |
|
Poll dramcfg freqchngctl |
|
- | - | - |
|
|
- | - | - |
|
Wait 2us for the soc update to finish |
|
- | - | - |
|
Assert MPC to Sending SR Exit during Resume Boot |
|
- | Yes | - |
|
Issue self-refresh exit command. One for each channel. SW needs to guarantee that at least 50usec has passed since removal of reset to AMC before issuing the self-refresh exit command, in case of resume boot. |
|
- | Yes | - |
|
Poll dramcmd mrinitcmd |
|
- | Yes | - |
|
Assert MPC to Sending SR Exit during Resume Boot |
|
- | No | - |
|
Issue self-refresh exit command. One for each channel. SW needs to guarantee that at least 50usec has passed since removal of reset to AMC before issuing the self-refresh exit command, in case of resume boot. |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Wait 2 us for tINIT5 in real init, which we have cooked down to 200ns for simulation. |
|
- | - | - |
|
|
- | - | - |
4. DRAM Reset, ZQ Calibration & Configuration (Cold Boot Only).
This step is only required for ColdBoot.
This step is to be repeated for each of the number of ranks per channel. The dramcmd.mrcmdch{N}.MRCmdCsCh{N} bit (Noted by letter R in the section) should be incremented in each loop.
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Issue DRAM ZQ calibration START MPC command MRINIT CMD registers. Note that the MPC command can be issued to different channels independently, as long as the system has separate ZQ reference resistor for eachchannel. TheZQcalibration MPC to each rank within the same channel must be issued in series. |
|
- | - | - |
|
Poll dramcmd mrinitcmd |
|
- | - | - |
|
Wait 1us for tZQCAL. |
|
- | - | - |
|
Issue DRAM ZQ calibration LATCH MPC command MRINIT CMD registers |
|
- | - | - |
|
Poll dramcmd mrinitcmd |
|
- | - | - |
|
Wait 20ns for tZQLAT. |
|
- | - | - |
|
Configure DRAM MR2 register (latency) through MRR/MRW command registers. The example shows the nominal programming for LPDDR2-1066 devices based on the JEDEC specifications. See Section 3.2.2.3 for values for other devices. |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Configure DRAM MR1 register through MRR/MRW command registers. This includes the following: WC=Wrap BT=Sequential BL=BL16. nWR, the example shows the nominal programming for LPDDR3- 1600 devices based on the JEDEC specifications. See Section 3.2.2.3 for values for other devices. |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
Program MR11 for FPGA
FPGA: Perform this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Perform this step |
|
- | No | - |
|
Program VRCG and Modified Refresh to 1 |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Program MR15/20 to match PatInvertMask of HW RdDQ calibration |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Program MR15/20 to match PatInvertMask of HW RdDQ calibration |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Program MR32/40 to match the PatPRBS4 pattern for HW RdDQ calibration |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Program MR32/40 to match the PatPRBS4 pattern for HW RdDQ calibration |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
5. Topology-specific configuration.
Here we perform MRR's to the memory to find out device density and program addrcfg, DramAccCtrl and mccchnldec registers
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
|
- | - | - |
|
|
- | - | - |
|
dram_Density_config(); |
|
- | - | - |
|
|
- | - | - |
6. Prepare for switch from boot-clock speed to normal operation speed
The frequency change is initiated by PMGR.
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Wait 5us before issuing a freq change to make sure all refreshes have been flushed. |
|
- | - | - |
|
Enable AMC scheduler to allow normal transactions to be processed. Scheduler has to be enabled to let AMC issue self-refresh entry and allow frequency change. |
|
- | - | - |
7. Setup registers for CA calibration for bucket 1
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Program FSP-WR to 1, and set VRCG and modified refresh
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
Configure DRAM MR2 register (latency) through MRR/MRW command registers. The example shows the nominal programming for LPDDR2-1066 devices based on the JEDEC specifications. See Section 3.2.2.3 for values for other devices.
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
Configure DRAM MR1 register through MRR/MRW command registers. This includes the following: WC=Wrap BT=Sequential BL=BL16. nWR, the example shows the nominal programming for LPDDR3- 1600 devices based on the JEDEC specifications. See Section 3.2.2.3 for values for other devices.
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll ampscawrlvl ampcawrlvlsdllcode
FPGA: Skip this step |
|
- | No | - |
8. AMP Dynamic Address Timing Calibration
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
step8Calibration(0, LPDDR3, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, CA_CALIB, 0, 0, 0, 0, 0, 0, 1, 16, 12); |
|
- | - | - |
|
Program DLL Init and Incr lock timers based on 24 MHz value
FPGA: Skip this step |
|
Yes | Yes | - |
|
Program DLL Init and Incr lock timers based on 24 MHz value
FPGA: Skip this step |
|
Yes | Yes | - |
|
Disable AMP Clock Gating for RunDllUpdt to go through
FPGA: Skip this step |
|
Yes | Yes | - |
|
Defer SDLL update until frequency change
FPGA: Skip this step |
|
Yes | Yes | - |
|
Defer SDLL update until frequency change
FPGA: Skip this step |
|
Yes | Yes | - |
|
Set MDLL override to 0
FPGA: Skip this step |
|
Yes | Yes | - |
|
Run MDLL update
FPGA: Skip this step |
|
Yes | Yes | - |
|
Poll ampsdqdllctl dllupdtcmd
FPGA: Skip this step |
|
Yes | Yes | - |
|
Enable back AMP Clock Gating for RunDllUpdt to go through
FPGA: Skip this step |
|
Yes | Yes | - |
|
Program DLL Init and Incr lock timers based on 24 MHz value
FPGA: Skip this step |
|
Yes | Yes | - |
|
Program DLL Init and Incr lock timers based on 24 MHz value
FPGA: Skip this step |
|
Yes | Yes | - |
|
RdWrDqCalSegLen_f0
PALLADIUM: Skip this step
FPGA: Skip this step |
|
Yes | Yes | - |
|
RdWrDqCalSegLen_f1
PALLADIUM: Skip this step
FPGA: Skip this step |
|
Yes | Yes | - |
|
FPGA: Skip this step |
|
Yes | Yes | - |
|
HWRdWrDqCalFullScanEnable
PALLADIUM: Skip this step
FPGA: Skip this step |
|
Yes | Yes | - |
9. Setup registers for DQ calibration for bucket 1
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Program FSP-WR and FSP-OP to 1 and set VRCG and modified refresh
FPGA: Skip this step |
|
Yes | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
Yes | No | - |
|
Wait 1us for FSP setting to take affect. |
|
- | - | - |
|
Program AutoSR
FPGA: Skip this step |
|
- | Yes | - |
|
Program FreqChngMRW Cnt
FPGA: Skip this step |
|
Yes | Yes | - |
|
WrDqDqsSDLLCtrl
FPGA: Skip this step |
|
Yes | Yes | - |
|
Re-enable SDLL updates
FPGA: Skip this step |
|
Yes | Yes | - |
|
Re-enable SDLL updates
FPGA: Skip this step |
|
Yes | Yes | - |
|
Disable MDLL override
FPGA: Skip this step |
|
Yes | Yes | - |
|
Call custom API provided by PMGR for changing mcu_clk to 800Mhz and mcu_fixed_clk to Mhz // TO BE COMPLETED
FPGA: Skip this step
|
|
- | - | - |
|
|
- | - | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcfg freqchngctl
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Wait 2us for the soc update to finish |
|
- | - | - |
10. AMP Dynamic DQ Calibration
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
step10Calibration(0, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, WRLVL, 0, 0, 0, 0, 1, 16, 12); |
|
- | - | - |
|
FPGA: Skip this step |
|
- | - | - |
|
FPGA: Skip this step |
|
- | - | - |
|
step10Calibration(0, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, RD_DQ_CAL, 0, 0, 0, 0, 1, 16, 12); |
|
- | - | - |
|
step10Calibration(0, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, WR_DQ_CAL, 0, 0, 0, 0, 1, 16, 12); |
|
- | - | - |
|
The scale factors for Bin0 and Bin1 WR DQS/DQ skew have to to programmed to the correct values based on board charaterization. Fields are being set to 0 here, since exact board skews are not available now (04/01/14).
FPGA: Skip this step |
|
- | - | - |
11. Setup registers for CA calibration for bucket 0
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Program FSP-WR to 0 and FSP-OP to 1 and set VRCG and modified refresh
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
Configure DRAM MR2 register (latency) through MRR/MRW command registers. The example shows the nominal programming for LPDDR2-1066 devices based on the JEDEC specifications. See Section 3.2.2.3 for values for other devices.
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
Configure DRAM MR1 register through MRR/MRW command registers. This includes the following: WC=Wrap BT=Sequential BL=BL16. nWR, the example shows the nominal programming for LPDDR3- 1600 devices based on the JEDEC specifications. See Section 3.2.2.3 for values for other devices.
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
12. AMP Dynamic Address Timing Calibration
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
step12Calibration(0, LPDDR3, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, CA_CALIB, 0, 0, 0, 0, 0, 0, 0, 24, 12); |
|
- | - | - |
13. Setup registers for DQ calibration for bucket 0
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Program FSP-WR and FSP-OP to 0 and set VRCG and modified refresh
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcmd mrinitcmd
FPGA: Skip this step |
|
- | No | - |
|
Wait 1us for FSP setting to take affect. |
|
- | - | - |
|
Call custom API provided by PMGR for changing mcu_clk to 1200Mhz and mcu_fixed_clk to Mhz // TO BE COMPLETED
FPGA: Skip this step
|
|
- | - | - |
|
|
- | - | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Poll dramcfg freqchngctl
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
Wait 2us for the soc update to finish |
|
- | - | - |
14. AMP Dynamic DQ Calibration
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
step14Calibration(0, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, WRLVL, 0, 0, 0, 0, 0, 24, 12); |
|
- | - | - |
|
FPGA: Skip this step |
|
- | No | - |
|
FPGA: Skip this step |
|
- | No | - |
|
step14Calibration(0, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, RD_DQ_CAL, 0, 0, 0, 0, 0, 24, 12); |
|
- | - | - |
|
step14Calibration(0, resume_boot, AMC_NUM_CHANS, AMC_NUM_RANKS, WR_DQ_CAL, 0, 0, 0, 0, 0, 24, 12); |
|
- | - | - |
15. Setup registers for boot.
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Program FSP-WR to 1 and FSP-OP to 0 and reset VRCG, since all calibrations are done |
|
- | No | - |
|
Poll dramcmd mrinitcmd |
|
- | No | - |
|
Wait 1us for FSP setting to take affect. |
|
- | - | - |
|
Program FreqChngMRW Cnt |
|
- | No | - |
|
|
- | No | - |
|
DO_CALIBRATION: Skip this step |
|
- | No | - |
|
Poll ampsdqsdllctrl rd0sdllctrl
DO_CALIBRATION: Skip this step |
|
- | No | - |
|
PALLADIUM: Skip this step |
|
- | - | - |
|
PALLADIUM: Skip this step |
|
- | - | - |
16. Enable other features
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Turn on the freq change waiting for refresh and self-refresh exit feature |
|
- | - | - |
|
Enable periodic ZQC. (Optional) Note the ZqCalIntrvl setting shown here is based on tREFI=3.9us and the target interval is ~128ms (max supported value). The actual setting may vary depending on the DRAM and the system. |
|
- | - | - |
|
Turn on the QBR enables. |
|
- | - | - |
|
|
- | No | - |
|
|
- | No | - |
|
|
- | No | - |
|
Turn on auto refresh. |
|
- | No | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
17. Enable the Fast Critical Word Forwarding feature (optional)
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Configure the MIF FCWF pull- in cycles. (Here we just use 0x8 as an example, please refer to register description for the valid programming range and refer to performance simulation results) |
|
- | - | - |
|
Turn on the PredictiveM2AReq feature in MIF. (The other Qbr enables are turned on here, but not related to CWF feature) |
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
18. Enable Power & ClockGating features and Configure the MCC and Global Timer
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Enable AMPCA Fixed MCLK Clock Gating |
|
- | - | - |
|
Enable AMPDQ Fixed MCLK Clock Gating |
|
- | - | - |
|
disable dynamic power-down. |
|
- | - | - |
|
disable dynamic power-down. |
|
- | No | - |
|
Revert auto self-refresh wait timer to guided value.
FPGA: Skip this step |
|
- | - | - |
|
Setting WqAgeOutVal to be 3/4 of SelfRefTmrVal, to flush writes in a reasonable time.
FPGA: Skip this step |
|
- | - | - |
|
Enable wakeups from glbl timer to pmgr |
|
Yes | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
- | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
|
Yes | - | - |
|
Dynamic clk pwr gating reg |
|
- | - | - |
19. Do a ODTS read and set ODTS interval so MR4 on-die temperature sensor read occurs periodically.
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
Perform an MRR to DRAM mode register MR4 to establish a base value for ODTS reading. Another intention is to bring DRAM out of self-refresh. Done in both cold boot and resume boot. |
|
- | - | - |
|
Poll dramcmd mrinitcmd |
|
- | - | - |
|
Enable periodic ODTS and temperature based refresh rate modulation. (Optional) Note the OdtsRdIntrvl setting shown here is based on tREFI=3.9us and the target interval is ~100. The actual setting may vary depending on the DRAM and the system. Palladium: this step is skipped, ODTS is not supported
PALLADIUM: Skip this step |
|
- | - | - |
Mcc Cache Initialization. This section is not part of the essential init sequence. This should be run when the system is done using the CacheAsRam
Description | Register Programming | AOP AWAKE | Resume Boot | AOP DDR |
|
|
- | - | - |
|
Program AF Allocation Hints, allocation does not happen unless there is a hint as the generic allocation policy |
|
- | - | - |
|
Poll mcccfg MccPwrOnWayCntStatus |
|
- | - | - |
|
Maximum Number of Powered Ways. |
|
- | - | - |
|
Turn on the MCC |
|
- | - | - |
|
Set Dynamic Way PowerGating |
|
- | - | - |