From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6C260EE57C0 for ; Wed, 11 Sep 2024 15:21:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=NhVrLmjC0R7D9xdKCL/D6dm1SqJK/hT2oEhSthTAA+4=; b=oLQHMWFOklO2lPZhzWNL7CxNah NEOE8bo4crSEByKaF7/mPJNjD6tiTA6w3/+x25GB4W5rwtITCGuGq8/O+nuJGVRah+oTeBPBYQ1RC 1Y9OKPY6aYcJ7/f8wb3rubDnOroVkJxLuwQhPd0VUwJzAKPac+GB+SInmyR0sYbzZPAAW55iOOgYo TN/dInkgGh16jwpvXJO4VEdTXBpqbNmIJdhXTB3gfzwu971CQcrrUy3EQrzxOaGqqqgjnth6nvwdY bJuAxmd2Z1LS1qPjixstX+HdhIQ+zrVuS5pwGmJ21KfH8tPPwiNvlHJ/0608IJN2MESoo6tvMff32 hIFWhQUg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1soPA0-0000000A7II-3QLC; Wed, 11 Sep 2024 15:21:36 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1soOlW-0000000A28m-3z1u for linux-arm-kernel@lists.infradead.org; Wed, 11 Sep 2024 14:56:20 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id 820A35C06C6; Wed, 11 Sep 2024 14:56:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 39136C4CECF; Wed, 11 Sep 2024 14:56:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1726066577; bh=OPBj4Qudavihi4KmrNd2ipOv17IedhIybARx9D2kEns=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=tDmogz9lkBqz3punQT2C12MDWaqNTFOGfwXmIgAy/y537o7njVPpicrO0C4hAHN7m wIOp7FWkPKgfmLXbTQ9ConR/swll0oAhX0nprTmCkoezdXiyL1/F/MsAW0TGHm3rYd zj4e6iluo33WS4ybOYFEMGlZni4xCw/mAjLx9qp8= Date: Wed, 11 Sep 2024 16:56:14 +0200 From: Greg Kroah-Hartman To: Ayush Singh Cc: fabien.parent@linaro.org, d-gole@ti.com, lorforlinux@beagleboard.org, jkridner@beagleboard.org, robertcnelson@beagleboard.org, Andrew Davis , Miguel Ojeda , Alex Gaynor , Boqun Feng , Gary Guo , =?iso-8859-1?Q?Bj=F6rn?= Roy Baron , Benno Lossin , Andreas Hindborg , Alice Ryhl , Trevor Gross , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Derek Kiernan , Dragan Cvetic , Arnd Bergmann , Nishanth Menon , Vignesh Raghavendra , Tero Kristo , linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH 1/8] rust: kernel: Add Platform device and driver abstractions Message-ID: <2024091106-scouring-smitten-e740@gregkh> References: <20240911-mikrobus-dt-v1-0-3ded4dc879e7@beagleboard.org> <20240911-mikrobus-dt-v1-1-3ded4dc879e7@beagleboard.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240911-mikrobus-dt-v1-1-3ded4dc879e7@beagleboard.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240911_075619_082168_B213212F X-CRM114-Status: GOOD ( 11.93 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Sep 11, 2024 at 07:57:18PM +0530, Ayush Singh wrote: > +/// An identifier for Platform devices. > +/// > +/// Represents the kernel's [`struct of_device_id`]. This is used to find an appropriate > +/// Platform driver. > +/// > +/// [`struct of_device_id`]: srctree/include/linux/mod_devicetable.h > +pub struct DeviceId(&'static CStr); > + > +impl DeviceId { I appreciate posting this, but this really should go on top of the device driver work Danilo Krummrich has been doing. He and I spent a lot of time working through this this past weekend (well, him talking and explaining, and me asking too many stupid questions...) I think what he has will make the platform driver/device work simpler here, and I'll be glad to take it based on that, this "independent" code that doesn't interact with that isn't the best idea overall. It also will properly handle the "Driver" interaction as well, which we need to get right, not a one-off like this for a platform driver. Hopefully that will not cause much, if any, changes for your use of this in your driver, but let's see. thanks, greg k-h