Lines Matching defs:var
226 if ((info->var.bits_per_pixel == 4) && (image->depth == 1)
238 if ((info->var.bits_per_pixel == 4)
320 static int vt8623fb_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
325 rv = svga_match_format (vt8623fb_formats, var, NULL);
333 if (var->xres > var->xres_virtual)
334 var->xres_virtual = var->xres;
336 if (var->yres > var->yres_virtual)
337 var->yres_virtual = var->yres;
341 var->xres_virtual = (var->xres_virtual+step) & ~step;
344 mem = ((var->bits_per_pixel * var->xres_virtual) >> 3) * var->yres_virtual;
353 if ((var->bits_per_pixel == 0) && (mem > (256*1024)))
360 rv = svga_check_timings (&vt8623_timing_regs, var, info->node);
368 if (var->vmode & FB_VMODE_INTERLACED)
379 u32 bpp = info->var.bits_per_pixel;
383 info->fix.line_length = (info->var.xres_virtual * bpp) / 8;
392 offset_value = (info->var.xres_virtual * bpp) / 64;
393 fetch_value = ((info->var.xres * bpp) / 128) + 4;
396 fetch_value = (info->var.xres / 8) + 8; /* + 0 is OK */
398 screen_size = info->var.yres_virtual * info->fix.line_length;
410 offset_value = info->var.xres_virtual / 16;
411 fetch_value = (info->var.xres / 8) + 8;
412 screen_size = (info->var.xres_virtual * info->var.yres_virtual) / 64;
415 info->var.xoffset = 0;
416 info->var.yoffset = 0;
417 info->var.activate = FB_ACTIVATE_NOW;
444 if (info->var.vmode & FB_VMODE_DOUBLE)
466 mode = svga_match_format(vt8623fb_formats, &(info->var), &(info->fix));
502 vt8623_set_pixclock(info, info->var.pixclock);
503 svga_set_timings(par->state.vgabase, &vt8623_timing_regs, &(info->var), 1, 1,
504 (info->var.vmode & FB_VMODE_DOUBLE) ? 2 : 1, 1,
523 switch (fb->var.bits_per_pixel) {
549 if (fb->var.green.length == 5)
552 else if (fb->var.green.length == 6)
611 static int vt8623fb_pan_display(struct fb_var_screeninfo *var, struct fb_info *info)
617 if (info->var.bits_per_pixel == 0) {
618 offset = (var->yoffset / 16) * info->var.xres_virtual
619 + var->xoffset;
622 offset = (var->yoffset * info->fix.line_length) +
623 (var->xoffset * info->var.bits_per_pixel / 8);
624 offset = offset >> ((info->var.bits_per_pixel == 4) ? 2 : 1);
748 rc = fb_find_mode(&(info->var), info, mode_option, NULL, 0, NULL, 8);