openocd/tcl/target/imx.cfg
Antonio Borneo 5df5e89cf3 tcl: remove trailing whitespace
The script checkpatch available in new Linux kernel offers an
experimental feature for automatically fix the code in place.
While still experimental, the feature works quite well for simple
fixes, like spacing.

This patch has been created automatically with the script under
review for inclusion in OpenOCD, using the command:
	find tcl/ -type f -exec ./tools/scripts/checkpatch.pl \
	-q --types TRAILING_WHITESPACE --fix-inplace -f {} \;

The patch only changes amount and position of whitespace, thus
the following commands show empty diff
	git diff -w
	git log -w -p
	git log -w --stat

Change-Id: Ie7e3a236f4db9c70019e3b3c7e851edbd3a9dd84
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5616
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Tested-by: jenkins
2020-05-09 14:38:40 +01:00

31 lines
797 B
INI

# utility fn's for Freescale i.MX series
global TARGETNAME
set TARGETNAME $_TARGETNAME
# rewrite commands of the form below to arm11 mcr...
# Data.Set c15:0x042f %long 0x40000015
proc setc15 {regs value} {
global TARGETNAME
echo [format "set p15 0x%04x, 0x%08x" $regs $value]
arm mcr 15 [expr ($regs>>12)&0x7] [expr ($regs>>0)&0xf] [expr ($regs>>4)&0xf] [expr ($regs>>8)&0x7] $value
}
proc imx3x_reset {} {
# this reset script comes from the Freescale PDK
#
# http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=IMX35PDK
echo "Target Setup: initialize DRAM controller and peripherals"
# Data.Set c15:0x01 %long 0x00050078
setc15 0x01 0x00050078
echo "configuring CP15 for enabling the peripheral bus"
# Data.Set c15:0x042f %long 0x40000015
setc15 0x042f 0x40000015
}