9 * @xrefitem bom "File Content Label" "Release Content"
11 * @e sub-project: (Mem)
12 * @e \$Revision: 49896 $ @e \$Date: 2011-03-30 16:18:18 +0800 (Wed, 30 Mar 2011) $
15 /*****************************************************************************
17 * Copyright (c) 2011, Advanced Micro Devices, Inc.
18 * All rights reserved.
20 * Redistribution and use in source and binary forms, with or without
21 * modification, are permitted provided that the following conditions are met:
22 * * Redistributions of source code must retain the above copyright
23 * notice, this list of conditions and the following disclaimer.
24 * * Redistributions in binary form must reproduce the above copyright
25 * notice, this list of conditions and the following disclaimer in the
26 * documentation and/or other materials provided with the distribution.
27 * * Neither the name of Advanced Micro Devices, Inc. nor the names of
28 * its contributors may be used to endorse or promote products derived
29 * from this software without specific prior written permission.
31 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
32 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
33 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
34 * DISCLAIMED. IN NO EVENT SHALL ADVANCED MICRO DEVICES, INC. BE LIABLE FOR ANY
35 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
36 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
37 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
38 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
39 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
40 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
41 * ***************************************************************************
48 /*----------------------------------------------------------------------------
49 * Mixed (DEFINITIONS AND MACROS / TYPEDEFS, STRUCTURES, ENUMS)
51 *----------------------------------------------------------------------------
54 /*-----------------------------------------------------------------------------
55 * DEFINITIONS AND MACROS
57 *-----------------------------------------------------------------------------
59 #define _4GB_RJ16 (((UINT32) 4) << (30 - 16))
60 #define _1TB_RJ16 (((UINT32) 1) << (40 - 16))
61 #define HT_REGION_BASE_RJ16 ((UINT32)0x00FD0000)
63 #define DCT_ACCESS_WRITE (UINT32) 0x40000000
65 #define THERMAL_OPT 31
68 #define DCT_PHY_ACCESS 1
71 #define DCT_PHY_DIRECT 0xF1
73 #define VT_MSK_VALUE 0
75 /*---------------------------------------------
76 * TSEFO - Type Start End Function Offset
78 * 31:30 Type of access (2-bits)
79 * 29:29 Special (1-bit)
80 * 28:28 Phy Direct (1-bit)
81 * 27:27 Whole Register Access (1-bit)
82 * 26:26 Linked (1-bit)
83 * 25:21 Start bit (5-bits)
84 * 20:16 End bit (5-bits)
85 * 15:00 Function_Offset/Index (16-bits)
86 *---------------------------------------------
91 MAKE_TSEFO(TableName, a, b, c, d, BitFieldIndex):
94 @param[in] BitFieldIndex
95 @param[in] a Type of access.
96 @param[in] b Index of register (can be in Function_Offset format).
97 @param[in] c Highest bit of the bit field.
98 @param[in] d Lowest bit of the bit field.
100 @return TSEFO Access params encrypted in TSEFO format.
102 #define MAKE_TSEFO(TableName, a, b, c, d, BitFieldIndex) \
103 TableName[BitFieldIndex] = ( \
104 (a == DCT_PHY_DIRECT) ? ( \
105 (((UINT32) DCT_PHY_ACCESS) << 30) | (((UINT32) 1) << 28) | (((UINT32) b) & 0xFFFF) | (\
106 ((c == 15) && (d == 0)) ? ( \
107 (((UINT32) 1) << 27) | (((UINT32) b) & 0xF0000) \
110 (((UINT32) c) << 21) | (((UINT32) d) << 16) \
112 (((UINT32) d) << 21) | (((UINT32) c) << 16) \
117 (((UINT32) a) << 30) | (((UINT32) b) & 0xFFFFFFF) | ( \
118 (((UINT32) b) >> 16) ? ( \
119 (((UINT32) 1) << 29) \
122 (((UINT32) c) << 21) | (((UINT32) d) << 16) \
124 (((UINT32) d) << 21) | (((UINT32) c) << 16) \
132 LINK_TSEFO(TableName, LowerBitFieldIndex, HigherBitFieldIndex):
133 This is one way link: any write to LowerBitFieldIndex would write to HigherBitFieldIndex,
134 but NOT the other way around.
135 Requirement: LowerBitFieldIndex must be declared *right* before HigherBitFieldIndex.
138 @param[in] LowerBitFieldIndex
139 @param[in] HigherBitFieldIndex
141 @return TSEFO Access params encrypted in TSEFO format.
143 #define LINK_TSEFO(TableName, LowerBitFieldIndex, HigherBitFieldIndex) { \
144 ASSERT (LowerBitFieldIndex == (HigherBitFieldIndex - 1)) ; \
145 TableName[LowerBitFieldIndex] = TableName[LowerBitFieldIndex] | (((UINT32) 1) << 26); \
148 // Indicate when a bitfield has multiple memory Pstate copy
149 #define MULTI_MPSTATE_COPY_TSEFO(TableName, BitFieldName) \
150 TableName[BitFieldName] = TableName[BitFieldName] | (((UINT32) 1) << 29)
152 #define TSEFO_TYPE(x) ((UINT8) (((UINT32) (x) >> 30) & 0x03))
153 #define TSEFO_START(x) ((UINT8) (((UINT32) (x) >> 21) & 0x1F))
154 #define TSEFO_END(x) ((UINT8) (((UINT32) (x) >> 16) & 0x1F))
155 #define TSEFO_OFFSET(x) ((UINT32) (x) & 0xFFFF)
156 #define TSEFO_LINKED(x) ((UINT8) (((UINT32) (x) >> 26) & 0x01))
157 #define TSEFO_DIRECT_EN(x) ((UINT8) (((UINT32) (x) >> 28) & 0x01))
158 #define TSEFO_WHOLE_REG_ACCESS(x) ((UINT8) (((UINT32) (x) >> 27) & 0x01))
159 #define _FN(x, y) (((UINT32) (x) << 12) + (UINT32) (y))
160 #define TSEFO_MULTI_MPSTATE_COPY(x) ((UINT8) (((UINT32) (x) >> 29) & 1))
174 #define DDR2_TRAIN_FLOW 0
175 #define DDR3_TRAIN_FLOW 1
178 // Minimum Data Eye width in consecutive 32nds of a UI of
181 #define MIN_RD_DATAEYE_WIDTH_NB 4
182 #define MIN_WR_DATAEYE_WIDTH_NB 4
185 // RELIABLE READ/WRITE MODE DEFINITIONS
187 #define PRECHARGE_ALL_BANKS 0xFF ///< Use to specify PrechargeAll Command to Precharge Cmd Function
188 #define CMD_TGT_A 0x00 ///< Issue Commands to Command Target A
189 #define CMD_TGT_AB 0x01 ///< Issue Commands to Command Targets A and B
190 #define CMD_TYPE_READ 0x00 ///< Read Command
191 #define CMD_TYPE_WRITE 0x01 ///< Write Command
192 #define CMD_TYPE_WR_RD 0x02 ///< Alternating Write and Read Commands
193 #define CPG_BANK_ADDRESS_A 0x0 ///< Dimm Bank address used in Reliable RD/RW mode training
194 #define CPG_BANK_ADDRESS_B 0x1 ///< Dimm Bank address used in Reliable RD/RW mode training
195 #define CPG_ROW_ADDRESS_A 0x0 ///< Dimm Row address used in Reliable RD/RW mode training
196 #define CPG_ROW_ADDRESS_B 0x0 ///< Dimm Row address used in Reliable RD/RW mode training
197 #define CPG_COL_ADDRESS_A 0x0 ///< Dimm Column address used in Reliable RD/RW mode training
198 #define CPG_COL_ADDRESS_B 0x0 ///< Dimm Column address used in Reliable RD/RW mode training
199 #define CPG_COMPARE_MASK_LOW 0x00000000 ///< Dram DQMask[31:0] used to mask comparison on reads. 1=ignore
200 #define CPG_COMPARE_MASK_HI 0x00000000 ///< Dram DQMask[63:32] used to mask comparison on reads. 1=ignore
201 #define CPG_COMPARE_MASK_ECC 0x00 ///< Dram EccMask used to mask comparison on reads. 1=ignore
202 #define PRBS_SEED_32 0x062221 ///< Data PRBS Seed
203 #define PRBS_SEED_64 0x066665 ///< Data PRBS Seed
204 #define PRBS_SEED_128 0x026666 ///< Data PRBS Seed
205 #define PRBS_SEED_256 0x044443 ///< Data PRBS Seed
208 /*----------------------------------------------------------------------------
209 * TYPEDEFS, STRUCTURES, ENUMS
211 *----------------------------------------------------------------------------
214 /// Structure for Reliable Read/Write Mode Data
215 /// These are values that may need to be referenced by the low level functions
216 /// during training and are initialized at the begining of a particular type of training.
217 typedef struct _RRW_SETTINGS {
218 UINT8 CmdTgt; ///< Value to program into CmdTgt
219 UINT8 TgtBankAddressA; ///< Target A Bank address
220 UINT32 TgtRowAddressA; ///< Target A Row address
221 UINT32 TgtColAddressA; ///< Target A Column address
222 UINT8 TgtBankAddressB; ///< Target B Bank address
223 UINT32 TgtRowAddressB; ///< Target B Row address
224 UINT32 TgtColAddressB; ///< Target B Column address
225 UINT32 CompareMaskLow; ///< Compare Mask Bits 31:0
226 UINT32 CompareMaskHigh; ///< Compare Mask Bits 63:32
227 UINT8 CompareMaskEcc; ///< Compare Mask Ecc
228 UINT32 DataPrbsSeed; ///< PRBS Seed value
231 /// DQS training related delays
233 AccessRcvEnDly, ///< Receiver enable delay
234 AccessWrDatDly, ///< Write data delay
235 AccessRdDqsDly, ///< Read DQS delay
236 AccessWrDqsDly, ///< Write DQS delay
237 AccessPhRecDly ///< Phase recovery delay
240 /// Training patterns for position training
242 POS_PATTERN_72B, ///< 72 bit pattern
243 POS_PATTERN_256B, ///< 256 bit pattern
244 } POS_TRN_PATTERN_TYPE;
248 MISSION_MODE, ///< ODT during mission mode
249 WRITE_LEVELING_MODE ///< ODT during write leveling
253 * DRBN - Dimm-Rank-Byte-Nibble
255 * 11:09 Dimm (3-bits)
258 * 04:01 Byte (4-bits)
262 #define MAKE_DRBN(dimm, rank, byte, nibble) ((((UINT32) (dimm)) << 9) | (((UINT32) (rank)) << 8) | \
263 (((UINT32) (byte)) << 1) | ((UINT32) (nibble)) )
264 #define DIMM_BYTE_ACCESS(dimm, byte) ((((UINT32) (dimm)) << 9) | (((UINT32) (byte)) << 1))
265 #define CS_NBBL_ACCESS(cs, nibble) ((((UINT32) (cs)) << 8) | ((UINT32) (nibble)))
266 #define DRBN_DIMM(x) ((UINT8) (((UINT32) (x) >> 9) & 0x07))
267 #define DRBN_RANK(x) ((UINT8) (((UINT32) (x) >> 8) & 0x01))
268 #define DRBN_BYTE(x) ((UINT8) (((UINT32) (x) >> 1) & 0x0F))
269 #define DRBN_NBBL(x) ((UINT8) (((UINT32) (x)) & 0x01))
279 #define DT_ANY_X4 0x71
280 #define DT_ANY_X8 0x72
281 #define DT_ANY_X16 0x74
282 #define DT_ANY_SR 0x17
283 #define DT_ANY_DR 0x27
284 #define DT_ANY_QR 0x47
285 #define DT_ANY_SR_DR (DT_ANY_SR | DT_ANY_DR)
286 #define DT_ANY (DT_ANY_SR | DT_ANY_DR | DT_ANY_QR)
288 /// Delay Scaling Info Struct - Describes number of delay increments per UI of a delay type
290 typedef struct _TRN_DLY_PARMS {
291 UINT8 Min; ///< Minimum Value
292 UINT8 Max; ///< Maximum Value
293 UINT8 Mask; ///< Mask to be applied (i.e. 0xFF if adjustable by one, 0xFE if adjustable by 2, etc.)
296 /// Structure for certain data saving needed for DCT.
298 UINT8 RcvEnDlyCounts[8]; ///< DQS Receiver Enable Delay counts
299 UINT32 PhRecReg[3]; ///< 3 Phase recovery control registers
302 /// Structure for table driven support.
303 typedef struct _MEM_TBL_ALIAS {
304 UINT8 time; ///< Modification time.
305 UINT8 node:4; ///< Node on which to make modification.
306 UINT8 dct:4; ///< DCT on which to make modification.
307 UINT8 dimm:4; ///< Dimm on which to make modification.
308 UINT8 attr:3; ///< Attribute of modification.
309 UINT8 vtype:1; ///< Flag indicating value type.
310 UINT32 bfindex; ///< Bit field index that need to be modified.
311 union { ///< Union is defined to easy select between single and multiple bytelane cases.
312 struct { ///< Sub-struct used for one bytelane value.
313 UINT16 bytelane:16; ///< Bytelane on which to make modification.
314 UINT32 value; ///< Modified value.
315 UINT8 reserved[3]; ///< Reserved for this purpose
316 } s; ///< single value to one or multiple bytelanes
317 UINT8 bytelanevalue[9]; ///< Array to specify individual bytelane values
321 /// Structure for Platform Specific Block.
322 typedef struct _MEM_PS_BLOCK {
323 UINT8 DramTerm; ///< Dram Term
324 UINT8 QR_DramTerm; ///< Dram Term for QR
325 UINT8 DynamicDramTerm; ///< Dynamic Dram Term
326 UINT8 NumOfReg[MAX_DIMMS_PER_CHANNEL]; ///< Number of registers on each RDIMM (From SPD)
327 UINT8 MR0WR; ///< MR0WR
328 UINT8 MR0CL31; ///< MR0[CL][3:1]
329 UINT8 MR0CL0; ///< MR0CL[0]
330 UINT8 RttNom[8]; ///< RttNom value for maximum 8 chipsels per channel
331 UINT8 RttWr[8]; ///< RttWr value for maximum 8 chipsels per channel
332 UINT8 F0RC8; ///< F0RC8
333 UINT8 F1RC0; ///< F1RC0
334 UINT8 F1RC1; ///< F1RC1
335 UINT8 F1RC2; ///< F1RC2
336 UINT8 RC10OpSpd; ///< RC10[OperatingSpeed]
337 UINT8 LrdimmRowAddrBits[MAX_DIMMS_PER_CHANNEL]; ///< Effective Row address bits used by LRDIMMS
338 /* PUBLIC functions */
339 BOOLEAN (*MemPDoPs) (struct _MEM_NB_BLOCK *NBPtr); ///< Function that gets Form factor info.
340 VOID (*MemPGetPORFreqLimit) (struct _MEM_NB_BLOCK *NBPtr); ///< Function that gets the speed limit of a dimm population.
343 /// Structure parameters needed in frequency change of client NB.
344 typedef struct _MEM_FREQ_CHANGE_PARAM {
345 UINT16 PllLockTimeDefault; ///< Default PllLockTime
346 UINT8 RdPtrInit667orHigher; ///< RdPtrInit for frequency 667MHz and higher
347 UINT8 RdPtrInitLower667; ///< RdPtrInit for frequency lower than 667MHz
348 UINT8 NclkPeriodMul2x; ///< Multiplier for NclkPeriod in parial sum calculation x 2
349 UINT8 MemClkPeriodMul2x; ///< Multiplier for MemClkPeriod in parial sum calculation x 2
350 UINT8 SyncTimeMul4x; ///< Multiplier for SyncTime
351 UINT16 TDataProp800orHigher; ///< TDataProp for frequency 800MHz or higher
352 UINT16 TDataPropLower800; ///< TDataProp for frequency lower than 800MHz
353 } MEM_FREQ_CHANGE_PARAM;
355 /// List for NB items that are supported
357 SetSpareEn, ///< Sets spare enable
358 CheckSpareEn, ///< Spare enabled
359 SetDllShutDown, ///< Sets DllShutDown
360 CheckEccDLLPwrDnConfig, ///< Checks to determine if EccDLLPwrDnConf needs to be adjusted
361 DimmBasedOnSpeed, ///< Checks to determine if Dimm number needs to be adjusted based on speed
362 CheckMaxDramRate, ///< Checks to determine the maximum rate
363 Check1GAlign, ///< Checks to determine if 1 GB alignment is supported
364 DramModeBeforeDimmPres, ///< Check to determine if DRAM mode needs to be set before dimm presence
365 DramModeAfterDimmPres, ///< Check to determine if DRAM mode needs to be set after dimm presence
366 CheckClearOnDimmMirror, ///< Check to determine if we need to clear on DIMM mirror
367 CheckDisDllShutdownSR, ///< Check to determine if DisDllShutdown needs to be set
368 CheckMemClkCSPresent, ///< Check to determine if chipselect needs to be set based on disabled memclocks
369 CheckChangeAvgValue, ///< Check to determine if we need to change average value
370 CheckMaxRdDqsDlyPtr, ///< Check to determine change Max Rd Dqs Delay
371 CheckPhyFenceTraining, ///< Check to determine if we need to Phy Fence training
372 CheckGetMCTSysAddr, ///< Check to determine if we need to GetMCTSysAddr
373 CheckSendAllMRCmds, ///< Check to determine if we need to SendAllMRCmds
374 CheckFindPSOverideWithSocket, ///< Check to determine if we need to Find PSOveride With Socket
375 CheckFindPSDct, ///< Check to determine if we need to Find PSOveride With DCT
376 CheckODTControls, ///< Check to determine if we need to set ODT controls
377 CheckDummyCLRead, ///< Check to determine if an extra dummy read is required
378 CheckDllStdBy, ///< Check to determine if setting DLL stand by is required
379 CheckSlewWithMarginImprv, ///< Check to determine if setting of Slew With MarginImprv is required
380 CheckSlewWithoutMarginImprv, ///< Check to determine if setting of Slew Without MarginImprv is required
381 CheckDllSpeedUp, ///< Check to determine if setting of Dll SpeedUp is required
382 CheckDllRegDis, ///< Check to determine if setting of DLL Regulator Disable is required
383 FenceTrnBeforeDramInit, ///< Check to determine if fence training has been done before Dram init
384 WLSeedAdjust, ///< Check to determine if WL seed needs to be adjusted
385 UnifiedNbFence, ///< Check to determine if Phy fence is of Unified NB
386 AdjustTwr, ///< Check to determine if Twr needs to be adjusted
387 ChannelPDMode, ///< Check to determine if channel power down mode is the only that is supported
388 ForceEnMemHoleRemapping, ///< Check to determine if we need to force enabling memory hole remapping
389 AdjustTrdrdSD, ///< Check to determine if we need to adjust TrdrdSD
390 ReverseMaxRdLatTrain, ///< Check to determine if reverse (pass to fail) algorithm is supported for MaxRdLat training
391 SkipErrTrain, ///< Check to determine if skip error training is supported
392 DramSrHys, ///< Check to determine if DRAM SR hysteresis is supported
393 PchgPDMode, ///< Check to determine if Precharge powerdown mode is supported
394 EccByteTraining, ///< Check to determine if DRAM ECC Byte training
395 CheckDrvImpCtrl, ///< Check to determine if we need to set DrvImpCtrl
396 CheckDramTerm, ///< Check to determine if we need to set DramTerm
397 CheckDramTermDyn, ///< Check to determine if we need to set DramTermDyn
398 CheckQoff, ///< Check to determine if we need to set Qoff
399 CheckSetSameDctODTsEn, ///< Check to defermine if we need to set "ODTsEn" the same on each DCT
400 WLNegativeDelay, ///< Check to determine if the NB can tolerate a negtive WL delay value
401 SchedDlySlot1Extra, ///< Check to determine if DataTxSchedDly Slot1 equation in slowMode to subtract an extra MEMCLK
402 TwoStageDramInit, ///< Check to determine if we need to seperate Draminit into 2 stages. The first one processes info on all nodes. The second one does Dram Init.
403 ExtraPclkInMaxRdLat, ///< Check to determine if an extra PCLK is needed for MaxRdLat
404 CsrPhyPllPdEn, ///< Check to determine if CSR Phy PLL Powerdown is enabled or not
405 AdjustTrc, ///< Check to determine if we need to adjust Trc
406 ProgramCsrComparator, ///< Check to determine if we need to program CsrComparator with the same value as D18F2x09C_x0D0F_0[7:0]1F[RxVioLvl]
407 EnProcOdtAdvForUDIMM, ///< Check to determine if we need to always enable ProcOdtAdv for UDIMM
408 SetTDqsForx8DimmOnly, ///< Only set MR1[TDQS] for x8 DIMMs when x4 and x8 DIMMs are both present on a channel
409 WlRttNomFor1of3Cfg, ///< Set Rtt_Nom = Rtt_Wr in one of three DIMMs per channel configurations
410 PerformanceOnly, ///< Only support performance policy, does not support battery life policy
412 EnumSize ///< Size of list
415 /// List for family specific functions that are supported
417 BeforePhyFenceTraining, ///< Family specific tasks before Phy Fence Training
418 BeforeMemClkFreqVal, ///< hook before setting MemClkFreqVal bit
419 AfterMemClkFreqVal, ///< Override PllMult and PllDiv
420 OverridePllMult, ///< Override PllMult
421 OverridePllDiv, ///< Override PllDiv
422 BeforeMemClr, ///< Before MemClr
423 SendMrsCmdsPerCs, ///< Send MRS commands per CS
424 SetupHwTrainingEngine, ///< Setup Hardware training engine for specific training type
425 OverrideRcvEnSeed, ///< Override seed for hardware based RcvEn training
426 AddlMaxRdLatTrain, ///< Perform additional MaxRdLat training if needed
427 ForceAutoComp, ///< Force Auto Comp
428 DetectMemPllError, ///< Detect MemPll Divide by 3 bug
429 ReEnablePhyComp, ///< Re-Enable Phy Compensation after RcvEn Training
430 ExtractWLODT, ///< Extract WL ODT value thr given ODT pattern
431 DCTSelectSwitch, ///< Select DCT when we switch DCT
432 ScrubberErratum, ///< Erratum for setting scrubber rate
433 MR0_PPD, ///< Override MR0[PPD]
434 GetDdrMaxRate, ///< Interpret DdrMaxRate with Familiy-specific encoding
435 ExitPhyAssistedTraining, ///< Perform family specific tasks when exiting phy assisted training
436 AfterSaveRestore, ///< Action after save/restore execution
437 OverrideDataTxFifoWrDly, ///< Override DataTxFifoWrDly based on training result of WrDatDly
438 OverrideRcvEnSeedPassN, ///< Override seed for hardware based RcvEn training where N greater than 0
439 AfterMemClkFreqChg, ///< Reprogram DIMMs' buffers after MEMCLK frequency change
440 AdjustTxpdll, ///< Adjust Txpdll value to encoded register value
441 CalcWrDqDqsEarly, ///< Calculate WrDqDqsEarly
442 TrainWlPerNibble, ///< Train Write Leveling per nibble
443 TrainWlPerNibbleAdjustWLDly, ///< Train WL per nibble and adjust the WL delay
444 TrainWlPerNibbleSeed, ///< Save the seed for WL nibble based training
445 TrainRxEnPerNibble, ///< Train Rx Enable Training per nibble
446 TrainRxEnAdjustDlyPerNibble, ///< Train Rx Enable Training nibble and adjust the RxEn delay
447 TrainRxEnGetAvgDlyPerNibble, ///< Display Rx Enable Training average nibble value for each BL
448 InitPerNibbleTrn, ///< Initiates Per Nibble Training.
449 BeforeSetCsTri, ///< Modify CS tri-state bit map.
450 ForceRdDqsPhaseB, ///< Force RdDqsDly to phase B
451 SetDqsODT, ///< Set DQS ODT
452 DisLowPwrDrvStr, ///< Hook to skip setting LowPowerDriveStrengthEn
453 AdjustRdDqsDlyOffset, ///< Adjust the bit offset of the RdDqsDly Bit Bitfield before writing and after reading
454 ResetRxFifoPtr, ///< Reset RxFifo pointer during Read DQS training
455 EnableParityAfterMemRst, ///< Enable DRAM Address Parity after memory reset.
456 FinalizeVDDIO, ///< Finalize VDDIO
457 TrainingNibbleZero, ///< Check for see Nibble zero is being trained (individually or with x8 training)
458 CalRdOdtTrnOnDlyLrDimm, ///< Calculate RdOdtTrnOnDly for LrDimm
459 SetSkewMemClk, ///< Set SkewMemClk
460 OverrideWLSeed, ///< Override WL seed
461 ForcePhyToM0, ///< Force Phy to M0
462 AdjustCSIntLvLowAddr, ///< Adjust CS interleaving low address
463 ReleaseNbPstate, ///< Release NB P-state
464 InitializeRxEnSeedlessTraining, ///< Initializes RxEn Seedless Training
465 TrackRxEnSeedlessRdWrNoWindBLError, ///< Track Bytelane Errors resulting from No window for RxEn Seedless Training
466 TrackRxEnSeedlessRdWrSmallWindBLError, ///< Track Bytelane Errors resulting from Small window for RxEn Seedless Training
467 InitialzeRxEnSeedlessByteLaneError, ///< Initializes ByteLaneError to False for RxEn Seedless Training
468 InitExtMMIOAddr, ///< Initializes extended MMIO address space
469 MemPstateStageChange, ///< handle training when multiple memory pstate is supported
470 ProgramFence2RxDll, ///< program RxDll in a different register
471 RdDqsDlyRestartChk, ///< Check to see if we need to restart RdDqsDly
472 BeforeWrDatTrn, ///< Check to see if special handling is needed before WrDatDly Training
473 ForceLvDimmVoltage, ///< Force LVDIMM voltage to 1.5V
474 BfAfExcludeDimm, ///< Workaround before and after excluding dimms
475 AdjustWrDqsBeforeSeedScaling, ///< For some family, negative WL is compensated and WrDqs needs to be adjusted before seed scaling
476 OverridePrevPassRcvEnDly, ///< Check to determine if we need override PrevPassRcvEnDly
478 NumberOfHooks ///< Size of list
479 } FAMILY_SPECIFIC_FUNC_INDEX;
481 ///< Entry for SPD Timing
483 BIT_FIELD_NAME BitField; ///< Bit field name of the timing
484 UINT8 Min; ///< Minimum value for timing
485 UINT8 Max; ///< Maximum value for timing
486 UINT8 Bias; ///< Bias from actual value
487 UINT8 Ratio_x2; ///< Actual value will be multiplied by (Ratio_x2/2)
490 /// Structure for northbridge block.
491 typedef struct _MEM_NB_BLOCK {
492 MEM_DATA_STRUCT *MemPtr; ///< Point to MEM_DATA_STRUCT.
493 MEM_PARAMETER_STRUCT *RefPtr; ///< Point to MEM_PARAMETER_STRUCT.
494 DIE_STRUCT *MCTPtr; ///< point to current Node's MCT struct
495 DCT_STRUCT *DCTPtr; ///< point to current Node's DCT struct
496 DCT_STRUCT *AllDCTPtr; ///< point to all Node's DCT structs
497 CH_DEF_STRUCT *ChannelPtr; ///< point to current channel data
498 SPD_DEF_STRUCT *SPDPtr; ///< Point to SPD data for current DCT.
499 struct _MEM_TECH_BLOCK *TechPtr; ///< point to technology block.
500 struct _MEM_FEAT_BLOCK_NB *FeatPtr; ///< point to NB Specific feature block.
501 struct _MEM_SHARED_DATA *SharedPtr; ///< Pointer to Memory scratchpad area
502 SPD_DEF_STRUCT *AllNodeSPDPtr; ///< Point to SPD data for the system.
503 DIE_STRUCT *AllNodeMCTPtr; ///< point to all Node's MCT structs
504 UINT8 DimmToBeUsed; ///< Dimm to be used in recovery mode.
505 MEM_PS_BLOCK *PsPtr; ///< point to platform specific block
506 MEM_PS_BLOCK *PSBlock; ///< point to the first platform specific block on this node.
507 MEM_FREQ_CHANGE_PARAM *FreqChangeParam; ///< pointer to parameter of frequency change.
509 PCI_ADDR PciAddr; ///< PCI address for this node
510 TSEFO *NBRegTable; ///< contains all bit field definitions
512 UINT8 Node; ///< current node.
513 UINT8 Dct; ///< current DCT.
514 UINT8 Channel; ///< current channel.
515 UINT8 DctCount; ///< number of DCTs on the current NB.
516 UINT8 ChannelCount; ///< number of channels per DCT of the current NB.
517 UINT8 NodeCount; ///< number of Nodes supported
518 BOOLEAN Ganged; ///< mode for current MCT controller.
519 POS_TRN_PATTERN_TYPE PosTrnPattern; ///< specifies the pattern that should be used for position training.
520 BOOLEAN MemCleared; ///< memory clear flag.
521 UINT32 CPGInit; ///< continuous pattern generation flag.
522 UINT16 StartupSpeed; ///< startup speed for DDR3.
523 UINT16 RcvrEnDlyLimit; ///< maximum value that RcvrEnDly field can take.
524 UINT32 McaNbCtlReg; ///< reserve MCA reports.
525 UINT32 VarMtrrHiMsk; ///< variable MTRR mask for upper 32 bits.
526 UINT32 CsRegMsk; ///< mask for CS base register
527 UINT32 NBClkFreq; ///< Current NB Clock frequency
528 UINT8 DefDctSelIntLvAddr; ///< Default DctSelIntLvAddr
529 UINT8 TrainingSequenceIndex; ///< Index into the Training Sequence
530 RRW_SETTINGS RrwSettings; ///<Settings for Reliable Read/Write mode
531 INT16 MinRxEnSeedGross; ///< Minimum value of the Receiver Enable
532 INT16 MaxRxEnSeedTotal; ///< Maximum value of the Receiver Enable
534 UINT16 MaxFreqVDDIO[VOLT1_25 + 1]; ///< Max Frequency each voltage supports.
536 MEM_DCT_CACHE DctCache[MAX_CHANNELS_PER_SOCKET]; ///< Allocate space for MCT_DCT_CACHE.
537 MEM_DCT_CACHE *DctCachePtr; ///< pointer to current Node's Node struct
539 /* Temporary storage */
540 BOOLEAN ClToNbFlag; ///< is used to restore ClLinesToNbDis bit after memory
541 UINT8 NbFreqChgState; ///< is used as a state index in NB frequency change state machine
542 UINT32 NbPsCtlReg; ///< is used to save/restore NB Pstate control register
543 MEM_PSTATE MemPstate; ///< is used to save current memory Pstate context
544 MEM_PSTATE_STAGE MemPstateStage; ///< is used to save the current stage status of memory pstate
545 RDDQSDLY_RTN_STAT RdDqsDlyRetrnStat; ///< is used to check if RdDqsDly training needs to be restarted
546 CONST UINT32 *RecModeDefRegArray; ///< points to an array of default register values that are set for recovery mode
548 ///< Determines if code should be executed on a give NB
549 BOOLEAN IsSupported[EnumSize];
550 BOOLEAN (*FamilySpecificHook[NumberOfHooks]) (struct _MEM_NB_BLOCK *NBPtr, VOID *OptParam); ///< This array of pointers point to
551 ///< family specific functions.
553 /* PUBLIC functions */
554 VOID (*SwitchDCT) (struct _MEM_NB_BLOCK *NBPtr, UINT8 DCT); ///< Switch to current DCT.
555 VOID (*SwitchChannel) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Channel); ///< Switch to current channel.
556 VOID (*SetMaxLatency) (struct _MEM_NB_BLOCK *NBPtr, UINT16 MaxRcvEnDly); ///< Set Max Rd Latency.
557 VOID (*getMaxLatParams) (struct _MEM_NB_BLOCK *NBPtr, UINT16 MaxDlyForMaxRdLat, UINT16 *MinDly, UINT16 *MaxDly, UINT16 *DlyBias); ///< retrieves the Max latency parameters.
558 BOOLEAN (*GetSysAddr) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Receiver, UINT32 *Addr); ///< Get system address for training dimm.
559 BOOLEAN (*RankEnabled) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Receiver); ///< Check if a rank has been enabled.
560 BOOLEAN (*InitializeMCT) (struct _MEM_NB_BLOCK *NBPtr); ///< MCT initialization.
561 BOOLEAN (*FinalizeMCT) (struct _MEM_NB_BLOCK *NBPtr); ///< sets final values in BUCFG and BUCFG2.
562 BOOLEAN (*InitMCT) (struct _MEM_NB_BLOCK *NBPtr); ///< main entry call for memory initialization.
563 VOID (*SendMrsCmd) (struct _MEM_NB_BLOCK *NBPtr); ///< send MRS command.
564 VOID (*sendZQCmd) (struct _MEM_NB_BLOCK *NBPtr); ///< send ZQ command.
565 VOID (*TrainingFlow) (struct _MEM_NB_BLOCK *NBPtr); ///< Set the training flow control
566 VOID (*WritePattern) (struct _MEM_NB_BLOCK *NBPtr, UINT32 Address, UINT8 Pattern[], UINT16 ClCount); ///< Write training pattern.
567 VOID (*ReadPattern) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Buffer[], UINT32 Address, UINT16 ClCount); ///< Read training pattern.
568 VOID (*GenHwRcvEnReads) (struct _MEM_NB_BLOCK *NBPtr, UINT32 Address); ///< generates a continuous burst of reads during HW RcvEn training.
569 UINT16 (*CompareTestPattern) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Buffer[], UINT8 Pattern[], UINT16 ByteCount); ///< Compare training pattern.
570 UINT16 (*InsDlyCompareTestPattern) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Buffer[], UINT8 Pattern[], UINT16 ByteCount); ///< Compare training pattern using 1 beat offset to check for insertion delay
571 BOOLEAN (*StitchMemory) (struct _MEM_NB_BLOCK *NBPtr); ///< combines all the memory into a contiguous map.
572 VOID (*ProgramCycTimings) (struct _MEM_NB_BLOCK *NBPtr); ///< programs the memory controller with SPD timings.
573 BOOLEAN (*AutoConfig) (struct _MEM_NB_BLOCK *NBPtr); ///< programs the memory controller with configuration parameters
574 BOOLEAN (*PlatformSpec) (struct _MEM_NB_BLOCK *NBPtr); ///< programs platform specific parameters.
575 VOID (*DisableDCT) (struct _MEM_NB_BLOCK *NBPtr); ///< disable a DCT if no dimm presents.
576 VOID (*StartupDCT) (struct _MEM_NB_BLOCK *NBPtr); ///< start a DCT.
577 VOID (*SyncTargetSpeed) (struct _MEM_NB_BLOCK *NBPtr); ///< Check and sync the target speed of all channels of this node.
578 VOID (*ChangeFrequency) (struct _MEM_NB_BLOCK *NBPtr); ///< Frequency change sequence.
579 BOOLEAN (*RampUpFrequency) (struct _MEM_NB_BLOCK *NBPtr); ///< Change frequency to the next supported level.
580 BOOLEAN (*ChangeNbFrequency) (struct _MEM_NB_BLOCK *NBPtr); ///< Change NB frequency.
581 VOID (*PhyFenceTraining) (struct _MEM_NB_BLOCK *NBPtr); ///< Phy fence training.
582 BOOLEAN (*SyncDctsReady) (struct _MEM_NB_BLOCK *NBPtr); ///< Synchronize DCTs.
583 BOOLEAN (*HtMemMapInit) (struct _MEM_NB_BLOCK *NBPtr); ///< Memory map initialization.
584 VOID (*SyncAddrMapToAllNodes) (struct _MEM_NB_BLOCK *NBPtr); ///< copies the Node 0 map to all the other nodes.
585 BOOLEAN (*CpuMemTyping) (struct _MEM_NB_BLOCK *NBPtr); ///< MTRR and TOM setting.
586 VOID (*BeforeDqsTraining) (struct _MEM_NB_BLOCK *NBPtr); ///< processes needed before DQS training.
587 VOID (*AfterDqsTraining) (struct _MEM_NB_BLOCK *NBPtr); ///< processes needed after DQS training.
588 BOOLEAN (*OtherTiming) (struct _MEM_NB_BLOCK *NBPtr); ///< setting non-spd timing.
589 VOID (*UMAMemTyping) (struct _MEM_NB_BLOCK *NBPtr); ///< MTRR and TOM setting needed for UMA platform.
590 VOID (*Feature) (struct _MEM_NB_BLOCK *NBPtr); ///< Feature support.
591 UINT8 (*GetSocketRelativeChannel) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Dct, UINT8 Channel); ///< Get channel number relative to a socket.
592 VOID (*SetDramOdtRec) (struct _MEM_NB_BLOCK *NBPtr, ODT_MODE OdtMode, UINT8 ChipSelect, UINT8 TargetCS); ///< Set Dram ODT.
593 UINT32 (*GetSysAddrRec) (VOID); ///< Get system address for training.
594 VOID (*SwitchNodeRec) (struct _MEM_NB_BLOCK *NBPtr, UINT8 NodeID); ///< Switch to current node.
595 VOID (*TechBlockSwitch) (struct _MEM_NB_BLOCK *NBPtr); ///< Selects appropriate Tech functions for the NB.
596 VOID (*SetEccSymbolSize) (struct _MEM_NB_BLOCK *NBPtr); ///< Set Ecc Symbol Size.
597 VOID (*GetTrainDlyParms) (struct _MEM_NB_BLOCK *NBPtr, TRN_DLY_TYPE TrnDly, TRN_DLY_PARMS *Parms); ///< Retrieve Specific Delay range info for current NB under current conditions.
598 AGESA_STATUS (*TrainingPatternInit) (struct _MEM_NB_BLOCK *NBPtr); ///< Initialize the training Pattern
599 AGESA_STATUS (*TrainingPatternFinalize) (struct _MEM_NB_BLOCK *NBPtr); ///< Finalize the training Pattern
600 BOOLEAN (*GetApproximateWriteDatDelay) (struct _MEM_NB_BLOCK *NBPtr, UINT8 Index, UINT8 *Value); ///< Retrieve the next WrDat Delay Approximation
601 UINT8 (*CSPerChannel) (struct _MEM_NB_BLOCK *NBPtr); ///< Return number of CS per channel.
602 UINT8 (*CSPerDelay) (struct _MEM_NB_BLOCK *NBPtr); ///< Return number of CS controlled per set of delay registers.
603 VOID (*FlushPattern) (struct _MEM_NB_BLOCK *NBPtr, UINT32 Address, UINT16 ClCount); ///<Flush the training pattern
604 UINT8 (*MinDataEyeWidth) (struct _MEM_NB_BLOCK *NBPtr); ///<Get Min Data Eye Width in 32nds of a UI
605 VOID (*MemNCapSpeedBatteryLife) (struct _MEM_NB_BLOCK *NBPtr); ///< Caps speed based on battery life check.
606 UINT32 (*GetUmaSize) (struct _MEM_NB_BLOCK *NBPtr); ///< Get Uma Size
607 UINT8 (*GetMemClkFreqId) (struct _MEM_NB_BLOCK *NBPtr, UINT16 Speed); ///< Translate MemClk frequency in MHz to MemClkFreq value
608 VOID (*EnableSwapIntlvRgn) (struct _MEM_NB_BLOCK *NBPtr, UINT32 Base, UINT32 Limit); ///< Enable swapped interleaving region
609 BOOLEAN (*ChangeNbFrequencyWrap) (struct _MEM_NB_BLOCK *NBPr, UINT32 NBPstate); ///< Wrapper for NB Pstate change function
610 VOID (*WaitXMemClks) (struct _MEM_NB_BLOCK *NBPr, UINT32 MemClkCount); ///< Waits a specified number of MemClks
611 VOID (*ProgramNbPsDependentRegs) (struct _MEM_NB_BLOCK *NBPtr); ///< Programs NB Pstate dependent registers
612 VOID (*AllocateC6Storage) (struct _MEM_NB_BLOCK *NBPtr); ///< Allocates DRAM region for Core C6
614 /* PUBLIC Get/Set register field functions */
615 UINT32 (*GetBitField) (struct _MEM_NB_BLOCK *NBPtr, BIT_FIELD_NAME FieldName); ///< Pci register bit field read.
616 VOID (*SetBitField) (struct _MEM_NB_BLOCK *NBPtr, BIT_FIELD_NAME FieldName, UINT32 Value); ///< Pci register bit field write.
617 BOOLEAN (*BrdcstCheck) (struct _MEM_NB_BLOCK *NBPtr, BIT_FIELD_NAME FieldName, UINT32 Value); ///< Pci register bit field broadcast read.
618 VOID (*BrdcstSet) (struct _MEM_NB_BLOCK *NBPtr, BIT_FIELD_NAME FieldName, UINT32 Value); ///< Pci register bit field broadcast write.
619 VOID (*PollBitField) (struct _MEM_NB_BLOCK *NBPtr, BIT_FIELD_NAME FieldName, UINT32 Field, UINT32 MicroSecond, BOOLEAN IfBroadCast); ///< Poll a Pci register bitfield.
620 UINT32 (*GetTrainDly) (struct _MEM_NB_BLOCK *NBPtr, TRN_DLY_TYPE TrnDly, DRBN DrbnVar); ///< Training register bit field read.
621 VOID (*SetTrainDly) (struct _MEM_NB_BLOCK *NBPtr, TRN_DLY_TYPE TrnDly, DRBN DrbnVar, UINT16 Value); ///< Training register bit field write.
622 AGESA_STATUS (*InitRecovery) (struct _MEM_NB_BLOCK *NBPtr); ///< Recover mode memory init
623 VOID (*MemRecNInitializeMctNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Initialize MCT changes
624 VOID (*MemRecNFinalizeMctNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Finalize MCT changes
625 VOID (*MemNInitPhyComp) (struct _MEM_NB_BLOCK *NBPtr); ///< Init Phy compensation
626 VOID (*MemNBeforeDramInitNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Before Dram init
627 BOOLEAN (*MemNIsIdSupportedNb) (struct _MEM_NB_BLOCK *NBPtr, CPU_LOGICAL_ID *LogicalIdPtr); ///< Determines if a given CPU id is supported
628 BOOLEAN (*MemNPlatformSpecificFormFactorInitNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Platform specific functions
629 VOID (*MemNSetOtherTimingNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Set non-spd timings
630 VOID (*MemNBeforePlatformSpecNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Apply settings prior to platform specific settings
631 UINT32 (*MemNCmnGetSetFieldNb) (struct _MEM_NB_BLOCK *NBPtr, UINT8 IsSet, BIT_FIELD_NAME FieldName, UINT32 Field); ///< Sets a register value
632 UINT32 (*MemNcmnGetSetTrainDly) (struct _MEM_NB_BLOCK *NBPtr, UINT8 IsSet, TRN_DLY_TYPE TrnDly, DRBN DrbnVar, UINT16 Field); ///< Sets a training delay field
633 VOID (*MemPPhyFenceTrainingNb) (struct _MEM_NB_BLOCK *NBPtr); ///< Phy Fence training
634 VOID (*MemPNodeMemBoundaryNb) (struct _MEM_NB_BLOCK *NBPtr, UINT32 *NodeSysLimit); ///< Phy Fence training
635 UINT32 (*MemRecNCmnGetSetFieldNb) (struct _MEM_NB_BLOCK *NBPtr, UINT8 IsSet, BIT_FIELD_NAME FieldName, UINT32 Field); ///< This functions sets bit fields in recover mode
636 UINT32 (*MemRecNcmnGetSetTrainDlyNb) (struct _MEM_NB_BLOCK *NBPtr, UINT8 IsSet, TRN_DLY_TYPE TrnDly, DRBN DrbnVar, UINT16 Field); ///< This functions sets bit fields in recover mode
637 VOID (*MemRecNSwitchDctNb) (struct _MEM_NB_BLOCK *NBPtr, UINT8 NodeID); ///< S3 Exit self refresh register
638 VOID (*MemNPFenceAdjustNb) (struct _MEM_NB_BLOCK *NBPtr, INT16 *Value16); ///< Adjust Avg PRE value of Phy fence training
639 VOID (*MemNPrepareRcvrEnDlySeed) (struct _MEM_NB_BLOCK *NBPtr); ///< Seed valude for HW RxEn training
640 UINT8 (*MemNGetDramTerm) (struct _MEM_NB_BLOCK *NBPtr, UINT8 ChipSel); ///< Dram Term value
641 UINT8 (*MemNGetDynDramTerm) (struct _MEM_NB_BLOCK *NBPtr, UINT8 ChipSel); ///< Dynamic Dram Term value
642 VOID (*MemNSaveMR0) (struct _MEM_NB_BLOCK *NBPtr, UINT32 MrsAddress); ///< Save MR0 during memory initialization
643 UINT32 (*MemNGetMR0CL) (struct _MEM_NB_BLOCK *NBPtr); ///< MR0[CL] value
644 UINT32 (*MemNGetMR0WR) (struct _MEM_NB_BLOCK *NBPtr); ///< MR0[WR] value
645 UINT32 (*MemNGetMR2CWL) (struct _MEM_NB_BLOCK *NBPtr); ///< MR2[CWL] value
649 /*----------------------------------------------------------------------------
650 * FUNCTIONS PROTOTYPE
652 *----------------------------------------------------------------------------
656 IN OUT MEM_NB_BLOCK *NBPtr
661 IN OUT MEM_NB_BLOCK *NBPtr,
666 MemNSwitchChannelNb (
667 IN OUT MEM_NB_BLOCK *NBPtr,
673 IN OUT MEM_NB_BLOCK *NBPtr,
674 IN BIT_FIELD_NAME FieldName
679 IN OUT MEM_NB_BLOCK *NBPtr,
680 IN BIT_FIELD_NAME FieldName,
686 IN OUT MEM_NB_BLOCK *NBPtr,
687 IN BIT_FIELD_NAME FieldName,
693 IN OUT MEM_NB_BLOCK *NBPtr,
694 IN BIT_FIELD_NAME FieldName,
701 IN OUT MEM_NB_BLOCK *NBPtr,
702 IN TRN_DLY_TYPE TrnDly,
708 IN OUT MEM_NB_BLOCK *NBPtr,
709 IN TRN_DLY_TYPE TrnDly,
716 IN OUT MEM_NB_BLOCK *NBPtr,
720 UINT8 MemNGetSocketRelativeChannelNb (
721 IN OUT MEM_NB_BLOCK *NBPtr,
727 MemNPhyFenceTrainingNb (
728 IN OUT MEM_NB_BLOCK *NBPtr
732 MemNGetMCTSysAddrNb (
733 IN OUT MEM_NB_BLOCK *NBPtr,
740 IN OUT MEM_NB_BLOCK *NBPtr
745 IN OUT MEM_NB_BLOCK *NBPtr
750 IN OUT MEM_NB_BLOCK *NBPtr
754 MemNDisableDCTClientNb (
755 IN OUT MEM_NB_BLOCK *NBPtr
760 IN OUT MEM_NB_BLOCK *NBPtr
765 IN OUT MEM_NB_BLOCK *NBPtr
770 IN OUT MEM_NB_BLOCK *NBPtr
774 MemNChangeFrequencyNb (
775 IN OUT MEM_NB_BLOCK *NBPtr
779 MemNRampUpFrequencyNb (
780 IN OUT MEM_NB_BLOCK *NBPtr
784 MemNProgramCycTimingsNb (
785 IN OUT MEM_NB_BLOCK *NBPtr
789 MemNGetMaxLatParamsNb (
790 IN OUT MEM_NB_BLOCK *NBPtr,
791 IN UINT16 MaxRcvEnDly,
792 IN OUT UINT16 *MinDlyPtr,
793 IN OUT UINT16 *MaxDlyPtr,
794 IN OUT UINT16 *DlyBiasPtr
798 MemNTotalSyncComponentsNb (
799 IN OUT MEM_NB_BLOCK *NBPtr
803 MemNSetMaxLatencyNb (
804 IN OUT MEM_NB_BLOCK *NBPtr,
805 IN UINT16 MaxRcvEnDly
810 IN OUT MEM_NB_BLOCK *NBPtr
815 IN OUT MEM_NB_BLOCK *NBPtr
820 IN OUT MEM_NB_BLOCK *NBPtr
824 MemNTrainPhyFenceNb (
825 IN OUT MEM_NB_BLOCK *NBPtr
830 IN OUT MEM_NB_BLOCK *NBPtr
834 MemNGetTrainDlyParmsNb (
835 IN OUT MEM_NB_BLOCK *NBPtr,
836 IN TRN_DLY_TYPE TrnDly,
837 IN OUT TRN_DLY_PARMS *Parms
842 MemNGetTrainDlyParmsClientNb (
843 IN OUT MEM_NB_BLOCK *NBPtr,
844 IN TRN_DLY_TYPE TrnDly,
845 IN OUT TRN_DLY_PARMS *Parms
849 MemNBeforeDQSTrainingNb (
850 IN OUT MEM_NB_BLOCK *NBPtr
854 MemNcmnGetSetTrainDlyNb (
855 IN OUT MEM_NB_BLOCK *NBPtr,
857 IN TRN_DLY_TYPE TrnDly,
863 MemNcmnGetSetTrainDlyClientNb (
864 IN OUT MEM_NB_BLOCK *NBPtr,
866 IN TRN_DLY_TYPE TrnDly,
872 MemNcmnGetSetTrainDlyUnb (
873 IN OUT MEM_NB_BLOCK *NBPtr,
875 IN TRN_DLY_TYPE TrnDly,
881 MemNSyncTargetSpeedNb (
882 IN OUT MEM_NB_BLOCK *NBPtr
886 MemNSyncDctsReadyNb (
887 IN OUT MEM_NB_BLOCK *NBPtr
892 IN OUT MEM_NB_BLOCK *NBPtr
897 IN OUT MEM_NB_BLOCK *NBPtr
902 IN OUT MEM_NB_BLOCK *NBPtr
907 IN OUT MEM_NB_BLOCK *NBPtr
912 IN OUT MEM_NB_BLOCK *NBPtr
917 IN OUT MEM_NB_BLOCK *NBPtr
922 IN OUT MEM_NB_BLOCK *NBPtr
927 IN OUT MEM_NB_BLOCK *NBPtr
932 IN OUT MEM_NB_BLOCK *NBPtr
936 MemNSyncAddrMapToAllNodesNb (
937 IN OUT MEM_NB_BLOCK *NBPtr
942 IN OUT MEM_NB_BLOCK *NBPtr
946 MemNTechBlockSwitchNb (
947 IN OUT MEM_NB_BLOCK *NBPtr
951 MemRecNGetBitFieldNb (
952 IN OUT MEM_NB_BLOCK *NBPtr,
953 IN BIT_FIELD_NAME FieldName
957 MemRecNSetBitFieldNb (
958 IN OUT MEM_NB_BLOCK *NBPtr,
959 IN BIT_FIELD_NAME FieldName,
964 MemRecNGetTrainDlyNb (
965 IN OUT MEM_NB_BLOCK *NBPtr,
966 IN TRN_DLY_TYPE TrnDly,
971 MemRecNSetTrainDlyNb (
972 IN OUT MEM_NB_BLOCK *NBPtr,
973 IN TRN_DLY_TYPE TrnDly,
979 MemRecNAutoConfigNb (
980 IN OUT MEM_NB_BLOCK *NBPtr
984 MemRecNPlatformSpecNb (
985 IN OUT MEM_NB_BLOCK *NBPtr
989 MemRecNStartupDCTNb (
990 IN OUT MEM_NB_BLOCK *NBPtr
994 MemRecNSetMaxLatencyNb (
995 IN OUT MEM_NB_BLOCK *NBPtr,
996 IN UINT16 MaxRcvEnDly
1000 MemRecNSetDramOdtNb (
1001 IN OUT MEM_NB_BLOCK *NBPtr,
1002 IN ODT_MODE OdtMode,
1003 IN UINT8 ChipSelect,
1008 MemRecNSendMrsCmdNb (
1009 IN OUT MEM_NB_BLOCK *NBPtr
1014 MemRecNSendZQCmdNb (
1015 IN OUT MEM_NB_BLOCK *NBPtr
1019 MemRecNContReadPatternClientNb (
1020 IN OUT MEM_NB_BLOCK *NBPtr,
1028 IN OUT MEM_NB_BLOCK *NBPtr
1032 MemRecNCPUMemRecTypingNb (
1033 IN OUT MEM_NB_BLOCK *NBPtr
1037 MemRecNGetMCTSysAddrNb (
1042 MemRecGetVarMtrrHiMsk (
1043 IN CPU_LOGICAL_ID *LogicalIdPtr,
1044 IN AMD_CONFIG_PARAMS *StdHeader
1048 MemNGetOptimalCGDDNb (
1049 IN OUT MEM_NB_BLOCK *NBPtr,
1050 IN TRN_DLY_TYPE TrnDly1,
1051 IN TRN_DLY_TYPE TrnDly2
1055 MemNPollBitFieldNb (
1056 IN OUT MEM_NB_BLOCK *NBPtr,
1057 IN BIT_FIELD_NAME FieldName,
1059 IN UINT32 MicroSecond,
1060 IN BOOLEAN IfBroadCast
1064 MemNSetEccSymbolSizeNb (
1065 IN OUT MEM_NB_BLOCK *NBPtr
1070 IN OUT MEM_NB_BLOCK *NBPtr
1075 IN OUT MEM_NB_BLOCK *NBPtr
1079 MemNTrainingFlowNb (
1080 IN OUT MEM_NB_BLOCK *NBPtr
1084 MemNRecTrainingFlowNb (
1085 IN OUT MEM_NB_BLOCK *NBPtr
1089 MemNRecTrainingFlowClientNb (
1090 IN OUT MEM_NB_BLOCK *NBPtr
1094 MemNRecTrainingFlowUnb (
1095 IN OUT MEM_NB_BLOCK *NBPtr
1099 MemRecNTotalSyncComponentsClientNb (
1100 IN OUT MEM_NB_BLOCK *NBPtr
1104 MemRecNStartupDCTClientNb (
1105 IN OUT MEM_NB_BLOCK *NBPtr
1110 MemRecNPhyVoltageLevelNb (
1111 IN OUT MEM_NB_BLOCK *NBPtr
1115 MemNTrainingPatternInitNb (
1116 IN OUT MEM_NB_BLOCK *NBPtr
1120 MemNGetApproximateWriteDatDelayNb (
1121 IN OUT MEM_NB_BLOCK *NBPtr,
1127 MemNTrainingPatternFinalizeNb (
1128 IN OUT MEM_NB_BLOCK *NBPtr
1132 MemNFlushPatternNb (
1133 IN OUT MEM_NB_BLOCK *NBPtr,
1139 MemNCSPerChannelNb (
1140 IN OUT MEM_NB_BLOCK *NBPtr
1145 IN OUT MEM_NB_BLOCK *NBPtr
1149 MemNMinDataEyeWidthNb (
1150 IN OUT MEM_NB_BLOCK *NBPtr
1154 MemNCompareTestPatternNb (
1155 IN OUT MEM_NB_BLOCK *NBPtr,
1162 MemNInsDlyCompareTestPatternNb (
1163 IN MEM_NB_BLOCK *NBPtr,
1172 IN OUT MEM_NB_BLOCK *NBPtr
1176 MemNSetMTRRUmaRegionUCNb (
1177 IN OUT MEM_NB_BLOCK *NBPtr,
1179 IN OUT UINT32 *LimitPtr
1183 MemNGetMemClkFreqIdNb (
1184 IN OUT MEM_NB_BLOCK *NBPtr,
1189 MemNGetMemClkFreqIdClientNb (
1190 IN OUT MEM_NB_BLOCK *NBPtr,
1195 MemNGetMemClkFreqIdUnb (
1196 IN OUT MEM_NB_BLOCK *NBPtr,
1201 MemNGetMemClkFreqUnb (
1202 IN OUT MEM_NB_BLOCK *NBPtr,
1207 MemNGetPlatformCfgNb (
1208 IN OUT MEM_NB_BLOCK *NBPtr
1212 MemNPlatformSpecUnb (
1213 IN OUT MEM_NB_BLOCK *NBPtr
1217 MemNProgramPlatformSpecNb (
1218 IN OUT MEM_NB_BLOCK *NBPtr
1222 MemNProgramCycTimingsClientNb (
1223 IN OUT MEM_NB_BLOCK *NBPtr
1228 IN OUT MEM_NB_BLOCK *NBPtr,
1229 IN TRN_DLY_TYPE TrnDlyType1,
1230 IN TRN_DLY_TYPE TrnDlyType2,
1231 IN BOOLEAN SameDimm,
1236 MemNChangeFrequencyClientNb (
1237 IN OUT MEM_NB_BLOCK *NBPtr
1241 MemNChangeFrequencyUnb (
1242 IN OUT MEM_NB_BLOCK *NBPtr
1246 MemNProgramNbPstateDependentRegistersUnb (
1247 IN OUT MEM_NB_BLOCK *NBPtr
1251 MemNProgramNbPstateDependentRegistersClientNb (
1252 IN OUT MEM_NB_BLOCK *NBPtr
1256 MemNAllocateC6StorageClientNb (
1257 IN OUT MEM_NB_BLOCK *NBPtr
1261 MemNAllocateC6StorageUnb (
1262 IN OUT MEM_NB_BLOCK *NBPtr
1266 MemNPhyVoltageLevelNb (
1267 IN OUT MEM_NB_BLOCK *NBPtr
1271 MemNPhyFenceTrainingUnb (
1272 IN OUT MEM_NB_BLOCK *NBPtr
1276 MemNPFenceAdjustUnb (
1277 IN OUT MEM_NB_BLOCK *NBPtr,
1278 IN OUT INT16 *Value16
1282 MemNInitPhyCompClientNb (
1283 IN OUT MEM_NB_BLOCK *NBPtr
1287 MemNTotalSyncComponentsClientNb (
1288 IN OUT MEM_NB_BLOCK *NBPtr
1292 MemNEnableSwapIntlvRgnNb (
1293 IN OUT MEM_NB_BLOCK *NBPtr,
1299 MemNPhyPowerSavingClientNb (
1300 IN OUT MEM_NB_BLOCK *NBPtr
1304 MemNPhyPowerSavingUnb (
1305 IN OUT MEM_NB_BLOCK *NBPtr
1310 IN OUT MEM_NB_BLOCK *NBPtr
1314 MemNPrepareRcvrEnDlySeedNb (
1315 IN OUT MEM_NB_BLOCK *NBPtr
1319 MemNChangeNbFrequencyUnb (
1320 IN OUT MEM_NB_BLOCK *NBPtr
1324 MemNChangeNbFrequencyNb (
1325 IN OUT MEM_NB_BLOCK *NBPtr
1329 MemNWaitXMemClksNb (
1330 IN OUT MEM_NB_BLOCK *NBPtr,
1331 IN UINT32 MemClkCount
1335 memNSequenceDDR3Nb (
1336 IN OUT MEM_NB_BLOCK *NBPtr
1340 GetTrainDlyFromHeapNb (
1341 IN OUT MEM_NB_BLOCK *NBPtr,
1342 IN TRN_DLY_TYPE TrnDlyType,
1347 MemNTrainingFlowUnb (
1348 IN OUT MEM_NB_BLOCK *NBPtr
1352 MemNSetupHwTrainingEngineUnb (
1353 IN OUT MEM_NB_BLOCK *NBPtr,
1358 MemNBeforePhyFenceTrainingClientNb (
1359 IN OUT MEM_NB_BLOCK *NBPtr,
1360 IN OUT VOID *OptParam
1364 MemNReEnablePhyCompNb (
1365 IN OUT MEM_NB_BLOCK *NBPtr,
1366 IN OUT VOID *OptParam
1371 IN OUT MEM_NB_BLOCK *NBPtr,
1376 MemNGetDynDramTermNb (
1377 IN OUT MEM_NB_BLOCK *NBPtr,
1383 IN OUT MEM_NB_BLOCK *NBPtr
1388 IN OUT MEM_NB_BLOCK *NBPtr
1393 IN OUT MEM_NB_BLOCK *NBPtr
1397 MemNDctCfgSelectUnb (
1398 IN OUT MEM_NB_BLOCK *NBPtr,
1403 MemNGetMaxDdrRateUnb (
1404 IN OUT MEM_NB_BLOCK *NBPtr,
1409 MemRecNReEnablePhyCompNb (
1410 IN OUT MEM_NB_BLOCK *NBPtr,
1411 IN OUT VOID *OptParam
1415 MemRecNcmnGetSetTrainDlyClientNb (
1416 IN OUT MEM_NB_BLOCK *NBPtr,
1418 IN TRN_DLY_TYPE TrnDly,
1425 IN OUT MEM_NB_BLOCK *NBPtr
1429 MemNAdjustTxpdllClientNb (
1430 IN OUT MEM_NB_BLOCK *NBPtr,
1431 IN OUT VOID *OptParam
1435 MemNCalcWrDqDqsEarlyUnb (
1436 IN OUT MEM_NB_BLOCK *NBPtr,
1437 IN OUT VOID *OptParam
1441 MemNGetTrainDlyParmsUnb (
1442 IN OUT MEM_NB_BLOCK *NBPtr,
1443 IN TRN_DLY_TYPE TrnDly,
1444 IN OUT TRN_DLY_PARMS *Parms
1448 MemNPlatformSpecificFormFactorInitTblDrvNb (
1449 IN OUT MEM_NB_BLOCK *NBPtr
1453 MemNChangeNbFrequencyWrapUnb (
1454 IN OUT MEM_NB_BLOCK *NBPtr,
1459 MemNForcePhyToM0Unb (
1460 IN OUT MEM_NB_BLOCK *NBPtr,
1461 IN OUT VOID *OptParam
1465 MemNProgramCycTimingsUnb (
1466 IN OUT MEM_NB_BLOCK *NBPtr
1470 MemNSetSkewMemClkUnb (
1471 IN OUT MEM_NB_BLOCK *NBPtr,
1472 IN OUT VOID *OptParam
1477 IN OUT MEM_NB_BLOCK *NBPtr
1481 MemNGetDramTermTblDrvNb (
1482 IN OUT MEM_NB_BLOCK *NBPtr,
1487 MemNGetDynDramTermTblDrvNb (
1488 IN OUT MEM_NB_BLOCK *NBPtr,
1494 IN OUT MEM_NB_BLOCK *NBPtr
1498 MemNGetMR0CLTblDrvNb (
1499 IN OUT MEM_NB_BLOCK *NBPtr
1503 MemNGetMR0WRTblDrvNb (
1504 IN OUT MEM_NB_BLOCK *NBPtr
1508 MemNRampUpFrequencyUnb (
1509 IN OUT MEM_NB_BLOCK *NBPtr
1513 MemNAfterSaveRestoreUnb (
1514 IN OUT MEM_NB_BLOCK *NBPtr,
1515 IN OUT VOID *OptParam
1519 MemNAdjustRdDqsDlyOffsetUnb (
1520 IN OUT MEM_NB_BLOCK *NBPtr,
1525 MemNCalcWrDqDqsEarlyClientNb (
1526 IN OUT MEM_NB_BLOCK *NBPtr,
1527 IN OUT VOID *OptParam
1531 MemNSlot1MaxRdLatTrainClientNb (
1532 IN OUT MEM_NB_BLOCK *NBPtr,
1533 IN OUT VOID *TestAddrRJ16
1538 IN OUT MEM_NB_BLOCK *NBPtr
1542 MemNInitializeRxEnSeedlessTrainingUnb (
1543 IN OUT MEM_NB_BLOCK *NBPtr,
1544 IN OUT VOID *OptParam
1548 MemNTrackRxEnSeedlessRdWrNoWindBLErrorUnb (
1549 IN OUT MEM_NB_BLOCK *NBPtr,
1550 IN OUT VOID *OptParam
1554 MemNTrackRxEnSeedlessRdWrSmallWindBLErrorUnb (
1555 IN OUT MEM_NB_BLOCK *NBPtr,
1556 IN OUT VOID *OptParam
1560 MemNInitialzeRxEnSeedlessByteLaneErrorUnb (
1561 IN OUT MEM_NB_BLOCK *NBPtr,
1562 IN OUT VOID *OptParam
1566 MemNPhyPowerSavingMPstateUnb (
1567 IN OUT MEM_NB_BLOCK *NBPtr
1571 MemNChangeMemPStateContextNb (
1572 IN OUT MEM_NB_BLOCK *NBPtr,
1573 IN MEM_PSTATE MemPstate
1577 MemNDramPowerMngTimingNb (
1578 IN OUT MEM_NB_BLOCK *NBPtr
1582 MemNBfAfExcludeDimmClientNb (
1583 IN OUT MEM_NB_BLOCK *NBPtr,
1584 IN OUT VOID *IsBefore
1589 MemNAllocateNBRegTableNb (
1590 IN OUT MEM_NB_BLOCK *NBPtr,
1591 IN NB_REG_TAB_HANDLE Handle
1595 MemTResetRcvFifoUnb (
1596 IN OUT struct _MEM_TECH_BLOCK *TechPtr,
1601 MemRecNContReadPatternUnb (
1602 IN OUT MEM_NB_BLOCK *NBPtr,
1609 MemRecNContWritePatternUnb (
1610 IN OUT MEM_NB_BLOCK *NBPtr,
1617 MemRecNCompareTestPatternUnb (
1618 IN OUT MEM_NB_BLOCK *NBPtr,
1625 MemNResetRxFifoPtrClientNb (
1626 IN OUT MEM_NB_BLOCK *NBPtr,
1627 IN OUT VOID *OptParam