summaryrefslogtreecommitdiffstats
path: root/src/import/chips/p9/procedures/hwp/cache/p9_l2err_extract.C
blob: 4d3d32bd66ea86a5041fa537a4614b7317a51fb5 (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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
/* IBM_PROLOG_BEGIN_TAG                                                   */
/* This is an automatically generated prolog.                             */
/*                                                                        */
/* $Source: src/import/chips/p9/procedures/hwp/cache/p9_l2err_extract.C $ */
/*                                                                        */
/* OpenPOWER HostBoot Project                                             */
/*                                                                        */
/* Contributors Listed Below - COPYRIGHT 2016,2017                        */
/* [+] International Business Machines Corp.                              */
/*                                                                        */
/*                                                                        */
/* Licensed under the Apache License, Version 2.0 (the "License");        */
/* you may not use this file except in compliance with the License.       */
/* You may obtain a copy of the License at                                */
/*                                                                        */
/*     http://www.apache.org/licenses/LICENSE-2.0                         */
/*                                                                        */
/* Unless required by applicable law or agreed to in writing, software    */
/* distributed under the License is distributed on an "AS IS" BASIS,      */
/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or        */
/* implied. See the License for the specific language governing           */
/* permissions and limitations under the License.                         */
/*                                                                        */
/* IBM_PROLOG_END_TAG                                                     */
//------------------------------------------------------------------------------
// *|
// *! TITLE       : p9_l2err_extract.C
// *! DESCRIPTION : Parse and extract error information from L2 trace array (FAPI2)
// *!
// *! OWNER NAME  : Chen Qian              Email: qianqc@cn.ibm.com
// *!
// *! ADDITIONAL COMMENTS :
// *!  See header file for additional comments.
//------------------------------------------------------------------------------


//------------------------------------------------------------------------------
// Includes
//------------------------------------------------------------------------------
#include <p9_l2err_extract.H>
//#include <p9_proc_gettracearray.H>
#include "../perv/p9_proc_gettracearray.H"
#include <p9_quad_scom_addresses.H>
#include <p9_quad_scom_addresses_fld.H>
//------------------------------------------------------------------------------
// Constant definitions
//------------------------------------------------------------------------------
const uint8_t P9_L2ERR_EXTRACT_ECC_PAT[73] =  { 0xc4, 0x8c, 0x94, 0xd0, 0xf4, 0xb0, 0xa8, 0xe0,
                                                0x62, 0x46, 0x4a, 0x68, 0x7a, 0x58, 0x54, 0x70,
                                                0x31, 0x23, 0x25, 0x34, 0x3d, 0x2c, 0x2a, 0x38,
                                                0x98, 0x91, 0x92, 0x1a, 0x9e, 0x16, 0x15, 0x1c,
                                                0x4c, 0xc8, 0x49, 0x0d, 0x4f, 0x0b, 0x8a, 0x0e,
                                                0x26, 0x64, 0xa4, 0x86, 0xa7, 0x85, 0x45, 0x07,
                                                0x13, 0x32, 0x52, 0x43, 0xd3, 0xc2, 0xa2, 0x83,
                                                0x89, 0x19, 0x29, 0xa1, 0xe9, 0x61, 0x51, 0xc1,
                                                0xc7, 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01
                                              };
const uint8_t L2ERR_MAX_CYCLES_BACK = 5;
const uint8_t L2ERR_NUM_DWS = 8;

extern "C"
{

//------------------------------------------------------------------------------
// Function definitions
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
// HWP entry point
//------------------------------------------------------------------------------
    fapi2::ReturnCode p9_l2err_extract(const fapi2::Target<fapi2::TARGET_TYPE_EX>& i_target,
                                       const fapi2::variable_buffer& i_ta_data,
                                       p9_l2err_extract_err_type i_err_type,
                                       p9_l2err_extract_err_data& o_err_data)
    {
        uint32_t                rc_ecmd = 0;
        // other vars
        bool                    error_found = false;
        bool                    ce_ue = true;//ce or ue flag
        int32_t                 trace_index = 0;

        //the index into the trace entry that is N cycles before the fail
        uint32_t                indexes[L2ERR_MAX_CYCLES_BACK];
        fapi2::variable_buffer  trace_array[PROC_GETTRACEARRAY_NUM_ENTRIES];
        uint8_t                 syndrome = 0;
        uint8_t                 dw = 0;
        uint32_t                ta_length = i_ta_data.getBitLength();
        uint32_t                exp_ta_length = PROC_GETTRACEARRAY_NUM_ENTRIES * PROC_GETTRACEARRAY_BITS_PER_ENTRY;

        //bool                    back_of_2to1 = false;
        bool                    back_of_2to1_nextcycle = false;
        uint8_t                 syndrome_col = 0;
        uint8_t                 addr48_55 = 0;
        uint8_t                 addr56_57 = 0;
        uint8_t                 addr48 = 0;
        uint8_t                 addr49 = 0;
        uint16_t                addr48_57 = 0;
        uint16_t                addr48_56 = 0;
        uint16_t                cgc = 0;
        uint32_t                addrBit2 = 0;
        fapi2::variable_buffer  address( 10 );
        uint8_t                 member = 0;
        uint8_t                 bank = 0;
        uint8_t                 ow_select = 0;
        bool                    found_dw = false;
        uint8_t                 macro = 0;
        uint8_t                 column = 0;
        uint8_t                 bitline = 0;
        bool                    is_top_sa = false;
        bool                    is_left_sa = false;
        bool                    odd_way = false;
        uint8_t                 way_bitline_offset = 0;
        uint32_t                physical_offset = 0;

        int32_t                 l_ce_trace_index = 0;
        uint32_t                indexes_index = 0;
        uint32_t                cycles = 0;


        // mark function entry
        FAPI_DBG("Entering p9_l2err_extract...");

        //check if the supplied data is the correct size, used mostly for manual tool input
        FAPI_ASSERT(!(ta_length != exp_ta_length),
                    fapi2::P9_L2ERR_EXTRACT_TA_WRONG_SIZE_ERR()
                    .set_TARGET(i_target)
                    .set_TA_DATA_SIZE(ta_length)
                    .set_EXP_TA_DATA_SIZE(exp_ta_length),
                    "Specified trace array length (%i) does not match expected length (%i)",
                    ta_length, exp_ta_length);

        //build the indexable array and print out contents at the same time for debug
        for(uint8_t i = 0; i < PROC_GETTRACEARRAY_NUM_ENTRIES; i++)
        {
            trace_array[i].resize(PROC_GETTRACEARRAY_BITS_PER_ENTRY);
            rc_ecmd |= i_ta_data.extract(trace_array[i], PROC_GETTRACEARRAY_BITS_PER_ENTRY * i, PROC_GETTRACEARRAY_BITS_PER_ENTRY);
            FAPI_DBG("%2X: 0x%016llX%016llX", i, trace_array[i].get<uint64_t>( 0 ), trace_array[i].get<uint64_t>( 1 ));
        }

        FAPI_ASSERT(!rc_ecmd,
                    fapi2::P9_L2ERR_EXTRACT_DATA_BUFFER_ERROR()
                    .set_TARGET(i_target),
                    "Error 0x%x extracting from trace array data buffer.",
                    rc_ecmd);


        //********************************************************************//
        // L2 Trace (scom 0x10012000 & 0x10012001)                            //
        //********************************************************************//
        // The array has 2 parts. Both halves matter for this code.           //
        // This code will handle both parts as a whole for simplicity.        //
        //                                                                    //
        // Three entry formats exist for bits 0:94:                           //
        //    ============================================                    //
        //    | 0:87 | 88:94 | Format Type               |                    //
        //    |------+-------+---------------------------|                    //
        //    |  =0  |  =0   | Compression start stamp   |                    //
        //    | !=0  |  =0   | Compression stamp         |                    //
        //    | any  | !=0   | Trace data (see below)    |                    //
        //    ============================================                    //
        //                                                                    //
        // Notes about compression:                                           //
        //  - The compression start stamp is set when compression is turned   //
        //     on, so it will probably never be in the trace. It represents   //
        //     no clock cycles so it can be ignored.                          //
        //  - The compression stamp indicates a repeat count that should be   //
        //     added to the repeat count of the previous data entry. Since we //
        //     only care about a 12 cycle window, we can ignore compression   //
        //     stamps, safe in the knowledge that the data entry itself will  //
        //     have a repeat count of more than 12 cycles.                    //
        //                                                                    //
        //    =============================================================== //
        //    |  Bits  |  Trace data format                                 | //
        //    |--------+----------------------------------------------------| //
        //    |   0:55 | Don't Care (debug data)                            | //
        //    |  56:63 | DW (Encoded, always 1 cycle back)                  | //
        //    |     64 | CE Occurred                                        | //
        //    |     65 | UE Occurred                                        | //
        //    |     66 | back_of_2to1 bit (Determines # cycles after read)  | //
        //    |  67:69 | Member (2 cycles back)                             | //
        //    |  70:71 | address 56:57 (56=bank, 4 cycles back)             | //
        //    |  72:79 | address 48:55 (4 cycles back)                      | //
        //    |  80:87 | Syndrome for lowesti # DW                          | //
        //    |  88:94 | LFSR (counts cycles)                               | //
        //    |     95 | Error (FIR bit has been set)                       | //
        //    |     96 | tied to 0                                          | //
        //    | 97:103 | Trace array address (auto-increments on scom read) | //
        //    |    104 | Which trace bank is valid in banked mode           | //
        //    |        |    0 = addresses 0-63 are valid                    | //
        //    |        |    1 = addresses 64-127 are valid                  | //
        //    |    105 | tied to 0                                          | //
        //    |106:111 | trace address when bank was switched in bank mode  | //
        //    |112:127 | tied to 0                                          | //
        //    =============================================================== //
        //                                                                    //
        //********************************************************************//

        //look for CE/UE
        error_found = false;
        trace_index = PROC_GETTRACEARRAY_NUM_ENTRIES; //the last entry in the array is the newest
        FAPI_DBG("trace_index = %X", trace_index);

        while( !error_found && (trace_index > 0) )
        {
            trace_index--;

            //Only look at data entries (ie ignore compression entries for now)
            if( !trace_array[trace_index].isBitClear( 88, 7 ) )
            {
                //Check for CE first, don't check if we are explicitly looking for a UE
                if(trace_array[trace_index].isBitSet( 64 ) && !(i_err_type == L2ERR_UE))
                {
                    FAPI_DBG("Found CE at trace index %i", trace_index);
                    FAPI_DBG("%2X: 0x%016llX%016llX", trace_index, trace_array[trace_index].get<uint64_t>( 0 ),
                             trace_array[trace_index].get<uint64_t>( 1 ));
                    error_found = true;
                    ce_ue = true;
                    break;
                }

                //Check for UE second, don't check if we are explicitly looking for a CE
                if(trace_array[trace_index].isBitSet( 65 ) && !(i_err_type == L2ERR_CE))
                {
                    FAPI_DBG("Found UE at trace index %i", trace_index);
                    error_found = true;
                    ce_ue = false;
                    break;
                }
            }
        } //end loop looking for CE/UE

        FAPI_DBG("Found UE or CE: error_found = %i", error_found);

        //log an error if nothing was found based on what the user was looking for
        FAPI_ASSERT(error_found,
                    fapi2::P9_L2ERR_EXTRACT_NO_CEUE_FOUND()
                    .set_TARGET(i_target)
                    .set_TA_DATA(i_ta_data)
                    .set_ERR_REQ_TYPE(i_err_type),
                    "No CE or UE found in trace array.");


        //generate compression indexes, we will use these to look back for data
        l_ce_trace_index = trace_index;

        while( (indexes_index < L2ERR_MAX_CYCLES_BACK) && (l_ce_trace_index >= 0) )
        {
            rc_ecmd |= trace_array[l_ce_trace_index].extractToRight( cycles, 88, 7 ); //LFSR
            FAPI_ASSERT(!rc_ecmd,
                        fapi2::P9_L2ERR_EXTRACT_DATA_BUFFER_ERROR()
                        .set_TARGET(i_target),
                        "Error 0x%x extracting from trace array data buffer.",
                        rc_ecmd);

            if( cycles != 0 )
            {
                //This is a data entry with LFSR data
                //convert LFSR to cycle count
                switch( cycles )
                {
                    case 0x7F:
                        cycles = 1;
                        break;

                    case 0x3F:
                        cycles = 2;
                        break;

                    case 0x5F:
                        cycles = 3;
                        break;

                    case 0x2F:
                        cycles = 4;
                        break;

                    case 0x57:
                        cycles = 5;
                        break;

                    //Only need to find a total of 4 cycles, so anything not above works
                    default:
                        cycles = 5;
                        break;
                }

                FAPI_DBG("cycles = %x", cycles);

                //Put "trace_index" into "indexes" up to "cycles" number of times
                for( ; (cycles > 0) && (indexes_index < L2ERR_MAX_CYCLES_BACK); cycles-- )
                {
                    indexes[indexes_index] = l_ce_trace_index;
                    indexes_index++;
                }
            }
            else
            {
                //This is a compression stamp
                FAPI_DBG( "Skipping compression stamp\n" );
            }

            //Go look at the previous entry
            l_ce_trace_index--;
        } // while


        for(int8_t i = L2ERR_MAX_CYCLES_BACK - 1; i >= 0; i--)
        {
            FAPI_DBG("uncomp %i cycles back: 0x%016llX%016llX", i, trace_array[indexes[i]].get<uint64_t>( 0 ),
                     trace_array[indexes[i]].get<uint64_t>( 1 ));
        }

        //find what cycle the CE occured on and calculate location of DW data
        //p9 updated find the next cycle of back_of_2to1 CE/UE trigger
        back_of_2to1_nextcycle = trace_array[trace_index + 1].isBitSet( 66 );

        //Get syndrome which is the cycle after the CE
        rc_ecmd = trace_array[ trace_index + 1 ].extractToRight( syndrome,  80,  8 );

        FAPI_DBG("rc_ecmd: %#x", rc_ecmd);
        FAPI_ASSERT(!rc_ecmd,
                    fapi2::P9_L2ERR_EXTRACT_SYNDROME_DATA()
                    .set_TARGET(i_target),
                    "Error 0x%x while extracting syndrome data.",
                    rc_ecmd);

        FAPI_ASSERT(!(ce_ue && (syndrome == 0)),
                    fapi2::P9_L2ERR_EXTRACT_SYNDROME_NOT_FOUND()
                    .set_TARGET(i_target)
                    .set_TRACE_ARRAY_1(trace_array[ trace_index + 1 ].get<uint64_t>( 0 ))
                    .set_TRACE_ARRAY_2(trace_array[ trace_index + 1 ].get<uint64_t>( 1 ))
                    .set_TRACE_ARRAY_3(trace_array[ trace_index + 2 ].get<uint64_t>( 0 ))
                    .set_TRACE_ARRAY_4(trace_array[ trace_index + 2 ].get<uint64_t>( 1 )),
                    "Error: could not find syndrome.\nTrace cycle CE+1= 0x%016llX%016llX\nTrace cycle CE+2=%016llX%016llX",
                    trace_array[ trace_index + 1 ].get<uint64_t>( 0 ),
                    trace_array[ trace_index + 1 ].get<uint64_t>( 1 ),
                    trace_array[ trace_index + 2 ].get<uint64_t>( 0 ),
                    trace_array[ trace_index + 2 ].get<uint64_t>( 1 ));

        FAPI_DBG("Found syndrome: %2X", syndrome);

        //look up column from syndrome
        if( ce_ue )
        {
            //decodes the specified syndrome into a column offset
            bool found = false;

            //use the ECC lookup to find what column the error occured
            for( uint8_t i = 0; i < (uint8_t)(sizeof(P9_L2ERR_EXTRACT_ECC_PAT) / sizeof(uint8_t)); i++)
            {
                if( syndrome == P9_L2ERR_EXTRACT_ECC_PAT[i] )
                {
                    syndrome_col = i;
                    found = true;
                    break;
                }
            }

            FAPI_ASSERT(found,
                        fapi2::P9_L2ERR_EXTRACT_UNKNOWN_SYNDROME_ECC()
                        .set_TARGET(i_target)
                        .set_SYNDROME(syndrome),
                        "Syndrome ECC is unknown. %2X", syndrome);

            FAPI_DBG("syndrome_col = %u", syndrome_col);
        }
        else
        {
            syndrome_col = 0;
        }

        //get member and address data
        rc_ecmd  = trace_array[ indexes[ 2 ]].extractToRight( member, 67, 3 );              // 2 cycles back
        rc_ecmd |= trace_array[ indexes[ 4 ]].extractToRight( addr48_55,  72,  8 );         // 4 cycles back
        rc_ecmd |= trace_array[ indexes[ 4 ]].extractToRight( addr56_57, 70, 2 );           // 4 cycles back

        rc_ecmd |= address.insertFromRight( addr48_55, 0, 8 );
        rc_ecmd |= address.insertFromRight( addr56_57, 8, 2 );
        rc_ecmd |= address.extractToRight( addr48_57, 0, 10 );
        rc_ecmd |= address.extractToRight( addr48_56, 0, 9 );

        // extract bank, cgc, addrBit2 from the address value
        bank = addr56_57 / 2;
        cgc = addr48_55;
        addrBit2 = ( cgc & 0x20) >> 5;

        FAPI_DBG("get member and address data: rc_ecmd = %i", rc_ecmd);
        FAPI_ASSERT(!rc_ecmd,
                    fapi2::P9_L2ERR_EXTRACT_BUILDING_DATA_ERROR()
                    .set_TARGET(i_target),
                    "Error 0x%x while extracting/building address data.",
                    rc_ecmd);

        FAPI_DBG("Found member: %i", member);
        FAPI_DBG("addr48_55=%X, addr56_57=%X, address48_57=%X", addr48_55, addr56_57, addr48_57);
        FAPI_DBG("bank = %i", bank);

        // calculate ow_select, determines which beat the error occurred on, first(0) or second(1)

        // then error occurred on second beat, otherwise first beat
        // ow_select is determined by next cycle back_of_2to1
        if(!back_of_2to1_nextcycle)
        {
            ow_select = !(addr56_57 % 2);
        }
        else
        {
            ow_select = (addr56_57 % 2);
        }

        FAPI_DBG("addr56_57=%u", addr56_57);

        //find DW
        for( dw = 0; dw < L2ERR_NUM_DWS; dw++ )
        {
            if((trace_array[ indexes[ 1 ] ].isBitSet( (56 + dw))))
            {
                found_dw = true;
                break;
            }
        }

        FAPI_ASSERT(found_dw,
                    fapi2::P9_L2ERR_EXTRACT_DW_NOT_FOUND()
                    .set_TARGET(i_target)
                    .set_TRACE_ARRAY_1(trace_array[ indexes[ 1 ] ].get<uint64_t>( 0 ))
                    .set_TRACE_ARRAY_2(trace_array[ indexes[ 1 ] ].get<uint64_t>( 1 )),
                    "Error: could not find DW.\nTrace cycle CE 1 cycle back = 0x%016llX%016llX",
                    trace_array[ indexes[ 1 ] ].get<uint64_t>( 0 ),
                    trace_array[ indexes[ 1 ] ].get<uint64_t>( 1 ));

        FAPI_DBG("Found DW=%i", dw);

        //calculate macro
        if( syndrome_col <= 23 )
        {
            macro = 0;
        }
        else if( syndrome_col <= 47)
        {
            macro = 1;
        }
        else
        {
            macro = 2;
        }

        //calculate macro-specific column
        column = syndrome_col - ( macro * 24 );

        //calculate top/bottom subarray
        addr48 = addr48_57 >> 9; //bit 48, cgc0-127 is top, cgc128-255 is bottom
        addr49 = (addr48_57) >> 8 & 0x01;
        FAPI_DBG("addr49 = %u", addr49);
        FAPI_DBG("addr48 = %u", addr48);

        // The submacros are named top_left, top_right, bottom_left, and bottom_right. A directory entry is spread across a left/right pair.
        // The top macros include congruence classes 0-127, the bottom include 128-255.
        // Parse addr48_49 to get the top/bottom, right/left information
        // Top_left = 0x00, top_right = 0x01, bottom_left = 0x10, bottom_right = 0x11. First bit is top/bottom, last bit is left/right
        if( addr48 == 0 )
        {
            is_top_sa = true;
        }
        else
        {
            is_top_sa = false;
        }

        if( addr49 == 0 )
        {
            is_left_sa = true;
        }
        else
        {
            is_left_sa = false;
        }

        FAPI_DBG("L2 fail is from %s macro.", (is_top_sa) ? "top" : "bottom");

        // calculate bitline
        physical_offset = 2 +   4 * ( ow_select  % 2) +   addrBit2    +   ((member & 0x1) << 1);
        bitline =   physical_offset + 8 * column;

        FAPI_DBG("addrBit2=%u", addrBit2);
        FAPI_DBG("physical_offset=%u", physical_offset);
        FAPI_DBG("cgc=%u", cgc);
        FAPI_DBG("odd_way=%u", odd_way);
        FAPI_DBG("member=%u", member);
        FAPI_DBG("ow_select=%u", ow_select);
        FAPI_DBG("way_bitline_offset=%u", way_bitline_offset);
        FAPI_DBG("column=%u", column);
        FAPI_DBG("Found bitline=%u", bitline);
        FAPI_DBG("ce_ue value = %u", ce_ue);

        // print out error location information
        if( ce_ue )
        {
            FAPI_DBG("CE Location Information");
        }
        else
        {
            FAPI_DBG("UE Location Information");
        }

        FAPI_DBG("\tDW     = %u", dw);
        FAPI_DBG("\tBank   = %u", bank);
        FAPI_DBG("\tMember = %u", member);
        FAPI_DBG("\tMacro  = %u", macro);
        FAPI_DBG("\tOW_Sel = %u", ow_select);
        FAPI_DBG("\tTop SA = %s", is_top_sa ? "true" : "false");
        FAPI_DBG("\tLeft SA = %s", is_left_sa ? "true" : "false");
        FAPI_DBG("\tAddress = 0x%X", addr48_55);
        FAPI_DBG("\tBitline = %u", bitline);
        o_err_data.ce_ue = ce_ue ? L2ERR_CE : L2ERR_UE;
        o_err_data.member = member;
        o_err_data.dw = dw;
        o_err_data.macro = macro;
        o_err_data.bank = bank;
        o_err_data.ow_select = ow_select;
        o_err_data.is_top_sa = is_top_sa;
        o_err_data.is_left_sa = is_left_sa;
        o_err_data.bitline = bitline;
        o_err_data.address = addr48_55;


        // mark HWP exit
    fapi_try_exit:
        FAPI_INF("Exiting p9_l2err_extract...");
        return fapi2::current_err;
    } // p9_l2err_extract

} // extern "C"

OpenPOWER on IntegriCloud