]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: pxamci: fix enum type confusion
authorArnd Bergmann <arnd@arndb.de>
Thu, 7 Mar 2019 10:09:19 +0000 (11:09 +0100)
committerUlf Hansson <ulf.hansson@linaro.org>
Mon, 18 Mar 2019 10:00:41 +0000 (11:00 +0100)
commite3affe0eb6ee50522097f91f9322d4e4d1998318
treec40fd09c686a0de0c5feabe63bdf3be99280a16c
parente34ba0d7c8ee128a8a7cc0a1d0345206aeb6a4e5
mmc: pxamci: fix enum type confusion

clang points out several instances of mismatched types in this drivers,
all coming from a single declaration:

drivers/mmc/host/pxamci.c:193:15: error: implicit conversion from enumeration type 'enum dma_transfer_direction' to
      different enumeration type 'enum dma_data_direction' [-Werror,-Wenum-conversion]
                direction = DMA_DEV_TO_MEM;
                          ~ ^~~~~~~~~~~~~~
drivers/mmc/host/pxamci.c:212:62: error: implicit conversion from enumeration type 'enum dma_data_direction' to
      different enumeration type 'enum dma_transfer_direction' [-Werror,-Wenum-conversion]
        tx = dmaengine_prep_slave_sg(chan, data->sg, host->dma_len, direction,

The behavior is correct, so this must be a simply typo from
dma_data_direction and dma_transfer_direction being similarly named
types with a similar purpose.

Fixes: cae616ecb106 ("mmc: pxamci: switch over to dmaengine use")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Nathan Chancellor <natechancellor@gmail.com>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Cc: stable@vger.kernel.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/pxamci.c