drm/fb: Fix video= mode computation
Reduced blanking is valid only when doing CVT modes. Also, generate GTF modes unless CVT was requested; CVT devices are required to support GTF, but the reverse is not true. [airlied: fix typo] Signed-off-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
a5f798ce2b
commit
b829e011f6
@ -146,7 +146,7 @@ static bool drm_fb_helper_connector_parse_command_line(struct drm_fb_helper_conn
|
|||||||
cvt = 1;
|
cvt = 1;
|
||||||
break;
|
break;
|
||||||
case 'R':
|
case 'R':
|
||||||
if (!cvt)
|
if (cvt)
|
||||||
rb = 1;
|
rb = 1;
|
||||||
break;
|
break;
|
||||||
case 'm':
|
case 'm':
|
||||||
@ -1024,11 +1024,18 @@ static struct drm_display_mode *drm_pick_cmdline_mode(struct drm_fb_helper_conne
|
|||||||
}
|
}
|
||||||
|
|
||||||
create_mode:
|
create_mode:
|
||||||
mode = drm_cvt_mode(fb_helper_conn->connector->dev, cmdline_mode->xres,
|
if (cmdline_mode->cvt)
|
||||||
cmdline_mode->yres,
|
mode = drm_cvt_mode(fb_helper_conn->connector->dev,
|
||||||
cmdline_mode->refresh_specified ? cmdline_mode->refresh : 60,
|
cmdline_mode->xres, cmdline_mode->yres,
|
||||||
cmdline_mode->rb, cmdline_mode->interlace,
|
cmdline_mode->refresh_specified ? cmdline_mode->refresh : 60,
|
||||||
cmdline_mode->margins);
|
cmdline_mode->rb, cmdline_mode->interlace,
|
||||||
|
cmdline_mode->margins);
|
||||||
|
else
|
||||||
|
mode = drm_gtf_mode(fb_helper_conn->connector->dev,
|
||||||
|
cmdline_mode->xres, cmdline_mode->yres,
|
||||||
|
cmdline_mode->refresh_specified ? cmdline_mode->refresh : 60,
|
||||||
|
cmdline_mode->interlace,
|
||||||
|
cmdline_mode->margins);
|
||||||
drm_mode_set_crtcinfo(mode, CRTC_INTERLACE_HALVE_V);
|
drm_mode_set_crtcinfo(mode, CRTC_INTERLACE_HALVE_V);
|
||||||
list_add(&mode->head, &fb_helper_conn->connector->modes);
|
list_add(&mode->head, &fb_helper_conn->connector->modes);
|
||||||
return mode;
|
return mode;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user