git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git]
/
drivers
/
video
/
matrox
/
matroxfb_crtc2.c
diff --git
a/drivers/video/matrox/matroxfb_crtc2.c
b/drivers/video/matrox/matroxfb_crtc2.c
index
0d7e067
..
27eb4bb
100644
(file)
--- a/
drivers/video/matrox/matroxfb_crtc2.c
+++ b/
drivers/video/matrox/matroxfb_crtc2.c
@@
-21,7
+21,7
@@
static int mem = 8192;
static int mem = 8192;
-
MODULE_PARM(mem, "i"
);
+
module_param(mem, int, 0
);
MODULE_PARM_DESC(mem, "Memory size reserved for dualhead (default=8MB)");
/* **************************************************** */
MODULE_PARM_DESC(mem, "Memory size reserved for dualhead (default=8MB)");
/* **************************************************** */
@@
-387,6
+387,7
@@
static int matroxfb_dh_set_par(struct fb_info* info) {
up_read(&ACCESS_FBINFO(altout).lock);
matroxfb_dh_cfbX_init(m2info);
}
up_read(&ACCESS_FBINFO(altout).lock);
matroxfb_dh_cfbX_init(m2info);
}
+ m2info->initialized = 1;
return 0;
#undef m2info
}
return 0;
#undef m2info
}
@@
-418,11
+419,10
@@
static int matroxfb_dh_get_vblank(const struct matroxfb_dh_fb_info* m2info, stru
return 0;
}
return 0;
}
-static int matroxfb_dh_ioctl(struct inode* inode,
- struct file* file,
+static int matroxfb_dh_ioctl(struct fb_info *info,
unsigned int cmd,
unsigned int cmd,
- unsigned long arg
,
-
struct fb_info* info)
{
+ unsigned long arg
)
+{
#define m2info (container_of(info, struct matroxfb_dh_fb_info, fbcon))
MINFO_FROM(m2info->primary_dev);
#define m2info (container_of(info, struct matroxfb_dh_fb_info, fbcon))
MINFO_FROM(m2info->primary_dev);
@@
-456,7
+456,7
@@
static int matroxfb_dh_ioctl(struct inode* inode,
case MATROXFB_GET_OUTPUT_MODE:
case MATROXFB_GET_ALL_OUTPUTS:
{
case MATROXFB_GET_OUTPUT_MODE:
case MATROXFB_GET_ALL_OUTPUTS:
{
- return ACCESS_FBINFO(fbcon.fbops)->fb_ioctl(
inode, file, cmd, arg, &ACCESS_FBINFO(fbcon)
);
+ return ACCESS_FBINFO(fbcon.fbops)->fb_ioctl(
&ACCESS_FBINFO(fbcon), cmd, arg
);
}
case MATROXFB_SET_OUTPUT_CONNECTION:
{
}
case MATROXFB_SET_OUTPUT_CONNECTION:
{
@@
-575,7
+575,6
@@
static struct fb_ops matroxfb_dh_ops = {
.fb_fillrect = cfb_fillrect,
.fb_copyarea = cfb_copyarea,
.fb_imageblit = cfb_imageblit,
.fb_fillrect = cfb_fillrect,
.fb_copyarea = cfb_copyarea,
.fb_imageblit = cfb_imageblit,
- .fb_cursor = soft_cursor,
};
static struct fb_var_screeninfo matroxfb_dh_defined = {
};
static struct fb_var_screeninfo matroxfb_dh_defined = {
@@
-603,7
+602,8
@@
static int matroxfb_dh_regit(CPMINFO struct matroxfb_dh_fb_info* m2info) {
m2info->fbcon.fbops = &matroxfb_dh_ops;
m2info->fbcon.flags = FBINFO_FLAG_DEFAULT;
m2info->fbcon.fbops = &matroxfb_dh_ops;
m2info->fbcon.flags = FBINFO_FLAG_DEFAULT;
- m2info->fbcon.currcon = -1;
+ m2info->fbcon.flags |= FBINFO_HWACCEL_XPAN |
+ FBINFO_HWACCEL_YPAN;
m2info->fbcon.pseudo_palette = m2info->cmap;
fb_alloc_cmap(&m2info->fbcon.cmap, 256, 1);
m2info->fbcon.pseudo_palette = m2info->cmap;
fb_alloc_cmap(&m2info->fbcon.cmap, 256, 1);
@@
-632,9
+632,8
@@
static int matroxfb_dh_regit(CPMINFO struct matroxfb_dh_fb_info* m2info) {
if (register_framebuffer(&m2info->fbcon)) {
return -ENXIO;
}
if (register_framebuffer(&m2info->fbcon)) {
return -ENXIO;
}
- if (
m2info->fbcon.currcon < 0) {
+ if (
!m2info->initialized)
fb_set_var(&m2info->fbcon, &matroxfb_dh_defined);
fb_set_var(&m2info->fbcon, &matroxfb_dh_defined);
- }
down_write(&ACCESS_FBINFO(crtc2.lock));
oldcrtc2 = ACCESS_FBINFO(crtc2.info);
ACCESS_FBINFO(crtc2.info) = m2info;
down_write(&ACCESS_FBINFO(crtc2.lock));
oldcrtc2 = ACCESS_FBINFO(crtc2.info);
ACCESS_FBINFO(crtc2.info) = m2info;
@@
-721,6
+720,9
@@
static struct matroxfb_driver crtc2 = {
.remove = matroxfb_crtc2_remove };
static int matroxfb_crtc2_init(void) {
.remove = matroxfb_crtc2_remove };
static int matroxfb_crtc2_init(void) {
+ if (fb_get_options("matrox_crtc2fb", NULL))
+ return -ENODEV;
+
matroxfb_register_driver(&crtc2);
return 0;
}
matroxfb_register_driver(&crtc2);
return 0;
}