]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - glsdk/iodelay-config.git/log
glsdk/iodelay-config.git
7 years agoDRA72x: Update guidelines for new modes in Data manual SR2.0 vB
Nikhil Devshatwar [Tue, 31 Jan 2017 10:04:53 +0000 (15:34 +0530)]
DRA72x: Update guidelines for new modes in Data manual SR2.0 vB

Added new modes DSS_VIRTUAL1 and MMC2_VIRTUAL2
Fixed XML correctness check errors in the script
Bumped version to 2.8

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Add support for additional mux in model XML
Nikhil Devshatwar [Tue, 31 Jan 2017 09:26:02 +0000 (14:56 +0530)]
script: Add support for additional mux in model XML

Some of the DRA72x pads have multiple signals available at
same muxmode. The selection happens via internal control module
registers.

To support these pads, XML file syntax has been modified to add
new nodes for AdditionalMux and describe the mux registers to refer

Modify the script to handle these additional modes
- Add utility function to extract register values based on names
- Iterate through different options, match the fields and select right signal
- Move the file read before XML parsing functions
- Add fatal error to force exit the script

Also add a simple script to ease experimenting with XML parsing

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoXML: PCT: Update XML files for Additional Mux
Nikhil Devshatwar [Thu, 26 Jan 2017 11:22:52 +0000 (16:52 +0530)]
XML: PCT: Update XML files for Additional Mux

DRA72x SoC has additional pins mapped to the same muxmode
The selections happens via group specific internal mux register
from control module

Also modify the script to handle the updated syntax

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoXML: PCT: Fix XML correctness test errors
Nikhil Devshatwar [Thu, 26 Jan 2017 11:11:54 +0000 (16:41 +0530)]
XML: PCT: Fix XML correctness test errors

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoXML: PCT: Migrate DRA72x to version 1.0.9
Nikhil Devshatwar [Thu, 22 Dec 2016 09:27:11 +0000 (14:57 +0530)]
XML: PCT: Migrate DRA72x to version 1.0.9

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoXML: PCT: Update DRA75x SR2.0 XML files
Nikhil Devshatwar [Wed, 14 Dec 2016 10:03:50 +0000 (15:33 +0530)]
XML: PCT: Update DRA75x SR2.0 XML files

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoPCT XML: DRA75x: Migrate to v3.0.16
Nikhil Devshatwar [Wed, 14 Dec 2016 09:22:16 +0000 (14:52 +0530)]
PCT XML: DRA75x: Migrate to v3.0.16

Use common guidelines and PCT files for DRA75x 1.0 and 1.1
Replace XML PCT files
Bump version

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoREADME: Update instructions for bios usecase
Nikhil Devshatwar [Thu, 8 Sep 2016 09:23:53 +0000 (14:53 +0530)]
README: Update instructions for bios usecase

Use CCS gel script to get pad register dumps

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Update bios format iodelay generation
Prasad Konnur [Thu, 8 Sep 2016 09:03:27 +0000 (14:33 +0530)]
script: Update bios format iodelay generation

Added the new parameter in the iodelay generation script
to be inline with latest starterware code.

Signed-off-by: Prasad Konnur <prasadkonnur@ti.com>
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Add checks for unsupported Si revisions
Nikhil Devshatwar [Mon, 29 Aug 2016 13:47:56 +0000 (19:17 +0530)]
script: Add checks for unsupported Si revisions

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Add warning for group muxed pads
Nikhil Devshatwar [Sun, 21 Aug 2016 19:59:18 +0000 (01:29 +0530)]
script: Add warning for group muxed pads

DRA72x onwards, some of the pads have multiple groups muxed inside
the chip, thus allowing multiple signals taking same muxmode.
The internal group mux is selected by the CTRL_CORE registers.
Currently XML doesn't have this support, till then add a warning
for the assumption being made.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Fix failures with SYSBOOT pin_name
Nikhil Devshatwar [Sun, 21 Aug 2016 19:34:49 +0000 (01:04 +0530)]
script: Fix failures with SYSBOOT pin_name

Script assumes each pin name to be made of module_signal.
This is not true for some signals like SYSBOOT0 signals.
Handle this case correctly to avoid failure in such cases.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: gpio: Refactor signal probing script
Nikhil Devshatwar [Fri, 8 Jul 2016 13:04:20 +0000 (18:34 +0530)]
script: gpio: Refactor signal probing script

Generate a better script for reading the signal values
based on the sysfs GPIO reads.
* Force input enable if not done already
* Make simpler to read script
* Easy to add and delete signals easily
* Continuous refresh

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Change debug messages
Nikhil Devshatwar [Tue, 10 May 2016 14:36:44 +0000 (20:06 +0530)]
script: Change debug messages

Add different debug levels and use the -d option to
select specific debug level.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Update correctness tests
Nikhil Devshatwar [Tue, 10 May 2016 13:17:19 +0000 (18:47 +0530)]
script: Update correctness tests

Run more test to find out if there are some modes
which are described in guidelines.txt but unused in the
PCT model XML.
This test will fail on the DRA72x ES2.0 where some of the MMC2
manual modes are not present in the PCT files.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoDM: Use SR specific guidelines document
Nikhil Devshatwar [Wed, 4 May 2016 09:28:31 +0000 (14:58 +0530)]
DM: Use SR specific guidelines document

guidelines.txt is referred for helping user choose
the right mode when using iodelay tool.
Sometimes, the modenames are changed, new modes are
added, deleted across Silicon Revision.

Use a SR specific guideline document for each part.
This version is derived from following data manual
DRA75x_74x_SR1.1 - vQ
DRA75x_74x_SR2.0 - vA
DRA72x_SR1.0     - vK
DRA72x_SR2.0     - v*

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
7 years agoscript: Add generate all modes helper
Nikhil Devshatwar [Wed, 4 May 2016 07:01:04 +0000 (12:31 +0530)]
script: Add generate all modes helper

Kernel device tree needs to have pad/delay config
information for all the supported modes of the peripheral.
e.g. MMC instances have multiple for different speeds.

Add a helper to generate data for all modes in one shot.
Update the README to document the usage.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: DRA72x: Migrate to v3.0.7
Nikhil Devshatwar [Tue, 12 Apr 2016 14:19:58 +0000 (19:49 +0530)]
PCT XML: DRA72x: Migrate to v3.0.7

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Exit after generating GPIO script
Nikhil Devshatwar [Wed, 16 Mar 2016 17:42:21 +0000 (23:12 +0530)]
script: Exit after generating GPIO script

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add additional mux support for DRA72x SoCs
Nikhil Devshatwar [Tue, 16 Feb 2016 13:16:16 +0000 (18:46 +0530)]
script: Add additional mux support for DRA72x SoCs

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Correct MMC related warnings in u-boot and kernel
Nikhil Devshatwar [Thu, 11 Feb 2016 11:05:33 +0000 (16:35 +0530)]
script: Correct MMC related warnings in u-boot and kernel

Even though MMC padconf is allowed and recommended in kernel DTS, we still
might need to program the pad and delays in the u-boot.
Remove the un-nececessary warnings for MMC module.
Only warn if non MMC module is enabled in kernel, but skip nothing.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: DRA75x: Migrate to v3.0.10
Nikhil Devshatwar [Wed, 10 Feb 2016 11:32:08 +0000 (17:02 +0530)]
PCT XML: DRA75x: Migrate to v3.0.10

This has the fixes for the RGMII additional modes

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Use Regular Expression in module filter
Nikhil Devshatwar [Thu, 4 Feb 2016 17:38:00 +0000 (23:08 +0530)]
script: Use Regular Expression in module filter

This will help get the pinmux for multiple instances in one go.
e.g. All kernel pinmux for MMC (-m MMC) or all video muxes (-m VIN)

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT: XML: Migrate DRA72x to PCT 1.0.6
Nikhil Devshatwar [Wed, 27 Jan 2016 10:05:33 +0000 (15:35 +0530)]
PCT: XML: Migrate DRA72x to PCT 1.0.6

Update the model file - with updated delay modes and values
Small corrections to the CTRL_CORE XML file.

8 years agoscript: Use reset value for slewcontrol bit in pads
Nikhil Devshatwar [Tue, 1 Dec 2015 11:06:37 +0000 (16:36 +0530)]
script: Use reset value for slewcontrol bit in pads

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>
8 years agoscript: Add support for SLEWCONTROL in the pad generation
Nikhil Devshatwar [Wed, 25 Nov 2015 09:17:02 +0000 (14:47 +0530)]
script: Add support for SLEWCONTROL in the pad generation

Bit number 19 of pad registers allow setting slewrate for that pad.
Interprete the bit and generate the SLEWCONTROL macro whenever required.
Same macro is used for linux and uboot formats.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Warn but generate MMC values
Nikhil Devshatwar [Mon, 23 Nov 2015 17:04:10 +0000 (22:34 +0530)]
script: Warn but generate MMC values

For MMC modules, only generate a warning if attempting
to generate pad data in u-boot.
Sometimes, it's okay to ignore the warning as the padconf
for MMC is essential in uboot.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Fix linux format typo error
Nikhil Devshatwar [Fri, 20 Nov 2015 12:10:49 +0000 (17:40 +0530)]
script: Fix linux format typo error

Fix the linux format pad generation to avoid compiler
errors in the DTS file.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Pass selected mode name in pad data
Nikhil Devshatwar [Fri, 20 Nov 2015 11:31:10 +0000 (17:01 +0530)]
script: Pass selected mode name in pad data

For MMC instance, there can be nodes for all the supported
delay modes. These are differentiated by the mode name.
To do this, pass the delay mode in the pad data.

Update the parameter extraction for linux/bios/uboot.
Use the modename to generate unique DTS nodes for MMC pads.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Fix the menu check in hurried push
Nikhil Devshatwar [Thu, 19 Nov 2015 13:51:01 +0000 (19:21 +0530)]
script: Fix the menu check in hurried push

Fix the menu check which breaks the menu selection of
last available mode.
The last commit 2e9c2437 (script: Add LEGACY mode menu option
to avoid manual/virtual) broke this check.
Fix this.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add LEGACY mode menu option to avoid manual/virtual
Nikhil Devshatwar [Thu, 19 Nov 2015 13:26:27 +0000 (18:56 +0530)]
script: Add LEGACY mode menu option to avoid manual/virtual

If the module has virtual/manual modes availble, user is presented
with the menu and a mode needs to be selected.
For some of the modules, Data manual suggests to use LEGACY mode.
This is valid even if some virtual/manual modes are available.

Fix this with LEGACY option in menu, upon selection of which would
configure the pads without any virtual/manual delays.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Use different guidelines info for parts
Nikhil Devshatwar [Fri, 6 Nov 2015 09:51:53 +0000 (15:21 +0530)]
script: Use different guidelines info for parts

Different parts may have virtual/manual modes with the same name.
It's better to use a different guideline so as to avoid conflicts.

Also, fix an RE regarding the parsing to handle extra columns.
Add the guidelines.txt for the DRA72 part.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add support for all DRA7xx parts
Nikhil Devshatwar [Tue, 3 Nov 2015 10:48:03 +0000 (16:18 +0530)]
script: Add support for all DRA7xx parts

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: Add data for DRA72x part
Nikhil Devshatwar [Tue, 3 Nov 2015 10:52:32 +0000 (16:22 +0530)]
PCT XML: Add data for DRA72x part

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: Move XML files to part specific directory
Nikhil Devshatwar [Tue, 3 Nov 2015 10:50:21 +0000 (16:20 +0530)]
PCT XML: Move XML files to part specific directory

Also delete some of the obsolete XML files for old version

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Print tool version and PCT version
Nikhil Devshatwar [Wed, 14 Oct 2015 08:10:02 +0000 (13:40 +0530)]
script: Print tool version and PCT version

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: Add XML files used in PCT v1.0.9
Nikhil Devshatwar [Wed, 14 Oct 2015 07:27:40 +0000 (12:57 +0530)]
PCT XML: Add XML files used in PCT v1.0.9

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: kernel: Fix delay format to avoid build error
Nikhil Devshatwar [Mon, 28 Sep 2015 14:28:07 +0000 (19:58 +0530)]
script: kernel: Fix delay format to avoid build error

Missing paranthesis around the delay values would result in DTB build error.
Fix the format string properly.

Reported-by: Vishal Mahaveer <vishalm@ti.com>
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Fix the gpio script for bit > 9
Nikhil Devshatwar [Mon, 14 Sep 2015 16:16:38 +0000 (21:46 +0530)]
script: Fix the gpio script for bit > 9

Fix a bug where the script would only consider first bit for the gpio pin
e.g. GPIO7_10 would be read to extract bit number '1' instead of '10'

Fix the regular expression to correct the script generation.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Small change in uboot delay format
Nikhil Devshatwar [Mon, 7 Sep 2015 12:52:21 +0000 (18:22 +0530)]
script: Small change in uboot delay format

Include the pin name associated with the PAD register and
also the name of the manual mode used.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Generate sorted manual delays in u-boot format
Nikhil Devshatwar [Mon, 7 Sep 2015 10:29:15 +0000 (15:59 +0530)]
script: Generate sorted manual delays in u-boot format

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>
8 years agoscript: Add strict mode command line option
Nikhil Devshatwar [Fri, 21 Aug 2015 12:27:55 +0000 (17:57 +0530)]
script: Add strict mode command line option

For some peripherals, only one delaymode cannot be used for all pads.
In this case, it is not good to remember the delaymode and select it
automatically for other pads.

e.g. ethernet or mcasp peripherals may use different delaymodes for
RX pads and different delaymodes for TX pads. With strict mode, the
script won't assume anything and ask questions for all the pads.

With this, it's possible to generate data for peripherals using
multiple delaymodes.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: Add support for ES2.0 silicon revision
Nikhil Devshatwar [Fri, 21 Aug 2015 12:26:48 +0000 (17:56 +0530)]
PCT XML: Add support for ES2.0 silicon revision

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add support for bios output format
Nikhil Devshatwar [Thu, 13 Aug 2015 15:45:12 +0000 (21:15 +0530)]
script: Add support for bios output format

Add support for pad/delay generation in bios output format.
Currently, the MMC check is not added, so all the pads/delays
are configured, irrespective.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoREADME: Update the steps with new options
Nikhil Devshatwar [Thu, 13 Aug 2015 12:26:51 +0000 (17:56 +0530)]
README: Update the steps with new options

Update the examples to use the new command line options.
Also, correct the FILES section to remove the config file which
is not being used now.
Add more examples for generating module specific config and for the
changing output format.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: Add XML files used in PCT v1.0.7
Nikhil Devshatwar [Thu, 13 Aug 2015 12:15:23 +0000 (17:45 +0530)]
PCT XML: Add XML files used in PCT v1.0.7

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add XML correctness checks
Nikhil Devshatwar [Thu, 13 Aug 2015 12:12:38 +0000 (17:42 +0530)]
script: Add XML correctness checks

Add a command line option -c / --check to perform some tests
to identify issues with the XML files.

This would perform a set of checks to verify the consistency of
the data in the XML files and the guidelines.txt.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add option to filter module and to dump gpio
Nikhil Devshatwar [Wed, 12 Aug 2015 16:28:48 +0000 (21:58 +0530)]
script: Add option to filter module and to dump gpio

Add another --module / -m option to generate values only
While iterating over all the pads, skip all the pads which
are not configured for the module specified.

Also, add the checks to avoid MMC configuration in uboot and
restrict the non MMC configuration in kernel.

For debugging purposes, some of the pads (input pads) can be
sampled using the GPIO DATA-IN registers even if the pad is
configured in non GPIO mux mode.
Add a command line option --gpio / -g to dump the script

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Add support for output format linux and uboot
Nikhil Devshatwar [Wed, 12 Aug 2015 15:54:21 +0000 (21:24 +0530)]
script: Add support for output format linux and uboot

Add a command line option to select the output format.
Format the pad and delay dump differently based on the format
selected by user.

Along with the padconf and delayconf lists(which are sorted address wise)
maintain a dictonary which has entries grouped for a specific module.

Use padconf in uboot format to generate one big array.
Use per_padconf in linux format to generate DTS entries for each module.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Refactoring the logic improved interface
Nikhil Devshatwar [Sat, 8 Aug 2015 11:59:21 +0000 (17:29 +0530)]
script: Refactoring the logic improved interface

* Remove the config file and the config parser.
* Add command line option parser and add basic options.
* Introduce debug levels controlled by cmd line option.
* Do not dump the generated values on the fly, save and dump later.
* Hooks to generate the data in the required format - kernel/uboot/QNX.
* Rename functions and variable to improve readability.
* Rearranged functions and added comments for better understanding.
* Fixed bugs for handling unused pads and lagacy mode.

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoREADME: Add Initial README file
Nikhil Devshatwar [Tue, 23 Jun 2015 15:55:24 +0000 (21:25 +0530)]
README: Add Initial README file

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoconfig: Set default config options
Nikhil Devshatwar [Tue, 23 Jun 2015 15:20:34 +0000 (20:50 +0530)]
config: Set default config options

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agodump: Add GLSDK CTRL CORE regdumps for common use cases
Nikhil Devshatwar [Thu, 11 Jun 2015 10:58:59 +0000 (16:28 +0530)]
dump: Add GLSDK CTRL CORE regdumps for common use cases

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoPCT XML: Add XML files used in PCT v1.0.6
Nikhil Devshatwar [Thu, 11 Jun 2015 10:58:27 +0000 (16:28 +0530)]
PCT XML: Add XML files used in PCT v1.0.6

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
8 years agoscript: Initial version of the IOdelay autogen script
Nikhil Devshatwar [Thu, 11 Jun 2015 10:57:41 +0000 (16:27 +0530)]
script: Initial version of the IOdelay autogen script

Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>