mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 19:30:30 +09:00
drm/rockchip: driver: crtc primary fb is for non atomic driver
meaningful for non-atomic drivers, for atomic drivers this is forced to be NULL. Change-Id: Ic3591c4f4c3ee6de53f89d0b4f230829b1ed056d Signed-off-by: Sandy Huang <hjc@rock-chips.com>
This commit is contained in:
@@ -1483,7 +1483,6 @@ static int rockchip_drm_bind(struct device *dev)
|
||||
|
||||
s = to_rockchip_crtc_state(crtc->state);
|
||||
if (is_support_hotplug(s->output_type)) {
|
||||
s->crtc_primary_fb = crtc->primary->fb;
|
||||
crtc->primary->fb = helper->fb;
|
||||
drm_framebuffer_get(helper->fb);
|
||||
}
|
||||
@@ -1551,15 +1550,8 @@ static int rockchip_drm_open(struct drm_device *dev, struct drm_file *file)
|
||||
{
|
||||
struct drm_crtc *crtc;
|
||||
|
||||
drm_for_each_crtc(crtc, dev) {
|
||||
struct rockchip_crtc_state *s = NULL;
|
||||
|
||||
s = to_rockchip_crtc_state(crtc->state);
|
||||
if (s->crtc_primary_fb) {
|
||||
crtc->primary->fb = s->crtc_primary_fb;
|
||||
s->crtc_primary_fb = NULL;
|
||||
}
|
||||
}
|
||||
drm_for_each_crtc(crtc, dev)
|
||||
crtc->primary->fb = NULL;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -121,7 +121,6 @@ struct rockchip_crtc_state {
|
||||
int color_space;
|
||||
int eotf;
|
||||
struct rockchip_hdr_state hdr;
|
||||
struct drm_framebuffer *crtc_primary_fb;
|
||||
};
|
||||
#define to_rockchip_crtc_state(s) \
|
||||
container_of(s, struct rockchip_crtc_state, base)
|
||||
|
||||
Reference in New Issue
Block a user