* [PM-OPP][PATCH v2 1/2] omap: pm: opp: remove opp_id
[not found] <[PM-OPP][PATCH 1/2] omap: pm: opp: remove opp_id>
@ 2010-08-11 2:43 ` Nishanth Menon
2010-08-11 23:46 ` Kevin Hilman
0 siblings, 1 reply; 3+ messages in thread
From: Nishanth Menon @ 2010-08-11 2:43 UTC (permalink / raw)
To: linux-omap
Cc: Nishanth Menon, Eduardo Valentin, Kevin Hilman, Paul Walmsley,
Rajendra Nayak, Sanjeev Premi, Thara Gopinath, Tony Lindgren
Remove the concept of opp_id now that SRF is gone from pm branch
the new framework should exist on silicon variants without the
notion of opp ids
This also removes the deprecated functions opp_get_opp_id and
opp_find_by_opp_id.
Cc: Eduardo Valentin <eduardo.valentin@nokia.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Cc: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Sanjeev Premi <premi@ti.com>
Cc: Thara Gopinath <thara@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
---
v1: original patch https://patchwork.kernel.org/patch/118723/
v2: I missed cleaning up opp_add properly :( (I should have removed
the variable i and removed the list walk for renumbering..) apologies
on the spam..
Note: for folks using SRF, you'd have to revert this patch
arch/arm/plat-omap/include/plat/opp.h | 15 ---------
arch/arm/plat-omap/opp.c | 52 ---------------------------------
2 files changed, 0 insertions(+), 67 deletions(-)
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..17f93b2 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
*
@@ -344,7 +298,6 @@ int opp_add(const struct omap_opp_def *opp_def)
struct omap_opp *opp, *new_opp;
struct platform_device *pdev;
struct list_head *head;
- int i;
/* find the correct hwmod, and device */
if (!opp_def->hwmod_name) {
@@ -410,11 +363,6 @@ int opp_add(const struct omap_opp_def *opp_def)
if (new_opp->enabled)
dev_opp->enabled_opp_count++;
- /* 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;
}
--
1.6.3.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PM-OPP][PATCH v2 1/2] omap: pm: opp: remove opp_id
2010-08-11 2:43 ` [PM-OPP][PATCH v2 1/2] omap: pm: opp: remove opp_id Nishanth Menon
@ 2010-08-11 23:46 ` Kevin Hilman
2010-08-12 1:36 ` Nishanth Menon
0 siblings, 1 reply; 3+ messages in thread
From: Kevin Hilman @ 2010-08-11 23:46 UTC (permalink / raw)
To: Nishanth Menon
Cc: linux-omap, Eduardo Valentin, Paul Walmsley, Rajendra Nayak,
Sanjeev Premi, Thara Gopinath, Tony Lindgren
Nishanth Menon <nm@ti.com> writes:
> Remove the concept of opp_id now that SRF is gone from pm branch
> the new framework should exist on silicon variants without the
> notion of opp ids
>
> This also removes the deprecated functions opp_get_opp_id and
> opp_find_by_opp_id.
>
> Cc: Eduardo Valentin <eduardo.valentin@nokia.com>
> Cc: Kevin Hilman <khilman@deeprootsystems.com>
> Cc: Paul Walmsley <paul@pwsan.com>
> Cc: Rajendra Nayak <rnayak@ti.com>
> Cc: Sanjeev Premi <premi@ti.com>
> Cc: Thara Gopinath <thara@ti.com>
> Cc: Tony Lindgren <tony@atomide.com>
>
> Signed-off-by: Nishanth Menon <nm@ti.com>
> ---
> v1: original patch https://patchwork.kernel.org/patch/118723/
> v2: I missed cleaning up opp_add properly :( (I should have removed
> the variable i and removed the list walk for renumbering..) apologies
> on the spam..
> Note: for folks using SRF, you'd have to revert this patch
>
> arch/arm/plat-omap/include/plat/opp.h | 15 ---------
> arch/arm/plat-omap/opp.c | 52 ---------------------------------
> 2 files changed, 0 insertions(+), 67 deletions(-)
I squashed this into patch 1 in pm-opp and also removed the references
to to the deprecated functions in Documentation/arm/OMAP/omap_pm.
Kevin
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PM-OPP][PATCH v2 1/2] omap: pm: opp: remove opp_id
2010-08-11 23:46 ` Kevin Hilman
@ 2010-08-12 1:36 ` Nishanth Menon
0 siblings, 0 replies; 3+ messages in thread
From: Nishanth Menon @ 2010-08-12 1:36 UTC (permalink / raw)
To: Kevin Hilman
Cc: linux-omap, Eduardo Valentin, Paul Walmsley, Nayak, Rajendra,
Premi, Sanjeev, Gopinath, Thara, Tony Lindgren
Kevin Hilman had written, on 08/11/2010 06:46 PM, the following:
> Nishanth Menon <nm@ti.com> writes:
>
>> Remove the concept of opp_id now that SRF is gone from pm branch
>> the new framework should exist on silicon variants without the
>> notion of opp ids
[...]
>>
>> arch/arm/plat-omap/include/plat/opp.h | 15 ---------
>> arch/arm/plat-omap/opp.c | 52 ---------------------------------
>> 2 files changed, 0 insertions(+), 67 deletions(-)
>
> I squashed this into patch 1 in pm-opp and also removed the references
> to to the deprecated functions in Documentation/arm/OMAP/omap_pm.
arrgh.. i missed that.. thanks for doing it..
--
Regards,
Nishanth Menon
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-08-12 1:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <[PM-OPP][PATCH 1/2] omap: pm: opp: remove opp_id>
2010-08-11 2:43 ` [PM-OPP][PATCH v2 1/2] omap: pm: opp: remove opp_id Nishanth Menon
2010-08-11 23:46 ` Kevin Hilman
2010-08-12 1:36 ` Nishanth Menon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).