Skip to content

Commit b3ec8cd

Browse files
Claudio SuarezThomas Zimmermann
Claudio Suarez
authored and
Thomas Zimmermann
committed
fbdev: Garbage collect fbdev scrolling acceleration, part 1 (from TODO list)
Scroll acceleration is disabled in fbcon by hard-wiring p->scrollmode = SCROLL_REDRAW. Remove the obsolete code in fbcon.c and fbdev/core/ Signed-off-by: Claudio Suarez <[email protected]> Signed-off-by: Thomas Zimmermann <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent cd06ab2 commit b3ec8cd

File tree

11 files changed

+51
-678
lines changed

11 files changed

+51
-678
lines changed

Documentation/gpu/todo.rst

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -314,16 +314,19 @@ Level: Advanced
314314
Garbage collect fbdev scrolling acceleration
315315
--------------------------------------------
316316

317-
Scroll acceleration is disabled in fbcon by hard-wiring p->scrollmode =
318-
SCROLL_REDRAW. There's a ton of code this will allow us to remove:
317+
Scroll acceleration has been disabled in fbcon. Now it works as the old
318+
SCROLL_REDRAW mode. A ton of code was removed in fbcon.c and the hook bmove was
319+
removed from fbcon_ops.
320+
Remaining tasks:
319321

320-
- lots of code in fbcon.c
321-
322-
- a bunch of the hooks in fbcon_ops, maybe the remaining hooks could be called
322+
- a bunch of the hooks in fbcon_ops could be removed or simplified by calling
323323
directly instead of the function table (with a switch on p->rotate)
324324

325325
- fb_copyarea is unused after this, and can be deleted from all drivers
326326

327+
- after that, fb_copyarea can be deleted from fb_ops in include/linux/fb.h as
328+
well as cfb_copyarea
329+
327330
Note that not all acceleration code can be deleted, since clearing and cursor
328331
support is still accelerated, which might be good candidates for further
329332
deletion projects.

drivers/video/fbdev/core/bitblit.c

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -43,21 +43,6 @@ static void update_attr(u8 *dst, u8 *src, int attribute,
4343
}
4444
}
4545

46-
static void bit_bmove(struct vc_data *vc, struct fb_info *info, int sy,
47-
int sx, int dy, int dx, int height, int width)
48-
{
49-
struct fb_copyarea area;
50-
51-
area.sx = sx * vc->vc_font.width;
52-
area.sy = sy * vc->vc_font.height;
53-
area.dx = dx * vc->vc_font.width;
54-
area.dy = dy * vc->vc_font.height;
55-
area.height = height * vc->vc_font.height;
56-
area.width = width * vc->vc_font.width;
57-
58-
info->fbops->fb_copyarea(info, &area);
59-
}
60-
6146
static void bit_clear(struct vc_data *vc, struct fb_info *info, int sy,
6247
int sx, int height, int width)
6348
{
@@ -393,7 +378,6 @@ static int bit_update_start(struct fb_info *info)
393378

394379
void fbcon_set_bitops(struct fbcon_ops *ops)
395380
{
396-
ops->bmove = bit_bmove;
397381
ops->clear = bit_clear;
398382
ops->putcs = bit_putcs;
399383
ops->clear_margins = bit_clear_margins;

0 commit comments

Comments
 (0)