From patchwork Tue Oct 1 13:33:01 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sudeep KarkadaNagesha X-Patchwork-Id: 2970031 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 EABE2BFF0B for ; Tue, 1 Oct 2013 13:32:49 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 02F132041D for ; Tue, 1 Oct 2013 13:32:48 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 00DFC203DC for ; Tue, 1 Oct 2013 13:32:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753310Ab3JANco (ORCPT ); Tue, 1 Oct 2013 09:32:44 -0400 Received: from cam-admin0.cambridge.arm.com ([217.140.96.50]:36894 "EHLO cam-admin0.cambridge.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752765Ab3JANco (ORCPT ); Tue, 1 Oct 2013 09:32:44 -0400 Received: from e103737-lin.cambridge.arm.com (e103737-lin.cambridge.arm.com [10.1.207.34]) by cam-admin0.cambridge.arm.com (8.12.6/8.12.6) with ESMTP id r91DWbkm007353; Tue, 1 Oct 2013 14:32:41 +0100 (BST) From: Sudeep KarkadaNagesha To: cpufreq@vger.kernel.org, linux-pm@vger.kernel.org, devicetree@vger.kernel.org Cc: Sudeep.KarkadaNagesha@arm.com, Sudeep KarkadaNagesha , "Rafael J. Wysocki" , Viresh Kumar Subject: [PATCH v2 4/5] cpufreq: arm_big_little_dt: enhance OPP error checking Date: Tue, 1 Oct 2013 14:33:01 +0100 Message-Id: <1380634382-15609-5-git-send-email-Sudeep.KarkadaNagesha@arm.com> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: <1380634382-15609-1-git-send-email-Sudeep.KarkadaNagesha@arm.com> References: <1380634382-15609-1-git-send-email-Sudeep.KarkadaNagesha@arm.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=-7.6 required=5.0 tests=BAYES_00, 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 From: Sudeep KarkadaNagesha Since the OPPs can be specified either through 'operating-points' as tuples or through 'operating-points-phandle' as phandle to the node containing tuples, we need to check for both the properties. Cc: "Rafael J. Wysocki" Cc: Viresh Kumar Signed-off-by: Sudeep KarkadaNagesha Acked-by: Viresh Kumar Reviewed-by: Nishanth Menon --- drivers/cpufreq/arm_big_little_dt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/cpufreq/arm_big_little_dt.c b/drivers/cpufreq/arm_big_little_dt.c index 480c0bd..b03d4fe 100644 --- a/drivers/cpufreq/arm_big_little_dt.c +++ b/drivers/cpufreq/arm_big_little_dt.c @@ -35,7 +35,8 @@ static struct device_node *get_cpu_node_with_valid_op(int cpu) { struct device_node *np = of_cpu_device_node_get(cpu); - if (!of_get_property(np, "operating-points", NULL)) { + if (!of_get_property(np, "operating-points", NULL) && + !of_get_property(np, "operating-points-phandle", NULL)) { of_node_put(np); np = NULL; }