[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y8c/ryHYsC1DjjbW@google.com>
Date: Wed, 18 Jan 2023 09:39:11 +0900
From: Sergey Senozhatsky <senozhatsky@...omium.org>
To: Arnd Bergmann <arnd@...nel.org>
Cc: Minchan Kim <minchan@...nel.org>,
Sergey Senozhatsky <senozhatsky@...omium.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Nhat Pham <nphamcs@...il.com>, Arnd Bergmann <arnd@...db.de>,
Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
Alexey Romanov <avromanov@...rdevices.ru>,
"Matthew Wilcox (Oracle)" <willy@...radead.org>,
linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] zsmalloc: avoid unused-function warning
On (23/01/17 18:04), Arnd Bergmann wrote:
> obj_allocated() can be called from two places that are each
> inside of an #ifdef. When both are disabled, the compiler warns:
>
> mm/zsmalloc.c:900:13: error: 'obj_allocated' defined but not used [-Werror=unused-function]
>
> Rather than trying to figure out the correct #ifdef, mark the
> trivial function as 'inline', which implies __maybe_unused and
> shuts up the warning.
>
> Fixes: 796c71ac728e ("zsmalloc: fix a race with deferred_handles storing")
> Signed-off-by: Arnd Bergmann <arnd@...db.de>
Reviewed-by: Sergey Senozhatsky <senozhatsky@...omium.org>
Powered by blists - more mailing lists