Linux userland API discussions
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: "André Almeida" <andrealmeid@igalia.com>,
	"Ingo Molnar" <mingo@redhat.com>,
	"Peter Zijlstra" <peterz@infradead.org>,
	"Darren Hart" <dvhart@infradead.org>,
	"Davidlohr Bueso" <dave@stgolabs.net>,
	"Arnd Bergmann" <arnd@arndb.de>,
	"Sebastian Andrzej Siewior" <bigeasy@linutronix.de>,
	"Waiman Long" <longman@redhat.com>,
	"Ryan Houdek" <Sonicadvance1@gmail.com>,
	"Thomas Gleixner" <tglx@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
	linux-kselftest@vger.kernel.org, linux-api@vger.kernel.org,
	kernel-dev@igalia.com, "André Almeida" <andrealmeid@igalia.com>
Subject: Re: [PATCH v8 04/10] futex: Create set_robust_list2() syscall
Date: Sat, 21 Nov 2026 01:14:37 +0100	[thread overview]
Message-ID: <20261121010932.k2PIHQOd-lkp@intel.com> (raw)
In-Reply-To: <20261115-tonyk-robust_futex-v8-4-a4fe47333a28@igalia.com>

Hi André,

kernel test robot noticed the following build warnings:

[auto build test WARNING on 9f74092fda91ef93c2b07585785c1dc83cd7971f]

url:    https://github.com/intel-lab-lkp/linux/commits/Andr-Almeida/futex-Skip-test_futex_robust_unlock-if-not-supported/20261115-143110
base:   9f74092fda91ef93c2b07585785c1dc83cd7971f
patch link:    https://lore.kernel.org/r/20261115-tonyk-robust_futex-v8-4-a4fe47333a28%40igalia.com
patch subject: [PATCH v8 04/10] futex: Create set_robust_list2() syscall
config: nios2-randconfig-r2306-20261120 (https://download.01.org/0day-ci/archive/20261121/20261121010932.k2PIHQOd-lkp@intel.com/config)
compiler: nios2-linux-gcc (GCC) 8.5.0
sparse: v0.6.5-rc1-21-g84ec0658
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261121/20261121010932.k2PIHQOd-lkp@intel.com/reproduce)

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/20261121010932.k2PIHQOd-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> kernel/futex/syscalls.c:111:46: sparse: sparse: dereference of noderef expression

vim +111 kernel/futex/syscalls.c

   107	
   108	SYSCALL_DEFINE4(set_robust_list2, struct robust_list_head * __user, head, unsigned int,
   109			cmd, unsigned int, index, unsigned int, flags)
   110	{
 > 111		uintptr_t entry = (__force uintptr_t)head;
   112		size_t align = sizeof(u32);
   113		int ret;
   114	
   115		if (flags)
   116			return -EINVAL;
   117	
   118		if (cmd >= FUTEX_ROBUST_LIST_CMD_USER_MAX)
   119			return -EINVAL;
   120	
   121		if (cmd == FUTEX_ROBUST_LIST_CMD_CREATE_64 ||
   122		    cmd == FUTEX_ROBUST_LIST_CMD_MODIFY_64) {
   123			if (futex_in_32bit_syscall())
   124				return -EOPNOTSUPP;
   125			align = sizeof(u64);
   126		}
   127	
   128		switch (cmd) {
   129		case FUTEX_ROBUST_LIST_CMD_CREATE_64:
   130		case FUTEX_ROBUST_LIST_CMD_CREATE_32:
   131			if (index)
   132				return -EINVAL;
   133	
   134			if (entry % align)
   135				return -EINVAL;
   136	
   137			/*
   138			 * The first two indexes are reserved for the kernel to be used
   139			 * with the legacy syscall, so we hide them from userspace.
   140			 *
   141			 * We map [0, FUTEX_ROBUST_LISTS_PER_USER) to
   142			 *  [FUTEX_ROBUST_LIST2_IDX, FUTEX_ROBUST_LIST2_MAX_IDX)
   143			 */
   144			ret = futex_robust_list_create(entry, cmd);
   145	
   146			if (ret >= 0)
   147				ret -= FUTEX_ROBUST_LIST2_IDX;
   148	
   149			return ret;
   150	
   151		case FUTEX_ROBUST_LIST_CMD_MODIFY_64:
   152		case FUTEX_ROBUST_LIST_CMD_MODIFY_32:
   153			if (entry % align)
   154				return -EINVAL;
   155			return futex_robust_list_modify(entry, cmd, index);
   156		case FUTEX_ROBUST_LIST_CMD_LIST_LIMIT:
   157			return FUTEX_ROBUST_LISTS_PER_USER;
   158		}
   159	
   160		return -EINVAL;
   161	}
   162	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  reply	other threads:[~2026-11-21  0:15 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-15 17:31 [PATCH v8 00/10] futex: Create {set,get}_robust_list2() syscalls André Almeida
2026-11-15 17:31 ` [PATCH v8 01/10] futex: Skip test_futex_robust_unlock() if not supported André Almeida
2026-11-15 17:31 ` [PATCH v8 02/10] futex: Use explicit sizes for compat_robust_list structs André Almeida
2026-11-15 17:31 ` [PATCH v8 03/10] futex: Make exit_robust_list32() unconditionally available for 64-bit kernels André Almeida
2026-11-15 17:31 ` [PATCH v8 04/10] futex: Create set_robust_list2() syscall André Almeida
2026-11-21  0:14   ` kernel test robot [this message]
2026-11-15 17:31 ` [PATCH v8 05/10] futex: Create get_robust_list2() syscall André Almeida
2026-11-21  0:35   ` kernel test robot
2026-11-21  0:46   ` kernel test robot
2026-11-15 17:31 ` [PATCH v8 06/10] futex: Wire up set_robust_list2 syscall André Almeida
2026-11-15 20:55   ` kernel test robot
2026-11-15 21:30   ` kernel test robot
2026-11-15 17:31 ` [PATCH v8 07/10] futex: Wire up get_robust_list2 syscall André Almeida
2026-11-15 17:31 ` [PATCH v8 08/10] selftests/futex: Expand for set_robust_list2() André Almeida
2026-11-15 17:31 ` [PATCH v8 09/10] selftests/futex: Expand for get_robust_list2() André Almeida
2026-11-15 17:31 ` [PATCH v8 10/10] futex: Use new robust list API internally André Almeida
2026-11-15 20:44   ` kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261121010932.k2PIHQOd-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=Sonicadvance1@gmail.com \
    --cc=andrealmeid@igalia.com \
    --cc=arnd@arndb.de \
    --cc=bigeasy@linutronix.de \
    --cc=dave@stgolabs.net \
    --cc=dvhart@infradead.org \
    --cc=kernel-dev@igalia.com \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=longman@redhat.com \
    --cc=mingo@redhat.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=peterz@infradead.org \
    --cc=tglx@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox