[dpdk-stable] [PATCH v4] test/rcu: fix build for small number of cores

Thomas Monjalon thomas at monjalon.net
Mon Nov 25 23:40:43 CET 2019


25/11/2019 04:36, Gavin Hu:
> If the RTE_MAX_LCORE is less than 10, a compilation error is generated:
> app/test/test_rcu_qsbr.c:234:10: error: comparison of integer
> expressions of different signedness: ‘unsigned int’ and ‘int’
> [-Werror=sign-compare]
> 
> The cause is (RTE_MAX_LCORE - 10) results in a negative value.
> 
> To fix, use rte_rand() to find a number between 0 and RTE_MAX_LCORE.
> 
> Fixes: b87089b0bb19 ("test/rcu: add API and functional tests")
> Cc: stable at dpdk.org
> 
> Signed-off-by: Gavin Hu <gavin.hu at arm.com>
> Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli at arm.com>
> Reviewed-by: Steve Capper <steve.capper at arm.com>
> Reviewed-by: Dharmik Thakkar <dharmik.thakkar at arm.com>

Applied, thanks





More information about the stable mailing list