Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp1244286ybg; Wed, 29 Jul 2020 09:11:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyuIqluMrTGK0C6ttQ8FGWUkMjANS+Coeq1Dggvb3JMupZpPCGmiilh9HfRIiyqfudg69M/ X-Received: by 2002:a17:906:c7d4:: with SMTP id dc20mr17212603ejb.283.1596039106507; Wed, 29 Jul 2020 09:11:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596039106; cv=none; d=google.com; s=arc-20160816; b=HqX9p8mK1Pw4g/n1rFbuXV/RTLc94tAAnIhkKmE0eaCEhA5TQhG32iqP+5Dryva6QF +HRULKolpYQgcbzj2KDjTIUlS+Yynr41Rt4OFVAy68A1RKxi0hG1DsqEYvaKiIGpXpLM FvENsZnlyNR1VjnMJO8WgzaN1uuYOrC4k9Kzzex9otIzkd1Fs6Y3eCWoQz9ip6YFGPNS 8PVnCWXoiznVgTahAQL1LV1KAVRTEIkvZM7gB/D7CFBwYyWh9ZMcOx4toxYvJXC238If axsjDiFrsT25Rbg363BbOxbVym0PiBtUTq9BGgkPHiTDUwolDk28Q+AJm31e582aDBXs rJzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=C57ZoglQ1/NsxLhHD+eXnV3QH8BgOk8c75vx6fiB7xM=; b=dr4r4Mu81i8uNnfbTmSVaw3XSMl7P1MeoZoJOPwHl3DNF1SOFoghmHN8W6s1p7H1IF chzJyiBb/9cDcIsXnTAwnKkqs+Q7K+FiPYOvQfcroj8WBFVHDP0kWVLpJrJ8alPsn8pe QqFSR9sJ2D8sttURl02E09HV79UVbbsr18Nt+YLrZDKoNzgoFMoE5N7TA79sLIK1zQaj OFidEzqdSjnh4tdVDovfQA7JRXzKy7Ub36LTTUXiy7chAIgp8YqIAxwHQMz7Jn/8BJ92 VrFmPm66ozdywRSlWPEOXR6fwOYZZNyx3Qsf4skJ7fnCmfh3J8WMMg4OuK+eXfr1SCYU DzRg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ktVE9NWS; 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 w6si1345966ejc.605.2020.07.29.09.11.24; Wed, 29 Jul 2020 09:11:46 -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=ktVE9NWS; 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 S1726951AbgG2QLF (ORCPT + 99 others); Wed, 29 Jul 2020 12:11:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:48758 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726341AbgG2QLF (ORCPT ); Wed, 29 Jul 2020 12:11:05 -0400 Received: from kozik-lap.mshome.net (unknown [194.230.155.213]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 15DD4208A9; Wed, 29 Jul 2020 16:10:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1596039064; bh=gAyLpOZYDu8tG7gPMVs7XDjNmD+CKe0ZmTsojRr4Vr8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ktVE9NWSRB2ds+ZQ3nVplOFB15l4g5AUaqpRaFKKl7u6bxP070LZ74x8jC+Qyq05d PIo1owA5o2YkaVnx3yye+kXTa8FpoasD9VaP6HbOdAnEZeoB8ukckc3J88t9Hjt/B2 fGqr5iLg/Ymes421syzCp108YL644AFBk9PPOIKQ= From: Krzysztof Kozlowski To: Russell King , Kukjin Kim , Krzysztof Kozlowski , Vincent Sanders , Simtec Linux Team , Kyungmin Park , Catalin Marinas , Will Deacon , Sylwester Nawrocki , Tomasz Figa , Chanwoo Choi , Michael Turquette , Stephen Boyd , Wim Van Sebroeck , Guenter Roeck , Arnd Bergmann , Linus Walleij , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, patches@opensource.cirrus.com, linux-clk@vger.kernel.org, linux-watchdog@vger.kernel.org Cc: Sergio Prado , Marek Szyprowski , Sylwester Nawrocki , Cedric Roux , Lihua Yao Subject: [PATCH 1/7] clk: samsung: s3c64xx: Declare s3c64xx_clk_init() in shared header Date: Wed, 29 Jul 2020 18:09:36 +0200 Message-Id: <20200729160942.28867-2-krzk@kernel.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200729160942.28867-1-krzk@kernel.org> References: <20200729160942.28867-1-krzk@kernel.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The s3c64xx_clk_init() is defined and used by clk-s3c64xx driver and also used in mach-s3c64xx machine code. Move the declaration to a header to fix W=1 build warning: drivers/clk/samsung/clk-s3c64xx.c:391:13: warning: no previous prototype for 's3c64xx_clk_init' [-Wmissing-prototypes] 391 | void __init s3c64xx_clk_init(struct device_node *np, unsigned long xtal_f, Signed-off-by: Krzysztof Kozlowski --- MAINTAINERS | 1 + arch/arm/mach-s3c64xx/common.c | 1 + arch/arm/mach-s3c64xx/common.h | 2 -- drivers/clk/samsung/clk-s3c64xx.c | 1 + include/linux/clk/samsung.h | 21 +++++++++++++++++++++ 5 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 include/linux/clk/samsung.h diff --git a/MAINTAINERS b/MAINTAINERS index 7f8c6e41a364..f5d7cf3c3aaa 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -15294,6 +15294,7 @@ F: Documentation/devicetree/bindings/clock/samsung,s3c* F: Documentation/devicetree/bindings/clock/samsung,s5p* F: drivers/clk/samsung/ F: include/dt-bindings/clock/exynos*.h +F: include/linux/clk/samsung.h SAMSUNG SPI DRIVERS M: Kukjin Kim diff --git a/arch/arm/mach-s3c64xx/common.c b/arch/arm/mach-s3c64xx/common.c index 13e91074308a..a655bf0c7802 100644 --- a/arch/arm/mach-s3c64xx/common.c +++ b/arch/arm/mach-s3c64xx/common.c @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include diff --git a/arch/arm/mach-s3c64xx/common.h b/arch/arm/mach-s3c64xx/common.h index 03670887a764..f4eca42cdc86 100644 --- a/arch/arm/mach-s3c64xx/common.h +++ b/arch/arm/mach-s3c64xx/common.h @@ -22,8 +22,6 @@ void s3c64xx_init_io(struct map_desc *mach_desc, int size); void s3c64xx_restart(enum reboot_mode mode, const char *cmd); struct device_node; -void s3c64xx_clk_init(struct device_node *np, unsigned long xtal_f, - unsigned long xusbxti_f, bool is_s3c6400, void __iomem *reg_base); void s3c64xx_set_xtal_freq(unsigned long freq); void s3c64xx_set_xusbxti_freq(unsigned long freq); diff --git a/drivers/clk/samsung/clk-s3c64xx.c b/drivers/clk/samsung/clk-s3c64xx.c index b96d33e5eb45..56f95b63f71f 100644 --- a/drivers/clk/samsung/clk-s3c64xx.c +++ b/drivers/clk/samsung/clk-s3c64xx.c @@ -7,6 +7,7 @@ #include #include +#include #include #include diff --git a/include/linux/clk/samsung.h b/include/linux/clk/samsung.h new file mode 100644 index 000000000000..b6b253c46c22 --- /dev/null +++ b/include/linux/clk/samsung.h @@ -0,0 +1,21 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Copyright (c) 2020 Krzysztof Kozlowski + */ + +#ifndef __LINUX_CLK_SAMSUNG_H_ +#define __LINUX_CLK_SAMSUNG_H_ + +#ifdef CONFIG_ARCH_S3C64XX +void __init s3c64xx_clk_init(struct device_node *np, unsigned long xtal_f, + unsigned long xusbxti_f, bool s3c6400, + void __iomem *base); +#else +static inline void __init s3c64xx_clk_init(struct device_node *np, + unsigned long xtal_f, + unsigned long xusbxti_f, + bool s3c6400, + void __iomem *base) { } +#endif /* CONFIG_ARCH_S3C64XX */ + +#endif /* __LINUX_CLK_SAMSUNG_H_ */ -- 2.17.1