summaryrefslogtreecommitdiffstats
path: root/src/usr/hwpf/hwp/occ/occ_procedures/p8_pm_init.C
blob: a52c411063c701ed08a6c59f3d68722d6e379119 (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
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
/* IBM_PROLOG_BEGIN_TAG                                                   */
/* This is an automatically generated prolog.                             */
/*                                                                        */
/* $Source: src/usr/hwpf/hwp/occ/occ_procedures/p8_pm_init.C $            */
/*                                                                        */
/* IBM CONFIDENTIAL                                                       */
/*                                                                        */
/* COPYRIGHT International Business Machines Corp. 2013                   */
/*                                                                        */
/* p1                                                                     */
/*                                                                        */
/* Object Code Only (OCO) source materials                                */
/* Licensed Internal Code Source Materials                                */
/* IBM HostBoot Licensed Internal Code                                    */
/*                                                                        */
/* The source code for this program is not published or otherwise         */
/* divested of its trade secrets, irrespective of what has been           */
/* deposited with the U.S. Copyright Office.                              */
/*                                                                        */
/* Origin: 30                                                             */
/*                                                                        */
/* IBM_PROLOG_END_TAG                                                     */
// $Id: p8_pm_init.C,v 1.18 2013/04/16 12:00:34 pchatnah Exp $
// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/p8_pm_init.C,v $  
//------------------------------------------------------------------------------
// *! (C) Copyright International Business Machines Corp. 2011
// *! All Rights Reserved -- Property of IBM
// *! *** IBM Confidential ***
//------------------------------------------------------------------------------
// *! OWNER NAME: Ralf Maier         Email: ralf.maier@de.ibm.com
// *!
/// \file p8_pm_init.C
/// \brief Calls each PM unit initialization procedures with the control 
///         parameter to process the respective phase:
///             config: use Platform Attributes to create an effective 
///                     configuration using relevant Feature Attributes
///             init:   use the Feature attributes to initialize the hardware
///             reset:  call the "p8_pm_prep_reset" procedure to invoke a 
///                     reset of the hardware to allow for reinitialization
// *!
// *! Procedure Prereq:
// *!   o System clocks are running
// *!
//------------------------------------------------------------------------------
///
/// \version -------------------------------------------------------------------
/// \version 1.0 stillgs 2012/03/06 Initial Version 
/// \version -------------------------------------------------------------------
///
///
/// \todo   Review
///
///
/// High-level procedure flow:
///
/// \verbatim
///     - call p8_pcbs_init.C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_pmc_init.C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_poreslw_init.C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_poregpe_init.C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_oha_init.C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_pba_init.C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_occ_sram_init.C *chiptarget,mode (PM_CONFIG, PM_INIT, PM_RESET)   
///     - evaluate RC
///
///     - call p8_ocb_init .C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///     - call p8_pss_init .C *chiptarget, mode (PM_CONFIG, PM_INIT, PM_RESET)
///     - evaluate RC
///
///  \endverbatim
///
// ----------------------------------------------------------------------
// Includes
// ----------------------------------------------------------------------

#include "p8_pm.H"
#include "p8_pm_init.H"

extern "C" {

using namespace fapi;

// ----------------------------------------------------------------------
// Constant definitions
// ----------------------------------------------------------------------


// ---------------------------------------------------------------------- 
// Global variables
// ----------------------------------------------------------------------


// ----------------------------------------------------------------------
// Function prototypes
// ----------------------------------------------------------------------


// ----------------------------------------------------------------------
// Function definitions
// ----------------------------------------------------------------------
  fapi::ReturnCode p8_pm_list(const Target& i_target, const Target& i_target2, uint32_t mode);

// ----------------------------------------------------------------------
// p8_pm_init 
// ----------------------------------------------------------------------

fapi::ReturnCode
p8_pm_init(const fapi::Target &i_target1 ,const fapi::Target &i_target2 , uint32_t mode)
{

    fapi::ReturnCode l_fapi_rc;
    
    FAPI_INF("Executing p8_pm_init in mode %x ....\n", mode);

    /// -------------------------------
    /// Configuration/Initialation
    if (mode == PM_CONFIG || mode == PM_INIT || mode == PM_RESET) 
    {       
        l_fapi_rc = p8_pm_list(i_target1, i_target2, mode);
	    if (l_fapi_rc) 
	    { 
	        FAPI_ERR("ERROR: p8_pm_list detected failed "); 
	        return l_fapi_rc;
	    }    
    }
    /// -------------------------------
    /// Unsupported Mode
    else 
    {

      FAPI_ERR("Unknown mode passed to p8_pm_init. Mode %x ....\n", mode);
      uint32_t & MODE = mode;
      FAPI_SET_HWP_ERROR(l_fapi_rc, RC_PROCPM_PMC_CODE_BAD_MODE); // proc_pmc_errors.xml

    }

    return l_fapi_rc;
}


// ----------------------------------------------------------------------
// p8_pm_list - process the underlying routines in the prescribed order 
// ----------------------------------------------------------------------

fapi::ReturnCode
p8_pm_list(const Target& i_target, const Target& i_target2, uint32_t mode)
{

    fapi::ReturnCode l_fapi_rc;
        uint64_t            SP_WKUP_REG_ADDRS;
    uint8_t                        l_functional = 0;
    uint8_t                        l_ex_number = 0;
    ecmdDataBufferBase  data(64);

    std::vector<fapi::Target>      l_exChiplets;   


    //  ******************************************************************
    //  PCBS_PM 
    //  ******************************************************************  
  
    FAPI_INF("Executing: p8_pcbs_init.C in mode %x", mode);  

    if ( i_target.getType() != TARGET_TYPE_NONE )
      {  
	FAPI_EXEC_HWP(l_fapi_rc, p8_pcbs_init, i_target, mode);
	if (l_fapi_rc) 
	  { 
        FAPI_ERR("ERROR: p8_pm_init detected failed PCBS_PM result"); 
        return l_fapi_rc;
	  }    
      }


    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_pcbs_init, i_target2, mode);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PCBS_PM result"); 
	    return l_fapi_rc;
	  }    
      }
    //  ******************************************************************
    //  PMC 
    //  ******************************************************************  
   
    FAPI_INF("Executing: p8_pmc_init in mode %x", mode);   

    FAPI_EXEC_HWP(l_fapi_rc, p8_pmc_init, i_target, i_target2, mode);
    if (l_fapi_rc) 
    { 
        FAPI_ERR("ERROR: p8_pm_init detected failed PMC result");
        return l_fapi_rc;
    }
    
    //  ******************************************************************
    //  PORE Sleep/Winkle engine 
    //  ******************************************************************  

    FAPI_INF("Executing: p8_poreslw_init in mode %x", mode); 
    if ( i_target.getType() != TARGET_TYPE_NONE )
      {    
	FAPI_EXEC_HWP(l_fapi_rc, p8_poreslw_init, i_target, mode);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PORE SLW result");
	    return l_fapi_rc;
	  }
      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_poreslw_init, i_target2, mode);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PORE SLW result");
	    return l_fapi_rc;
	  }
      }
    //  ******************************************************************
    //  PORE General Purpose Engines
    //  ******************************************************************  

    FAPI_INF("Executing: p8_poregpe_init in mode %x", mode);
       
    if ( i_target.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_poregpe_init, i_target, mode , GPEALL);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PORE GPE result");
	    return l_fapi_rc;
	  }
	
      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_poregpe_init, i_target2, mode , GPEALL);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PORE GPE result");
	    return l_fapi_rc;
	  }
    
      }
    //  ******************************************************************
    //  OHA
    //  ******************************************************************  

    FAPI_INF("Executing: p8_oha_init in mode %x", mode);

    if ( i_target.getType() != TARGET_TYPE_NONE )
      {     
	FAPI_EXEC_HWP(l_fapi_rc, p8_oha_init, i_target, mode);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OHA result");
	    return l_fapi_rc;
	  }
      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_oha_init, i_target2, mode);
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OHA result");
	    return l_fapi_rc;
	  }
      }
    
    //  ******************************************************************
    //  OCC-SRAM 
    //  ******************************************************************  
  

    FAPI_INF("Executing: p8_occ_sram_init in mode %x", mode);
    
    if ( i_target.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_occ_sram_init, i_target, mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCC-SRAM result");
	    return l_fapi_rc;
	  }
      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_occ_sram_init, i_target2, mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCC-SRAM result");
	    return l_fapi_rc;
	  }
      }
    
    //  ******************************************************************
    //  OCB 
    //  ******************************************************************  

    FAPI_INF("Executing: p8_ocb_init in mode %x", mode);   
    if ( i_target.getType() != TARGET_TYPE_NONE )
      {
   
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target, mode,OCB_CHAN0,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 0");
	    return l_fapi_rc;
	  }
       
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target, mode,OCB_CHAN1,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 1");
	    return l_fapi_rc;
	  }
    
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target, mode,OCB_CHAN2,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 2");
	    return l_fapi_rc;
	  }
    
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target, mode,OCB_CHAN3,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 0");
	    return l_fapi_rc;
	  }

      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {


	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target2, mode,OCB_CHAN0,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 0");
	    return l_fapi_rc;
	  }
       
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target2, mode,OCB_CHAN1,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 1");
	    return l_fapi_rc;
	  }
    
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target2, mode,OCB_CHAN2,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 2");
	    return l_fapi_rc;
	  }
    
	FAPI_EXEC_HWP(l_fapi_rc, p8_ocb_init, i_target2, mode,OCB_CHAN3,OCB_TYPE_NULL, 0x10000000, 1 , OCB_Q_OUFLOW_EN , OCB_Q_ITPTYPE_NOTFULL   );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed OCB result on channel 0");
	    return l_fapi_rc;
	  }

      }

 
    //  ******************************************************************
    //  PSS 
    //  ******************************************************************  
   
    FAPI_INF("Executing:p8_pss_init in mode %x", mode);

    if ( i_target.getType() != TARGET_TYPE_NONE )
      {
    
	FAPI_EXEC_HWP(l_fapi_rc, p8_pss_init, i_target, mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PSS result");
	    return l_fapi_rc;
	  }
      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_pss_init, i_target2, mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PSS result");
	    return l_fapi_rc;
	  }
      }

    //  ******************************************************************
    //  PBA 
    //  ******************************************************************  
    
    FAPI_INF("Executing: p8_pba_init  in mode %x", mode);
    if ( i_target.getType() != TARGET_TYPE_NONE )
      {         
	FAPI_EXEC_HWP(l_fapi_rc, p8_pba_init, i_target, mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PBA result");
	    return l_fapi_rc;
	  }
      }
    
    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {
	FAPI_EXEC_HWP(l_fapi_rc, p8_pba_init, i_target2, mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_init detected failed PBA result");
	    return l_fapi_rc;
	  }
      }




 

    // loop over all the core chiplets

    if (mode == PM_INIT)
      {
	


    //  ******************************************************************
    //  FIRINIT
    //  ******************************************************************  
    

    FAPI_INF("Executing:p8_pm_firinit in mode %x", mode);

    if ( i_target.getType() != TARGET_TYPE_NONE )
      {
    
	FAPI_EXEC_HWP(l_fapi_rc, p8_pm_firinit, i_target , mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_firinit detected failed  result");
	    return l_fapi_rc;
	  }
      }

    if ( i_target2.getType() != TARGET_TYPE_NONE )
      {

	FAPI_EXEC_HWP(l_fapi_rc, p8_pm_firinit, i_target2 , mode );
	if (l_fapi_rc) 
	  { 
	    FAPI_ERR("ERROR: p8_pm_firinit detected failed  result");
	    return l_fapi_rc;
	  }
      }


    //  ******************************************************************
    //  CPU_SPECIAL_WAKEUP switch off
    //  ******************************************************************  


    if ( i_target.getType() != TARGET_TYPE_NONE )
      {
	l_fapi_rc = fapiGetChildChiplets (  i_target, 
					    TARGET_TYPE_EX_CHIPLET, 
					    l_exChiplets, 
					    TARGET_STATE_PRESENT);
	if (l_fapi_rc)
	  { 
	    FAPI_ERR("Error from fapiGetChildChiplets!");       
	    return l_fapi_rc;     
	  }
	
	FAPI_DBG("\tChiplet vector size  => %u ", l_exChiplets.size());
	
	// Iterate through the returned chiplets
	for (uint8_t j=0; j < l_exChiplets.size(); j++)
	  {
	    
	    // Determine if it's functional
	    l_fapi_rc = FAPI_ATTR_GET(  ATTR_FUNCTIONAL, 
					&l_exChiplets[j], 
					l_functional);
	    if (l_fapi_rc)
	      {
		FAPI_ERR("fapiGetAttribute of ATTR_FUNCTIONAL error"); 
		break;
	      }
	    
	    if ( l_functional )
	      {
	        // The ex is functional let's build the SCOM address 
	        l_fapi_rc = FAPI_ATTR_GET(ATTR_CHIP_UNIT_POS, &l_exChiplets[j], l_ex_number);
	        FAPI_DBG("Running special wakeup on ex chiplet %d ", l_ex_number);
		
	        // Set special wakeup for EX
	        // Commented due to attribute errors 
		SP_WKUP_REG_ADDRS = PM_SPECIAL_WKUP_OCC_0x100F010C + (l_ex_number  * 0x01000000) ;
		l_fapi_rc=fapiGetScom(i_target, SP_WKUP_REG_ADDRS , data); if(l_fapi_rc) return l_fapi_rc;                                  
		FAPI_DBG("  Before clear of SPWKUP_REG PM_SPECIAL_WKUP_OCC_(0x%08llx) => =>0x%16llx",  SP_WKUP_REG_ADDRS, data.getDoubleWord(0));
		
		if (data.isBitSet(0))
		  {
		    //		    FAPI_EXEC_HWP(l_fapi_rc, p8_cpu_special_wakeup, l_exChiplets[j], SPCWKUP_DISABLE , HOST);
		      l_fapi_rc = fapiSpecialWakeup(l_exChiplets[j], false);
		    if (l_fapi_rc) { FAPI_ERR("p8_cpu_special_wakeup: Failed to put CORE into special wakeup. With rc = 0x%x", (uint32_t)l_fapi_rc);  return l_fapi_rc;    }    


		  }
	      }
	  }  // chiplet loop 

      }
    ///////////////////////////////////////////// SLAVE TARGET /////////////////////////////////////////////////


      if ( i_target2.getType() != TARGET_TYPE_NONE )
	{
	  l_fapi_rc = fapiGetChildChiplets (  i_target2, 
					      TARGET_TYPE_EX_CHIPLET, 
					      l_exChiplets, 
					      TARGET_STATE_PRESENT);
	  if (l_fapi_rc)
	    { 
	      FAPI_ERR("Error from fapiGetChildChiplets!");       
	      return l_fapi_rc;     
	    }
	
	  FAPI_DBG("\tChiplet vector size  => %u ", l_exChiplets.size());
	
	  // Iterate through the returned chiplets
	  for (uint8_t j=0; j < l_exChiplets.size(); j++)
	    {
	    
	      // Determine if it's functional
	      l_fapi_rc = FAPI_ATTR_GET(  ATTR_FUNCTIONAL, 
					  &l_exChiplets[j], 
					  l_functional);
	      if (l_fapi_rc)
		{
		  FAPI_ERR("fapiGetAttribute of ATTR_FUNCTIONAL error"); 
		  break;
		}
	    
	      if ( l_functional )
		{
		  // The ex is functional let's build the SCOM address 
		  l_fapi_rc = FAPI_ATTR_GET(ATTR_CHIP_UNIT_POS, &l_exChiplets[j], l_ex_number);
		  FAPI_DBG("Running special wakeup on ex chiplet %d ", l_ex_number);
		
		  // Set special wakeup for EX
		  // Commented due to attribute errors 
		  SP_WKUP_REG_ADDRS = PM_SPECIAL_WKUP_OCC_0x100F010C + (l_ex_number  * 0x01000000) ;
		  l_fapi_rc=fapiGetScom(i_target2, SP_WKUP_REG_ADDRS , data); if(l_fapi_rc) return l_fapi_rc;                                  
		  FAPI_DBG("  Before clear of SPWKUP_REG PM_SPECIAL_WKUP_OCC_(0x%08llx) => =>0x%16llx",  SP_WKUP_REG_ADDRS, data.getDoubleWord(0));
		
		  if (data.isBitSet(0))
		    {
		      //		      FAPI_EXEC_HWP(l_fapi_rc, p8_cpu_special_wakeup, l_exChiplets[j], SPCWKUP_DISABLE , HOST);
		      l_fapi_rc = fapiSpecialWakeup(l_exChiplets[j], false);
		      if (l_fapi_rc) { FAPI_ERR("p8_cpu_special_wakeup: Failed to put CORE into special wakeup. With rc = 0x%x", (uint32_t)l_fapi_rc);  return l_fapi_rc;    }    


		    }
		}
	    }  // chiplet loop  
	}



       
	
      }
	return l_fapi_rc;
  
}


  //#ifdef FAPIECMD
} //end extern C
//#endif 
OpenPOWER on IntegriCloud