~ubuntu-branches/ubuntu/jaunty/xserver-xorg-video-nv/jaunty

« back to all changes in this revision

Viewing changes to src/g80_driver.c

  • Committer: Bazaar Package Importer
  • Author(s): Stefan Potyra
  • Date: 2008-06-15 15:03:42 UTC
  • mfrom: (1.1.13 upstream)
  • Revision ID: james.westby@ubuntu.com-20080615150342-ke266hqt4p7m8qyd
Tags: 1:2.1.9-1ubuntu1
* Merge from unstable (LP: #240034), remaining changes:
  + debian/patches/100_fedora-panel-fix.patch from Timo Aaltonen:
    Don't discard EDID blocks just because their input type bit
    disagrees with the hardware connection sensing; this usually
    just means the block is lying. (cf. LP #188549).
  + debian/control: update Maintainer field as per spec.

Show diffs side-by-side

added added

removed removed

Lines of Context:
106
106
    OPTION_NOACCEL,
107
107
    OPTION_ACCEL_METHOD,
108
108
    OPTION_FP_DITHER,
 
109
    OPTION_ALLOW_DUAL_LINK,
109
110
} G80Opts;
110
111
 
111
112
static const OptionInfoRec G80Options[] = {
112
 
    { OPTION_HW_CURSOR,         "HWCursor",     OPTV_BOOLEAN,   {0}, FALSE },
113
 
    { OPTION_NOACCEL,           "NoAccel",      OPTV_BOOLEAN,   {0}, FALSE },
114
 
    { OPTION_ACCEL_METHOD,      "AccelMethod",  OPTV_STRING,    {0}, FALSE },
115
 
    { OPTION_FP_DITHER,         "FPDither",     OPTV_BOOLEAN,   {0}, FALSE },
116
 
    { -1,                       NULL,           OPTV_NONE,      {0}, FALSE }
 
113
    { OPTION_HW_CURSOR,         "HWCursor",             OPTV_BOOLEAN,   {0}, FALSE },
 
114
    { OPTION_NOACCEL,           "NoAccel",              OPTV_BOOLEAN,   {0}, FALSE },
 
115
    { OPTION_ACCEL_METHOD,      "AccelMethod",          OPTV_STRING,    {0}, FALSE },
 
116
    { OPTION_FP_DITHER,         "FPDither",             OPTV_BOOLEAN,   {0}, FALSE },
 
117
    { OPTION_ALLOW_DUAL_LINK,   "AllowDualLinkModes",   OPTV_BOOLEAN,   {0}, FALSE },
 
118
    { -1,                       NULL,                   OPTV_NONE,      {0}, FALSE }
117
119
};
118
120
 
119
121
static Bool
331
333
    }
332
334
 
333
335
    pNv->Dither = xf86ReturnOptValBool(pNv->Options, OPTION_FP_DITHER, FALSE);
 
336
    pNv->AllowDualLink = xf86ReturnOptValBool(pNv->Options, OPTION_ALLOW_DUAL_LINK, FALSE);
334
337
 
335
338
    /* Set the bits per RGB for 8bpp mode */
336
339
    if(pScrn->depth == 8)
367
370
    }
368
371
 
369
372
    pNv->architecture = pNv->reg[0] >> 20 & 0x1ff;
370
 
    pNv->RamAmountKBytes = pNv->RamAmountKBytes = (pNv->reg[0x0010020C/4] & 0xFFF00000) >> 10;
371
 
    pNv->videoRam = pNv->RamAmountKBytes;
 
373
    tmp = pNv->reg[0x0010020C/4];
 
374
    pNv->videoRam = pNv->RamAmountKBytes = tmp >> 10 | (tmp & 1) << 22;
372
375
 
373
376
    /* Determine the size of BAR1 */
374
377
    /* Some configs have BAR1 < total RAM < 256 MB */