• Home
  • Raw
  • Download

Lines Matching refs:mode

382 			      struct fb_videomode *mode)  in calc_mode_timings()  argument
393 mode->xres = xres; in calc_mode_timings()
394 mode->yres = yres; in calc_mode_timings()
395 mode->pixclock = var->pixclock; in calc_mode_timings()
396 mode->refresh = refresh; in calc_mode_timings()
397 mode->left_margin = var->left_margin; in calc_mode_timings()
398 mode->right_margin = var->right_margin; in calc_mode_timings()
399 mode->upper_margin = var->upper_margin; in calc_mode_timings()
400 mode->lower_margin = var->lower_margin; in calc_mode_timings()
401 mode->hsync_len = var->hsync_len; in calc_mode_timings()
402 mode->vsync_len = var->vsync_len; in calc_mode_timings()
403 mode->vmode = 0; in calc_mode_timings()
404 mode->sync = 0; in calc_mode_timings()
409 static int get_est_timing(unsigned char *block, struct fb_videomode *mode) in get_est_timing() argument
416 calc_mode_timings(720, 400, 70, &mode[num]); in get_est_timing()
417 mode[num++].flag = FB_MODE_IS_CALCULATED; in get_est_timing()
421 calc_mode_timings(720, 400, 88, &mode[num]); in get_est_timing()
422 mode[num++].flag = FB_MODE_IS_CALCULATED; in get_est_timing()
426 mode[num++] = vesa_modes[3]; in get_est_timing()
430 calc_mode_timings(640, 480, 67, &mode[num]); in get_est_timing()
431 mode[num++].flag = FB_MODE_IS_CALCULATED; in get_est_timing()
435 mode[num++] = vesa_modes[4]; in get_est_timing()
439 mode[num++] = vesa_modes[5]; in get_est_timing()
443 mode[num++] = vesa_modes[7]; in get_est_timing()
447 mode[num++] = vesa_modes[8]; in get_est_timing()
453 mode[num++] = vesa_modes[9]; in get_est_timing()
457 mode[num++] = vesa_modes[10]; in get_est_timing()
461 calc_mode_timings(832, 624, 75, &mode[num]); in get_est_timing()
462 mode[num++].flag = FB_MODE_IS_CALCULATED; in get_est_timing()
466 mode[num++] = vesa_modes[12]; in get_est_timing()
470 mode[num++] = vesa_modes[13]; in get_est_timing()
474 mode[num++] = vesa_modes[14]; in get_est_timing()
478 mode[num++] = vesa_modes[15]; in get_est_timing()
482 mode[num++] = vesa_modes[21]; in get_est_timing()
487 mode[num++] = vesa_modes[17]; in get_est_timing()
494 static int get_std_timing(unsigned char *block, struct fb_videomode *mode, in get_std_timing() argument
505 if (i < DMT_SIZE && dmt_modes[i].mode) { in get_std_timing()
507 *mode = *dmt_modes[i].mode; in get_std_timing()
508 mode->flag |= FB_MODE_IS_STANDARD; in get_std_timing()
540 calc_mode_timings(xres, yres, refresh, mode); in get_std_timing()
545 && PICOS2KHZ(mode->pixclock) * 1000 > specs->dclkmax) { in get_std_timing()
553 static int get_dst_timing(unsigned char *block, struct fb_videomode *mode, in get_dst_timing() argument
559 num += get_std_timing(block, &mode[num], ver, rev, specs); in get_dst_timing()
565 struct fb_videomode *mode) in get_detailed_timing() argument
567 mode->xres = H_ACTIVE; in get_detailed_timing()
568 mode->yres = V_ACTIVE; in get_detailed_timing()
569 mode->pixclock = PIXEL_CLOCK; in get_detailed_timing()
570 mode->pixclock /= 1000; in get_detailed_timing()
571 mode->pixclock = KHZ2PICOS(mode->pixclock); in get_detailed_timing()
572 mode->right_margin = H_SYNC_OFFSET; in get_detailed_timing()
573 mode->left_margin = (H_ACTIVE + H_BLANKING) - in get_detailed_timing()
575 mode->upper_margin = V_BLANKING - V_SYNC_OFFSET - in get_detailed_timing()
577 mode->lower_margin = V_SYNC_OFFSET; in get_detailed_timing()
578 mode->hsync_len = H_SYNC_WIDTH; in get_detailed_timing()
579 mode->vsync_len = V_SYNC_WIDTH; in get_detailed_timing()
581 mode->sync |= FB_SYNC_HOR_HIGH_ACT; in get_detailed_timing()
583 mode->sync |= FB_SYNC_VERT_HIGH_ACT; in get_detailed_timing()
584 mode->refresh = PIXEL_CLOCK/((H_ACTIVE + H_BLANKING) * in get_detailed_timing()
587 mode->yres *= 2; in get_detailed_timing()
588 mode->upper_margin *= 2; in get_detailed_timing()
589 mode->lower_margin *= 2; in get_detailed_timing()
590 mode->vsync_len *= 2; in get_detailed_timing()
591 mode->vmode |= FB_VMODE_INTERLACED; in get_detailed_timing()
593 mode->flag = FB_MODE_IS_DETAILED; in get_detailed_timing()
619 struct fb_videomode *mode, *m; in fb_create_modedb() local
624 mode = kcalloc(50, sizeof(struct fb_videomode), GFP_KERNEL); in fb_create_modedb()
625 if (mode == NULL) in fb_create_modedb()
630 kfree(mode); in fb_create_modedb()
643 get_detailed_timing(block, &mode[num]); in fb_create_modedb()
645 mode[num].flag |= FB_MODE_IS_FIRST; in fb_create_modedb()
654 num += get_est_timing(block, &mode[num]); in fb_create_modedb()
659 num += get_std_timing(block, &mode[num], ver, rev, specs); in fb_create_modedb()
664 num += get_dst_timing(block + 5, &mode[num], in fb_create_modedb()
670 kfree(mode); in fb_create_modedb()
677 return mode; in fb_create_modedb()
678 memmove(m, mode, num * sizeof(struct fb_videomode)); in fb_create_modedb()
679 kfree(mode); in fb_create_modedb()
720 struct fb_videomode *modes, *mode; in fb_get_monitor_limits() local
732 mode = &modes[i]; in fb_get_monitor_limits()
734 htotal = mode->xres + mode->right_margin + mode->hsync_len in fb_get_monitor_limits()
735 + mode->left_margin; in fb_get_monitor_limits()
736 vtotal = mode->yres + mode->lower_margin + mode->vsync_len in fb_get_monitor_limits()
737 + mode->upper_margin; in fb_get_monitor_limits()
739 if (mode->vmode & FB_VMODE_INTERLACED) in fb_get_monitor_limits()
742 if (mode->vmode & FB_VMODE_DOUBLE) in fb_get_monitor_limits()