drivers/imx_gpio: fix polarity of srst and trst 47/4847/2
authorAntonio Borneo <borneo.antonio@gmail.com>
Fri, 11 Jan 2019 17:29:38 +0000 (18:29 +0100)
committerMatthias Welwarsky <matthias@welwarsky.de>
Thu, 7 Feb 2019 07:51:41 +0000 (07:51 +0000)
The comment above the function is correct, but the code set
the GPIO with wrong (reversed) polarity.

Change-Id: Ifd09688150d3d2018af73521e0da3926bb1b7f84
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/4847
Tested-by: jenkins
Reviewed-by: Grzegorz Kostka <kostka.grzegorz@gmail.com>
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
src/jtag/drivers/imx_gpio.c

index 2a822afe97598495b6c7e3dd35d8abedfb9ab2b4..f42692c38d3d373b4d5f7acca24564ac564f399f 100644 (file)
@@ -160,10 +160,10 @@ static int imx_gpio_swd_write(int tck, int tms, int tdi)
 static int imx_gpio_reset(int trst, int srst)
 {
        if (trst_gpio != -1)
 static int imx_gpio_reset(int trst, int srst)
 {
        if (trst_gpio != -1)
-               trst ? gpio_set(trst_gpio) : gpio_clear(trst_gpio);
+               trst ? gpio_clear(trst_gpio) : gpio_set(trst_gpio);
 
        if (srst_gpio != -1)
 
        if (srst_gpio != -1)
-               srst ? gpio_set(srst_gpio) : gpio_clear(srst_gpio);
+               srst ? gpio_clear(srst_gpio) : gpio_set(srst_gpio);
 
        return ERROR_OK;
 }
 
        return ERROR_OK;
 }

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)