diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 576b4b7dcd89c14a0417af74eab6aa78a3b87cb6..466dfbba82564be3b3400382f6bfe324095e8662 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +++ b/drivers/gpu/drm/drm_probe_helper.c @@ -159,6 +159,8 @@ static int drm_helper_probe_add_cmdline_mode(struct drm_connector *connector) continue; } + /* Mark the matching mode as being preferred by the user */ + mode->type |= DRM_MODE_TYPE_USERDEF; return 0; } diff --git a/include/drm/drm_modes.h b/include/drm/drm_modes.h index 730fc31de4fbfedbdfd8f0de7c5b65ab0ce690cf..6a4c4b26caad47b93b88da1d19dd5d830fcf20f3 100644 --- a/include/drm/drm_modes.h +++ b/include/drm/drm_modes.h @@ -256,7 +256,8 @@ struct drm_display_mode { * - DRM_MODE_TYPE_DRIVER: Mode created by the driver, which is all of * them really. Drivers must set this bit for all modes they create * and expose to userspace. - * - DRM_MODE_TYPE_USERDEF: Mode defined via kernel command line + * - DRM_MODE_TYPE_USERDEF: Mode defined or selected via the kernel + * command line. * * Plus a big list of flags which shouldn't be used at all, but are * still around since these flags are also used in the userspace ABI.