projects
/
contrib
/
mraa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
79d1acd
)
uart: fix issue where a index is checked before set
author
Thomas Ingleby
<thomas.c.ingleby@intel.com>
Mon, 29 Jun 2015 18:51:34 +0000
(19:51 +0100)
committer
Thomas Ingleby
<thomas.c.ingleby@intel.com>
Mon, 29 Jun 2015 18:51:34 +0000
(19:51 +0100)
Related to #152
Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
src/uart/uart.c
patch
|
blob
|
history
diff --git
a/src/uart/uart.c
b/src/uart/uart.c
index
6ab5e7f
..
22868a5
100644
(file)
--- a/
src/uart/uart.c
+++ b/
src/uart/uart.c
@@
-142,8
+142,8
@@
mraa_uart_init(int index)
}
}
+ pos = plat->uart_dev[index].tx;
if (pos >= 0) {
- pos = plat->uart_dev[index].tx;
if (plat->pins[pos].uart.mux_total > 0) {
if (mraa_setup_mux_mapped(plat->pins[pos].uart) != MRAA_SUCCESS) {
syslog(LOG_ERR, "uart: failed to setup muxes for TX pin");