edid: Use edid_mode struct to reduce redundancy
This replaces various timing mode parameters parameters with an edid_mode struct within the edid struct. Notes for cherry-picking: Reverted ToT's changes to src/soc/nvidia/tegra132/dp.c. Most of that file wasn't implemented in the firmware-veyron branch, so pretty much the whole file showed up as a diff. For src/soc/rockchip/rk3288/hdmi.c, there were some simple conflicts caused by the writel/write32 transition. BUG=none BRANCH=firmware-veyron TEST=built and booted on Mickey, saw display come up, also compiled for link,falco,peppy,rambi,nyan_big,rush,smaug Change-Id: I1bfba5b06a708d042286db56b37f67302f61fff6 Signed-off-by: David Hendricks <dhendrix@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/289964 Reviewed-by: Yakir Yang <ykk@rock-chips.com> Reviewed-by: Julius Werner <jwerner@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/293605
This commit is contained in:
parent
d54ef1ca82
commit
b427dc2434
9 changed files with 120 additions and 105 deletions
|
|
@ -20,6 +20,31 @@
|
|||
#ifndef EDID_H
|
||||
#define EDID_H
|
||||
|
||||
enum edid_modes {
|
||||
EDID_MODE_AUTO = 0,
|
||||
EDID_MODE_640x480_60Hz,
|
||||
};
|
||||
|
||||
struct edid_mode {
|
||||
const char *name;
|
||||
unsigned int pixel_clock;
|
||||
unsigned int refresh;
|
||||
unsigned int ha;
|
||||
unsigned int hbl;
|
||||
unsigned int hso;
|
||||
unsigned int hspw;
|
||||
unsigned int hborder;
|
||||
unsigned int va;
|
||||
unsigned int vbl;
|
||||
unsigned int vso;
|
||||
unsigned int vspw;
|
||||
unsigned int vborder;
|
||||
unsigned char phsync;
|
||||
unsigned char pvsync;
|
||||
unsigned int x_mm;
|
||||
unsigned int y_mm;
|
||||
};
|
||||
|
||||
/* structure for communicating EDID information from a raw EDID block to
|
||||
* higher level functions.
|
||||
* The size of the data types is not critical, so we leave them as
|
||||
|
|
@ -49,20 +74,8 @@ struct edid {
|
|||
*/
|
||||
unsigned int panel_bits_per_pixel;
|
||||
/* used to compute timing for graphics chips. */
|
||||
unsigned char phsync;
|
||||
unsigned char pvsync;
|
||||
unsigned int pixel_clock;
|
||||
struct edid_mode mode;
|
||||
unsigned int link_clock;
|
||||
unsigned int ha;
|
||||
unsigned int hbl;
|
||||
unsigned int hso;
|
||||
unsigned int hspw;
|
||||
unsigned int hborder;
|
||||
unsigned int va;
|
||||
unsigned int vbl;
|
||||
unsigned int vso;
|
||||
unsigned int vspw;
|
||||
unsigned int vborder;
|
||||
/* 3 variables needed for coreboot framebuffer.
|
||||
* In most cases, they are the same as the ha
|
||||
* and va variables, but not always, as in the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue