diff options
author | Dave Airlie <airlied@linux.ie> | 2007-03-11 15:18:55 +1100 |
---|---|---|
committer | Dave Airlie <airlied@linux.ie> | 2007-03-11 15:18:55 +1100 |
commit | 7d5e1aec51ec91a7b6d38a965902911181e7f2cd (patch) | |
tree | fca02cffcfe09f618390455b641c968846c30bcf | |
parent | e2343bdf6838880d4a8235c7af390e7b23e39914 (diff) | |
download | xorg-driver-xf86-video-nouveau-7d5e1aec51ec91a7b6d38a965902911181e7f2cd.tar.gz |
fixup DAC mapping
-rw-r--r-- | src/nv_output.c | 12 | ||||
-rw-r--r-- | src/nvreg.h | 2 |
2 files changed, 8 insertions, 6 deletions
diff --git a/src/nv_output.c b/src/nv_output.c index 150f541..ffa3e54 100644 --- a/src/nv_output.c +++ b/src/nv_output.c @@ -396,13 +396,13 @@ nv_output_mode_set_regs(xf86OutputPtr output, DisplayModePtr mode) if (is_fp == TRUE) regp->output = 0x0; - else if (nv_crtc->crtc == 0 && nv_output->ramdac == 1 && (two_crt == TRUE)) + else + regp->output = NV_RAMDAC_OUTPUT_DAC_ENABLE; - regp->output = 0x101; - else - regp->output = 0x1; + if (nv_crtc->crtc == 1 && (two_crt == TRUE)) + regp->output |= NV_RAMDAC_OUTPUT_SELECT_CRTC2; - if (nv_crtc->crtc == 1 && nv_output->ramdac == 0 && two_mon) { + if (nv_crtc->crtc == 1 && two_mon) { state->vpll2 = state->pll; state->vpll2B = state->pllB; state->pllsel |= (1<<29) | (1<<11); @@ -633,7 +633,7 @@ void NvSetupOutputs(ScrnInfoPtr pScrn) nv_output->ramdac = i; NV_I2CInit(pScrn, &nv_output->pDDCBus, i ? 0x36 : 0x3e, ddc_name[i]); - output->possible_crtcs = i ? 1 : crtc_mask; + output->possible_crtcs = crtc_mask; } if (pNv->Mobile) { diff --git a/src/nvreg.h b/src/nvreg.h index 2c978ec..e79e521 100644 --- a/src/nvreg.h +++ b/src/nvreg.h @@ -170,6 +170,8 @@ #define NV_RAMDAC_SEL_CLK 0x524 #define NV_RAMDAC_DITHER_NV11 0x528 #define NV_RAMDAC_OUTPUT 0x52c +#define NV_RAMDAC_OUTPUT_DAC_ENABLE (1<<0) +#define NV_RAMDAC_OUTPUT_SELECT_CRTC2 (1<<8) #define NV_RAMDAC_NVPLL_B 0x570 #define NV_RAMDAC_MPLL_B 0x574 |