Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mmc: mmc_spi: remove unnecessary check in mmc_spi_setup_data_message()

An earlier commit changed the outer if statement from
"if (multiple || write) {" to "if (write) {" so now we know that "write"
is true and no longer need to check. Delete the unnecessary check.

Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/r/aKcR2ea747xkw_it@stanley.mountain
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

authored by

Dan Carpenter and committed by
Ulf Hansson
1f69220b 9674f9e3

+1 -1
+1 -1
drivers/mmc/host/mmc_spi.c
··· 566 566 if (write) { 567 567 t = &host->early_status; 568 568 memset(t, 0, sizeof(*t)); 569 - t->len = write ? sizeof(scratch->status) : 1; 569 + t->len = sizeof(scratch->status); 570 570 t->tx_buf = host->ones; 571 571 t->rx_buf = scratch->status; 572 572 t->cs_change = 1;