edid: add function to manually specify mode
This patch will let you to choose a favourite mode to display, while not just taking the edid detail timing. But not all modes are able to set, only modes that are in established or standard timing, and we only support a few common common resolutions for now. BUG=chrome-os-partner:42946 BRANCH=firmware-veyron TEST=tested dev mode on Mickey at 640x480@60Hz Change-Id: Iaa8c9a6fad106ee792f7cd1a0ac77e3dcbadf481 Signed-off-by: Yakir Yang <ykk@rock-chips.com> Signed-off-by: David Hendricks <dhendrix@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/293606
This commit is contained in:
parent
b427dc2434
commit
3df64a8a58
2 changed files with 68 additions and 2 deletions
|
|
@ -21,8 +21,13 @@
|
|||
#define EDID_H
|
||||
|
||||
enum edid_modes {
|
||||
EDID_MODE_AUTO = 0,
|
||||
EDID_MODE_640x480_60Hz,
|
||||
EDID_MODE_720x480_60Hz,
|
||||
EDID_MODE_1280x720_60Hz,
|
||||
EDID_MODE_1920x1080_60Hz,
|
||||
NUM_KNOWN_MODES,
|
||||
|
||||
EDID_MODE_AUTO
|
||||
};
|
||||
|
||||
struct edid_mode {
|
||||
|
|
@ -75,6 +80,7 @@ struct edid {
|
|||
unsigned int panel_bits_per_pixel;
|
||||
/* used to compute timing for graphics chips. */
|
||||
struct edid_mode mode;
|
||||
u8 mode_is_supported[NUM_KNOWN_MODES];
|
||||
unsigned int link_clock;
|
||||
/* 3 variables needed for coreboot framebuffer.
|
||||
* In most cases, they are the same as the ha
|
||||
|
|
@ -89,5 +95,6 @@ struct edid {
|
|||
/* Defined in src/lib/edid.c */
|
||||
int decode_edid(unsigned char *edid, int size, struct edid *out);
|
||||
void set_vbe_mode_info_valid(struct edid *edid, uintptr_t fb_addr);
|
||||
int set_display_mode(struct edid *edid, enum edid_modes mode);
|
||||
|
||||
#endif /* EDID_H */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue