Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3102986pxb; Mon, 9 Nov 2020 02:37:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJwUBXWZCYRDHl7GGRovBy/V8aiA/yjecl6JeiobWe7RzxgHRTLbxZSzKrjZQ4LaYb/o7kMp X-Received: by 2002:a05:6402:150d:: with SMTP id f13mr14441791edw.119.1604918276745; Mon, 09 Nov 2020 02:37:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604918276; cv=none; d=google.com; s=arc-20160816; b=L64fRriSZAw9OQO890l0ZJ32pIn5iJxUJxYZohenopsI2vqMt5ymPnjQexwZOI4HI2 KbkKYEUDE3Xxx6jP7BYt9LSA26/9m01BZqtjqIsm+LuPooDgr3J4EDhOlWXm0mrk+2fq hIofKWmD1cgjrdoIUJbhpn0NNc7hwBe9rd6Y4ibhDDslSpsxmnz8dIvqf3ZkwGUUUaPp XXZlQpO/JKLzIZqtQb5GaWcto+/S8s8e+fFnN/JlHLNmZtzS47jm7uZ+vINS/eDX2muc 152oisp7mrF9b4VEeCkJ3i/7NKiCi1hBzN/ioNO8WHypim1Q5EfisW9lpZLMqnJ51yb5 /A/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=XS09Dli2VwP0XUI6msFWHiNIK+6UWwzfV2cWIsB5Gvs=; b=1GqpkUUk4BMy9gq7KJBHC6axxkiRGC5ztqRUQNO8igaHB31bqvFYNkeEjTQuRfONId /wtxaTEc8Doe2Hc1X0bLrQcHaSUooEe4/2Laq/NVxY0ib6msEQ2BwEapKamu0h0frF+i URDb5RAjJsxdHvdQQ0XRVevLDyl0bFwLBtfoKdUw0aG3Uz4ZWj0vR+Od5BSRFCQqa1rI 8AFw8xrbWPoUEJtCwJ1iB/Iew+OofRzJEJtnjLiTEturzWRdpp5NmF9+LBkgU7d1UppE leBsh2tzAy9HAhi3GuTF1LOE/cnICEqnWbkvfLixN9wRcqW0yACnEPDSjjGuN+OSmPFb s8iw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=VN81xgKX; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c21si6955248ejr.483.2020.11.09.02.37.34; Mon, 09 Nov 2020 02:37:56 -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=VN81xgKX; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729050AbgKIKgE (ORCPT + 99 others); Mon, 9 Nov 2020 05:36:04 -0500 Received: from mail.kernel.org ([198.145.29.99]:42218 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726646AbgKIKgE (ORCPT ); Mon, 9 Nov 2020 05:36:04 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (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 5A273206B2; Mon, 9 Nov 2020 10:36:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604918164; bh=SM+6eV/g7OP/MMAwSNFCdCRNGoiKXfSSU3Fd/r+uyV4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=VN81xgKXJ/c1bkxqX9lFnc0F8bTOHD8ufUm0z9FH/Xx5qa0y1criFJ4pT5y1XpuZ2 dWr0C9CK7SiQgBMF4JK/4E0QXDUpToe3agIiubwMtPIuyxAVSS010/Aixk+KK48san Wl5Bbjp1nmLUxh5rrEOA8D/ZP8U/9RbD2XcwcidU= Date: Mon, 9 Nov 2020 11:37:03 +0100 From: Greg Kroah-Hartman To: Sudip Mukherjee Cc: "Rafael J . Wysocki" , linux-kernel , Shawn Guo , Stephen Boyd , Dong Aisheng Subject: Re: [PATCH RESEND] driver core: export device_is_bound() to fix build failure Message-ID: <20201109103703.GA1310551@kroah.com> References: <20201107224727.11015-1-sudipm.mukherjee@gmail.com> <20201108082317.GA40741@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Nov 09, 2020 at 10:14:46AM +0000, Sudip Mukherjee wrote: > Hi Greg, > > On Sun, Nov 8, 2020 at 8:23 AM Greg Kroah-Hartman > wrote: > > > > On Sat, Nov 07, 2020 at 10:47:27PM +0000, Sudip Mukherjee wrote: > > > When CONFIG_MXC_CLK_SCU is configured as 'm' the build fails as it > > > is unable to find device_is_bound(). The error being: > > > ERROR: modpost: "device_is_bound" [drivers/clk/imx/clk-imx-scu.ko] > > > undefined! > > > > > > Export the symbol so that the module finds it. > > > > > > Fixes: 77d8f3068c63 ("clk: imx: scu: add two cells binding support") > > > Signed-off-by: Sudip Mukherjee > > > --- > > > > > > resending with the Fixes: tag. > > > > > > drivers/base/dd.c | 1 + > > > 1 file changed, 1 insertion(+) > > > > > > diff --git a/drivers/base/dd.c b/drivers/base/dd.c > > > index 148e81969e04..a796a57e5efb 100644 > > > --- a/drivers/base/dd.c > > > +++ b/drivers/base/dd.c > > > @@ -353,6 +353,7 @@ bool device_is_bound(struct device *dev) > > > { > > > return dev->p && klist_node_attached(&dev->p->knode_driver); > > > } > > > +EXPORT_SYMBOL(device_is_bound); > > > > EXPORT_SYMBOL_GPL() please, like all the other exports in this file. > > > > Also, wait, no, don't call this, are you sure you are calling it in a > > race-free way? And what branch/tree is the above commit in? > > I have not checked fully but since it is being called from probe() I > assume the lock will be held at that time. probe() should never call this function as it makes no sense at all at that point in time. The driver should be fixed. This function should not be exported, sorry. thanks, greg k-h