While browsing file util.c (for DVFlasher version 1.14 and before), I saw
the code
// Simple wait loop - comes in handy.
void waitloop(Uint32 loopcnt)
{
for (loopcnt = 0; loopcnt<1000; loopcnt++)
{
asm(" NOP");
}
}
Since the input paramerer is ignored by the for loop, I revised it. It
now loops for the max( input parameter, 1000 ).
Can't tell it it "fixed" anything not previously working (since it's been
working since 2007 or before), but at least it makes
esthetic sense.
Also, changed the count variable to 'volatile'.
// Simple wait loop - comes in handy.
void waitloop(Uint32 loopcnt)
{
Uint32 total=loopcnt;
volatile Uint32 cnt;
if (total<1000) total=1000; // set max count to parm or 1000,
whichever was higher
for (cnt = 0; cnt<total; cnt++)
{
asm(" NOP");
}
}
Regards._______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source