From: Haolin Li Date: Sat, 6 Nov 2021 10:03:34 +0000 (-0700) Subject: spi: mxc_spi: remove redundant code in spi_xchg_single() X-Git-Url: http://git.dujemihanovic.xyz/login.html?a=commitdiff_plain;h=6f753d8cea77e1c3bda84237be786118d0cc719d;p=u-boot.git spi: mxc_spi: remove redundant code in spi_xchg_single() The value of cnt is overwritten without being used. Signed-off-by: Haolin Li Reviewed-by: Fabio Estevam --- diff --git a/drivers/spi/mxc_spi.c b/drivers/spi/mxc_spi.c index 3c53de165d..5adfdf8b5f 100644 --- a/drivers/spi/mxc_spi.c +++ b/drivers/spi/mxc_spi.c @@ -391,8 +391,6 @@ int spi_xchg_single(struct mxc_spi_slave *mxcs, unsigned int bitlen, nbytes = DIV_ROUND_UP(bitlen, 8); - cnt = nbytes % 32; - if (bitlen % 32) { data = reg_read(®s->rxdata); cnt = (bitlen % 32) / 8;