Re: [RFC] clang: 'unused-function' warning on static inline functions

From: Arnd Bergmann
Date: Thu Jun 08 2017 - 04:59:47 EST


On Wed, Jun 7, 2017 at 9:43 PM, Arnd Bergmann <arnd@xxxxxxxx> wrote:
> On Tue, Jun 6, 2017 at 11:28 PM, Linus Torvalds
> <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:

> I even found one function that should be called but is not:
> __ila_hash_secret_init(). This one might be a serious bug,
> or it might be harmless.
>
> [Adding Tom Herbert to Cc here, Tom, please have a look
> at net/ipv6/ila/ila_xlat.c for the missing initialization of hashrnd]

I submitted a patch for this one now, and another one for a function
in kernel/cpu.c that was obviously meant to be removed not too long
ago. I checked that all other instances of the warning I found in the
kernel are indeed harmless and don't need a patch when there is
no warning.

Arnd