|
From: Geert U. <ge...@li...> - 2002-08-25 15:19:20
|
On Mon, 19 Aug 2002, Geert Uytterhoeven wrote: > On Mon, 19 Aug 2002, Geert Uytterhoeven wrote: > > In cfb_copyarea(), `tmp' must be unsigned long because it is used to store > > unsigned long values (see patch at the end). > > > > cfb_copyarea() also doesn't clear the bits to modify in the first and last > > words of a line, e.g. it does > > > > | last = (FB_READ(src) & start_mask); > > | > > | if (shift > 0) > > | FB_WRITE(FB_READ(dst) | (last >> shift_right), dst); > > ^^^^^^^^^^^^ > > After this read, the bits to modify must be cleared first, before the OR! > > > > I'm working on a version of cfb_copyarea() that fixes this and handles _all_ > > possible values of var.bits_per_pixel (the current code assumes > > var.bits_per_pixel is a multiple of 8). Stay tuned! > ^^^^^^^^^^^^^^^ > Oops, actually 8, 16, or 32 only (and 24 after Antonino Daplas' patch). I also > plan on relaxing the current limitation that line_size must be a multiple of > sizeof(unsigned long). A very first version is available in fbtest (module `fbtest' in linux-fbdev's CVS at sourceforge.net). More optimizations (e.g. cached first/last masks) to be released later... Gr{oetje,eeting}s, Geert P.S. Yes, I work in userspace right know ;-) -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- ge...@li... In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds |