aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/fbdev/fsl-diu-fb.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/video/fbdev/fsl-diu-fb.c')
-rw-r--r--drivers/video/fbdev/fsl-diu-fb.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/drivers/video/fbdev/fsl-diu-fb.c b/drivers/video/fbdev/fsl-diu-fb.c
index fe00a07c122e..ca3d6b366471 100644
--- a/drivers/video/fbdev/fsl-diu-fb.c
+++ b/drivers/video/fbdev/fsl-diu-fb.c
@@ -439,12 +439,12 @@ static struct mfb_info mfb_template[] = {
static void __attribute__ ((unused)) fsl_diu_dump(struct diu __iomem *hw)
{
mb();
- pr_debug("DIU: desc=%08x,%08x,%08x, gamma=%08x pallete=%08x "
+ pr_debug("DIU: desc=%08x,%08x,%08x, gamma=%08x palette=%08x "
"cursor=%08x curs_pos=%08x diu_mode=%08x bgnd=%08x "
"disp_size=%08x hsyn_para=%08x vsyn_para=%08x syn_pol=%08x "
"thresholds=%08x int_mask=%08x plut=%08x\n",
hw->desc[0], hw->desc[1], hw->desc[2], hw->gamma,
- hw->pallete, hw->cursor, hw->curs_pos, hw->diu_mode,
+ hw->palette, hw->cursor, hw->curs_pos, hw->diu_mode,
hw->bgnd, hw->disp_size, hw->hsyn_para, hw->vsyn_para,
hw->syn_pol, hw->thresholds, hw->int_mask, hw->plut);
rmb();
@@ -703,12 +703,6 @@ static int fsl_diu_check_var(struct fb_var_screeninfo *var,
if (var->yres_virtual < var->yres)
var->yres_virtual = var->yres;
- if (var->xoffset < 0)
- var->xoffset = 0;
-
- if (var->yoffset < 0)
- var->yoffset = 0;
-
if (var->xoffset + info->var.xres > info->var.xres_virtual)
var->xoffset = info->var.xres_virtual - info->var.xres;
@@ -1254,8 +1248,7 @@ static int fsl_diu_pan_display(struct fb_var_screeninfo *var,
(info->var.yoffset == var->yoffset))
return 0; /* No change, do nothing */
- if (var->xoffset < 0 || var->yoffset < 0
- || var->xoffset + info->var.xres > info->var.xres_virtual
+ if (var->xoffset + info->var.xres > info->var.xres_virtual
|| var->yoffset + info->var.yres > info->var.yres_virtual)
return -EINVAL;