Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3385111pxb; Mon, 9 Nov 2020 09:45:14 -0800 (PST) X-Google-Smtp-Source: ABdhPJxGJm/eMmOBEVq11vqB5VsDcYshRsrhflIHPCK52/b2M4dDbt0bu9Ib7lYpEhKHnU1vCMWf X-Received: by 2002:a17:906:fa0a:: with SMTP id lo10mr11600843ejb.309.1604943913777; Mon, 09 Nov 2020 09:45:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604943913; cv=none; d=google.com; s=arc-20160816; b=nYVpHsRYIMxDZ2HRtQ4evGbrM+V8Gx0gy2fr5DptuD85hsCrQuW6oPFUSJ/E9Uj3df zGd0fmwXODxi13TS5MS2itUsr5nZvuqUmIkVgp9GjoX0XPvPvO/cY7gHRFwKBI4lgEHP xCM5px4B6b6wV8TottieLrw1L+4nI+YUkgBziGbmJERtFH050V+9QOcf1FVjQdh3vzaK nbdGV/txkxTG2Y5dF8JBQz9wLlelKDLkjFwIZ4VhpHw4srHGpr44YnIaZQ1P0ylEvbKG kGJKmXfYqJMM/q4SW3mhL67CXpK5tM0x79EzZH7x2lFKbYdpFUWFIZ+gITm6Sx92luNy RnKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=jltC+bDWwlOBb3k+Lvr3JSR+3XveeKXCX1xQmKSLgQw=; b=LJ4azQDZflG3OzskjTuzaFv9uB0k5ee7nDuebBJmX+lB3YGnARdV+gVLkTNMKQHH3N RxwDVfKOBvfKkDZjY0bGAr8LpdlRjZE33tVc27o0gVV+PFTWnQcpoJRlS4f3WBd3cnKB luStsWg4FaYHzYifnoP9BY3OsXCCFsOtcVyjNgwYedQ0aZ1SUupxy1UGpYfMzjEEGAd1 9dCbYh969PoqaFDjH5kEdhf++Z7y/sk+bmPPeVacZArkjb8lGvWio8Fbnpxl+FeGLYXH 64S8/RMNi9cOZIVvodWNZfSxy5EnHKsuKi63uR44CM/LOd1dvqTKG/CLRkyakbVP/zEY zXQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=weCjyh02; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f10si7536186edx.567.2020.11.09.09.44.49; Mon, 09 Nov 2020 09:45:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=weCjyh02; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732274AbgKIRlX (ORCPT + 99 others); Mon, 9 Nov 2020 12:41:23 -0500 Received: from mail.kernel.org ([198.145.29.99]:42164 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731476AbgKIRlW (ORCPT ); Mon, 9 Nov 2020 12:41:22 -0500 Received: from localhost (fw-tnat.cambridge.arm.com [217.140.96.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id A276521D93; Mon, 9 Nov 2020 17:41:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604943682; bh=jltC+bDWwlOBb3k+Lvr3JSR+3XveeKXCX1xQmKSLgQw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=weCjyh02JTUiDSJx+tgvVS4Q1Z4WDTGoYFDi2S8mBUL3rbrib5togaKtxZ5mcNkOY 7fO6b/qvY+fhk/OiEIPUuQboLa2hqQH9iHS1V+GU9paet0OUOzEOGdu621uDZHdDTJ LLoTSytEbhg07OMGI56JrINl99ayhNtlsG9ecy98= Date: Mon, 9 Nov 2020 17:41:08 +0000 From: Mark Brown To: Rob Herring Cc: Saravana Kannan , Greg Kroah-Hartman , "Rafael J . Wysocki" , Daniel Mentz , LKML , Frank Rowand Subject: Re: [PATCH RFC] driver core: Ensure DT devices always have fwnode set Message-ID: <20201109174108.GK6380@sirena.org.uk> References: <20201106150747.31273-1-broonie@kernel.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="ibq+fG+Ci5ONsaof" Content-Disposition: inline In-Reply-To: X-Cookie: This fortune is false. User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --ibq+fG+Ci5ONsaof Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Nov 09, 2020 at 11:25:39AM -0600, Rob Herring wrote: > On Fri, Nov 6, 2020 at 1:09 PM Saravana Kannan wrote: > > And all the subsystems that create their own device from an of_node > > should use of_set_device_of_node() to set the device's of_node. That > > way, all this is done in a consistent manner across subsystems and > > avoid all of the of_get/put() and OF_POPULATED set/clear strewn all > > over the subsystems. > Perhaps a fwnode call in device_add instead that implements the above > and anything else needed for each type of fwnode. It might even be > possible with that to get rid of most of I'd suggested doing it with a callout as well in the original thread that sparked my proposal - my patch was just the most minimal implementation to fix the current problem. > of_platform_device_create_pdata() and of_device_add(). IIRC, those > were pretty much copies of the core code. > That would also be less fragile than having a coccinelle script. --ibq+fG+Ci5ONsaof Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAl+pfzMACgkQJNaLcl1U h9BwuAf+Ifvb6jENdSABE4ZiMAMqCgybbePbrFprkqHG4M7jIiXqRSigNor+ptQS 3GFjy2IiR5+LgRW58IThVh97j3Ju4sCIGXZvlV1ixs2HfMDL58cuVkIOEL8Q9zqC WF0gBQlyO1rhgxbj48fD1czx5I8q5jxcNdophbDNOHNB2vNcr8yXbZyPZLdsD8Dh N2sfmi9Kls1yfhqzh7B9XU2nS/D4h5afIpfQNz9TEQSg2Ka3otnLdysQUQkim+6S BxOLUbSxeB+r0IXGSJqjEZYnWREojywWymdHUpXk4w57b0G10bh2CFWmAKNbCEqV IjUNKcURgrgns5KHUKXXA4NtVLOHmg== =jsPy -----END PGP SIGNATURE----- --ibq+fG+Ci5ONsaof--