Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp223874imu; Tue, 27 Nov 2018 11:23:59 -0800 (PST) X-Google-Smtp-Source: AFSGD/U7pPzrjTHtvKi8vBVePZeDIIP4qzShQhFDpJ7ze2bwcgd647SIby51Ibj9J66G4yBu1tkX X-Received: by 2002:a63:7219:: with SMTP id n25mr30693149pgc.324.1543346639552; Tue, 27 Nov 2018 11:23:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543346639; cv=none; d=google.com; s=arc-20160816; b=hykULXHtlAMlcexzS7iw3cjlNhfu+ogUjmiveiH+lBmz+lKTk1hW0quUI6RrF4vsVY q2p9y1Fx2bIJ+LWOhlQ0i8Nk6iEa8GoB8vNJb9YGjxzvzVx9kSfWcRHn6zYAz4Om8TZd iLNjxEAzXR06Y0dp7Lon2E8QeI9bX+ItTVbQ5p0WPrfE2tV/3kLXxT/6gZVKpjZuiN3U In09FHQpd6aiGcBv6E1/dN8G6MJiSca4gVoHbc/CCR0VscBB4VVgN3Fe9TevdHHm40b+ Bf4B69PnSGLtg1fRjL82IMv9HsDiUnLRC3KLRgdCy71tvLFNxAA5dbuIa/YuG6NNw3iC 365w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=1ffxiJmGhyI+qmS5hqK0XbuHYdX/Z7ZTdSQHbWFgX/A=; b=xF+GSyG1wAMJnA8gLkYFycK4wvrQIviQ8q7UvkNSg24mdYnPTMVxnxEN6kYXYGUIFa jKBcqszEKVFy+98b4rWRkfIqa3HFDL0Fo2vtgHvz+HbqFA0Te8seotbd9i2AwX5TjUWS E7NNFIWe2nDr9KmkZIFCE03d+YKQRNuiR9sj/c+UNOlbQC+BG5KLzawc5/CpfE5+nwjG tbbr15q2cr8yzearfQ2E5SNdDlKSUb60mOxlO0XUgw49g5TdYkwpk9I4k0klkTFjoPkH Xd8KsDHOU+0hLuE5lud80KQFr5Xf0xL/5LdmUfKohPGt2VWt10GoRdInuUkSi0PVK+oa s5cw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z22si4963322pfd.197.2018.11.27.11.23.44; Tue, 27 Nov 2018 11:23:59 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729080AbeK1CD4 (ORCPT + 99 others); Tue, 27 Nov 2018 21:03:56 -0500 Received: from mail5.windriver.com ([192.103.53.11]:40998 "EHLO mail5.wrs.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726381AbeK1CDz (ORCPT ); Tue, 27 Nov 2018 21:03:55 -0500 Received: from ALA-HCB.corp.ad.wrs.com (ala-hcb.corp.ad.wrs.com [147.11.189.41]) by mail5.wrs.com (8.15.2/8.15.2) with ESMTPS id wARF3p3n029992 (version=TLSv1 cipher=AES128-SHA bits=128 verify=FAIL); Tue, 27 Nov 2018 07:04:02 -0800 Received: from yow-pgortmak-d1.corp.ad.wrs.com (128.224.56.57) by ALA-HCB.corp.ad.wrs.com (147.11.189.41) with Microsoft SMTP Server id 14.3.408.0; Tue, 27 Nov 2018 07:03:41 -0800 Received: by yow-pgortmak-d1.corp.ad.wrs.com (Postfix, from userid 1000) id 196372E0841; Tue, 27 Nov 2018 10:03:41 -0500 (EST) Date: Tue, 27 Nov 2018 10:03:41 -0500 From: Paul Gortmaker To: Lee Jones CC: kbuild test robot , , , David Dajun Chen , Support Opensource Subject: Re: [PATCH 02/11] mfd: da9055-core: make it explicitly non-modular Message-ID: <20181127150340.GG14659@windriver.com> References: <1542861179-8941-3-git-send-email-paul.gortmaker@windriver.com> <201811231036.wIjm7GBh%fengguang.wu@intel.com> <20181123031456.GD14659@windriver.com> <20181123144328.GE14659@windriver.com> <20181127130711.GL4272@dell> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20181127130711.GL4272@dell> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [Re: [PATCH 02/11] mfd: da9055-core: make it explicitly non-modular] On 27/11/2018 (Tue 13:07) Lee Jones wrote: > On Fri, 23 Nov 2018, Paul Gortmaker wrote: [...] > > My other pending MFD patches have a trivial runtime behavior change; > > deleting a ".remove" field/function - that will never be used for a > > non-module case, but in theory could be (pointlessly) triggered by > > forcing a driver unbind. (see mainline 98b72b94def9 as an example) > > Patches like this were left behind for a future send batch. > > What about when .remove() is invoked during shutdown? It is my understanding that .remove is not invoked during shutdown. If we step outside of MFD and look at mainline commit 7aa8619a66aea5 ("iommu/arm-smmu-v3: Implement shutdown method") -- you can see it adds a shutdown that is just a wrapper around the remove function. If shutdown called remove, then this commit would cause the remove function to get called *twice* on a shutdown. I also don't see any obvious coupling in drivers/base/platform.c - they seem independent, but it is possible I've overlooked something? Thanks, Paul. ---------- static int platform_drv_remove(struct device *_dev) { struct platform_driver *drv = to_platform_driver(_dev->driver); struct platform_device *dev = to_platform_device(_dev); int ret = 0; if (drv->remove) ret = drv->remove(dev); dev_pm_domain_detach(_dev, true); return ret; } static void platform_drv_shutdown(struct device *_dev) { struct platform_driver *drv = to_platform_driver(_dev->driver); struct platform_device *dev = to_platform_device(_dev); if (drv->shutdown) drv->shutdown(dev); } ----------