From: Andy Shevchenko Date: Fri, 24 Apr 2020 16:11:45 +0000 (+0300) Subject: dmaengine: dmatest: Allow negative timeout value to specify infinite wait X-Git-Tag: Ubuntu-5.13.0-19.19~5804^2~16 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=35c5fc028511c743db5313f0ef8cac35141706e9;p=mirror_ubuntu-jammy-kernel.git dmaengine: dmatest: Allow negative timeout value to specify infinite wait The dmatest module parameter 'timeout' is documented as accepting a -1 to mean "infinite timeout". However, an infinite timeout is not advised, nor possible since the module parameter is an unsigned int, which won't accept a negative value. Change the parameter type to be signed integer. Cc: Gary Hook Signed-off-by: Andy Shevchenko Link: https://lore.kernel.org/r/20200424161147.16895-4-andriy.shevchenko@linux.intel.com Signed-off-by: Vinod Koul --- diff --git a/drivers/dma/dmatest.c b/drivers/dma/dmatest.c index d02089850ec1..f86903661428 100644 --- a/drivers/dma/dmatest.c +++ b/drivers/dma/dmatest.c @@ -60,7 +60,7 @@ MODULE_PARM_DESC(pq_sources, "Number of p+q source buffers (default: 3)"); static int timeout = 3000; -module_param(timeout, uint, S_IRUGO | S_IWUSR); +module_param(timeout, int, S_IRUGO | S_IWUSR); MODULE_PARM_DESC(timeout, "Transfer Timeout in msec (default: 3000), " "Pass -1 for infinite timeout");