From patchwork Wed Aug 11 02:16:57 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nishanth Menon X-Patchwork-Id: 118723 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o7B2HAJR023528 for ; Wed, 11 Aug 2010 02:17:10 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758154Ab0HKCRJ (ORCPT ); Tue, 10 Aug 2010 22:17:09 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:34521 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758030Ab0HKCRI (ORCPT ); Tue, 10 Aug 2010 22:17:08 -0400 Received: from dlep34.itg.ti.com ([157.170.170.115]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id o7B2H3C5004249 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 10 Aug 2010 21:17:03 -0500 Received: from legion.dal.design.ti.com (localhost [127.0.0.1]) by dlep34.itg.ti.com (8.13.7/8.13.7) with ESMTP id o7B2H1Tp002331; Tue, 10 Aug 2010 21:17:01 -0500 (CDT) Received: from senorita (senorita.am.dhcp.ti.com [128.247.74.250]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id o7B2H0f20524; Tue, 10 Aug 2010 21:17:00 -0500 (CDT) Received: by senorita (Postfix, from userid 1000) id 6AE19C15B; Tue, 10 Aug 2010 21:17:00 -0500 (CDT) From: Nishanth Menon To: linux-omap Cc: Nishanth Menon , Eduardo Valentin , Kevin Hilman , Paul Walmsley , Rajendra Nayak , Sanjeev Premi , Thara Gopinath , Tony Lindgren Subject: [PM-OPP][PATCH 1/2] omap: pm: opp: remove opp_id Date: Tue, 10 Aug 2010 21:16:57 -0500 Message-Id: <1281493018-29294-2-git-send-email-nm@ti.com> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: <1281493018-29294-1-git-send-email-nm@ti.com> References: <1281493018-29294-1-git-send-email-nm@ti.com> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Wed, 11 Aug 2010 02:17:10 +0000 (UTC) diff --git a/arch/arm/plat-omap/include/plat/opp.h b/arch/arm/plat-omap/include/plat/opp.h index f9feb8d..997b56e 100644 --- a/arch/arm/plat-omap/include/plat/opp.h +++ b/arch/arm/plat-omap/include/plat/opp.h @@ -82,10 +82,6 @@ int opp_enable(struct omap_opp *opp); int opp_disable(struct omap_opp *opp); -struct omap_opp *__deprecated opp_find_by_opp_id(struct device *dev, - u8 opp_id); -u8 __deprecated opp_get_opp_id(struct omap_opp *opp); - void opp_init_cpufreq_table(struct device *dev, struct cpufreq_frequency_table **table); #else @@ -139,17 +135,6 @@ static inline int opp_disable(struct omap_opp *opp) return 0; } -static inline struct omap_opp *__deprecated -opp_find_by_opp_id(struct omap_opp *opps, u8 opp_id) -{ - return ERR_PTR(-EINVAL); -} - -static inline u8 __deprecated opp_get_opp_id(struct omap_opp *opp) -{ - return 0; -} - static inline void opp_init_cpufreq_table(struct omap_opp *opps, struct cpufreq_frequency_table **table) diff --git a/arch/arm/plat-omap/opp.c b/arch/arm/plat-omap/opp.c index b9b7bda..a246bb9 100644 --- a/arch/arm/plat-omap/opp.c +++ b/arch/arm/plat-omap/opp.c @@ -27,7 +27,6 @@ * @enabled: true/false - marking this OPP as enabled/disabled * @rate: Frequency in hertz * @u_volt: Nominal voltage in microvolts corresponding to this OPP - * @opp_id: opp identifier (deprecated) * @dev_opp: contains the device_opp struct * * This structure stores the OPP information for a given domain. @@ -38,7 +37,6 @@ struct omap_opp { bool enabled; unsigned long rate; unsigned long u_volt; - u8 opp_id; struct device_opp *dev_opp; }; @@ -132,50 +130,6 @@ unsigned long opp_get_freq(const struct omap_opp *opp) } /** - * opp_find_by_opp_id - look up OPP by OPP ID (deprecated) - * @opp_type: OPP type where we want the look up to happen. - * @opp_id: OPP ID to search for - * - * Returns the struct omap_opp pointer corresponding to the given OPP - * ID @opp_id, or returns NULL on error. - */ -struct omap_opp * __deprecated opp_find_by_opp_id(struct device *dev, - u8 opp_id) -{ - struct device_opp *dev_opp; - struct omap_opp *temp_opp, *opp = ERR_PTR(-ENODEV); - - dev_opp = find_device_opp(dev); - if (IS_ERR(dev_opp)) - return opp; - - list_for_each_entry(temp_opp, &dev_opp->opp_list, node) { - if (temp_opp->enabled && temp_opp->opp_id == opp_id) { - opp = temp_opp; - break; - } - } - - return opp; -} - -/** - * opp_get_opp_id() - Provide OPP ID corresponding to an OPP (deprecated) - * @opp: opp for which frequency has to be returned for - * - * Returns an OPP ID for the OPP required, if error, returns 0 - */ -u8 __deprecated opp_get_opp_id(struct omap_opp *opp) -{ - if (unlikely(!opp || IS_ERR(opp)) || !opp->enabled) { - pr_err("%s: Invalid parameter being passed\n", __func__); - return 0; - } - - return opp->opp_id; -} - -/** * opp_get_opp_count() - Get number of opps enabled in the opp list * @opp_type: OPP type we want to count * @@ -413,7 +367,6 @@ int opp_add(const struct omap_opp_def *opp_def) /* renumber (deprecated) OPP IDs based on new order */ i = 0; list_for_each_entry(opp, &dev_opp->opp_list, node) - opp->opp_id = i++; return 0; }