Support new CRTC/Output prepare/commit hooks.
New hooks replace explicit invocation of DPMS functions to manage mode setting sequencing.
This commit is contained in:
parent
b27fa2c257
commit
bc20b54c34
|
|
@ -341,7 +341,9 @@ static const xf86OutputFuncsRec i830_crt_output_funcs = {
|
|||
.restore = i830_crt_restore,
|
||||
.mode_valid = i830_crt_mode_valid,
|
||||
.mode_fixup = i830_crt_mode_fixup,
|
||||
.prepare = i830_output_prepare,
|
||||
.mode_set = i830_crt_mode_set,
|
||||
.commit = i830_output_commit,
|
||||
.detect = i830_crt_detect,
|
||||
.get_modes = i830_ddc_get_modes,
|
||||
.destroy = i830_crt_destroy
|
||||
|
|
|
|||
|
|
@ -613,6 +613,30 @@ i830_crtc_unlock (xf86CrtcPtr crtc)
|
|||
#endif
|
||||
}
|
||||
|
||||
static void
|
||||
i830_crtc_prepare (xf86CrtcPtr crtc)
|
||||
{
|
||||
crtc->funcs->dpms (crtc, DPMSModeOff);
|
||||
}
|
||||
|
||||
static void
|
||||
i830_crtc_commit (xf86CrtcPtr crtc)
|
||||
{
|
||||
crtc->funcs->dpms (crtc, DPMSModeOn);
|
||||
}
|
||||
|
||||
void
|
||||
i830_output_prepare (xf86OutputPtr output)
|
||||
{
|
||||
output->funcs->dpms (output, DPMSModeOff);
|
||||
}
|
||||
|
||||
void
|
||||
i830_output_commit (xf86OutputPtr output)
|
||||
{
|
||||
output->funcs->dpms (output, DPMSModeOn);
|
||||
}
|
||||
|
||||
static Bool
|
||||
i830_crtc_mode_fixup(xf86CrtcPtr crtc, DisplayModePtr mode,
|
||||
DisplayModePtr adjusted_mode)
|
||||
|
|
@ -1377,7 +1401,9 @@ static const xf86CrtcFuncsRec i830_crtc_funcs = {
|
|||
.lock = i830_crtc_lock,
|
||||
.unlock = i830_crtc_unlock,
|
||||
.mode_fixup = i830_crtc_mode_fixup,
|
||||
.prepare = i830_crtc_prepare,
|
||||
.mode_set = i830_crtc_mode_set,
|
||||
.commit = i830_crtc_commit,
|
||||
.gamma_set = i830_crtc_gamma_set,
|
||||
.shadow_create = i830_crtc_shadow_create,
|
||||
.shadow_allocate = i830_crtc_shadow_allocate,
|
||||
|
|
|
|||
|
|
@ -40,3 +40,6 @@ void i830ReleaseLoadDetectPipe(xf86OutputPtr output);
|
|||
void i830_crtc_init(ScrnInfoPtr pScrn, int pipe);
|
||||
void i830_crtc_load_lut(xf86CrtcPtr crtc);
|
||||
DisplayModePtr i830_crtc_mode_get(ScrnInfoPtr pScrn, xf86CrtcPtr crtc);
|
||||
void i830_output_prepare (xf86OutputPtr output);
|
||||
void i830_output_commit (xf86OutputPtr output);
|
||||
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|||
|
||||
#include "xf86.h"
|
||||
#include "i830.h"
|
||||
#include "i830_display.h"
|
||||
#include "i810_reg.h"
|
||||
|
||||
#include "sil164/sil164.h"
|
||||
|
|
@ -226,7 +227,9 @@ static const xf86OutputFuncsRec i830_dvo_output_funcs = {
|
|||
.restore = i830_dvo_restore,
|
||||
.mode_valid = i830_dvo_mode_valid,
|
||||
.mode_fixup = i830_dvo_mode_fixup,
|
||||
.prepare = i830_output_prepare,
|
||||
.mode_set = i830_dvo_mode_set,
|
||||
.commit = i830_output_commit,
|
||||
.detect = i830_dvo_detect,
|
||||
.get_modes = i830_ddc_get_modes,
|
||||
.destroy = i830_dvo_destroy
|
||||
|
|
|
|||
|
|
@ -392,7 +392,9 @@ static const xf86OutputFuncsRec i830_lvds_output_funcs = {
|
|||
.restore = i830_lvds_restore,
|
||||
.mode_valid = i830_lvds_mode_valid,
|
||||
.mode_fixup = i830_lvds_mode_fixup,
|
||||
.prepare = i830_output_prepare,
|
||||
.mode_set = i830_lvds_mode_set,
|
||||
.commit = i830_output_commit,
|
||||
.detect = i830_lvds_detect,
|
||||
.get_modes = i830_lvds_get_modes,
|
||||
#ifdef RANDR_12_INTERFACE
|
||||
|
|
|
|||
|
|
@ -1060,7 +1060,9 @@ static const xf86OutputFuncsRec i830_sdvo_output_funcs = {
|
|||
.restore = i830_sdvo_restore,
|
||||
.mode_valid = i830_sdvo_mode_valid,
|
||||
.mode_fixup = i830_sdvo_mode_fixup,
|
||||
.prepare = i830_output_prepare,
|
||||
.mode_set = i830_sdvo_mode_set,
|
||||
.commit = i830_output_commit,
|
||||
.detect = i830_sdvo_detect,
|
||||
.get_modes = i830_sdvo_get_modes,
|
||||
.destroy = i830_sdvo_destroy
|
||||
|
|
|
|||
|
|
@ -1406,7 +1406,9 @@ static const xf86OutputFuncsRec i830_tv_output_funcs = {
|
|||
.restore = i830_tv_restore,
|
||||
.mode_valid = i830_tv_mode_valid,
|
||||
.mode_fixup = i830_tv_mode_fixup,
|
||||
.prepare = i830_output_prepare,
|
||||
.mode_set = i830_tv_mode_set,
|
||||
.commit = i830_output_commit,
|
||||
.detect = i830_tv_detect,
|
||||
.get_modes = i830_tv_get_modes,
|
||||
.destroy = i830_tv_destroy
|
||||
|
|
|
|||
Loading…
Reference in New Issue