Re: [PATCH mm v2] tracing: incorrect gfp_t conversion

From: Steven Rostedt
Date: Sun May 15 2022 - 18:09:11 EST


On Wed, 11 May 2022 10:20:39 +0300
Vasily Averin <vvs@xxxxxxxxxx> wrote:

> Fixes the following sparse warnings:
>
> include/trace/events/*: sparse: cast to restricted gfp_t
> include/trace/events/*: sparse: restricted gfp_t degrades to integer
>
> gfp_t type is bitwise and requires __force attributes for any casts.
>
> Signed-off-by: Vasily Averin <vvs@xxxxxxxxxx>
> ---
> v2: 1) re-based to 5.18-rc6
> 2) re-defined __def_gfpflag_names array according to
> akpm@, willy@ and Joe Perches recommendations
> ---
> include/linux/gfp.h | 2 +-
> include/trace/events/btrfs.h | 4 +-
> include/trace/events/compaction.h | 4 +-
> include/trace/events/kmem.h | 12 ++---
> include/trace/events/mmflags.h | 84 ++++++++++++++++---------------
> include/trace/events/vmscan.h | 16 +++---
> mm/compaction.c | 2 +-
> 7 files changed, 63 insertions(+), 61 deletions(-)

>From the tracing POV:

Acked-by: Steven Rostedt (Google) <rostedt@xxxxxxxxxxx>

-- Steve