From: Spencer Oliver Date: Wed, 26 Sep 2012 14:31:53 +0000 (+0100) Subject: ftdi: incorrectly using output register for direction X-Git-Tag: v0.6.1~17 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=6cb0c3ff140f3f171f6ee3c544a43f5d9d8c33f0;p=openocd ftdi: incorrectly using output register for direction fix a simple copy/paste bug. Change-Id: I5caaa4d16d30f26a453bd6a00c95261fd6e716c5 Signed-off-by: Spencer Oliver Reviewed-on: http://openocd.zylin.com/873 Tested-by: jenkins --- diff --git a/src/jtag/drivers/ftdi.c b/src/jtag/drivers/ftdi.c index 46797d7d..b5bea835 100644 --- a/src/jtag/drivers/ftdi.c +++ b/src/jtag/drivers/ftdi.c @@ -175,7 +175,7 @@ static int ftdi_set_signal(const struct signal *s, char value) output = data ? output | s->data_mask : output & ~s->data_mask; if (s->oe_mask == s->data_mask) - direction = oe ? output | s->oe_mask : output & ~s->oe_mask; + direction = oe ? direction | s->oe_mask : direction & ~s->oe_mask; else output = oe ? output | s->oe_mask : output & ~s->oe_mask;