From 9d65abab153cdf3ab2b7e3e2843d573b22ea6769 Mon Sep 17 00:00:00 2001 From: Aaron Plattner Date: Wed, 14 Mar 2007 21:16:04 -0700 Subject: Fix VGA output with vesafb on nv4x and G7x GPUs. SuSE bug #160812. --- src/nv_hw.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/nv_hw.c') diff --git a/src/nv_hw.c b/src/nv_hw.c index ab703f1..6232cd6 100644 --- a/src/nv_hw.c +++ b/src/nv_hw.c @@ -878,6 +878,10 @@ void NVCalcStateExt ( state->general = bpp == 16 ? 0x00101100 : 0x00100100; state->repaint1 = hDisplaySize < 1280 ? 0x04 : 0x00; break; + case NV_ARCH_40: + if(!pNv->FlatPanel) + state->control = pNv->PRAMDAC0[0x0580/4] & 0xeffffeff; + /* fallthrough */ case NV_ARCH_10: case NV_ARCH_20: case NV_ARCH_30: @@ -1475,6 +1479,10 @@ void NVLoadStateExt ( VGA_WR08(pNv->PCIO, 0x03D5, state->interlace); if(!pNv->FlatPanel) { + if(pNv->Architecture >= NV_ARCH_40) { + pNv->PRAMDAC0[0x0580/4] = state->control; + } + pNv->PRAMDAC0[0x050C/4] = state->pllsel; pNv->PRAMDAC0[0x0508/4] = state->vpll; if(pNv->twoHeads) @@ -1541,6 +1549,10 @@ void NVUnloadStateExt state->scale = pNv->PRAMDAC[0x0848/4]; state->config = pNv->PFB[0x0200/4]; + if(pNv->Architecture >= NV_ARCH_40 && !pNv->FlatPanel) { + state->control = pNv->PRAMDAC0[0x0580/4]; + } + if(pNv->Architecture >= NV_ARCH_10) { if(pNv->twoHeads) { state->head = pNv->PCRTC0[0x0860/4]; -- cgit v1.2.3