Re: [PATCH] ARM: OMAP2+: OPP: Fix to ensure check of right oppdef after bad one

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Kevin, Nishanth,

On 06/01/12 02:15, Kevin Hilman wrote:
> Nishanth Menon <nm@xxxxxx> writes:
> 
>> Commit 9fa2df6b90786301b175e264f5fa9846aba81a65
>> (ARM: OMAP2+: OPP: allow OPP enumeration to continue if device is not present)
>> makes the logic:
>> for (i = 0; i < opp_def_size; i++) {
>> 	<snip>
>> 	if (!oh || !oh->od) {
>> 		<snip>
>> 		continue;
>> 	}
>> <snip>
>> opp_def++;
>> }
>>
>> In short, the moment we hit a "Bad OPP", we end up looping the list
>> comparing against the bad opp definition pointer for the rest of the
>> iteration count. Instead, increment opp_def in the for loop itself
>> and allow continue to be used in code without much thought so that
>> we check the next set of OPP definition pointers :)
>>
>> Cc: Kevin Hilman <khilman@xxxxxx>
>> Cc: Steve Sakoman <steve@xxxxxxxxxxx>
>> Cc: Tony Lindgren <tony@xxxxxxxxxxx>
>> Cc: linux-omap@xxxxxxxxxxxxxxx
>> Cc: linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
>>
>> Signed-off-by: Nishanth Menon <nm@xxxxxx>
> 
> Good catch.
> 
> Queuing for my next set of PM fixes for v3.5-rc (branch: for_3.5/fixes/pm-2)

I think this should also apply for stable, right?
If it should, can you please add a
Cc: stable@xxxxxxxxxxxxxxx
?

Thanks


-- 
Regards,
Igor.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux