[openeuler:OLK-6.6 2972/2972] mm/memcontrol.c:8068:35: sparse: sparse: incorrect type in initializer (incompatible argument 3 (different address spaces))

tree: https://gitee.com/openeuler/kernel.git OLK-6.6 head: f974d7dec2997dfe2d417f1c9cc0e2a6adb2d25c commit: 65b18684d289783f92db2eb97d60bf24c9200cf7 [2972/2972] memcg: introduce memcg swap qos feature config: x86_64-randconfig-r121-20251016 (https://download.01.org/0day-ci/archive/20251016/202510160946.S2au7i5E-lkp@i...) compiler: gcc-14 (Debian 14.2.0-19) 14.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251016/202510160946.S2au7i5E-lkp@i...) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202510160946.S2au7i5E-lkp@intel.com/ sparse warnings: (new ones prefixed by >>) mm/memcontrol.c:4255:50: sparse: sparse: incorrect type in argument 3 (different address spaces) @@ expected void * @@ got void [noderef] __user *buffer @@ mm/memcontrol.c:4255:50: sparse: expected void * mm/memcontrol.c:4255:50: sparse: got void [noderef] __user *buffer mm/memcontrol.c:4516:21: sparse: sparse: incompatible types in comparison expression (different address spaces): mm/memcontrol.c:4516:21: sparse: struct mem_cgroup_threshold_ary [noderef] __rcu * mm/memcontrol.c:4516:21: sparse: struct mem_cgroup_threshold_ary * mm/memcontrol.c:4518:21: sparse: sparse: incompatible types in comparison expression (different address spaces): mm/memcontrol.c:4518:21: sparse: struct mem_cgroup_threshold_ary [noderef] __rcu * mm/memcontrol.c:4518:21: sparse: struct mem_cgroup_threshold_ary * mm/memcontrol.c:4674:9: sparse: sparse: incompatible types in comparison expression (different address spaces): mm/memcontrol.c:4674:9: sparse: struct mem_cgroup_threshold_ary [noderef] __rcu * mm/memcontrol.c:4674:9: sparse: struct mem_cgroup_threshold_ary * mm/memcontrol.c:4768:9: sparse: sparse: incompatible types in comparison expression (different address spaces): mm/memcontrol.c:4768:9: sparse: struct mem_cgroup_threshold_ary [noderef] __rcu * mm/memcontrol.c:4768:9: sparse: struct mem_cgroup_threshold_ary * mm/memcontrol.c:6811:23: sparse: sparse: incompatible types in comparison expression (different address spaces): mm/memcontrol.c:6811:23: sparse: struct task_struct [noderef] __rcu * mm/memcontrol.c:6811:23: sparse: struct task_struct * mm/memcontrol.c:7028:52: sparse: sparse: incompatible types in comparison expression (different address spaces): mm/memcontrol.c:7028:52: sparse: struct task_struct [noderef] __rcu * mm/memcontrol.c:7028:52: sparse: struct task_struct *
mm/memcontrol.c:8068:35: sparse: sparse: incorrect type in initializer (incompatible argument 3 (different address spaces)) @@ expected int ( [usertype] *proc_handler )( ... ) @@ got int ( * )( ... ) @@ mm/memcontrol.c:8068:35: sparse: expected int ( [usertype] *proc_handler )( ... ) mm/memcontrol.c:8068:35: sparse: got int ( * )( ... ) mm/memcontrol.c: note: in included file: include/linux/memcontrol.h:786:9: sparse: sparse: context imbalance in 'folio_lruvec_lock' - wrong count at exit include/linux/memcontrol.h:786:9: sparse: sparse: context imbalance in 'folio_lruvec_lock_irq' - wrong count at exit include/linux/memcontrol.h:786:9: sparse: sparse: context imbalance in 'folio_lruvec_lock_irqsave' - wrong count at exit mm/memcontrol.c:2135:6: sparse: sparse: context imbalance in 'folio_memcg_lock' - wrong count at exit mm/memcontrol.c:2182:17: sparse: sparse: context imbalance in '__folio_memcg_unlock' - unexpected unlock mm/memcontrol.c:6671:9: sparse: sparse: context imbalance in 'mem_cgroup_count_precharge_pte_range' - unexpected unlock mm/memcontrol.c:6939:9: sparse: sparse: context imbalance in 'mem_cgroup_move_charge_pte_range' - unexpected unlock
vim +8068 mm/memcontrol.c 8044 8045 #ifdef CONFIG_SYSCTL 8046 static struct ctl_table mem_cgroup_sysctls[] = { 8047 #ifdef CONFIG_MEMCG_OOM_PRIORITY 8048 { 8049 /* 8050 * This sysctl is used to control memcg oom priority 8051 * feature, the sysctl name is for compatibility. 8052 */ 8053 .procname = "memcg_qos_enable", 8054 .data = &sysctl_memcg_oom_prio, 8055 .maxlen = sizeof(int), 8056 .mode = 0644, 8057 .proc_handler = sysctl_memcg_oom_prio_handler, 8058 .extra1 = SYSCTL_ZERO, 8059 .extra2 = SYSCTL_ONE, 8060 }, 8061 #endif 8062 #ifdef CONFIG_MEMCG_SWAP_QOS 8063 { 8064 .procname = "memcg_swap_qos_enable", 8065 .data = &sysctl_memcg_swap_qos_stat, 8066 .maxlen = sizeof(int), 8067 .mode = 0644,
8068 .proc_handler = sysctl_memcg_swap_qos_handler, 8069 .extra1 = SYSCTL_ZERO, 8070 .extra2 = SYSCTL_ONE, 8071 }, 8072 #endif 8073 }; 8074
-- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
participants (1)
-
kernel test robot