From 6336cc05d0277622c8b12e7682f9ae96cfdcf7a4 Mon Sep 17 00:00:00 2001 From: dumbbell Date: Tue, 16 Sep 2014 18:02:24 +0000 Subject: vt(4): Use vt_fb_drawrect() and vt_fb_setpixel() in all vt_fb-derivative Review: https://reviews.freebsd.org/D789 Reviewed by: nwhitehorn Approved by: nwhitehorn MFC after: 2 days --- sys/dev/vt/hw/efifb/efifb.c | 2 ++ sys/dev/vt/hw/fb/vt_early_fb.c | 2 ++ sys/dev/vt/hw/fb/vt_fb.c | 7 ++----- sys/dev/vt/hw/fb/vt_fb.h | 2 ++ 4 files changed, 8 insertions(+), 5 deletions(-) (limited to 'sys/dev/vt') diff --git a/sys/dev/vt/hw/efifb/efifb.c b/sys/dev/vt/hw/efifb/efifb.c index ff95391..05b2d79 100644 --- a/sys/dev/vt/hw/efifb/efifb.c +++ b/sys/dev/vt/hw/efifb/efifb.c @@ -62,6 +62,8 @@ static struct vt_driver vt_efifb_driver = { .vd_blank = vt_fb_blank, .vd_bitblt_text = vt_fb_bitblt_text, .vd_bitblt_bmp = vt_fb_bitblt_bitmap, + .vd_drawrect = vt_fb_drawrect, + .vd_setpixel = vt_fb_setpixel, .vd_fb_ioctl = vt_fb_ioctl, .vd_fb_mmap = vt_fb_mmap, /* Better than VGA, but still generic driver. */ diff --git a/sys/dev/vt/hw/fb/vt_early_fb.c b/sys/dev/vt/hw/fb/vt_early_fb.c index ff50a9c..187f7f7 100644 --- a/sys/dev/vt/hw/fb/vt_early_fb.c +++ b/sys/dev/vt/hw/fb/vt_early_fb.c @@ -61,6 +61,8 @@ static struct vt_driver vt_fb_early_driver = { .vd_blank = vt_fb_blank, .vd_bitblt_text = vt_fb_bitblt_text, .vd_bitblt_bmp = vt_fb_bitblt_bitmap, + .vd_drawrect = vt_fb_drawrect, + .vd_setpixel = vt_fb_setpixel, .vd_priority = VD_PRIORITY_GENERIC, }; diff --git a/sys/dev/vt/hw/fb/vt_fb.c b/sys/dev/vt/hw/fb/vt_fb.c index ddec76d..422bb03 100644 --- a/sys/dev/vt/hw/fb/vt_fb.c +++ b/sys/dev/vt/hw/fb/vt_fb.c @@ -41,9 +41,6 @@ __FBSDID("$FreeBSD$"); #include #include -static vd_drawrect_t vt_fb_drawrect; -static vd_setpixel_t vt_fb_setpixel; - static struct vt_driver vt_fb_driver = { .vd_name = "fb", .vd_init = vt_fb_init, @@ -146,7 +143,7 @@ vt_fb_mmap(struct vt_device *vd, vm_ooffset_t offset, vm_paddr_t *paddr, return (EINVAL); } -static void +void vt_fb_setpixel(struct vt_device *vd, int x, int y, term_color_t color) { struct fb_info *info; @@ -181,7 +178,7 @@ vt_fb_setpixel(struct vt_device *vd, int x, int y, term_color_t color) } -static void +void vt_fb_drawrect(struct vt_device *vd, int x1, int y1, int x2, int y2, int fill, term_color_t color) { diff --git a/sys/dev/vt/hw/fb/vt_fb.h b/sys/dev/vt/hw/fb/vt_fb.h index 9a0da6e..43ce2b7 100644 --- a/sys/dev/vt/hw/fb/vt_fb.h +++ b/sys/dev/vt/hw/fb/vt_fb.h @@ -40,6 +40,8 @@ vd_init_t vt_fb_init; vd_blank_t vt_fb_blank; vd_bitblt_text_t vt_fb_bitblt_text; vd_bitblt_bmp_t vt_fb_bitblt_bitmap; +vd_drawrect_t vt_fb_drawrect; +vd_setpixel_t vt_fb_setpixel; vd_postswitch_t vt_fb_postswitch; vd_fb_ioctl_t vt_fb_ioctl; vd_fb_mmap_t vt_fb_mmap; -- cgit v1.1