summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c0d6be6)
raw | patch | inline | side by side (parent: c0d6be6)
author | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Mon, 7 Sep 2015 10:29:15 +0000 (15:59 +0530) | ||
committer | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Mon, 7 Sep 2015 11:13:37 +0000 (16:43 +0530) |
Generate the manual delay data and store in a list.
Sort the list on the delay offset and dump the sorted list.
* Improve help message to add information on pad dump generation
* Generate the array name based on the silicon revision.
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
Sort the list on the delay offset and dump the sorted list.
* Improve help message to add information on pad dump generation
* Generate the array name based on the silicon revision.
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
iodelay-autogen.py | patch | blob | history |
diff --git a/iodelay-autogen.py b/iodelay-autogen.py
index 0c36c71d3a062ff0028608bb02452d4678b9a1ad..3094328599df40884491bc9abc21f8a36e80e080 100755 (executable)
--- a/iodelay-autogen.py
+++ b/iodelay-autogen.py
'This script refers to the XML data and automatically generates\n' \
'PAD and DELAY data for the same use case.\n' \
'Note that only the PADs which are used in the dump are configured.',
- epilog='Generate the pad and delay data using pad regdump')
+ epilog='Generate the pad and delay data using pad register dumps. For this,\n' \
+ 'Run omapconf dump 0x4a003400 0x4a00380c and save the output')
parser.add_argument('-d', '--debug', dest='debug',
action='store', type=int, choices=[0, 1, 2], default=0,
print "};\n"
def uboot_format_delay_regs(delayconf, per_delayconf):
- print "\nconst struct iodelay_cfg_entry dra742_iodelay_cfg_array[] = {"
+ manual_del = []
for i in delayconf:
(pad_name, pin_name, regname, del_offset, man_name, adel, gdel) = i
print "WARN: Skipping MMC delayconf in uboot"
continue
- print "\t{ 0x%04X, %5d, %5d },\t/* %s */" % (del_offset, adel, gdel, regname)
+ entry = (del_offset, adel, gdel, regname)
+ manual_del.append(entry)
+
+ es_rev = args.revision.replace('.', '_')
+ print "\nconst struct iodelay_cfg_entry dra742_es" + es_rev + "_iodelay_cfg_array[] = {"
+ for entry in sorted(manual_del):
+ print "\t{ 0x%04X, %5d, %5d },\t/* %s */" % entry
print "};\n"
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #