cpt_upgrader.py (9956:6f2b525b8f16) cpt_upgrader.py (9959:ad4564da49b5)
1#!/usr/bin/env python
2
3# Copyright (c) 2012-2013 ARM Limited
4# All rights reserved
5#
6# The license below extends only to copyright in the software and shall
7# not be construed as granting a license to any other intellectual
8# property including but not limited to intellectual property relating

--- 203 unchanged lines hidden (view full) ---

212# Version 7 of the checkpoint adds support for the IDE dmaAbort flag
213def from_6(cpt):
214 # Update IDE disk devices with dmaAborted
215 for sec in cpt.sections():
216 # curSector only exists in IDE devices, so key on that attribute
217 if cpt.has_option(sec, "curSector"):
218 cpt.set(sec, "dmaAborted", "false")
219
1#!/usr/bin/env python
2
3# Copyright (c) 2012-2013 ARM Limited
4# All rights reserved
5#
6# The license below extends only to copyright in the software and shall
7# not be construed as granting a license to any other intellectual
8# property including but not limited to intellectual property relating

--- 203 unchanged lines hidden (view full) ---

212# Version 7 of the checkpoint adds support for the IDE dmaAbort flag
213def from_6(cpt):
214 # Update IDE disk devices with dmaAborted
215 for sec in cpt.sections():
216 # curSector only exists in IDE devices, so key on that attribute
217 if cpt.has_option(sec, "curSector"):
218 cpt.set(sec, "dmaAborted", "false")
219
220# Version 8 of the checkpoint adds an ARM MISCREG
221def from_7(cpt):
222 if cpt.get('root','isa') == 'arm':
223 for sec in cpt.sections():
224 import re
225 # Search for all ISA sections
226 if re.search('.*sys.*\.cpu.*\.isa', sec):
227 mr = cpt.get(sec, 'miscRegs').split()
228 # Add dummy value for MISCREG_TEEHBR
229 mr.insert(51,0);
230 cpt.set(sec, 'miscRegs', ' '.join(str(x) for x in mr))
220
231
232
221migrations = []
222migrations.append(from_0)
223migrations.append(from_1)
224migrations.append(from_2)
225migrations.append(from_3)
226migrations.append(from_4)
227migrations.append(from_5)
228migrations.append(from_6)
233migrations = []
234migrations.append(from_0)
235migrations.append(from_1)
236migrations.append(from_2)
237migrations.append(from_3)
238migrations.append(from_4)
239migrations.append(from_5)
240migrations.append(from_6)
241migrations.append(from_7)
229
230verbose_print = False
231
232def verboseprint(*args):
233 if not verbose_print:
234 return
235 for arg in args:
236 print arg,

--- 95 unchanged lines hidden ---
242
243verbose_print = False
244
245def verboseprint(*args):
246 if not verbose_print:
247 return
248 for arg in args:
249 print arg,

--- 95 unchanged lines hidden ---