Hi. On Fri, Nov 27, 2020 at 04:50:34PM +0000, Jonathon Fernyhough wrote: > On 25/11/2020 10:28, Ard Biesheuvel wrote: > > On Wed, 25 Nov 2020 at 11:27, Oleksandr Natalenko > > <oleksandr@xxxxxxxxxxxxxx> wrote: > >> > >> On 25.11.2020 08:53, Ard Biesheuvel wrote: > --snip-- > >> > >> Do we need to do this as well: > >> > >> #include <linux/kmemleak.h> > >> > >> ? > >> > >> Because otherwise for 5.9 I get: > >> > >> [ 148s] fs/efivarfs/inode.c: In function 'efivarfs_create': > >> [ 148s] fs/efivarfs/inode.c:106:2: error: implicit declaration of > >> function 'kmemleak_ignore' [-Werror=implicit-function-declaration] > >> [ 148s] 106 | kmemleak_ignore(var); > >> [ 148s] | ^~~~~~~~~~~~~~~ > >> > > > > Ah yes, thanks for the report. I will add the include to the patch. > > > > > > Is this necessary if CONFIG_DEBUG_KMEMLEAK is not enabled in the kernel > config? e.g. should there be an #ifdef CONFIG_DEBUG_KMEMLEAK somewhere > in there? kmemleak_ignore() is a noop if CONFIG_DEBUG_KMEMLEAK is not set. See include/linux/kmemleak.h. Thus no extra condition is needed here. -- Oleksandr Natalenko (post-factum)