blob: 9910ded78b0f08e8f1d5a1064f1b6df5a99668e2 [file] [log] [blame]
Curtis Dunham87b9da22015-09-02 15:23:30 -05001# Add the ARM CONTEXTIDR_EL2 miscreg.
2def upgrader(cpt):
3 if cpt.get('root','isa') == 'arm':
4 for sec in cpt.sections():
5 import re
6 # Search for all ISA sections
7 if re.search('.*sys.*\.cpu.*\.isa$', sec):
8 miscRegs = cpt.get(sec, 'miscRegs').split()
9 # CONTEXTIDR_EL2 defaults to 0b11111100000000000001
10 miscRegs[599:599] = [0xFC001]
11 cpt.set(sec, 'miscRegs', ' '.join(str(x) for x in miscRegs))
12
13legacy_version = 14