[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202204250949.KPASl3Sz-lkp@intel.com>
Date: Mon, 25 Apr 2022 09:30:24 +0800
From: kernel test robot <lkp@...el.com>
To: Ingo Molnar <mingo@...nel.org>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [mingo-tip:sched/headers 1805/2579] include/linux/gfp_api.h:26:27:
sparse: sparse: restricted gfp_t degrades to integer
tree: git://git.kernel.org/pub/scm/linux/kernel/git/mingo/tip.git sched/headers
head: 49e1ec6c70a6eb4b7de9250a455b8b63eb42afbe
commit: ae3f246b57ee3809edbb8b4bc6f887cc0e9e2f9e [1805/2579] headers/deps: mm: Create <linux/gfp_api.h>
config: i386-randconfig-s001 (https://download.01.org/0day-ci/archive/20220425/202204250949.KPASl3Sz-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.2.0-20) 11.2.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.4-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/mingo/tip.git/commit/?id=ae3f246b57ee3809edbb8b4bc6f887cc0e9e2f9e
git remote add mingo-tip git://git.kernel.org/pub/scm/linux/kernel/git/mingo/tip.git
git fetch --no-tags mingo-tip sched/headers
git checkout ae3f246b57ee3809edbb8b4bc6f887cc0e9e2f9e
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=i386 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
sparse warnings: (new ones prefixed by >>)
mm/page_owner.c: note: in included file (through include/linux/mm.h, include/linux/mm_api.h):
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
--
mm/compaction.c: note: in included file (through include/trace/trace_events.h, include/trace/define_trace.h, include/trace/events/compaction.h):
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast from restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: incorrect type in argument 3 (different base types) @@ expected unsigned long flags @@ got restricted gfp_t [usertype] gfp_mask @@
include/trace/events/compaction.h:155:1: sparse: expected unsigned long flags
include/trace/events/compaction.h:155:1: sparse: got restricted gfp_t [usertype] gfp_mask
mm/compaction.c: note: in included file (through include/trace/trace_events.h, include/trace/define_trace.h, include/trace/events/compaction.h):
include/trace/events/compaction.h:155:1: sparse: sparse: cast to restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: cast to restricted gfp_t
include/trace/events/compaction.h:155:1: sparse: sparse: restricted gfp_t degrades to integer
include/trace/events/compaction.h:155:1: sparse: sparse: restricted gfp_t degrades to integer
mm/compaction.c:2619:39: sparse: sparse: incorrect type in initializer (different base types) @@ expected int may_perform_io @@ got restricted gfp_t @@
mm/compaction.c:2619:39: sparse: expected int may_perform_io
mm/compaction.c:2619:39: sparse: got restricted gfp_t
mm/compaction.c:555:39: sparse: sparse: context imbalance in 'compact_unlock_should_abort' - unexpected unlock
mm/compaction.c:675:39: sparse: sparse: context imbalance in 'isolate_freepages_block' - unexpected unlock
mm/compaction.c: note: in included file (through include/linux/mm.h, include/linux/huge_mm.h):
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
--
mm/page_alloc.c: note: in included file (through include/linux/mm.h, include/linux/huge_mm.h):
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
>> include/linux/gfp_api.h:26:27: sparse: sparse: restricted gfp_t degrades to integer
vim +26 include/linux/gfp_api.h
15
16 static inline int gfp_migratetype(const gfp_t gfp_flags)
17 {
18 VM_WARN_ON((gfp_flags & GFP_MOVABLE_MASK) == GFP_MOVABLE_MASK);
19 BUILD_BUG_ON((1UL << GFP_MOVABLE_SHIFT) != ___GFP_MOVABLE);
20 BUILD_BUG_ON((___GFP_MOVABLE >> GFP_MOVABLE_SHIFT) != MIGRATE_MOVABLE);
21
22 if (unlikely(page_group_by_mobility_disabled))
23 return MIGRATE_UNMOVABLE;
24
25 /* Group based on mobility */
> 26 return (gfp_flags & GFP_MOVABLE_MASK) >> GFP_MOVABLE_SHIFT;
27 }
28 #undef GFP_MOVABLE_MASK
29 #undef GFP_MOVABLE_SHIFT
30
--
0-DAY CI Kernel Test Service
https://01.org/lkp
Powered by blists - more mailing lists