From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ej1-f74.google.com (mail-ej1-f74.google.com [209.85.218.74]) (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 ED6D41E4AF for ; Sun, 8 Mar 2026 15:08:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.74 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772982535; cv=none; b=Fcv3a8kB7mjSVXc13bK4Xyzw4Y8rdHQVPomqdyCaSKd9ZK5c2rfOcNbGDbHgdi4OfhxRl+hPxRmAUAhsd45ip1aI+9TKL/MwjWxXsyPUyFXMG0gMeuz4lezyfHXYB3htM0g/M6GB1dEjYD9sUI0JpzMomx0BDVixB7NYtC3VW7Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772982535; c=relaxed/simple; bh=mFK99LHKdUsRe+T0sCQq/VZyh7HJ7+oeMkEN2v6F0Ko=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=oFYBkIrb8PX5VspOdpckhPxhmy1TuSwX80xVNx4J9ZvW16CaXkwfKGxz/Az4spaVU+p/UFtnRotZnNpUKN6SsPHTNYvVxMn1gEn+3qbCQWyp9+HShbWXd2Wruyyzi0KwuHlkEvXtf3djLtyf7TsothJIfBfS5XhNfCJiVqk/lhE= 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=mAAAj3Gw; arc=none smtp.client-ip=209.85.218.74 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="mAAAj3Gw" Received: by mail-ej1-f74.google.com with SMTP id a640c23a62f3a-b943b0819cbso166005066b.0 for ; Sun, 08 Mar 2026 08:08:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1772982532; x=1773587332; darn=vger.kernel.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=LkMvYk7sOOVr/eHkJO3RqJKUvxETsQyLKsECTZgBTXM=; b=mAAAj3GwaoiN/+DzaHWynfZuZJnYGpPOTBo3A6ehJjk6lGhjmEFag55d5LB/JR0PKT CUoUOe7/8n8oHZD5fjvPk/pXYjgWujNJlWPJds8sGUAZIA88HDHwPjv0mIQBDBVIMIYj KJEnSsKR2tTdbhbGI3drZY0KLS1FzpDASxA/aki3f6I2YiGQyJtQsJmGJGC8XOMvi45+ TA7K4P/4e8DAoivaWM92LHF51vCGeYbXP7yPUyAi3uz+U8VIXL5JXkDGMxmDWpoz5wmq ObsL78gM8dKQOkzU3k2LMCUAp8IeOrxoSgBbVu/eCaPQ1UJZAnCbfsjmj8+dwEHKDSQ5 anyQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772982532; x=1773587332; h=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=LkMvYk7sOOVr/eHkJO3RqJKUvxETsQyLKsECTZgBTXM=; b=tBiEwUwi+qOdTD76E2gCdz81ICMBeA/sZ4GIfHiYAI9dKQfA1QaVjLXdoHjZBtQoIy muIpvZO5z+9s/p0wdKpDes2kFF63i7wZynzlcUNrRePyAVV9sz1/C8n3YenAkvuZPOOi YrjpaYDuVP2+uHVRLhABHiYYX9lqdxh/fbpFJUUT6r0FOIXOhG3ax8UlYHRweHGrBn68 B/Ru2l753bXwt2rM5/Cg7WbZSlllRA59/oxu7APE0liI23vomiOBjdWboHxtFOLElunF VjpH6Diwi3SILDqF6oN3RsiGQq1in0BXgYmJQHxGzuevFxYtXJ6jM9Bdg/7fRWXxYyq4 M3FA== X-Forwarded-Encrypted: i=1; AJvYcCV4bPIgoXYM33Fx0R1nmNIipbr+VuLr69TIiDKabmOinj5tONFk4NBoZ5+Nt7/YmkTqqvz3YjlSOzkWGkE=@vger.kernel.org X-Gm-Message-State: AOJu0YwzU4kTn+k6gUPy1dbemQiga02QFZILfikWLeNL/hZZMFCqndA3 HJotpki9mzT3I2nOjiPgO5WkF+iCJ71cp1WeWvvx63IdBn0fQ4q1FBnS55MjFnY28Mq4a4X/Rpi FVl0VuC2azsj0CjLK1w== X-Received: from edon12.prod.google.com ([2002:aa7:d04c:0:b0:660:dc70:2f35]) (user=aliceryhl job=prod-delivery.src-stubby-dispatcher) by 2002:a17:907:f816:b0:b83:b7c5:de2c with SMTP id a640c23a62f3a-b942dbcd35dmr433671666b.10.1772982532042; Sun, 08 Mar 2026 08:08:52 -0700 (PDT) Date: Sun, 8 Mar 2026 15:08:50 +0000 In-Reply-To: <88bd0bd2-74bd-4795-be3d-c303c75eee7e@lunn.ch> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260306-binder-netlink-v1-0-daceb5bc83f2@google.com> <20260307104131.4c1d0de5@kernel.org> <42407d43-00e9-4938-8d6c-70d83b0f2ac9@lunn.ch> <88bd0bd2-74bd-4795-be3d-c303c75eee7e@lunn.ch> Message-ID: Subject: Re: [PATCH 0/4] Rust netlink support + use in Rust Binder From: Alice Ryhl To: Andrew Lunn Cc: Jakub Kicinski , Miguel Ojeda , Boqun Feng , Gary Guo , "=?utf-8?B?QmrDtnJu?= Roy Baron" , Benno Lossin , Andreas Hindborg , Trevor Gross , Danilo Krummrich , Donald Hunter , "David S. Miller" , Eric Dumazet , Paolo Abeni , Simon Horman , Greg Kroah-Hartman , "Arve =?utf-8?B?SGrDuG5uZXbDpWc=?=" , Todd Kjos , Christian Brauner , Carlos Llamas , linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org, netdev@vger.kernel.org Content-Type: text/plain; charset="utf-8" On Sun, Mar 08, 2026 at 03:12:55PM +0100, Andrew Lunn wrote: > On Sat, Mar 07, 2026 at 10:41:09PM +0000, Alice Ryhl wrote: > > On Sat, Mar 07, 2026 at 10:39:28PM +0100, Andrew Lunn wrote: > > > > > Please no duplication of existing code in Rust. > > > > > > > > The plan is certainly to get rid of C Binder, but it was unfortunately > > > > not possible to get there without a transition period. > > > > > > Dumb question.... > > > > > > Why? > > > > The reasons for moving to a Rust implementation are discussed in the > > cover letter [1], and in my 2023 plumbers talk [2]. > > Ah, so you meant binder itself has be dual implementation for a while. Yes, that's right. > > No, it sends the same messages. The intent is for Android to move to the > > Rust implementation without userspace being able to tell the difference. > > Any reason you cannot use this Rust netlink code with the C binder? > You can then throw away the C netlink code, no code duplication. I think the benefit from that would be quite little. It would probably not have helped avoid commit 5e8a3d015442 ("binder: fix UAF in binder_netlink_report()") because that was a bug in the caller of binder_netlink_report(), rather than a bug in the function itself. And as for the benefit from avoiding duplication on its own, Binder's netlink logic is very small to begin with, so I do not think that's worth it either. It'll go away eventually when the entire C driver is deleted. Alice