]> git.sur5r.net Git - openocd/commit
ftdi: Enable SWDIO output before sending data on it
authorJonas Norling <jonas.norling@cyanconnode.com>
Wed, 25 Oct 2017 09:33:06 +0000 (11:33 +0200)
committerSpencer Oliver <spen@spen-soft.co.uk>
Fri, 27 Oct 2017 10:48:36 +0000 (11:48 +0100)
commit41092636d1a10d7fe55a986f0d5556a4c34b58d2
tree1f306afcfaee38bc40feb589df69511adac63351
parentc0881ba2d5752ce747a4f74daf7531662f9360a9
ftdi: Enable SWDIO output before sending data on it

The SWDIO buffer has to be enabled, by setting SWDIO_OE, for data on
SWDIO to reach the target. Explicitly do this before sending the
switch sequences for JTAG-to-SWD, etc.

This makes the code insensitive to the state of SWDIO_OE specified in
ftdi_layout_init. It used to work only on adapters with a non-inverted
SWDIO_OE inited to 1, or inverted SWDIO_OE inited to 0.

Change-Id: I4b9e520ac1c7ce2a437251a05fc036bc68de718e
Signed-off-by: Jonas Norling <jonas.norling@cyanconnode.com>
Reviewed-on: http://openocd.zylin.com/4270
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
src/jtag/drivers/ftdi.c