mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 12:43:29 +02:00
bitmap_parse: Support 'all' semantics
RCU code supports an 'all' group as a special case when parsing rcu_nocbs parameter. This patch moves the 'all' support to the core bitmap_parse code, so that all bitmap users can enjoy this extension. Moving 'all' parsing to a bitmap_parse level also allows users to pass patterns together with 'all' in regular group:pattern format, for example, "rcu_nocbs=all:1/2" would offload all the even-numbered CPUs regardless of the number of CPUs on the system. Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Yury Norov <yury.norov@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
This commit is contained in:
committed by
Paul E. McKenney
parent
6efb943b86
commit
b18def121f
@@ -366,6 +366,13 @@ static const struct test_bitmap_parselist parselist_tests[] __initconst = {
|
||||
{0, "0-31:1/3,1-31:1/3,2-31:1/3", &exp1[8 * step], 32, 0},
|
||||
{0, "1-10:8/12,8-31:24/29,0-31:0/3", &exp1[9 * step], 32, 0},
|
||||
|
||||
{0, "all", &exp1[8 * step], 32, 0},
|
||||
{0, "0, 1, all, ", &exp1[8 * step], 32, 0},
|
||||
{0, "all:1/2", &exp1[4 * step], 32, 0},
|
||||
{0, "ALL:1/2", &exp1[4 * step], 32, 0},
|
||||
{-EINVAL, "al", NULL, 8, 0},
|
||||
{-EINVAL, "alll", NULL, 8, 0},
|
||||
|
||||
{-EINVAL, "-1", NULL, 8, 0},
|
||||
{-EINVAL, "-0", NULL, 8, 0},
|
||||
{-EINVAL, "10-1", NULL, 8, 0},
|
||||
|
Reference in New Issue
Block a user