From patchwork Mon Mar 3 16:02:09 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Figa X-Patchwork-Id: 3755431 Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id A83FDBF13A for ; Mon, 3 Mar 2014 16:06:03 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C81F8203DF for ; Mon, 3 Mar 2014 16:06:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DA5C1203DA for ; Mon, 3 Mar 2014 16:06:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755095AbaCCQFS (ORCPT ); Mon, 3 Mar 2014 11:05:18 -0500 Received: from mail-ea0-f177.google.com ([209.85.215.177]:59786 "EHLO mail-ea0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754821AbaCCQCl (ORCPT ); Mon, 3 Mar 2014 11:02:41 -0500 Received: by mail-ea0-f177.google.com with SMTP id h10so4578199eak.8 for ; Mon, 03 Mar 2014 08:02:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=YGWcYTisGWK9vIbZ3f+OSJbdn429jJ5SFvznswHQ2RQ=; b=J7lLY3D1i+TFkqKNdvTiCV8A7T8mXOzgzDMBBRGpvSx/m1WGVWmAV6ou9iA/svwUmf 8TjcMny4n7FvmvrAJHIP32Vj3SRnGXwBykNNWIeFFzACi9sZQa6y4iE+omA98hq+nez+ SXzN4l6FZBILjxW9thoakF4DQEMhC+GqXA1nrC0UJ5OM0JRTQSBcNE+5Q2Qj6mF6SOKb 9ExaU3HkWNl/gVInEC0nU+tSpHs3u61mYMm1HTzeq9ohv5qN72q4HRd+/XvgC4S3z4TH D7ooCtNB7i362O+AnwWLdtY8hVLhNopSefwVqV/AOwgOMTSG8nQGVyn3egg9WOB8fpNW 475Q== X-Received: by 10.14.95.2 with SMTP id o2mr40606929eef.69.1393862559673; Mon, 03 Mar 2014 08:02:39 -0800 (PST) Received: from flatron.tomeq (87-207-52-162.dynamic.chello.pl. [87.207.52.162]) by mx.google.com with ESMTPSA id y51sm51430597eeu.0.2014.03.03.08.02.37 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 03 Mar 2014 08:02:38 -0800 (PST) From: Tomasz Figa To: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, Greg Kroah-Hartman , "Rafael J. Wysocki" , Pavel Machek , Len Brown , Russell King , Kukjin Kim , Kumar Gala , Ian Campbell , Mark Rutland , Pawel Moll , Rob Herring , Bartlomiej Zolnierkiewicz , Stephen Warren , Tomasz Figa , Mark Brown , Stephen Boyd , Lorenzo Pieralisi , Ulf Hansson , Marek Szyprowski , Tomasz Figa Subject: [PATCH v2 04/11] ARM: s3c64xx: pm: Use name field of generic_pm_domain Date: Mon, 3 Mar 2014 17:02:09 +0100 Message-Id: <1393862536-9842-5-git-send-email-tomasz.figa@gmail.com> X-Mailer: git-send-email 1.9.0 In-Reply-To: <1393862536-9842-1-git-send-email-tomasz.figa@gmail.com> References: <1393862536-9842-1-git-send-email-tomasz.figa@gmail.com> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Spam-Status: No, score=-3.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, KHOP_BIG_TO_CC, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, 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 This patch removes name field from private s3c64xx_pm_domain struct and moves domain name to dedicated field of generic_pm_domain struct. Signed-off-by: Tomasz Figa --- arch/arm/mach-s3c64xx/pm.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/arch/arm/mach-s3c64xx/pm.c b/arch/arm/mach-s3c64xx/pm.c index b5a6698..df4b7b2 100644 --- a/arch/arm/mach-s3c64xx/pm.c +++ b/arch/arm/mach-s3c64xx/pm.c @@ -36,7 +36,6 @@ #include "regs-syscon-power.h" struct s3c64xx_pm_domain { - char *const name; u32 ena; u32 pwr_stat; struct generic_pm_domain pd; @@ -77,7 +76,7 @@ static int s3c64xx_pd_on(struct generic_pm_domain *domain) } while (retry--); if (!retry) { - pr_err("Failed to start domain %s\n", pd->name); + pr_err("Failed to start domain %s\n", pd->pd.name); return -EBUSY; } } @@ -86,78 +85,78 @@ static int s3c64xx_pd_on(struct generic_pm_domain *domain) } static struct s3c64xx_pm_domain s3c64xx_pm_irom = { - .name = "IROM", .ena = S3C64XX_NORMALCFG_IROM_ON, .pd = { + .name = "IROM", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_etm = { - .name = "ETM", .ena = S3C64XX_NORMALCFG_DOMAIN_ETM_ON, .pwr_stat = S3C64XX_BLKPWRSTAT_ETM, .pd = { + .name = "ETM", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_s = { - .name = "S", .ena = S3C64XX_NORMALCFG_DOMAIN_S_ON, .pwr_stat = S3C64XX_BLKPWRSTAT_S, .pd = { + .name = "S", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_f = { - .name = "F", .ena = S3C64XX_NORMALCFG_DOMAIN_F_ON, .pwr_stat = S3C64XX_BLKPWRSTAT_F, .pd = { + .name = "F", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_p = { - .name = "P", .ena = S3C64XX_NORMALCFG_DOMAIN_P_ON, .pwr_stat = S3C64XX_BLKPWRSTAT_P, .pd = { + .name = "P", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_i = { - .name = "I", .ena = S3C64XX_NORMALCFG_DOMAIN_I_ON, .pwr_stat = S3C64XX_BLKPWRSTAT_I, .pd = { + .name = "I", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_g = { - .name = "G", .ena = S3C64XX_NORMALCFG_DOMAIN_G_ON, .pd = { + .name = "G", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, }, }; static struct s3c64xx_pm_domain s3c64xx_pm_v = { - .name = "V", .ena = S3C64XX_NORMALCFG_DOMAIN_V_ON, .pwr_stat = S3C64XX_BLKPWRSTAT_V, .pd = { + .name = "V", .power_off = s3c64xx_pd_off, .power_on = s3c64xx_pd_on, },