Skip to contentSkip to conversation

Ah! Found a bug in radeonfb.c!

DISCUSSION Timothy Miller 1 participant 1 message Mar 12, 2004

lore
Share & tools
lore
#0 lore raw

I was WONDERING why certain things would get corrupted on the screen when using the radeon framebuffer driver. I've been seeing a number of off-by-one errors.

First of all, the kernel source I'm looking at is 2.4.22-gentoo-r7.

Anyhow, here's the deal. Look at the function 'fbcon_radeon_bmove'. I'm having to type this in by hand due to circumstances, so, here's something that looks vaguely like a patch but which will require people to actually look at (I've never submitted a patch before, so let's just discuss it first):

line 4399:

    if (srcy < dsty) {
-        srcy += height;
-        dsty += height;
+        srcy += height-1;
+        dsty += height-1;
    } else

line 4404:

    if (srcx < dstx) {
-        srcx += width;
-        dstx += width;
+        srcx += width-1;
+        dstx += width-1;
    }