From: Matthew Wilcox Date: Mon, 15 Oct 2018 20:23:08 +0000 (-0400) Subject: test_ida: Fix lockdep warning X-Git-Tag: v4.19~27^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c994b12945a65cd892ca2cf7ddcf0b7d8b25cdec;p=platform%2Fkernel%2Flinux-rpi.git test_ida: Fix lockdep warning The IDA was declared on the stack instead of statically, so lockdep triggered a warning that it was improperly initialised. Reported-by: 0day bot Tested-by: Rong Chen Signed-off-by: Matthew Wilcox --- diff --git a/lib/test_ida.c b/lib/test_ida.c index 2d1637d..b068806 100644 --- a/lib/test_ida.c +++ b/lib/test_ida.c @@ -150,10 +150,10 @@ static void ida_check_conv(struct ida *ida) IDA_BUG_ON(ida, !ida_is_empty(ida)); } +static DEFINE_IDA(ida); + static int ida_checks(void) { - DEFINE_IDA(ida); - IDA_BUG_ON(&ida, !ida_is_empty(&ida)); ida_check_alloc(&ida); ida_check_destroy(&ida);