Commit 8f6e4a50 authored by Petr Vandrovec's avatar Petr Vandrovec Committed by Linus Torvalds

[PATCH] Assorted matroxfb fixes

This small change does:

(1) Properly document 'outputs' option.

(2) Properly use accelerated characters drawing.  fbcon used depth == 0
    for character painting long ago, but it is fixed for several months.

(3) Provide correct hints for fbcon about matroxfb/matroxfb_crtc2
    hardware capabilities.
Signed-off-by: default avatarPetr Vandrovec <vandrove@vc.cvut.cz>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent c726558b
...@@ -223,6 +223,13 @@ dfp:X - use settings X for digital flat panel interface. X is number from ...@@ -223,6 +223,13 @@ dfp:X - use settings X for digital flat panel interface. X is number from
selects who is source of display clocks, whether G400, or panel. selects who is source of display clocks, whether G400, or panel.
Default value is now read back from hardware - so you should specify Default value is now read back from hardware - so you should specify
this value only if you are also using `init' parameter. this value only if you are also using `init' parameter.
outputs:XYZ - set mapping between CRTC and outputs. Each letter can have value
of 0 (for no CRTC), 1 (CRTC1) or 2 (CRTC2), and first letter corresponds
to primary analog output, second letter to the secondary analog output
and third letter to the DVI output. Default setting is 100 for
cards below G400 or G400 without DFP, 101 for G400 with DFP, and
111 for G450 and G550. You can set mapping only on first card,
use matroxset for setting up other devices.
vesa:X - selects startup videomode. X is number from 0 to 0x1FF, see table vesa:X - selects startup videomode. X is number from 0 to 0x1FF, see table
above for detailed explanation. Default is 640x480x8bpp if driver above for detailed explanation. Default is 640x480x8bpp if driver
has 8bpp support. Otherwise first available of 640x350x4bpp, has 8bpp support. Otherwise first available of 640x350x4bpp,
......
...@@ -470,7 +470,7 @@ static void matroxfb_imageblit(struct fb_info* info, const struct fb_image* imag ...@@ -470,7 +470,7 @@ static void matroxfb_imageblit(struct fb_info* info, const struct fb_image* imag
DBG_HEAVY(__FUNCTION__); DBG_HEAVY(__FUNCTION__);
if (image->depth == 0) { if (image->depth == 1) {
u_int32_t fgx, bgx; u_int32_t fgx, bgx;
fgx = ((u_int32_t*)info->pseudo_palette)[image->fg_color]; fgx = ((u_int32_t*)info->pseudo_palette)[image->fg_color];
......
...@@ -1750,6 +1750,12 @@ static int initMatrox2(WPMINFO struct board* b){ ...@@ -1750,6 +1750,12 @@ static int initMatrox2(WPMINFO struct board* b){
ACCESS_FBINFO(fbcon.pseudo_palette) = ACCESS_FBINFO(cmap); ACCESS_FBINFO(fbcon.pseudo_palette) = ACCESS_FBINFO(cmap);
/* after __init time we are like module... no logo */ /* after __init time we are like module... no logo */
ACCESS_FBINFO(fbcon.flags) = hotplug ? FBINFO_FLAG_MODULE : FBINFO_FLAG_DEFAULT; ACCESS_FBINFO(fbcon.flags) = hotplug ? FBINFO_FLAG_MODULE : FBINFO_FLAG_DEFAULT;
ACCESS_FBINFO(fbcon.flags) |= FBINFO_PARTIAL_PAN_OK | /* Prefer panning for scroll under MC viewer/edit */
FBINFO_HWACCEL_COPYAREA | /* We have hw-assisted bmove */
FBINFO_HWACCEL_FILLRECT | /* And fillrect */
FBINFO_HWACCEL_IMAGEBLIT | /* And imageblit */
FBINFO_HWACCEL_XPAN | /* And we support both horizontal */
FBINFO_HWACCEL_YPAN; /* And vertical panning */
ACCESS_FBINFO(video.len_usable) &= PAGE_MASK; ACCESS_FBINFO(video.len_usable) &= PAGE_MASK;
fb_alloc_cmap(&ACCESS_FBINFO(fbcon.cmap), 256, 1); fb_alloc_cmap(&ACCESS_FBINFO(fbcon.cmap), 256, 1);
......
...@@ -603,6 +603,8 @@ static int matroxfb_dh_regit(CPMINFO struct matroxfb_dh_fb_info* m2info) { ...@@ -603,6 +603,8 @@ static int matroxfb_dh_regit(CPMINFO struct matroxfb_dh_fb_info* m2info) {
m2info->fbcon.fbops = &matroxfb_dh_ops; m2info->fbcon.fbops = &matroxfb_dh_ops;
m2info->fbcon.flags = FBINFO_FLAG_DEFAULT; m2info->fbcon.flags = FBINFO_FLAG_DEFAULT;
m2info->fbcon.flags |= FBINFO_HWACCEL_XPAN |
FBINFO_HWACCEL_YPAN;
m2info->fbcon.currcon = -1; m2info->fbcon.currcon = -1;
m2info->fbcon.pseudo_palette = m2info->cmap; m2info->fbcon.pseudo_palette = m2info->cmap;
fb_alloc_cmap(&m2info->fbcon.cmap, 256, 1); fb_alloc_cmap(&m2info->fbcon.cmap, 256, 1);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment