Skip to content
Commit 2f57b8d5 authored by Fabio Estevam's avatar Fabio Estevam Committed by Vinod Koul
Browse files

dmaengine: imx-sdma: Fix: Remove 'always true' comparison



event_id0 is defined as 'unsigned int', so it is always greater or
equal to zero.

Remove the unneeded comparisons to fix the following W=1 build
warning:

drivers/dma/imx-sdma.c: In function 'sdma_free_chan_resources':
drivers/dma/imx-sdma.c:1334:23: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
1334 |  if (sdmac->event_id0 >= 0)
|                       ^~
drivers/dma/imx-sdma.c: In function 'sdma_config':
drivers/dma/imx-sdma.c:1635:23: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
1635 |  if (sdmac->event_id0 >= 0) {
|

Fixes: 25962e1a ("dmaengine: imx-sdma: Fix the event id check to include RX event for UART6")
Reported-by: default avatarkernel test robot <lkp@intel.com>
Signed-off-by: default avatarFabio Estevam <festevam@gmail.com>
Reviewed-by: default avatarFrieder Schrempf <frieder.schrempf@kontron.de>
Link: https://lore.kernel.org/r/20200621155730.28766-1-festevam@gmail.com


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 1aea5c13
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment