From bcfd1018674522a74c0865792d69db51376a7dd9 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Wed, 22 May 2019 11:40:30 -0400 Subject: [PATCH] spi_software: Minor simplification to spi_software_prepare() Signed-off-by: Kevin O'Connor --- src/spi_software.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/spi_software.c b/src/spi_software.c index 92ffe5eb8..2d086f789 100644 --- a/src/spi_software.c +++ b/src/spi_software.c @@ -45,7 +45,7 @@ spi_software_oid_lookup(uint8_t oid) void spi_software_prepare(struct spi_software *ss) { - gpio_out_write(ss->sclk, ss->mode < 2 ? 0 : 1); + gpio_out_write(ss->sclk, ss->mode & 0x02); } void