Skip to content

Commit 6b41030

Browse files
murzinvvinodkoul
authored andcommitted
dmaengine: dmatest: Restore default for channel
In case of dmatest is built-in and no channel was configured test doesn't run with: dmatest: Could not start test, no channels configured Even though description to "channel" parameter claims that default is any. Add default channel back as it used to be rather than reject test with no channel configuration. Fixes: d53513d ("dmaengine: dmatest: Add support for multi channel testing) Reported-by: Dijil Mohan <[email protected]> Signed-off-by: Vladimir Murzin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Vinod Koul <[email protected]>
1 parent 4f30264 commit 6b41030

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

drivers/dma/dmatest.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1166,10 +1166,11 @@ static int dmatest_run_set(const char *val, const struct kernel_param *kp)
11661166
mutex_unlock(&info->lock);
11671167
return ret;
11681168
} else if (dmatest_run) {
1169-
if (is_threaded_test_pending(info))
1170-
start_threaded_tests(info);
1171-
else
1172-
pr_info("Could not start test, no channels configured\n");
1169+
if (!is_threaded_test_pending(info)) {
1170+
pr_info("No channels configured, continue with any\n");
1171+
add_threaded_test(info);
1172+
}
1173+
start_threaded_tests(info);
11731174
} else {
11741175
stop_threaded_test(info);
11751176
}

0 commit comments

Comments
 (0)