From patchwork Fri Apr 22 11:28:44 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 8910771 X-Patchwork-Delegate: geert@linux-m68k.org Return-Path: X-Original-To: patchwork-linux-renesas-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 3DF11BF29F for ; Fri, 22 Apr 2016 11:30:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7BE9D201C7 for ; Fri, 22 Apr 2016 11:30:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5208B20220 for ; Fri, 22 Apr 2016 11:30:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753632AbcDVL3d (ORCPT ); Fri, 22 Apr 2016 07:29:33 -0400 Received: from mail-pf0-f175.google.com ([209.85.192.175]:35014 "EHLO mail-pf0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753638AbcDVL3b (ORCPT ); Fri, 22 Apr 2016 07:29:31 -0400 Received: by mail-pf0-f175.google.com with SMTP id n1so40712776pfn.2 for ; Fri, 22 Apr 2016 04:29:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=Y7fFjQHPaViukIZNfXi2QFXvufynAGHDaDvN5OaJtLg=; b=HkEPP2u/Y5SQ4YGDNL1JS/ZFx6eElzsiCF27rHIjZ9oKrhbENuoDz2FepbC2OB/qew SLqpErPDURzBLDOXN0dcwLbZGT6uUtZLgp7S0taH6VRaAzp+OSumOmjY9FSxRrVNVlBC 0j2TPmLZCDX9WCn1pEuoDQcBDgET+25PVDFmA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=Y7fFjQHPaViukIZNfXi2QFXvufynAGHDaDvN5OaJtLg=; b=ChNRFJJWAgepR9DjuluyAB41AvVytM4eZddJ95JI24HZxZw8lvUXAIzus3DEHhFjm2 KNcUmTxJ3VOCnz2zgqlzKY/ystFlpdZMqYO7Q922ttQUcR6lyJyvONQzZMac7u+rYjJv b8B5XOBjH++L/VYDtu+COgM5PjA8UTJid0JqDplLZCrWB6TJvfvGuE9DolFS4Lt4kERj T9/uHBMMwO/CaDyy2JhKdgTkoER9Pmb6eCwC4ybas+nnOBzL/syjPCQNkIobliEqyeWD NXwus4UWONV3rb9dkeVgodgCb4B75Ov5+hEFueb/B5VsE/dNbFUsxSs+tlL7IzO2crIw ty2g== X-Gm-Message-State: AOPr4FWVF/UPMBPtXHLH9IYMn0VViISMLHhMlNqB+o0Mn9nGM+M6HV3DPbp1AnjZALLrDCZw X-Received: by 10.98.76.22 with SMTP id z22mr27454584pfa.78.1461324570031; Fri, 22 Apr 2016 04:29:30 -0700 (PDT) Received: from localhost ([122.167.26.250]) by smtp.gmail.com with ESMTPSA id h85sm7798686pfj.52.2016.04.22.04.29.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 22 Apr 2016 04:29:29 -0700 (PDT) From: Viresh Kumar To: Rafael Wysocki , Simon Horman , Magnus Damm , Viresh Kumar Cc: linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org, geert@linux-m68k.org, Arnd Bergmann , linux-renesas-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH V2 6/9] cpufreq: shmobile: Use generic platdev driver Date: Fri, 22 Apr 2016 16:58:44 +0530 Message-Id: <79f9216705870417483bad374e6ff5ee7b4d267c.1461324267.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.7.1.410.g6faf27b In-Reply-To: References: In-Reply-To: References: Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Spam-Status: No, score=-8.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Cc: Simon Horman Cc: Magnus Damm Signed-off-by: Viresh Kumar Acked-by: Arnd Bergmann --- arch/arm/mach-shmobile/Makefile | 1 - arch/arm/mach-shmobile/common.h | 7 ------- arch/arm/mach-shmobile/cpufreq.c | 19 ------------------- drivers/cpufreq/cpufreq-dt-platdev.c | 12 ++++++++++++ 4 files changed, 12 insertions(+), 27 deletions(-) delete mode 100644 arch/arm/mach-shmobile/cpufreq.c diff --git a/arch/arm/mach-shmobile/Makefile b/arch/arm/mach-shmobile/Makefile index a65c80ac9009..c9ea0e6ff4f9 100644 --- a/arch/arm/mach-shmobile/Makefile +++ b/arch/arm/mach-shmobile/Makefile @@ -38,7 +38,6 @@ smp-$(CONFIG_ARCH_EMEV2) += smp-emev2.o headsmp-scu.o platsmp-scu.o # PM objects obj-$(CONFIG_SUSPEND) += suspend.o -obj-$(CONFIG_CPU_FREQ) += cpufreq.o obj-$(CONFIG_PM_RCAR) += pm-rcar.o obj-$(CONFIG_PM_RMOBILE) += pm-rmobile.o obj-$(CONFIG_ARCH_RCAR_GEN2) += pm-rcar-gen2.o diff --git a/arch/arm/mach-shmobile/common.h b/arch/arm/mach-shmobile/common.h index 5464b7a75e30..3b562d87826d 100644 --- a/arch/arm/mach-shmobile/common.h +++ b/arch/arm/mach-shmobile/common.h @@ -25,16 +25,9 @@ static inline int shmobile_suspend_init(void) { return 0; } static inline void shmobile_smp_apmu_suspend_init(void) { } #endif -#ifdef CONFIG_CPU_FREQ -int shmobile_cpufreq_init(void); -#else -static inline int shmobile_cpufreq_init(void) { return 0; } -#endif - static inline void __init shmobile_init_late(void) { shmobile_suspend_init(); - shmobile_cpufreq_init(); } #endif /* __ARCH_MACH_COMMON_H */ diff --git a/arch/arm/mach-shmobile/cpufreq.c b/arch/arm/mach-shmobile/cpufreq.c deleted file mode 100644 index 634d701c56a7..000000000000 --- a/arch/arm/mach-shmobile/cpufreq.c +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CPUFreq support code for SH-Mobile ARM - * - * Copyright (C) 2014 Gaku Inami - * - * This file is subject to the terms and conditions of the GNU General Public - * License. See the file "COPYING" in the main directory of this archive - * for more details. - */ - -#include - -#include "common.h" - -int __init shmobile_cpufreq_init(void) -{ - platform_device_register_simple("cpufreq-dt", -1, NULL, 0); - return 0; -} diff --git a/drivers/cpufreq/cpufreq-dt-platdev.c b/drivers/cpufreq/cpufreq-dt-platdev.c index 75fa921d8540..4b94fe3427f9 100644 --- a/drivers/cpufreq/cpufreq-dt-platdev.c +++ b/drivers/cpufreq/cpufreq-dt-platdev.c @@ -29,6 +29,18 @@ static const struct of_device_id machines[] __initconst = { { .compatible = "samsung,exynos5800", }, #endif + { .compatible = "renesas,emev2", }, + { .compatible = "renesas,r7s72100", }, + { .compatible = "renesas,r8a73a4", }, + { .compatible = "renesas,r8a7740", }, + { .compatible = "renesas,r8a7778", }, + { .compatible = "renesas,r8a7779", }, + { .compatible = "renesas,r8a7790", }, + { .compatible = "renesas,r8a7791", }, + { .compatible = "renesas,r8a7793", }, + { .compatible = "renesas,r8a7794", }, + { .compatible = "renesas,sh73a0", }, + { .compatible = "rockchip,rk2928", }, { .compatible = "rockchip,rk3036", }, { .compatible = "rockchip,rk3066a", },