tests/intel/xe_sriov_flr: Add flr-twice subtest
[drm/igt-gpu-tools.git] / lib / monitor_edids / monitor_edids_helper.h
blob05679f0897f3d0618d656cc071b565b48d31da28
1 /* SPDX-License-Identifier: MIT */
2 /*
3 * A helper library for parsing and making use of real EDID data from monitors
4 * and make them compatible with IGT and Chamelium.
6 * Copyright 2022 Google LLC.
8 * Authors: Mark Yacoub <markyacoub@chromium.org>
9 */
11 #ifndef TESTS_CHAMELIUM_MONITOR_EDIDS_MONITOR_EDIDS_HELPER_H_
12 #define TESTS_CHAMELIUM_MONITOR_EDIDS_MONITOR_EDIDS_HELPER_H_
14 #include <stdint.h>
16 #include "igt_chamelium.h"
18 /* Max Length can be increased as needed, when new EDIDs are added. */
19 #define EDID_NAME_MAX_LEN 28
20 #define EDID_HEX_STR_MAX_LEN 512
22 typedef struct monitor_edid {
23 char name[EDID_NAME_MAX_LEN + 1];
24 char edid[EDID_HEX_STR_MAX_LEN + 1];
25 } monitor_edid;
27 const char *monitor_edid_get_name(const monitor_edid *edid);
28 struct chamelium_edid *
29 get_chameleon_edid_from_monitor_edid(struct chamelium *chamelium,
30 const monitor_edid *edid);
31 void free_chamelium_edid_from_monitor_edid(struct chamelium_edid *edid);
33 #endif /* TESTS_CHAMELIUM_MONITOR_EDIDS_MONITOR_EDIDS_HELPER_H_ */