From nobody Mon Jun 8 05:26:40 2026 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 58B6D3F4842; Fri, 5 Jun 2026 13:08:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780664893; cv=none; b=YoDE4huKsZiOPaFHZVC0SLLGx6psSJJXYHeb+VGwrUj4An21F8Y6vn1jQU0kRVZz6wJfF+QiKHgP3GnJhQGf+ZsNgrHmDLlbA6glDPnct8Dr7zJInWqeczUVjaumg6AcOIG3Ho67/wk9Co0dvu8ecgNA6CBjH9EzF9/DO07BOws= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780664893; c=relaxed/simple; bh=fHfUmONbQ3jshtV9C6VewEMjPEtyd55x1CNUjqNhrZ8=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=uQWiJX5q+FLp7Gb0+qvoXQCJmk3bp/DYzEERPTRm3dDCkyON4Y20QoJA7l+qmwKSRtAxb7PFibkZnqZeX0WDpgGvouYMj0SppUm3jTGS1rZYGcsBpzqUCwK/03i9jC69CmSqyhbDVOU8Wwi0+mH2ApFL+er43EibaqhKhN3MliI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=M/bBOA42; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=qlOnxmF7; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="M/bBOA42"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="qlOnxmF7" Date: Fri, 05 Jun 2026 13:08:09 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1780664890; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=A2KzMN1naNHlCwlhJamIKIAU1Y7Wqy7FMdH4jaqconM=; b=M/bBOA42uDK1OFzmk1qD3JInXhLNIOcxAgRWB9WQDBOmPpwympZpuJLX63kxC2/NZIyCky t4G8hPuQ59Q8HPJaBOdlvdPe3lQTpOzET9B81OTml7L/Nko8wwsOdSIoxmU+uEt6vRx/21 dP8lpdXXRYSRxV5F0S/+mOxG0E4/hAi3hi91UFmz+srmPVdjEVhRQlokxSNflcji1RPPJo cLS7Hvxe03084zPJRLvbWIlDjV3eO6WZd7ugleHNQ/oYBlDJuxo84VbxD7dCztFpuy9jv4 d49yPD2AjKr67VnDVxFGuFsE6wRKPDPS3bDNLIu9d0V1etasY6tkWCfBnkXjJg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1780664890; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=A2KzMN1naNHlCwlhJamIKIAU1Y7Wqy7FMdH4jaqconM=; b=qlOnxmF7aQUz1u6/ROpeUR3ATYzWJgeIlkApqMxxMte4RjZusGP0cneZuJ8KzTMkzJvWbc 2nI6YStUXwfe7eDw== From: "tip-bot2 for Dmitry Ilvokhin" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: locking/core] cleanup: Specify nonnull argument index Cc: Dan Carpenter , Dmitry Ilvokhin , "Peter Zijlstra (Intel)" , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <178066488924.710.16327470691661981001.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable The following commit has been merged into the locking/core branch of tip: Commit-ID: a40e0f8eadd44d7b0f856b54c876aea1b93415f4 Gitweb: https://git.kernel.org/tip/a40e0f8eadd44d7b0f856b54c876aea1b= 93415f4 Author: Dmitry Ilvokhin AuthorDate: Fri, 05 Jun 2026 03:06:22 -07:00 Committer: Peter Zijlstra CommitterDate: Fri, 05 Jun 2026 14:46:51 +02:00 cleanup: Specify nonnull argument index The guard constructors were annotated with an empty __nonnull_args(), relying on __nonnull__() marking every pointer parameter as non-NULL. Sparse cannot parse the empty argument list. Both constructors take the lock pointer as their first parameter, so specify the index explicitly: __nonnull_args(1). Reported-by: Dan Carpenter Closes: https://lore.kernel.org/all/aiJi0WcYE8FZt-jO@stanley.mountain/ Signed-off-by: Dmitry Ilvokhin Signed-off-by: Peter Zijlstra (Intel) Link: https://patch.msgid.link/aiKpH3cLBEj3TF2Q@shell.ilvokhin.com --- include/linux/cleanup.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/cleanup.h b/include/linux/cleanup.h index 6541693..b1b5698 100644 --- a/include/linux/cleanup.h +++ b/include/linux/cleanup.h @@ -397,7 +397,7 @@ static __maybe_unused const bool class_##_name##_is_con= ditional =3D _is_cond __DEFINE_GUARD_LOCK_PTR(_name, _T) =20 #define DEFINE_GUARD(_name, _type, _lock, _unlock) \ - static __always_inline __nonnull_args() _type class_##_name##_constructor= (_type _T); \ + static __always_inline __nonnull_args(1) _type class_##_name##_constructo= r(_type _T); \ DEFINE_CLASS(_name, _type, _unlock, ({ _lock; _T; }), _type _T); \ DEFINE_CLASS_IS_GUARD(_name) =20 @@ -498,7 +498,7 @@ static __always_inline void class_##_name##_destructor(= class_##_name##_t *_T) \ __DEFINE_GUARD_LOCK_PTR(_name, &_T->lock) =20 #define __DEFINE_LOCK_GUARD_1(_name, _type, ...) \ -static __always_inline __nonnull_args() \ +static __always_inline __nonnull_args(1) \ class_##_name##_t class_##_name##_constructor(_type *l) \ __no_context_analysis \ { \