diff options
author | Andres Salomon <dilinger@queued.net> | 2008-11-26 01:39:28 -0500 |
---|---|---|
committer | Jordan Crouse <jordan@cosmicpenguin.net> | 2008-11-26 09:08:53 -0700 |
commit | 8080f7a01cf62a13c5a32013668b2796c23d97a4 (patch) | |
tree | e8753aa7518c07a316b9d803c860ccd52e78f7b7 /src/geode_dcon.c | |
parent | f57f2bd7161d4a7c2ededfc43a7709fb06213b99 (diff) |
xf86-video-geode: DCON: set the default (physical) screen size if we detect a DCON
We can be assured that a DCON device has an OLPC panel that's 152x114 mm.
This adds fields to GeodeRec to allow other panels to potentially
override physical width/height fields, and also allows xorg.conf to
override the values.
Signed-off-by: Andres Salomon <dilinger@debian.org>
Diffstat (limited to 'src/geode_dcon.c')
-rw-r--r-- | src/geode_dcon.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/geode_dcon.c b/src/geode_dcon.c index 0baa178..13e5fd2 100644 --- a/src/geode_dcon.c +++ b/src/geode_dcon.c @@ -92,6 +92,9 @@ dcon_init(ScrnInfoPtr pScrni) { GeodeRec *pGeode = GEODEPTR(pScrni); + pGeode->mm_width = 0; + pGeode->mm_height = 0; + if (!dcon_present()) { xf86DrvMsg(pScrni->scrnIndex, X_DEFAULT, "No DCON is present\n"); return FALSE; @@ -115,6 +118,9 @@ dcon_init(ScrnInfoPtr pScrni) pGeode->panelMode->VTotal = 912; pGeode->panelMode->Flags = V_NHSYNC | V_NVSYNC; + pGeode->mm_width = 152; + pGeode->mm_height = 114; + xf86SetModeDefaultName(pGeode->panelMode); /* TODO: Print board revision once sysfs exports it. */ |