xserver: Branch 'master' - 2 commits
Keith Packard
keithp at kemper.freedesktop.org
Fri Jan 30 14:22:51 PST 2009
hw/xfree86/modes/xf86Crtc.c | 29 ++++++++++++++++++-----------
hw/xfree86/modes/xf86RandR12.c | 11 -----------
2 files changed, 18 insertions(+), 22 deletions(-)
New commits:
commit ea309e47457156b60aadbf113f04e5b6851029c8
Author: Keith Packard <keithp at keithp.com>
Date: Fri Jan 30 14:19:41 2009 -0800
Make crtc_notify wrap/unwrap code do nothing unless mode code is inuse
Drivers not using the new hw/xfree86/modes code would crash in DRI due to
that code trying to monitor CRTC changes.
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index cb13deb..217e01c 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -3117,22 +3117,29 @@ xf86_crtc_clip_video_helper(ScrnInfoPtr pScrn,
xf86_crtc_notify_proc_ptr
xf86_wrap_crtc_notify (ScreenPtr screen, xf86_crtc_notify_proc_ptr new)
{
- ScrnInfoPtr scrn = xf86Screens[screen->myNum];
- xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
- xf86_crtc_notify_proc_ptr old;
-
- old = config->xf86_crtc_notify;
- config->xf86_crtc_notify = new;
- return old;
+ if (xf86CrtcConfigPrivateIndex != -1)
+ {
+ ScrnInfoPtr scrn = xf86Screens[screen->myNum];
+ xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
+ xf86_crtc_notify_proc_ptr old;
+
+ old = config->xf86_crtc_notify;
+ config->xf86_crtc_notify = new;
+ return old;
+ }
+ return NULL;
}
void
xf86_unwrap_crtc_notify(ScreenPtr screen, xf86_crtc_notify_proc_ptr old)
{
- ScrnInfoPtr scrn = xf86Screens[screen->myNum];
- xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
-
- config->xf86_crtc_notify = old;
+ if (xf86CrtcConfigPrivateIndex != -1)
+ {
+ ScrnInfoPtr scrn = xf86Screens[screen->myNum];
+ xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
+
+ config->xf86_crtc_notify = old;
+ }
}
void
commit fff00df94d7ebd18a8e24537ec96073717375a3f
Author: Keith Packard <keithp at keithp.com>
Date: Fri Jan 30 14:16:12 2009 -0800
Ignore EDID-supplied monitor physical sizes for core screen size
We report the EDID values in RandR, and we let people configure whatever
they like for the screen in xorg.conf. Reporting the EDID values in the core
means applications get inconsistent font sizes in the default configuration.
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
index 13f6310..83a4f4f 100644
--- a/hw/xfree86/modes/xf86RandR12.c
+++ b/hw/xfree86/modes/xf86RandR12.c
@@ -600,17 +600,6 @@ xf86RandR12CreateScreenResources (ScreenPtr pScreen)
mmWidth = output->conf_monitor->mon_width;
mmHeight = output->conf_monitor->mon_height;
}
- else if (crtc && crtc->mode.HDisplay &&
- output->mm_width && output->mm_height)
- {
- /*
- * If the output has a mode and a declared size, use that
- * to scale the screen size
- */
- DisplayModePtr mode = &crtc->mode;
- mmWidth = output->mm_width * width / mode->HDisplay;
- mmHeight = output->mm_height * height / mode->VDisplay;
- }
else
{
/*
More information about the xorg-commit
mailing list