Files
vfio-native/patches/qemu/07-edid.patch

63 lines
2.0 KiB
Diff

Subject: [PATCH] edid: (display identity)
Targets VMAware check: (display identity)
Generated EDID vendor and model. Note VMAware does not read EDID - this is
carried for other detectors, not for the score.
Applies to QEMU v11.1.1. Apply from the source root with:
patch -p1 < 07-edid.patch
---
diff --git a/hw/display/edid-generate.c b/hw/display/edid-generate.c
index 2cb8196..45003e8 100644
--- a/hw/display/edid-generate.c
+++ b/hw/display/edid-generate.c
@@ -388,22 +388,22 @@ void qemu_edid_generate(uint8_t *edid, size_t size,
uint8_t *did = NULL;
uint32_t width_mm, height_mm;
uint32_t refresh_rate = info->refresh_rate ? info->refresh_rate : 75000;
- uint32_t dpi = 100; /* if no width_mm/height_mm */
+ uint32_t dpi = 93; /* if no width_mm/height_mm */
uint32_t large_screen = 0;
/* =============== set defaults =============== */
if (!info->vendor || strlen(info->vendor) != 3) {
- info->vendor = "RHT";
+ info->vendor = "SAM";
}
if (!info->name) {
- info->name = "QEMU Monitor";
+ info->name = "SyncMaster";
}
if (!info->prefx) {
- info->prefx = 1280;
+ info->prefx = 1920;
}
if (!info->prefy) {
- info->prefy = 800;
+ info->prefy = 1080;
}
if (info->width_mm && info->height_mm) {
width_mm = info->width_mm;
@@ -449,15 +449,15 @@ void qemu_edid_generate(uint8_t *edid, size_t size,
uint16_t vendor_id = ((((info->vendor[0] - '@') & 0x1f) << 10) |
(((info->vendor[1] - '@') & 0x1f) << 5) |
(((info->vendor[2] - '@') & 0x1f) << 0));
- uint16_t model_nr = 0x1234;
+ uint16_t model_nr = 0x0dca;
uint32_t serial_nr = info->serial ? atoi(info->serial) : 0;
stw_be_p(edid + 8, vendor_id);
stw_le_p(edid + 10, model_nr);
stl_le_p(edid + 12, serial_nr);
/* manufacture week and year */
- edid[16] = 42;
- edid[17] = 2014 - 1990;
+ edid[16] = 17;
+ edid[17] = 2018 - 1990;
/* edid version */
edid[18] = 1;