From patchwork Mon Nov 11 04:56:09 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_F=C3=A4rber?= X-Patchwork-Id: 11236549 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8BE52159A for ; Mon, 11 Nov 2019 04:56:24 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 633102084F for ; Mon, 11 Nov 2019 04:56:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="UAsuCEsQ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 633102084F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=vzTpO68FxTb1N1pgj4gR+REH4toumbWKgVMnG99ZdPU=; b=UAsuCEsQAPhbl8 d5P75yW5ofT7U1Y+evY7R/23w4l3lMCMHYkkaICnc/Sz/JXLul467doUhmqNDYYqCiA7vU56FW+H5 sN+Ft77zmNHxFrILwW1p+hFLg8GtoQtGo2ffcmgHMhkzWUnRyd6UJtJP6MYuE6Rq9yQCCFiF4pIgo 2tOCH3uwCZB6WDHFUGPMYz4MhqJHKkD3SI+Huky3GsPtIZN32mpLHeiVHCJZuQP7cSKDu4VeWv+sW xwmcD3rBX/YLd/3PQfJb78lx21RCCt6nL5yDdKHOYhWIukhQtC0F8KxObljUCjxQQRJ6jFR4JyV/H y+J46Fypr0i7rebRHcNw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iU1kT-0008Qt-85; Mon, 11 Nov 2019 04:56:21 +0000 Received: from mx2.suse.de ([195.135.220.15] helo=mx1.suse.de) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iU1kQ-0008QL-F7; Mon, 11 Nov 2019 04:56:20 +0000 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id E3D15B18C; Mon, 11 Nov 2019 04:56:16 +0000 (UTC) From: =?utf-8?q?Andreas_F=C3=A4rber?= To: linux-realtek-soc@lists.infradead.org Subject: [PATCH] base: soc: Export soc_device_to_device() helper Date: Mon, 11 Nov 2019 05:56:09 +0100 Message-Id: <20191111045609.7026-1-afaerber@suse.de> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20191103013645.9856-3-afaerber@suse.de> References: <20191103013645.9856-3-afaerber@suse.de> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191110_205618_653605_268B7D62 X-CRM114-Status: GOOD ( 10.36 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [195.135.220.15 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Geert Uytterhoeven , "Rafael J. Wysocki" , Greg Kroah-Hartman , linux-kernel@vger.kernel.org, Bjorn Andersson , Lee Jones , =?utf-8?q?Andreas_F=C3=A4rber?= , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use of soc_device_to_device() in driver modules causes a build failure. Given that the helper is nicely documented in include/linux/sys_soc.h, let's export it as GPL symbol. struct soc_device is local to soc.c, so it can't be inlined into the header or into driver code. This still handles only the case that CONFIG_SOC_BUS is enabled. Same as commit da65a1589dacc7ec44ea0557a14d70a39d991f32 ("base: soc: Provide a dummy implementation of soc_device_match()") we'd need to provide a dummy inline implementation to cope with COMPILE_TEST, too. Reported-by: kbuild test robot Cc: Lee Jones Cc: Bjorn Andersson Cc: Geert Uytterhoeven Signed-off-by: Andreas Färber --- drivers/base/soc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/base/soc.c b/drivers/base/soc.c index 4af11a423475..72848587cd51 100644 --- a/drivers/base/soc.c +++ b/drivers/base/soc.c @@ -41,6 +41,7 @@ struct device *soc_device_to_device(struct soc_device *soc_dev) { return &soc_dev->dev; } +EXPORT_SYMBOL_GPL(soc_device_to_device); static umode_t soc_attribute_mode(struct kobject *kobj, struct attribute *attr,