Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp2501055pxx; Sun, 1 Nov 2020 00:44:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJweWWll+FYZKfrXcuCRVUJHWv22Xwrf42SPRSqCv5dhDKCqtn/s7TXg91yr6zVIMXdGAcZy X-Received: by 2002:a05:6402:236e:: with SMTP id a14mr11160740eda.103.1604216688078; Sun, 01 Nov 2020 00:44:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1604216688; cv=none; d=google.com; s=arc-20160816; b=M2leG4a4nT8p2LAPGSuD63TEs4l68mKvvmn9GNFqYQVbG+NN3kzk7A+oF2osl4eB5m 1iHbdAn9Pt2QWRrkFKEZwUceOpKcZ+6BMWOwqi5bp3g+Bnl8X594i3nxUeAClhFlxFaM AptMsEWrO5CWQsTYD2kB10h/QOXcP/jDbN+f7zdieunmBPl87JuFM4M0+n5bdNFzPzO5 ehzc0DfQNaIG8677HIXxhh4jpDZpCzvIHT4jj7t3SkPqUJPhPqyZGqFUwqvy4j9vZJU2 enEbXaU/Fg6IH+hvUO5hcNEHJr74o7p3qzOOTb7Aj6HTWqaxpJkpNNhqZasV/xNbltrA O9UQ== 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=t0+OApuCWAlUxCS7vjgG3avMmw4sEw51QjV9zcEgbj0=; b=0yf8ZkEgZ3tdpQLw/gH5MhDgPsiCShDWSHQbSIbQtFHunc5FrIf184jEy7wP8ttD0X qn7pNjIJI3HR0FeKVYC1pZM64shk+8YhXINvEQ87BAnq3bePc2bsLrD5snTdKhqVLRGd I6fL8b9cu0cRFRbxVUf2XlMqVJv2Xl8Tv7Y6CyTNIYVSbGbCtX1XnVHyFmYVgKQrlkYM rH7OXpeFrCUqxh8BIiasttf136ETNXLNnomgeAuS+kE+Yhvoj5VXxfmiP8X1IcXs1l/V 3wOsbTRVvD6g2J4JgUrWiTFFY71ocmqvOb7XMotDbsidDdt+9rFo201D3FHqIVP5VUwD g4jg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="pTJKakq/"; 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 g16si7943488edp.288.2020.11.01.00.44.25; Sun, 01 Nov 2020 00:44:48 -0700 (PDT) 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="pTJKakq/"; 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 S1725936AbgKAHnI (ORCPT + 99 others); Sun, 1 Nov 2020 02:43:08 -0500 Received: from mail.kernel.org ([198.145.29.99]:37450 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725773AbgKAHnH (ORCPT ); Sun, 1 Nov 2020 02:43:07 -0500 Received: from dragon (80.251.214.228.16clouds.com [80.251.214.228]) (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 D8FFE208A9; Sun, 1 Nov 2020 07:43:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604216586; bh=qp7HDhOZNF9cCr2O01GugOZ4lkhXue/Od24USAgscpQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=pTJKakq/BSuUPfzoaIBbvyMOlwYO06+ondNa5cVl2/Ln4vOSoNOggCommoc/aXEuy XjTSia9iGweL3fM8G7qaLMgp39Y0l6qNDWjAYanp31Pd3K7DclfzkxnYgz4Y58WOuV XnMDmVZvdNeeLJp8JIGooMQ0NCVqDMScHO+x7Zg0= Date: Sun, 1 Nov 2020 15:43:01 +0800 From: Shawn Guo To: Joakim Zhang Cc: mkl@pengutronix.de, robh+dt@kernel.org, s.hauer@pengutronix.de, kernel@pengutronix.de, linux-imx@nxp.com, victor.liu@nxp.com, linux-can@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH V4 1/6] firmware: imx: always export SCU symbols Message-ID: <20201101074300.GF31601@dragon> References: <20201021052437.3763-1-qiangqing.zhang@nxp.com> <20201021052437.3763-2-qiangqing.zhang@nxp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201021052437.3763-2-qiangqing.zhang@nxp.com> User-Agent: Mutt/1.9.4 (2018-02-28) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 21, 2020 at 01:24:32PM +0800, Joakim Zhang wrote: > From: Liu Ying > > Always export SCU symbols for both SCU SoCs and non-SCU SoCs to avoid > build error. > > Signed-off-by: Liu Ying > Signed-off-by: Peng Fan > Signed-off-by: Joakim Zhang > --- > include/linux/firmware/imx/ipc.h | 15 +++++++++++++++ Could you rebase it to my imx/drivers branch? There is one patch from Peng Fan that already changed ipc.h. Shawn > include/linux/firmware/imx/svc/misc.h | 23 +++++++++++++++++++++++ > 2 files changed, 38 insertions(+) > > diff --git a/include/linux/firmware/imx/ipc.h b/include/linux/firmware/imx/ipc.h > index 891057434858..300fa253fc30 100644 > --- a/include/linux/firmware/imx/ipc.h > +++ b/include/linux/firmware/imx/ipc.h > @@ -34,6 +34,7 @@ struct imx_sc_rpc_msg { > uint8_t func; > }; > > +#if IS_ENABLED(CONFIG_IMX_SCU) > /* > * This is an function to send an RPC message over an IPC channel. > * It is called by client-side SCFW API function shims. > @@ -55,4 +56,18 @@ int imx_scu_call_rpc(struct imx_sc_ipc *ipc, void *msg, bool have_resp); > * @return Returns an error code (0 = success, failed if < 0) > */ > int imx_scu_get_handle(struct imx_sc_ipc **ipc); > + > +#else > +static inline int > +imx_scu_call_rpc(struct imx_sc_ipc *ipc, void *msg, bool have_resp) > +{ > + return -EIO; > +} > + > +static inline int imx_scu_get_handle(struct imx_sc_ipc **ipc) > +{ > + return -EIO; > +} > +#endif > + > #endif /* _SC_IPC_H */ > diff --git a/include/linux/firmware/imx/svc/misc.h b/include/linux/firmware/imx/svc/misc.h > index 031dd4d3c766..d255048f17de 100644 > --- a/include/linux/firmware/imx/svc/misc.h > +++ b/include/linux/firmware/imx/svc/misc.h > @@ -46,6 +46,7 @@ enum imx_misc_func { > * Control Functions > */ > > +#if IS_ENABLED(CONFIG_IMX_SCU) > int imx_sc_misc_set_control(struct imx_sc_ipc *ipc, u32 resource, > u8 ctrl, u32 val); > > @@ -55,4 +56,26 @@ int imx_sc_misc_get_control(struct imx_sc_ipc *ipc, u32 resource, > int imx_sc_pm_cpu_start(struct imx_sc_ipc *ipc, u32 resource, > bool enable, u64 phys_addr); > > +#else > +static inline int > +imx_sc_misc_set_control(struct imx_sc_ipc *ipc, u32 resource, > + u8 ctrl, u32 val) > +{ > + return -EIO; > +} > + > +static inline int > +imx_sc_misc_get_control(struct imx_sc_ipc *ipc, u32 resource, > + u8 ctrl, u32 *val) > +{ > + return -EIO; > +} > + > +static inline int imx_sc_pm_cpu_start(struct imx_sc_ipc *ipc, u32 resource, > + bool enable, u64 phys_addr) > +{ > + return -EIO; > +} > +#endif > + > #endif /* _SC_MISC_API_H */ > -- > 2.17.1 >