Message ID | 1405413629-4266-7-git-send-email-sonika.jindal@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Tue, Jul 15, 2014 at 02:10:29PM +0530, sonika.jindal@intel.com wrote: > From: Sonika Jindal <sonika.jindal@intel.com> > > Reset rotation property to 0 wherever applicable > > Signed-off-by: Sonika Jindal <sonika.jindal@intel.com> > --- > drivers/gpu/drm/drm_fb_helper.c | 10 +++++++++- > 1 file changed, 9 insertions(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/drm_fb_helper.c b/drivers/gpu/drm/drm_fb_helper.c > index 3144db9..961afcb 100644 > --- a/drivers/gpu/drm/drm_fb_helper.c > +++ b/drivers/gpu/drm/drm_fb_helper.c > @@ -345,9 +345,17 @@ static bool restore_fbdev_mode(struct drm_fb_helper *fb_helper) > > drm_warn_on_modeset_not_all_locked(dev); > > - list_for_each_entry(plane, &dev->mode_config.plane_list, head) > + list_for_each_entry(plane, &dev->mode_config.plane_list, head) { > + > + if (dev->mode_config.rotation_property) { > + drm_object_property_set_value(&plane->base, > + dev->mode_config.rotation_property, > + BIT(DRM_ROTATE_0)); > + } > + > if (plane->type != DRM_PLANE_TYPE_PRIMARY) > drm_plane_force_disable(plane); I would reset the property after disabling the plane. > + } > > for (i = 0; i < fb_helper->crtc_count; i++) { > struct drm_mode_set *mode_set = &fb_helper->crtc_info[i].mode_set; > -- > 1.7.10.4 > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx
On 8/4/2014 5:31 PM, Ville Syrjälä wrote: > On Tue, Jul 15, 2014 at 02:10:29PM +0530, sonika.jindal@intel.com wrote: >> From: Sonika Jindal <sonika.jindal@intel.com> >> >> Reset rotation property to 0 wherever applicable >> >> Signed-off-by: Sonika Jindal <sonika.jindal@intel.com> >> --- >> drivers/gpu/drm/drm_fb_helper.c | 10 +++++++++- >> 1 file changed, 9 insertions(+), 1 deletion(-) >> >> diff --git a/drivers/gpu/drm/drm_fb_helper.c b/drivers/gpu/drm/drm_fb_helper.c >> index 3144db9..961afcb 100644 >> --- a/drivers/gpu/drm/drm_fb_helper.c >> +++ b/drivers/gpu/drm/drm_fb_helper.c >> @@ -345,9 +345,17 @@ static bool restore_fbdev_mode(struct drm_fb_helper *fb_helper) >> >> drm_warn_on_modeset_not_all_locked(dev); >> >> - list_for_each_entry(plane, &dev->mode_config.plane_list, head) >> + list_for_each_entry(plane, &dev->mode_config.plane_list, head) { >> + >> + if (dev->mode_config.rotation_property) { >> + drm_object_property_set_value(&plane->base, >> + dev->mode_config.rotation_property, >> + BIT(DRM_ROTATE_0)); >> + } >> + >> if (plane->type != DRM_PLANE_TYPE_PRIMARY) >> drm_plane_force_disable(plane); > > I would reset the property after disabling the plane. Ok, I will change that. > >> + } >> >> for (i = 0; i < fb_helper->crtc_count; i++) { >> struct drm_mode_set *mode_set = &fb_helper->crtc_info[i].mode_set; >> -- >> 1.7.10.4 >> >> _______________________________________________ >> Intel-gfx mailing list >> Intel-gfx@lists.freedesktop.org >> http://lists.freedesktop.org/mailman/listinfo/intel-gfx >
diff --git a/drivers/gpu/drm/drm_fb_helper.c b/drivers/gpu/drm/drm_fb_helper.c index 3144db9..961afcb 100644 --- a/drivers/gpu/drm/drm_fb_helper.c +++ b/drivers/gpu/drm/drm_fb_helper.c @@ -345,9 +345,17 @@ static bool restore_fbdev_mode(struct drm_fb_helper *fb_helper) drm_warn_on_modeset_not_all_locked(dev); - list_for_each_entry(plane, &dev->mode_config.plane_list, head) + list_for_each_entry(plane, &dev->mode_config.plane_list, head) { + + if (dev->mode_config.rotation_property) { + drm_object_property_set_value(&plane->base, + dev->mode_config.rotation_property, + BIT(DRM_ROTATE_0)); + } + if (plane->type != DRM_PLANE_TYPE_PRIMARY) drm_plane_force_disable(plane); + } for (i = 0; i < fb_helper->crtc_count; i++) { struct drm_mode_set *mode_set = &fb_helper->crtc_info[i].mode_set;