From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f73.google.com (mail-wr1-f73.google.com [209.85.221.73]) (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 717DD3101A6 for ; Wed, 17 Jun 2026 07:35:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.73 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781681719; cv=none; b=mVXFlOOy6w+wsbn2BI8A6i85r9JCW5doBNjlKMWesGVG5xp1H8A64Ed9dumiyRyTZ/TfJ+my062Hr2PfGOaLCSzunyJp7Z49m2lSgKyRSuWnb2tyJCSYU4u5jRrDAs4XhhENJFPdM99m7VbPr9Fj/vlodlkdatC1JWVz/FHSoeg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781681719; c=relaxed/simple; bh=0+urfASc2gfxIY6c/RRftPzs6EUNdqaNb5wjiCzOB5w=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=ou0rDs41+XNzB+21joRTHGvehvput0gbsSnGdM2da1eiGJ9g3HkoO1kAnoxtbCpn6yM0sHeLBJa4CA/ydiQhqBwp17wAPUek5ThXskj1FBQQB8WHXpFDV7vA0Tk52zAFSgrOW5FlPrUG4REMwiuRDvoInRthlIDWLV+OVgv3NyU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--aliceryhl.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=PXfI1Zm7; arc=none smtp.client-ip=209.85.221.73 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--aliceryhl.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="PXfI1Zm7" Received: by mail-wr1-f73.google.com with SMTP id ffacd0b85a97d-4623bdcad2fso417480f8f.0 for ; Wed, 17 Jun 2026 00:35:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1781681716; x=1782286516; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:from:subject:message-id:references :mime-version:in-reply-to:date:from:to:cc:subject:date:message-id :reply-to; bh=0+urfASc2gfxIY6c/RRftPzs6EUNdqaNb5wjiCzOB5w=; b=PXfI1Zm70OSIYL/mmA/kTpbrk/VB/FGUft5CjJx3dTgRlJxL4vl4XRnN3GePtGAznf GTBm53t9YArYUKQ7FL1syQrJVcDkfSaT+loeqFfKTkn/PuAKgLzqp4c1S1j0JvCo6ZGP xkdh5n5OSVVcOihwwcD3PjlV79hzSv5YdqX79Cv8p0GrUbtrzWpTqHpc1943XBMzZanC eyfvzZjqGmWgJ2Rsxii7bUiyqCsWlAosyh+ZZNjEYHs9SipbFcsTEsDcv6nwcD3V9rJC vUlt3pf85S3QEEnzhHOi0Jz8Na9USglm474pH1HaWoDslJrsRQNLor919rKwxUF7AoxG bZ5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1781681716; x=1782286516; h=content-transfer-encoding:cc:to:from:subject:message-id:references :mime-version:in-reply-to:date:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=0+urfASc2gfxIY6c/RRftPzs6EUNdqaNb5wjiCzOB5w=; b=VQ3SZync+mqO0d/MSltK7sGT8mXkxupDQ0O/vAg3B0uHFAy8OB5IiTmscd7f8Gbl+n n6l6CoTpMVLgPxQdsiuT9MkSZFJoC0NgJ41MAZCLmSl2c84c13oiv4SQz9IlBPiOCs5e xlwTl9vaVWL3e4Nm8rQswgAG6BMQwjy7AkONqlfKoRHZ9x09o6YC02wS8cgSVkFmyGRj A8KlWbC3z4bdNOgC9I5d6AL5Q/ScrgkI8njO9RG4o92BrUOQcn6wwOybxuUsXyMAEBE1 jYRQDp4kTECnrEWF2txwtsX0bAid7R4T/n6OU52wMXepu9FO6FfMcstTJbVNE0WqA6ni f/xw== X-Forwarded-Encrypted: i=1; AFNElJ/OTXGH2QYvmIEomYeh+ipaPkxev3FnJvqhtPjT26IVRJeuvMMRRI+JBZMhuz+5ZZGJ2MiZtx/RE7mFDt8=@vger.kernel.org X-Gm-Message-State: AOJu0YycYT9+UryBGWtDdQn7IVLkA+8qjNt8PToy7ltJQc3WAF+6O9Ev yV+Yp7Knz6U3DqnGADc2nRNXOwvKN8Ox2gzC2jRJGGuC2Gl5jEFEeY+jmwm1znajvuFzT5t5nar xYj4yNY1E8Dpw/MhkIg== X-Received: from wrwo4.prod.google.com ([2002:a5d:6844:0:b0:45e:ed83:d3e7]) (user=aliceryhl job=prod-delivery.src-stubby-dispatcher) by 2002:a05:6000:4906:b0:45e:9420:ed16 with SMTP id ffacd0b85a97d-462370e1644mr4713138f8f.10.1781681715479; Wed, 17 Jun 2026 00:35:15 -0700 (PDT) Date: Wed, 17 Jun 2026 07:35:13 +0000 In-Reply-To: <20260616223614.16444-1-nico.antinori.7@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260616223614.16444-1-nico.antinori.7@gmail.com> Message-ID: Subject: Re: [PATCH] usb: rust: mark Device and Interface methods as inline From: Alice Ryhl To: "=?utf-8?Q?Nicol=C3=A1s?= Antinori" Cc: Miguel Ojeda , Alexandre Courbot , Andreas Hindborg , Benno Lossin , "=?utf-8?B?QmrDtnJu?= Roy Baron" , Boqun Feng , Daniel Almeida , Danilo Krummrich , Gary Guo , "Onur =?utf-8?B?w5Z6a2Fu?=" , Shuah Khan , Tamir Duberstein , Trevor Gross , linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org, linux-kernel-mentees@lists.linux.dev Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable On Tue, Jun 16, 2026 at 07:36:06PM -0300, Nicol=C3=A1s Antinori wrote: > When building the kernel using llvm-19.1.7-rust-1.85.1-x86_64, the > following symbols are generated: >=20 > $ nm vmlinux | grep ' _R'.*usb.*Device | rustfilt > ... > ffffffff823f2490 T ::dec_ref > ffffffff823f2470 T ::inc_ref > ... >=20 > $ nm vmlinux | grep ' _R'.*usb.*Interface | rustfilt > ffffffff823f2450 T ::dec_ref > ffffffff823f2430 T ::inc_ref > ... >=20 > However, these Rust symbols are trivial wrappers around the > `usb_get_dev`, `usb_put_dev`, `usb_get_intf` and `usb_put_intf` > functions. It doesn't make sense to go through a trivial wrapper > for these functions. >=20 > Link: https://github.com/Rust-for-Linux/linux/issues/1145 > Suggested-by: Alice Ryhl > Signed-off-by: Nicol=C3=A1s Antinori Reviewed-by: Alice Ryhl