summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 16acc1d)
raw | patch | inline | side by side (parent: 16acc1d)
author | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Tue, 1 Dec 2015 11:06:37 +0000 (16:36 +0530) | ||
committer | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Tue, 1 Dec 2015 11:06:37 +0000 (16:36 +0530) |
It is recommended to use the reset value of the slewcontrol bit
in the pad registers. Update the bitfield by referring to the
reset value given in the CTRL_MODULE_CORE.xml
Add an option if someone does not want to override this bit.
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
in the pad registers. Update the bitfield by referring to the
reset value given in the CTRL_MODULE_CORE.xml
Add an option if someone does not want to override this bit.
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 f1a79ebd9af96d80b573d4ac5f53970f7d75ebbf..0b52e95aedf888ac8d764f31c27b84473b116daa 100755 (executable)
--- a/iodelay-autogen.py
+++ b/iodelay-autogen.py
help='check consistency of the XML files and other data')
args = parser.parse_args()
+
+# Some more knobs for developers, Don't want to expose them to cmd line
+args.resetslew = True
+
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
VERSION = "2.4"
else:
return padlist[0].get("id")
+def xml_pad_get_slew(offset):
+ padlist = pad_xml.findall("register[@offset='0x%X']" % offset)
+ if (len(padlist) == 0):
+ return 0x0
+ else:
+ bitlist = padlist[0].findall("bitfield[@begin='19']")
+ if (len(bitlist) == 0):
+ return 0x0
+ else:
+ return int(bitlist[0].get("resetval"), 16)
+
def xml_pad_get_pin(offset, muxmode):
padlist = pad_xml.findall("register[@offset='0x%X']" % offset)
if (len(padlist) == 0):
if (args.module != "" and args.module != module):
continue
+ # It is recommended to keep the reset value of the slewcontrol bit
+ # Find out the reset value from XML and update if required
+ if (args.resetslew):
+ val |= (xml_pad_get_slew(offset) & 0x1) << 19
+
if (args.debug >= 1):
print "\nPAD: %s: Addr= 0x%08X Value = 0x%08X \"%s\"" \
% (pad_name, addr, val, pin_name)