From f6238693bdf079dedb9c32202a91c83fbecefb0b Mon Sep 17 00:00:00 2001 From: Stew Benedict Date: Wed, 23 Feb 2005 00:05:11 +0000 Subject: Support for XBox. Original code up the machine. --- tools/ddcprobe/ddcxinfos.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'tools/ddcprobe/ddcxinfos.c') diff --git a/tools/ddcprobe/ddcxinfos.c b/tools/ddcprobe/ddcxinfos.c index e595d549c..44d9fdc48 100644 --- a/tools/ddcprobe/ddcxinfos.c +++ b/tools/ddcprobe/ddcxinfos.c @@ -9,6 +9,7 @@ #include #include "vbe.h" #include "vesamode.h" +#include "xbox.h" #ifdef HAVE_VBE #include "int10/vbios.h" @@ -43,13 +44,17 @@ int main(void) /* Determine PCI configuration type */ pci_config_type = 1; - /* Initialize Int10 */ - if (InitInt10(pci_config_type)) return 1; - /* Get VBE information */ - if (vbe_get_vbe_info(vbe_info) == 0) { - FreeInt10(); - return 1; + if (box_is_xbox() == 1) { + if (get_fb_info(vbe_info) == 0) + return 1; + } else { + /* Initialize Int10 */ + if (InitInt10(pci_config_type)) return 1; + if (vbe_get_vbe_info(vbe_info) == 0) { + FreeInt10(); + return 1; + } } printf("%dKB of video ram\n", vbe_info->memory_size / 1024); @@ -64,6 +69,9 @@ int main(void) known_vesa_modes[i].y ); #endif + /* optimal on a TV, just return canned values */ + if (box_is_xbox() == 1) + printf("%d %d %d\n", 16777216, 640, 480); printf("\n"); /* Get EDID information */ -- cgit v1.2.1