summaryrefslogtreecommitdiff
path: root/src/stm/ao_serial_stm.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2018-09-11 10:40:24 -0700
committerKeith Packard <keithp@keithp.com>2018-10-13 08:23:25 -0700
commitcdaa0d7b272505c49017f409b7c0b8e3240608f0 (patch)
tree75a8777ac04f7d4cc31260a5a7fd9dc9e3576948 /src/stm/ao_serial_stm.c
parentf7ca88282466c271bad5e25e804729580fe83c47 (diff)
altos: Eliminate 'pin' field from GPIO functions
This was used with the 8051 bit-addressing mode to provide single-instruction access to GPIO pins. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/stm/ao_serial_stm.c')
-rw-r--r--src/stm/ao_serial_stm.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/stm/ao_serial_stm.c b/src/stm/ao_serial_stm.c
index 2afee5b5..c1a2f1bd 100644
--- a/src/stm/ao_serial_stm.c
+++ b/src/stm/ao_serial_stm.c
@@ -33,7 +33,7 @@ _ao_usart_tx_start(struct ao_stm_usart *usart)
{
if (!ao_fifo_empty(usart->tx_fifo)) {
#if HAS_SERIAL_SW_FLOW
- if (usart->gpio_cts && ao_gpio_get(usart->gpio_cts, usart->pin_cts, foo) == 1) {
+ if (usart->gpio_cts && ao_gpio_get(usart->gpio_cts, usart->pin_cts) == 1) {
ao_exti_enable(usart->gpio_cts, usart->pin_cts);
return 0;
}
@@ -73,7 +73,7 @@ _ao_usart_rx(struct ao_stm_usart *usart, int is_stdin)
* for it to drain a bunch
*/
if (usart->gpio_rts && ao_fifo_mostly(usart->rx_fifo)) {
- ao_gpio_set(usart->gpio_rts, usart->pin_rts, usart->pin_rts, 1);
+ ao_gpio_set(usart->gpio_rts, usart->pin_rts, 1);
usart->rts = 0;
}
#endif
@@ -118,7 +118,7 @@ _ao_usart_pollchar(struct ao_stm_usart *usart)
#if HAS_SERIAL_SW_FLOW
/* If we've cleared RTS, check if there's space now and turn it back on */
if (usart->gpio_rts && usart->rts == 0 && ao_fifo_barely(usart->rx_fifo)) {
- ao_gpio_set(usart->gpio_rts, usart->pin_rts, foo, 0);
+ ao_gpio_set(usart->gpio_rts, usart->pin_rts, 0);
usart->rts = 1;
}
#endif
@@ -403,7 +403,7 @@ ao_serial_set_sw_rts_cts(struct ao_stm_usart *usart,
{
/* Pull RTS low to note that there's space in the FIFO
*/
- ao_enable_output(port_rts, pin_rts, foo, 0);
+ ao_enable_output(port_rts, pin_rts, 0);
usart->gpio_rts = port_rts;
usart->pin_rts = pin_rts;
usart->rts = 1;