Skip to content
Snippets Groups Projects
Commit ee4a1dd9 authored by Linux Build Service Account's avatar Linux Build Service Account
Browse files

Promotion of opensource-tools.lnx.1.0-00016.

CRs      Change ID                                   Subject
--------------------------------------------------------------------------------------------------------------
2049892   Ica6fef3dc6ed76851f026b248555fc16748f33b2   dcc_parser: Add offset option for stand alone parser use
2049892   I0bfbf46a08e8fe1e8fc9572d411dc164a6bdd991   dcc_parser: Fix XML output

Change-Id: I2c094414d8344be142e677e3a964be32f98bd1ec
CRs-Fixed: 2049892
parents 402549fd 34f7e5e4
No related branches found
No related tags found
No related merge requests found
......@@ -92,6 +92,9 @@ def read_config(config_pt):
#word size
track_len = 4
if options.config_offset is not None:
config_pt.seek(options.config_offset, 1)
while True:
word = config_pt.read(4)
if len(word) != 4:
......@@ -184,7 +187,7 @@ def dump_regs_json(options):
def dump_regs_xml(options):
log.info("Dumping regs in XML format in \'{0}\' file.".format(options.outfile))
parsed_data.info("<?xml version=\"1.0\" encoding=\"utf-8\"?>")
parsed_data.info("<hwioDump version=\"1\"")
parsed_data.info("<hwioDump version=\"1\">")
parsed_data.info("\t<timestamp>{0}</timestamp>".format(datetime.date.today().strftime('%m/%d/%y')))
parsed_data.info("\t<generator>Linux DCC Parser</generator>")
parsed_data.info("\t<chip name=\"{0}\" version=\"{1}\">".format(options.chipname, options.chipversion))
......@@ -223,6 +226,8 @@ if __name__ == '__main__':
help='chip version')
parser.add_option('--v2', dest='version', action="store_const", const='2',
help='DCC driver version 2')
parser.add_option('--config-offset', dest='config_offset', type=int,
help='Start offset for DCC configuration')
(options, args) = parser.parse_args()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment