summaryrefslogtreecommitdiffstats
path: root/src/build/simics/triggerMPIPL.simics
blob: e026b1319d50ec074a565f48d6e8d643c628fbca (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
#This script is to be ran after IPL Complete has run (after istep16)
#Run it while simics is at a breakpoint then continue, you should start
#at the bootloader

#trigger coreReset with fake action/reg
($hb_masterproc).proc_chip.invoke parallel_store SCOM 0x05000004 "10000000_00000000" 64

#set PPM General Power Management Mode Register to 0
($hb_masterproc).proc_chip.invoke parallel_store SCOM 0x200f0100 "0x00000000_00000000" 64
#set actual/required stop states on PPM STOP_STATE_HIST_OTR_REG
($hb_masterproc).proc_chip.invoke parallel_store SCOM 0x200f0113 "0x2B000000_00000000" 64


#set regs on master thread to prepare for bootloader
($hb_cpu).write-reg IAR 0x3000
($hb_cpu).write-reg HRMOR 0x8200000
($hb_cpu).write-reg MSR 0xd000000000000000
($hb_cpu).write-reg LPCR 0x800040000000800c

#load in the bootloader code
system_cmp0.phys_mem.load-file ../obj/ppc/hbfw/img/hbbl.bin 0x8203000

#set up memory that SBE usually sets
system_cmp0.phys_mem.write address = 0x820000c value = 0x0000000000006000 size = 8

#set isMPIPL mode to be true
($hb_masterproc).proc_chip.invoke parallel_store SCOM 0x5003A "20000000_00000000" 64

#start off the master thread
($hb_cpu).enable
OpenPOWER on IntegriCloud