Re: [PATCH] scripts: kernel-doc: Ignore __alloc_size() attribute

From: Jonathan Corbet
Date: Tue Oct 12 2021 - 16:23:07 EST


Kees Cook <keescook@xxxxxxxxxxxx> writes:

> Fixes "Compiler Attributes: add __alloc_size() for better bounds checking"
> so that the __alloc_size() macro is ignored for function prototypes when
> generating kerndoc. Avoids warnings like:
>
> ./include/linux/slab.h:662: warning: Function parameter or member '1' not described in '__alloc_size'
> ./include/linux/slab.h:662: warning: Function parameter or member '2' not described in '__alloc_size'
> ./include/linux/slab.h:662: warning: expecting prototype for kcalloc(). Prototype was for __alloc_size() instead
>
> Suggested-by: Matthew Wilcox <willy@xxxxxxxxxxxxx>
> Reported-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
> Signed-off-by: Kees Cook <keescook@xxxxxxxxxxxx>
> ---
> scripts/kernel-doc | 1 +
> 1 file changed, 1 insertion(+)

Applied, thanks.

jon