From patchwork Mon Aug 25 03:03:52 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 4772291 Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 9ADC59F3B4 for ; Mon, 25 Aug 2014 03:01:37 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BF71220121 for ; Mon, 25 Aug 2014 03:01:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D358920114 for ; Mon, 25 Aug 2014 03:01:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753894AbaHYDBe (ORCPT ); Sun, 24 Aug 2014 23:01:34 -0400 Received: from mail-pa0-f51.google.com ([209.85.220.51]:50835 "EHLO mail-pa0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753826AbaHYDBe (ORCPT ); Sun, 24 Aug 2014 23:01:34 -0400 Received: by mail-pa0-f51.google.com with SMTP id ey11so20071016pad.38 for ; Sun, 24 Aug 2014 20:01:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:date:message-id:in-reply-to:references:subject; bh=7r5mg8XCxhmw/XYfI5TtYpRGHBEyyHHOwjq36Bj1z6g=; b=C2POVtMHI9l0Zt6iPndFPLakmmTIsDdubOfHJ8qI4vBPzAlR6T6w3DD/Y/CX9rB2Bu rdvNVKTxt55oLc+55ludwgriSo4UrFbBkLLiu0Fb9lLFXWgO67EhyWWUy9KySIEwcI7M gU7Xa/1T7e4fSVuB1T5VSpYMOAYQ55fjqkcZsD0IN731BCCYxyYw1wrT30hNAKhv+fAq 887TdXoR1uycdWXYCB7DpwXfKiWMwnTG8JkRxt6iiW66rg+83HraetESoKLaY5ZZISFy zBfxZinuMtE5RUA6or7GqN3B8LeAvBGDzPlQ9vsY41HS1GDSlPEAdmjhpFCO1TPbevzI mnHQ== X-Received: by 10.66.182.227 with SMTP id eh3mr25127890pac.68.1408935693936; Sun, 24 Aug 2014 20:01:33 -0700 (PDT) Received: from [127.0.0.1] (s214090.ppp.asahi-net.or.jp. [220.157.214.90]) by mx.google.com with ESMTPSA id vu7sm130606527pab.34.2014.08.24.20.01.31 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Aug 2014 20:01:32 -0700 (PDT) From: Magnus Damm To: linux-sh@vger.kernel.org Cc: Magnus Damm , horms@verge.net.au, geert+renesas@glider.be Date: Mon, 25 Aug 2014 12:03:52 +0900 Message-Id: <20140825030352.1936.88538.sendpatchset@w520> In-Reply-To: <20140825030316.1936.88249.sendpatchset@w520> References: <20140825030316.1936.88249.sendpatchset@w520> Subject: [PATCH v2 04/05] ARM: shmobile: Cleanup pm-rcar.o build using Kconfig Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Magnus Damm Add a CONFIG_PM_RCAR entry and enable it for R-Car Generation 1 or 2 in case CONFIG_PM or CONFIG_SMP is set. Consolidate power management objects and get rid of #ifdefs in the C code. Signed-off-by: Magnus Damm Acked-by: Geert Uytterhoeven --- Changes since V1: - None arch/arm/mach-shmobile/Kconfig | 5 +++++ arch/arm/mach-shmobile/Makefile | 10 ++++------ arch/arm/mach-shmobile/pm-rcar.c | 4 ---- 3 files changed, 9 insertions(+), 10 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- 0005/arch/arm/mach-shmobile/Kconfig +++ work/arch/arm/mach-shmobile/Kconfig 2014-08-19 22:23:13.000000000 +0900 @@ -2,13 +2,18 @@ config ARCH_SHMOBILE bool select ARCH_WANT_OPTIONAL_GPIOLIB +config PM_RCAR + bool + config ARCH_RCAR_GEN1 bool + select PM_RCAR if PM || SMP select RENESAS_INTC_IRQPIN select SYS_SUPPORTS_SH_TMU config ARCH_RCAR_GEN2 bool + select PM_RCAR if PM || SMP select RENESAS_IRQC select SYS_SUPPORTS_SH_CMT --- 0005/arch/arm/mach-shmobile/Makefile +++ work/arch/arm/mach-shmobile/Makefile 2014-08-19 22:24:59.000000000 +0900 @@ -11,9 +11,9 @@ obj-$(CONFIG_ARCH_SH73A0) += setup-sh73a obj-$(CONFIG_ARCH_R8A73A4) += setup-r8a73a4.o obj-$(CONFIG_ARCH_R8A7740) += setup-r8a7740.o obj-$(CONFIG_ARCH_R8A7778) += setup-r8a7778.o -obj-$(CONFIG_ARCH_R8A7779) += setup-r8a7779.o -obj-$(CONFIG_ARCH_R8A7790) += setup-r8a7790.o -obj-$(CONFIG_ARCH_R8A7791) += setup-r8a7791.o +obj-$(CONFIG_ARCH_R8A7779) += setup-r8a7779.o pm-r8a7779.o +obj-$(CONFIG_ARCH_R8A7790) += setup-r8a7790.o pm-r8a7790.o +obj-$(CONFIG_ARCH_R8A7791) += setup-r8a7791.o pm-r8a7791.o obj-$(CONFIG_ARCH_EMEV2) += setup-emev2.o obj-$(CONFIG_ARCH_R7S72100) += setup-r7s72100.o @@ -48,12 +48,10 @@ smp-$(CONFIG_ARCH_EMEV2) += smp-emev2.o obj-$(CONFIG_SUSPEND) += suspend.o obj-$(CONFIG_CPU_IDLE) += cpuidle.o obj-$(CONFIG_CPU_FREQ) += cpufreq.o +obj-$(CONFIG_PM_RCAR) += pm-rcar.o obj-$(CONFIG_ARCH_SH7372) += pm-sh7372.o sleep-sh7372.o pm-rmobile.o obj-$(CONFIG_ARCH_SH73A0) += pm-sh73a0.o obj-$(CONFIG_ARCH_R8A7740) += pm-r8a7740.o pm-rmobile.o -obj-$(CONFIG_ARCH_R8A7779) += pm-r8a7779.o pm-rcar.o -obj-$(CONFIG_ARCH_R8A7790) += pm-r8a7790.o pm-rcar.o -obj-$(CONFIG_ARCH_R8A7791) += pm-r8a7791.o pm-rcar.o # IRQ objects obj-$(CONFIG_ARCH_SH7372) += entry-intc.o --- 0001/arch/arm/mach-shmobile/pm-rcar.c +++ work/arch/arm/mach-shmobile/pm-rcar.c 2014-08-19 22:26:10.000000000 +0900 @@ -31,8 +31,6 @@ #define SYSCISR_RETRIES 1000 #define SYSCISR_DELAY_US 1 -#if defined(CONFIG_PM) || defined(CONFIG_SMP) - static void __iomem *rcar_sysc_base; static DEFINE_SPINLOCK(rcar_sysc_lock); /* SMP CPUs + I/O devices */ @@ -137,5 +135,3 @@ void __iomem *rcar_sysc_init(phys_addr_t return rcar_sysc_base; } - -#endif /* CONFIG_PM || CONFIG_SMP */