$Id$ This enables resume from suspend level S3 by asking the Radeon chip if it thinks it has no memory. If so, the card is re-POSTed via the int10 interface. Reportedly enables the driver to work for this type of suspend/resume cycle on Dell D600 laptops (Dell D800s as well, if the video BIOS is patched to 4.28.20.31.C1 or later). See Debian Bug #234575. This patch by Emmanuel Thomé and Ole Rohne. diff -ruN xc-old/programs/Xserver/hw/xfree86/drivers/ati/radeon_driver.c xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_driver.c --- xc-old/programs/Xserver/hw/xfree86/drivers/ati/radeon_driver.c 2004-10-20 13:11:12.744159000 +0000 +++ xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_driver.c 2004-10-20 13:12:36.694397296 +0000 @@ -373,6 +373,7 @@ "xf86InitInt10", "xf86FreeInt10", "xf86int10Addr", + "xf86ExecX86int10", NULL }; @@ -7208,9 +7214,22 @@ { ScrnInfoPtr pScrn = xf86Screens[scrnIndex]; RADEONInfoPtr info = RADEONPTR(pScrn); + unsigned char *RADEONMMIO = info->MMIO; RADEONTRACE(("RADEONEnterVT\n")); + if (INREG(RADEON_CONFIG_MEMSIZE) == 0) { /* Softboot V_BIOS */ + xf86Int10InfoPtr pInt; + xf86DrvMsg(pScrn->scrnIndex, X_WARNING, + "zero MEMSIZE, probably at D3cold. Re-POSTing via int10.\n"); + pInt = xf86InitInt10 (info->pEnt->index); + if (pInt) { + pInt->num = 0xe6; + xf86ExecX86int10 (pInt); + xf86FreeInt10 (pInt); + } + } + if (info->FBDev) { unsigned char *RADEONMMIO = info->MMIO; if (!fbdevHWEnterVT(scrnIndex,flags)) return FALSE;