Removed distro specific stuff.
Fixed FreeType module to build with FreeType versions older than 2.1.7. Fixed typo. Added vtSema to protect call of driver DPMS function. removed unneeded variable Modified RandR driver hook to reduce the number of function calls to one. Function is sufficiently generic to be extended in the future.
This commit is contained in:
parent
b759da83ae
commit
e6b9cc79c2
|
@ -749,8 +749,8 @@ configureDDCMonitorSection (int screennum)
|
|||
ptr->mon_vrefresh[ptr->mon_n_hsync].lo =
|
||||
ConfiguredMonitor->det_mon[i].section.ranges.min_v;
|
||||
ptr->mon_vrefresh[ptr->mon_n_hsync].hi =
|
||||
ConfiguredMonitor->det_mon[i].section.ranges.max_v;
|
||||
ptr->mon_n_hsync++;
|
||||
ConfiguredMonitor->det_mon[i].section.ranges.max_v;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -118,7 +118,13 @@ DPMSClose(int i, ScreenPtr pScreen)
|
|||
|
||||
pScreen->CloseScreen = pDPMS->CloseScreen;
|
||||
|
||||
if (xf86Screens[i]->DPMSSet) {
|
||||
/*
|
||||
* Turn on DPMS when shutting down. If this function can be used
|
||||
* depends on the order the driver wraps things. If this is called
|
||||
* after the driver has shut down everything the driver will have
|
||||
* to deal with this internally.
|
||||
*/
|
||||
if (xf86Screens[i]->vtSema && xf86Screens[i]->DPMSSet) {
|
||||
xf86Screens[i]->DPMSSet(xf86Screens[i],DPMSModeOn,0);
|
||||
}
|
||||
|
||||
|
|
|
@ -873,7 +873,6 @@ Bool
|
|||
xf86SetDefaultVisual(ScrnInfoPtr scrp, int visual)
|
||||
{
|
||||
MessageType visualFrom = X_DEFAULT;
|
||||
Bool bad = FALSE;
|
||||
|
||||
if (defaultColorVisualClass >= 0) {
|
||||
scrp->defaultVisual = defaultColorVisualClass;
|
||||
|
|
|
@ -902,8 +902,7 @@ InitOutput(ScreenInfo *pScreenInfo, int argc, char **argv)
|
|||
xf86Screens[i]->DPMSSet = NULL;
|
||||
xf86Screens[i]->LoadPalette = NULL;
|
||||
xf86Screens[i]->SetOverscan = NULL;
|
||||
xf86Screens[i]->RRGetInfo = NULL;
|
||||
xf86Screens[i]->RRSetConfig = NULL;
|
||||
xf86Screens[i]->RRFunc = NULL;
|
||||
scr_index = AddScreen(xf86Screens[i]->ScreenInit, argc, argv);
|
||||
if (scr_index == i) {
|
||||
/*
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $XdotOrg: xc/programs/Xserver/hw/xfree86/common/xf86RandR.c,v 1.2 2004/04/23 19:20:32 eich Exp $ */
|
||||
/* $XdotOrg: xc/programs/Xserver/hw/xfree86/common/xf86RandR.c,v 1.3 2004/07/30 21:53:09 eich Exp $ */
|
||||
/*
|
||||
* $XFree86: xc/programs/Xserver/hw/xfree86/common/xf86RandR.c,v 1.7tsi Exp $
|
||||
*
|
||||
|
@ -102,9 +102,15 @@ xf86RandRGetInfo (ScreenPtr pScreen, Rotation *rotations)
|
|||
}
|
||||
|
||||
/* If there is driver support for randr, let it set our supported rotations */
|
||||
if(scrp->RRGetInfo)
|
||||
return (*scrp->RRGetInfo)(scrp, rotations);
|
||||
|
||||
if(scrp->RRFunc) {
|
||||
xorgRRRotation RRRotation;
|
||||
|
||||
RRRotation.RRRotations = *rotations;
|
||||
if (!(*scrp->RRFunc)(scrp, RR_GET_INFO, &RRRotation))
|
||||
return FALSE;
|
||||
*rotations = RRRotation.RRRotations;
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
@ -198,9 +204,16 @@ xf86RandRSetConfig (ScreenPtr pScreen,
|
|||
}
|
||||
|
||||
/* Have the driver do its thing. */
|
||||
if (scrp->RRSetConfig &&
|
||||
!(*scrp->RRSetConfig)(scrp, rotation, rate, pSize->width, pSize->height))
|
||||
return FALSE;
|
||||
if (scrp->RRFunc) {
|
||||
xorgRRRotation RRRotation;
|
||||
RRRotation.RRConfig.rotation = rotation;
|
||||
RRRotation.RRConfig.rate = rate;
|
||||
RRRotation.RRConfig.width = pSize->width;
|
||||
RRRotation.RRConfig.height = pSize->height;
|
||||
|
||||
if (!(*scrp->RRFunc)(scrp, RR_SET_CONFIG, &RRRotation))
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (!xf86RandRSetMode (pScreen, mode, useVirtual))
|
||||
return FALSE;
|
||||
|
|
|
@ -476,7 +476,7 @@ typedef struct _confdrirec {
|
|||
/* These values should be adjusted when new fields are added to ScrnInfoRec */
|
||||
#define NUM_RESERVED_INTS 16
|
||||
#define NUM_RESERVED_POINTERS 15
|
||||
#define NUM_RESERVED_FUNCS 10
|
||||
#define NUM_RESERVED_FUNCS 11
|
||||
|
||||
typedef pointer (*funcPointer)(void);
|
||||
|
||||
|
@ -737,6 +737,24 @@ typedef struct {
|
|||
PixmapPtr pPix;
|
||||
} DGADeviceRec, *DGADevicePtr;
|
||||
|
||||
typedef enum {
|
||||
RR_GET_INFO,
|
||||
RR_SET_CONFIG
|
||||
} xorgRRFuncFlags;
|
||||
|
||||
typedef struct {
|
||||
int rotation;
|
||||
int rate;
|
||||
int width;
|
||||
int height;
|
||||
} xorgRRConfig;
|
||||
|
||||
typedef union {
|
||||
short RRRotations;
|
||||
xorgRRConfig RRConfig;
|
||||
} xorgRRRotation, *xorgRRRotationPtr;
|
||||
|
||||
|
||||
/*
|
||||
* Flags for driver Probe() functions.
|
||||
*/
|
||||
|
@ -767,8 +785,9 @@ typedef int xf86HandleMessageProc (int, const char*, const char*, char**);
|
|||
typedef void xf86DPMSSetProc (ScrnInfoPtr, int, int);
|
||||
typedef void xf86LoadPaletteProc (ScrnInfoPtr, int, int *, LOCO *, VisualPtr);
|
||||
typedef void xf86SetOverscanProc (ScrnInfoPtr, int);
|
||||
typedef Bool xf86RRGetInfoProc (ScrnInfoPtr, unsigned short *);
|
||||
typedef Bool xf86RRSetConfigProc (ScrnInfoPtr, int, int, int, int);
|
||||
typedef Bool xorgRRFuncProc (ScrnInfoPtr, xorgRRFuncFlags,
|
||||
xorgRRRotationPtr);
|
||||
|
||||
|
||||
/*
|
||||
* ScrnInfoRec
|
||||
|
@ -923,8 +942,7 @@ typedef struct _ScrnInfoRec {
|
|||
xf86DPMSSetProc *DPMSSet;
|
||||
xf86LoadPaletteProc *LoadPalette;
|
||||
xf86SetOverscanProc *SetOverscan;
|
||||
xf86RRGetInfoProc *RRGetInfo;
|
||||
xf86RRSetConfigProc *RRSetConfig;
|
||||
xorgRRFuncProc *RRFunc;
|
||||
|
||||
/*
|
||||
* This can be used when the minor ABI version is incremented.
|
||||
|
|
Loading…
Reference in New Issue