• David Miller's avatar
    video/aty/mach64_ct.c: fix bogus delay loop · d9202f17
    David Miller authored
    CT based mach64 cards were reported to hang on sparc64 boxes when
    compiled with gcc-4.1.x and later.
    
    Looking at this piece of code, it's no surprise.  A critical
    delay was implemented as an empty for() loop, and gcc 4.0.x
    and previous did not optimize it away, so we did get a delay.
    
    But gcc-4.1.x and later can optimize it away, and we get crashes.
    
    Use a real udelay() to fix this.  Fix verified on SunBlade100.
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    Cc: Andrew Morton <akpm@linux-foundation.org>
    Cc: "Antonino A. Daplas" <adaplas@pol.net>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    d9202f17
mach64_ct.c 19.3 KB