Skip to content

Commit fc7f148

Browse files
committed
drm/virtio: drop virtio_gpu_output->enabled
Not needed, already tracked by drm_crtc_state->active. Signed-off-by: Gerd Hoffmann <[email protected]> Acked-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] (cherry picked from commit 1174c8a)
1 parent 5e2e260 commit fc7f148

File tree

3 files changed

+1
-6
lines changed

3 files changed

+1
-6
lines changed

drivers/gpu/drm/virtio/virtgpu_display.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,6 @@ static void virtio_gpu_crtc_mode_set_nofb(struct drm_crtc *crtc)
9797
static void virtio_gpu_crtc_atomic_enable(struct drm_crtc *crtc,
9898
struct drm_crtc_state *old_state)
9999
{
100-
struct virtio_gpu_output *output = drm_crtc_to_virtio_gpu_output(crtc);
101-
102-
output->enabled = true;
103100
}
104101

105102
static void virtio_gpu_crtc_atomic_disable(struct drm_crtc *crtc,
@@ -111,7 +108,6 @@ static void virtio_gpu_crtc_atomic_disable(struct drm_crtc *crtc,
111108

112109
virtio_gpu_cmd_set_scanout(vgdev, output->index, 0, 0, 0, 0, 0);
113110
virtio_gpu_notify(vgdev);
114-
output->enabled = false;
115111
}
116112

117113
static int virtio_gpu_crtc_atomic_check(struct drm_crtc *crtc,

drivers/gpu/drm/virtio/virtgpu_drv.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,6 @@ struct virtio_gpu_output {
137137
struct edid *edid;
138138
int cur_x;
139139
int cur_y;
140-
bool enabled;
141140
bool needs_modeset;
142141
};
143142
#define drm_crtc_to_virtio_gpu_output(x) \

drivers/gpu/drm/virtio/virtgpu_plane.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane,
142142
if (WARN_ON(!output))
143143
return;
144144

145-
if (!plane->state->fb || !output->enabled) {
145+
if (!plane->state->fb || !output->crtc.state->active) {
146146
DRM_DEBUG("nofb\n");
147147
virtio_gpu_cmd_set_scanout(vgdev, output->index, 0,
148148
plane->state->src_w >> 16,

0 commit comments

Comments
 (0)