From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-vk1-f174.google.com (mail-vk1-f174.google.com [209.85.221.174]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0F64F355F28 for ; Mon, 16 Mar 2026 08:21:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.174 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773649286; cv=none; b=pwwZ96E3hK4+eqK2XF4DyGbk6q8qVUdPUIWsRj3blzts5zVKLvfCES54sN/qfHdHmM1yxcmcSvAldgLzlodwOI7qMD/j/ewpn5wiVvWfTxnWwSyARjl74vAKhmG8qWUCu4SkH7FofXQtPVNETP1Ph7gZqwLVB1rxmCjrPSr5KpE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773649286; c=relaxed/simple; bh=g7S/TfR84iMcvzUx+ooTqFtTekTHlycg3CAyKm29cnk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=NCBCvys6l9aBrmPnHP+X+2/yoPtYLRlc5qrFMIk50dVawFj4Q/Hu4V/6aKhKOBLCIvYHzmbvIexF3M75jySmD5SQHkafIaDGm6CAUDYWAVOOzq5EIuV03cZu/EOki1BUEZ56Zij1kzQqSFsdrgCMh753duYVNd0iioqJb2hNxhM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=alice0.com; spf=pass smtp.mailfrom=gmail.com; arc=none smtp.client-ip=209.85.221.174 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=alice0.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-vk1-f174.google.com with SMTP id 71dfb90a1353d-56b16428b77so4543797e0c.0 for ; Mon, 16 Mar 2026 01:21:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1773649284; x=1774254084; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=kykdzT3KMd0TXKFAz/WK/nN/uUi8cpMSApP1ovckd7o=; b=hVj/9znTFcdQTa1jhzdKLUeQ6Kzco16NU8MKosexyFpKcvbPvwhP3Uhm/JM9XSobvZ 79/g7UIJ36S9BeCfcxnRiAfZY3hbriabwPFQFm0H4ePWwicC/DxN22+/e4z/pFnIHzBa rS7kp1wzfwCOnETkiBgNNGWUukf4KaoS/KsHCXHZ2255QcpsvG8A7t469qSeMB0k9Be/ GaK5pDM4JRISHO4jUwP3PACmpZR8VGIXf8YvlmPuJXwqKvOsUXg6TF89a1Qg89/joV9X uisA7M/f2SLg3XPJzIp2eFh2v7d+okyfhxYf7xBKq/UpfxJwpPNiSzMiGf855y0LTbla NMQw== X-Forwarded-Encrypted: i=1; AJvYcCX6omVgODiLQJAmiKq3sa+qOsZO50vt7lrR6F0ZY0dr4MR5N9ZkxQ+9uTU/gdj0GFNqBSftM6HBirFcMPI=@vger.kernel.org X-Gm-Message-State: AOJu0Yz7FTnGRHDBxr+1kcwkurw3qKy87h/nySiTCMZjww+XZ0moQRIH hkhDf5Q7SL4MytCs2he8QzHsyy1Rx547ELU/DI2Mk7OeTSNTh2sltvbc X-Gm-Gg: ATEYQzwbYx4vWPwJMWW2tHh7WxY45iVfT/OJLNieBGX/VonwLWrusxOh3pPul8bZ5s5 DZEiW193v0rfT8C62Una1U1eUnQFC4exz7QOcv2RwoBapX/PHgqXVWhbVJIuHKN9Ai3RmChc4NJ WUY69c3VoUySf0DPERVuDwvkOMg4fDsNgPYPioV8SSDxbtKrY6YaWTq5f73lWLnfTtsHjSB0CwR IigudeVWazO3u7Ou5BZGIbSpyn681MKGSsVTFYqZQCKmO8957vIcUmbVMcpk9B3zmDcQpiHpUUk P/l0gSuU/oPulru5v3Byawang1j/VkF8qQPGtEq8IIp0ExG9MFtX5rp82rHb/FGAVER4HH6+Ue7 9ClbXFX1ozuD0c9znIDKZwmP/2zH48oimarM5F4BHJk7S54W4Teq0wJgq5Slp2qRSGW2ZErEkF9 otLbV2GXbXw4LCz5jxJkM= X-Received: by 2002:a05:6102:c4a:b0:5ff:ba2d:17ab with SMTP id ada2fe7eead31-6020e16767fmr5280469137.8.1773649284041; Mon, 16 Mar 2026 01:21:24 -0700 (PDT) Received: from W871.localdomain ([38.183.115.123]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-601f31e7520sm5759207137.4.2026.03.16.01.21.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Mar 2026 01:21:23 -0700 (PDT) From: Fabricio Parra a@alice0.com To: Miguel Ojeda Cc: Boqun Feng , Gary Guo , =?UTF-8?q?Bj=C3=B6rn=20Roy=20Baron?= , Benno Lossin , Andreas Hindborg , Alice Ryhl , Trevor Gross , Danilo Krummrich , rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org, Fabricio Parra Subject: [PATCH] rust: sync: completion: mark inline complete_all and wait_for_completion Date: Mon, 16 Mar 2026 04:21:11 -0400 Message-ID: <20260316082111.398170-1-a@alice0.com> X-Mailer: git-send-email 2.53.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Fabricio Parra When building the kernel using the llvm-22.1.0-rust-1.93.1-x86_64 toolchain provided by kernel.org with ARCH=x86_64, the following symbols are generated: $ nm vmlinux | grep ' _R'.*Completion | rustfilt ffffffff81827930 T ::complete_all ffffffff81827950 T ::wait_for_completion These Rust methods are thin wrappers around the C completion helpers `complete_all` and `wait_for_completion`. Mark them `#[inline]` to keep the wrapper pattern consistent with other small Rust helper methods. After applying this patch, the above command will produce no output. Link: https://github.com/Rust-for-Linux/linux/issues/1145 Suggested-by: Alice Ryhl Signed-off-by: Fabricio Parra --- rust/kernel/sync/completion.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rust/kernel/sync/completion.rs b/rust/kernel/sync/completion.rs index c50012a940a3..35ff049ff078 100644 --- a/rust/kernel/sync/completion.rs +++ b/rust/kernel/sync/completion.rs @@ -94,6 +94,7 @@ fn as_raw(&self) -> *mut bindings::completion { /// /// This method wakes up all tasks waiting on this completion; after this operation the /// completion is permanently done, i.e. signals all current and future waiters. + #[inline] pub fn complete_all(&self) { // SAFETY: `self.as_raw()` is a pointer to a valid `struct completion`. unsafe { bindings::complete_all(self.as_raw()) }; @@ -105,6 +106,7 @@ pub fn complete_all(&self) { /// timeout. /// /// See also [`Completion::complete_all`]. + #[inline] pub fn wait_for_completion(&self) { // SAFETY: `self.as_raw()` is a pointer to a valid `struct completion`. unsafe { bindings::wait_for_completion(self.as_raw()) }; base-commit: 79e25710e7227228902d672417b552dd1d7e5d3b -- 2.53.0