summaryrefslogtreecommitdiffstats
path: root/drivers/video/fbdev/sis
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/video/fbdev/sis')
-rw-r--r--drivers/video/fbdev/sis/sis_main.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/video/fbdev/sis/sis_main.c b/drivers/video/fbdev/sis/sis_main.c
index 0f5374f6ef..431b1a138c 100644
--- a/drivers/video/fbdev/sis/sis_main.c
+++ b/drivers/video/fbdev/sis/sis_main.c
@@ -1475,6 +1475,8 @@ sisfb_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
vtotal = var->upper_margin + var->lower_margin + var->vsync_len;
+ if (!var->pixclock)
+ return -EINVAL;
pixclock = var->pixclock;
if((var->vmode & FB_VMODE_MASK) == FB_VMODE_NONINTERLACED) {
@@ -1911,6 +1913,7 @@ static const struct fb_ops sisfb_ops = {
.owner = THIS_MODULE,
.fb_open = sisfb_open,
.fb_release = sisfb_release,
+ __FB_DEFAULT_IOMEM_OPS_RDWR,
.fb_check_var = sisfb_check_var,
.fb_set_par = sisfb_set_par,
.fb_setcolreg = sisfb_setcolreg,
@@ -1923,7 +1926,8 @@ static const struct fb_ops sisfb_ops = {
#ifdef SIS_NEW_CONFIG_COMPAT
.fb_compat_ioctl= sisfb_ioctl,
#endif
- .fb_ioctl = sisfb_ioctl
+ .fb_ioctl = sisfb_ioctl,
+ __FB_DEFAULT_IOMEM_OPS_MMAP,
};
/* ---------------- Chip generation dependent routines ---------------- */