One final point
>>+int set_pd_latency(struct shared_resource *resp, u32 latency)
>>+{
>>+ u32 pd_lat_level, ind;
>>+ struct pd_latency_db *pd_lat_db;
>>+ struct powerdomain *pwrdm;
>>+
>>+ pd_lat_db = resp->resource_data;
>>+ pwrdm = pd_lat_db->pd;
>>+ pd_lat_level = PD_LATENCY_OFF;
>>+ /* using the latency db map to the appropriate PD state */
>>+ for (ind = 0; ind < PD_LATENCY_MAXLEVEL; ind++) {
>>+ if (pd_lat_db->latency[ind] < latency) {
>>+ pd_lat_level = ind;
>>+ break;
>>+ }
>>+ }
>>+
>[Romit] Again is this the right place for this? It should be done only if
>set_pwrdm_state returns successfully. So I think that should be checked as
>well.
>>+ resp->curr_level = pd_lat_level;
>>+ set_pwrdm_state(pwrdm, pd_lat_level);
>>+ return 0;
>>+}
[Romit] In retrospect, I think the code is not right. Someone sets a latency
for say 30ms and what gets updated is the index in the curr_level. Next [s]he
sets a latency value and we will be comparing index with time. Cant we have a
function that would convert the latency (in time) to the right index?
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html