From patchwork Tue Jul 1 16:32:32 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 4460741 Return-Path: X-Original-To: patchwork-linux-arm-msm@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 DB862BEEAA for ; Tue, 1 Jul 2014 16:39:00 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 1ADF6203EB for ; Tue, 1 Jul 2014 16:39:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 21DAD2015A for ; Tue, 1 Jul 2014 16:38:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758349AbaGAQd5 (ORCPT ); Tue, 1 Jul 2014 12:33:57 -0400 Received: from mail-pa0-f44.google.com ([209.85.220.44]:44408 "EHLO mail-pa0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758343AbaGAQdz (ORCPT ); Tue, 1 Jul 2014 12:33:55 -0400 Received: by mail-pa0-f44.google.com with SMTP id rd3so10908676pab.31 for ; Tue, 01 Jul 2014 09:33:54 -0700 (PDT) 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=96j2++v/lthwq+rFoylmepvGgKXZyQwjiCsG0H0xGnI=; b=MfiPuWzAPDLAdIxf7vMiXWnC4Kf3sH0YV/3WLU1AEoWyxbc1hIIcVxGpNi8JPMWV5v Wru7DQAXJ5jzUE01kn7j596vJpkbGYEwvZVfenuMk03lUA7XC1jPszTJM5THU7yTZCKs 15/Ka6FoM5xMwZ4xDWGSNgaHWcRUgOV777dLQzcz8dPIN23dMsAwYEKe+SX1gyytLBvW akha/xzEC/5m1jvrbXfzmAMF+sdX+FkmXWMOGXqkgys0XZPCnyVjiut5YCQxGija3XiK pZ+gmxsqU/pha22HuAF6/WpIyWLFE1LWDdKGSV7lKPEpqaNWCbeVNXybvuYwvkDYBwPL dagg== X-Gm-Message-State: ALoCoQkZyVDByIiZX6olDuSwLbpCio0426NvEh2mz5G+Bz1aGc3TbHk0JoohtVXoGGmnzYEVp7Yn X-Received: by 10.66.237.8 with SMTP id uy8mr1846911pac.95.1404232434402; Tue, 01 Jul 2014 09:33:54 -0700 (PDT) Received: from localhost ([122.166.172.22]) by mx.google.com with ESMTPSA id y9sm217191pdj.52.2014.07.01.09.33.48 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 01 Jul 2014 09:33:53 -0700 (PDT) From: Viresh Kumar To: rjw@rjwysocki.net, shawn.guo@linaro.org Cc: linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, arvind.chauhan@arm.com, sboyd@codeaurora.org, linux-arm-msm@vger.kernel.org, spk.linux@gmail.com, thomas.ab@samsung.com, nm@ti.com, t.figa@samsung.com, Viresh Kumar Subject: [PATCH 03/14] cpufreq: Add support for per-policy driver data Date: Tue, 1 Jul 2014 22:02:32 +0530 Message-Id: <0614df495e361dd23ebe2d4e4ee3d40cb23948da.1404231535.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.0.0.rc2 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, 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 Drivers supporting multiple clusters or multiple 'struct cpufreq_policy' instances may need to keep per-policy data. If the core doesn't support them, they might do it in the most unoptimized way: 'per-cpu' data. This patch adds another field in 'struct cpufreq_policy': 'driver_data'. It isn't accessed by core and is for driver's internal use. Signed-off-by: Viresh Kumar --- include/linux/cpufreq.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/cpufreq.h b/include/linux/cpufreq.h index ec4112d..d4b1108 100644 --- a/include/linux/cpufreq.h +++ b/include/linux/cpufreq.h @@ -112,6 +112,9 @@ struct cpufreq_policy { spinlock_t transition_lock; wait_queue_head_t transition_wait; struct task_struct *transition_task; /* Task which is doing the transition */ + + /* For cpufreq driver's internal use */ + void *driver_data; }; /* Only for ACPI */