virtio-gpu: Respect UI refresh rate for EDID
Signed-off-by: Akihiko Odaki <akihiko.odaki@gmail.com> Message-Id: <20220226115516.59830-4-akihiko.odaki@gmail.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
aeffd071ed
commit
b95b56311a
|
@ -79,6 +79,7 @@ static void virtio_gpu_ui_info(void *opaque, uint32_t idx, QemuUIInfo *info)
|
||||||
|
|
||||||
g->req_state[idx].x = info->xoff;
|
g->req_state[idx].x = info->xoff;
|
||||||
g->req_state[idx].y = info->yoff;
|
g->req_state[idx].y = info->yoff;
|
||||||
|
g->req_state[idx].refresh_rate = info->refresh_rate;
|
||||||
g->req_state[idx].width = info->width;
|
g->req_state[idx].width = info->width;
|
||||||
g->req_state[idx].height = info->height;
|
g->req_state[idx].height = info->height;
|
||||||
g->req_state[idx].width_mm = info->width_mm;
|
g->req_state[idx].width_mm = info->width_mm;
|
||||||
|
|
|
@ -217,6 +217,7 @@ virtio_gpu_generate_edid(VirtIOGPU *g, int scanout,
|
||||||
.height_mm = b->req_state[scanout].height_mm,
|
.height_mm = b->req_state[scanout].height_mm,
|
||||||
.prefx = b->req_state[scanout].width,
|
.prefx = b->req_state[scanout].width,
|
||||||
.prefy = b->req_state[scanout].height,
|
.prefy = b->req_state[scanout].height,
|
||||||
|
.refresh_rate = b->req_state[scanout].refresh_rate,
|
||||||
};
|
};
|
||||||
|
|
||||||
edid->size = cpu_to_le32(sizeof(edid->edid));
|
edid->size = cpu_to_le32(sizeof(edid->edid));
|
||||||
|
|
|
@ -80,6 +80,7 @@ struct virtio_gpu_scanout {
|
||||||
struct virtio_gpu_requested_state {
|
struct virtio_gpu_requested_state {
|
||||||
uint16_t width_mm, height_mm;
|
uint16_t width_mm, height_mm;
|
||||||
uint32_t width, height;
|
uint32_t width, height;
|
||||||
|
uint32_t refresh_rate;
|
||||||
int x, y;
|
int x, y;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue