@@ -64,7 +64,7 @@ namespace lrdimm
64
64
/// @param[in] i_target - the MCA target on which to operate
65
65
/// @param[in] i_rp - the rank pair
66
66
/// @param[in] i_abort_on_error - whether or not we are aborting on cal error
67
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
67
+ /// @return FAPI2_RC_SUCCESS iff ok
68
68
///
69
69
fapi2 ::ReturnCode mrd_coarse ::pre_workaround ( const fapi2 ::Target < fapi2 ::TARGET_TYPE_MCA > & i_target ,
70
70
const uint64_t i_rp ,
@@ -86,7 +86,7 @@ fapi_try_exit:
86
86
/// @param[in] i_target - the MCA target on which to operate
87
87
/// @param[in] i_rp - the rank pair
88
88
/// @param[in] i_abort_on_error - whether or not we are aborting on cal error
89
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS if ok
89
+ /// @return FAPI2_RC_SUCCESS if ok
90
90
///
91
91
fapi2 ::ReturnCode mrd_coarse ::post_workaround ( const fapi2 ::Target < fapi2 ::TARGET_TYPE_MCA > & i_target ,
92
92
const uint64_t i_rp ,
@@ -105,7 +105,7 @@ fapi_try_exit:
105
105
/// @param[in] i_target the DIMM target
106
106
/// @param[in] i_rank the DIMM rank on which to set the delay
107
107
/// @param[in] i_delay the indexed delay to set
108
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
108
+ /// @return FAPI2_RC_SUCCESS iff ok
109
109
/// @note Sets up buffer control word F6BC4x to do compares on a per-bit level
110
110
///
111
111
fapi2 ::ReturnCode mrd_coarse ::set_delay (const fapi2 ::Target < fapi2 ::TARGET_TYPE_DIMM > & i_target ,
@@ -167,7 +167,7 @@ fapi_try_exit:
167
167
/// @param[in] i_dimm_rank the DIMM rank on which to set the delay
168
168
/// @param[in] i_delay the delay for this run
169
169
/// @param[in,out] io_results the results
170
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
170
+ /// @return FAPI2_RC_SUCCESS iff ok
171
171
///
172
172
fapi2 ::ReturnCode mrd_coarse ::analyze_results (const fapi2 ::Target < fapi2 ::TARGET_TYPE_DIMM > & i_target ,
173
173
const uint64_t i_dimm_rank ,
@@ -186,7 +186,7 @@ fapi2::ReturnCode mrd_coarse::analyze_results(const fapi2::Target<fapi2::TARGET_
186
186
// Displays all of the data here - just.in.case.
187
187
for (uint8_t l_buffer_loop = 0 ; l_buffer_loop < MAX_LRDIMM_BUFFERS ; ++ l_buffer_loop )
188
188
{
189
- for (uint8_t i = 0 ; i < 8 ; ++ i )
189
+ for (uint8_t i = 0 ; i < data_response :: MAX_NUM_BEATS ; ++ i )
190
190
{
191
191
FAPI_DBG ("%s delay:0x%02x MRD_COARSE result buffer%u BEAT%u data:0x%02x" ,
192
192
mss ::c_str (i_target ), i_delay , l_buffer_loop , i , l_data .iv_buffer_beat [l_buffer_loop ][i ]);
@@ -374,7 +374,7 @@ fapi_try_exit:
374
374
/// @param[in] i_target the MCA target
375
375
/// @param[in] i_dimm_rank the DIMM rank on which to set the delay
376
376
/// @param[in,out] io_results the results
377
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
377
+ /// @return FAPI2_RC_SUCCESS iff ok
378
378
///
379
379
fapi2 ::ReturnCode mrd_coarse ::find_final_results (const fapi2 ::Target < fapi2 ::TARGET_TYPE_DIMM > & i_target ,
380
380
const uint64_t i_dimm_rank ,
@@ -399,7 +399,7 @@ fapi_try_exit:
399
399
/// @param[in] i_dimm_rank the DIMM rank on which to set the delay
400
400
/// @param[in] i_results the results
401
401
/// @param[out] o_container the PBA commands structure
402
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
402
+ /// @return FAPI2_RC_SUCCESS iff ok
403
403
///
404
404
fapi2 ::ReturnCode mrd_coarse ::set_final_delays_helper (const fapi2 ::Target < fapi2 ::TARGET_TYPE_DIMM > & i_target ,
405
405
const uint64_t i_dimm_rank ,
@@ -431,7 +431,7 @@ fapi2::ReturnCode mrd_coarse::set_final_delays_helper(const fapi2::Target<fapi2:
431
431
l_result .first .iv_final_delay :
432
432
l_result .second .iv_final_delay ;
433
433
434
- FAPI_DBG ("%s MRD coarse rank%u buffer:%u final values (0x%02x,0x%02x) %s swapped nibble0:0x%02x nibble1:0x%02x" ,
434
+ FAPI_DBG ("%s MRD_COARSE rank%u buffer:%u final values (0x%02x,0x%02x) %s swapped nibble0:0x%02x nibble1:0x%02x" ,
435
435
mss ::c_str (l_mca ), i_dimm_rank , l_buffer , l_result .first .iv_final_delay , l_result .second .iv_final_delay ,
436
436
l_are_nibbles_swapped ? "are" : "not" , l_bcw_result0 , l_bcw_result1 );
437
437
@@ -462,7 +462,7 @@ fapi_try_exit:
462
462
/// @param[in] i_target the DIMM target
463
463
/// @param[in] i_dimm_rank the DIMM rank on which to set the delay
464
464
/// @param[in] i_results the results
465
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
465
+ /// @return FAPI2_RC_SUCCESS iff ok
466
466
///
467
467
fapi2 ::ReturnCode mrd_coarse ::set_final_delays (const fapi2 ::Target < fapi2 ::TARGET_TYPE_DIMM > & i_target ,
468
468
const uint64_t i_dimm_rank ,
@@ -491,15 +491,22 @@ fapi_try_exit:
491
491
/// @param[in] i_target - the MCA target on which to operate
492
492
/// @param[in] i_rp - the rank pair
493
493
/// @param[in] i_abort_on_error - whether or not we are aborting on cal error
494
- /// @return fapi2::ReturnCode fapi2:: FAPI2_RC_SUCCESS iff ok
494
+ /// @return FAPI2_RC_SUCCESS iff ok
495
495
///
496
496
fapi2 ::ReturnCode mrd_coarse ::run ( const fapi2 ::Target < fapi2 ::TARGET_TYPE_MCA > & i_target ,
497
497
const uint64_t i_rp ,
498
498
const uint8_t i_abort_on_error ) const
499
499
{
500
500
constexpr uint8_t MPR_LOCATION0 = 0 ;
501
501
std ::vector < uint64_t > l_ranks ;
502
+
503
+ // Use 0x2b for the pattern
504
+ // This pattern was determined experimentally, but has the following good qualities
505
+ // 1) it is not cyclic
506
+ // 2) it has all transitions (00, 01, 10, 11), making for a good SI test pattern
502
507
constexpr uint8_t l_pattern_expected = 0x2B ;
508
+ // We write to all of the MPR registers, so we clone the 2B pattern four times
509
+ // The patterns get split and written individually
503
510
constexpr uint32_t l_pattern_set = 0x2B2B2B2B ;
504
511
505
512
// 1) Get our ranks within the configured rank pair
0 commit comments