Hello community,
here is the log from the commit of package xorg-x11-driver-video for openSUSE:Factory
checked in at Wed Jun 3 00:57:23 CEST 2009.
--------
--- xorg-x11-driver-video/xorg-x11-driver-video.changes 2009-06-02 10:08:22.000000000 +0200
+++ /mounts/work_src_done/STABLE/xorg-x11-driver-video/xorg-x11-driver-video.changes 2009-06-02 15:43:18.000000000 +0200
@@ -1,0 +2,10 @@
+Tue Jun 2 14:46:19 CEST 2009 - eich@suse.de
+
+- Integrated Intel driver fixes from the Moblin Project
+ * Support for 'rootless' X: option -nb.
+ * BIOS and register dumper for Intel.
+ * Support for fixed LVDS modes.
+ * Free frontbuffer when X exits.
+ * Copy initial framebuffer contents when starting with -br.
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
biosdumper.patch
copy-fb.patch
eeetop_sdvo_lvds.patch
Free-front-buffer-bo-when-X-exit.patch
regdumper.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ xorg-x11-driver-video.spec ++++++
--- /var/tmp/diff_new_pack.K32252/_old 2009-06-03 00:56:53.000000000 +0200
+++ /var/tmp/diff_new_pack.K32252/_new 2009-06-03 00:56:53.000000000 +0200
@@ -22,7 +22,7 @@
BuildRequires: Mesa-devel libdrm-devel pkgconfig xorg-x11-proto-devel xorg-x11-server-sdk
Url: http://xorg.freedesktop.org/
Version: 7.4
-Release: 64
+Release: 65
License: X11/MIT
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Group: System/X11/Servers/XF86_4
@@ -99,6 +99,11 @@
Patch71: xf86-video-fbdev.diff
Patch103: xf86-video-ati-6.7.197-r128-xvideo.patch
Patch104: xf86-video-ati-disable-dri-bug437651-ia64only.diff
+Patch110: regdumper.patch
+Patch111: biosdumper.patch
+Patch112: Free-front-buffer-bo-when-X-exit.patch
+Patch113: copy-fb.patch
+Patch114: eeetop_sdvo_lvds.patch
%description
This package contains X.Org video drivers.
@@ -173,6 +178,12 @@
pushd xf86-video-fbdev-*
%patch71
popd
+pushd xf86-video-intel-* %patch110 -p1
+%patch111 -p1
+%patch112 -p1
+%patch113 -p1
+%patch114 -p1
+popd
%build
for dir in xf86-video-nv-* \
@@ -259,6 +270,9 @@
%dir /var/lib/hardware
%dir /var/lib/hardware/ids
/usr/bin/intel_*
+/usr/bin/bios_dumper
+/usr/bin/bios_reader
+/usr/bin/swf_dumper
%{_libdir}/lib*
%{_libdir}/xorg/modules/
%{_mandir}/man1/*
@@ -268,6 +282,13 @@
/var/lib/hardware/ids/20.%{name}
%changelog
+* Tue Jun 02 2009 eich@suse.de
+- Integrated Intel driver fixes from the Moblin Project
+ * Support for 'rootless' X: option -nb.
+ * BIOS and register dumper for Intel.
+ * Support for fixed LVDS modes.
+ * Free frontbuffer when X exits.
+ * Copy initial framebuffer contents when starting with -br.
* Tue Jun 02 2009 sndirsch@suse.de
- xf86-video-vmware 10.16.6
* various fixes
++++++ biosdumper.patch ++++++
diff --git a/src/bios_reader/Makefile.am b/src/bios_reader/Makefile.am
index 9f1c45a..b58a5e9 100644
--- a/src/bios_reader/Makefile.am
+++ b/src/bios_reader/Makefile.am
@@ -1,7 +1,7 @@
AM_CFLAGS = @WARN_CFLAGS@ @XORG_CFLAGS@ @XMODES_CFLAGS@ @PCIACCESS_CFLAGS@ \
-DREG_DUMPER
-noinst_PROGRAMS = bios_reader $(BIOS_DUMPER) $(SWF_DUMPER)
+bin_PROGRAMS = bios_reader $(BIOS_DUMPER) $(SWF_DUMPER)
if LIBPCIACCESS
BIOS_DUMPER = bios_dumper
++++++ copy-fb.patch ++++++
commit b209cbc72f8d524b2c4c6d0e6e6acf8385e96062
Author: Kristian Høgsberg
Date: Tue Feb 24 10:49:45 2009 -0500
Copy initial framebuffer contents when starting with -br.
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index df0f1a2..35dc24c 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -29,6 +29,8 @@
#include "config.h"
#endif
+#include
+
#include "xorgVersion.h"
#ifdef XF86DRM_MODE
@@ -145,7 +147,7 @@ drmmode_set_mode_major(xf86CrtcPtr crtc, DisplayModePtr mode,
unsigned int pitch = pScrn->displayWidth * pI830->cpp;
if (drmmode->fb_id == 0) {
- ret = drmModeAddFB(drmmode->fd,
+ ret = drmModeAddFB(drmmode->fd,
pScrn->virtualX, pScrn->virtualY,
pScrn->depth, pScrn->bitsPerPixel,
pitch, pI830->front_buffer->bo->handle,
@@ -523,6 +525,13 @@ drmmode_output_dpms(xf86OutputPtr output, int mode)
drmmode_ptr drmmode = drmmode_output->drmmode;
int i;
drmModePropertyPtr props;
+ I830Ptr pI830 = I830PTR(output->scrn);
+
+ /* xf86Crtc.c calls dpms off in set desired modes, so ignore
+ * the request if we're starting up. */
+
+ if (pI830->starting)
+ return;
for (i = 0; i < koutput->count_props; i++) {
props = drmModeGetProperty(drmmode->fd, koutput->props[i]);
@@ -753,6 +762,8 @@ Bool drmmode_pre_init(ScrnInfoPtr pScrn, int fd, int cpp)
xf86InitialConfiguration(pScrn, pI830->can_resize);
+ pScrn->canDoBGNoneRoot = TRUE;
+
return TRUE;
}
@@ -780,4 +791,97 @@ Bool drmmode_is_rotate_pixmap(ScrnInfoPtr pScrn, pointer pPixData, dri_bo **bo)
#endif
}
+static PixmapPtr
+drmmode_create_pixmap_for_fbcon(ScrnInfoPtr pScrn)
+{
+ xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
+ drmmode_crtc_private_ptr drmmode_crtc = xf86_config->crtc[0]->driver_private;
+ ScreenPtr pScreen = screenInfo.screens[pScrn->scrnIndex];
+ drmmode_ptr drmmode = drmmode_crtc->drmmode;
+ I830Ptr pI830 = I830PTR(pScrn);
+ drmModeFBPtr fbcon;
+ struct drm_gem_flink flink;
+ drm_intel_bo *bo;
+ PixmapPtr pixmap = NULL;
+ int i;
+
+ for (i = 0; i < drmmode->mode_res->count_crtcs; i++) {
+ drmmode_crtc = xf86_config->crtc[i]->driver_private;
+ if (drmmode_crtc->mode_crtc->buffer_id == 0)
+ continue;
+ fbcon = drmModeGetFB(drmmode->fd,
+ drmmode_crtc->mode_crtc->buffer_id);
+ if (fbcon != NULL)
+ break;
+ }
+ if (i == drmmode->mode_res->count_crtcs)
+ return NULL;
+
+ flink.handle = fbcon->handle;
+ if (ioctl(drmmode->fd, DRM_IOCTL_GEM_FLINK, &flink) < 0) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Couldn't flink fbcon handle\n");
+ return NULL;
+ }
+
+ bo = drm_intel_bo_gem_create_from_name(pI830->bufmgr,
+ "fbcon", flink.name);
+ if (bo == NULL) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Couldn't allocate bo for fbcon handle\n");
+ return NULL;
+ }
+
+ pixmap = GetScratchPixmapHeader(pScreen,
+ fbcon->width, fbcon->height,
+ fbcon->depth, fbcon->bpp,
+ fbcon->pitch, NULL);
+ if (pixmap == NULL) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Couldn't allocate pixmap fbcon contents\n");
+ return NULL;
+ }
+
+ i830_set_pixmap_bo(pixmap, bo);
+ drm_intel_bo_unreference(bo);
+ drmModeFreeFB(fbcon);
+
+ return pixmap;
+}
+void drmmode_copy_fb(ScrnInfoPtr pScrn)
+{
+ ScreenPtr pScreen = screenInfo.screens[pScrn->scrnIndex];
+ I830Ptr pI830 = I830PTR(pScrn);
+ PixmapPtr src, dst;
+ unsigned int pitch = pScrn->displayWidth * pI830->cpp;
+
+ src = drmmode_create_pixmap_for_fbcon(pScrn);
+ if (src == NULL) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Couldn't create pixmap for fbcon\n");
+ return;
+ }
+
+ /* We dont have a screen Pixmap yet */
+ dst = GetScratchPixmapHeader(pScreen,
+ pScrn->virtualX, pScrn->virtualY,
+ pScrn->depth, pScrn->bitsPerPixel,
+ pitch,
+ NULL);
+ i830_set_pixmap_bo(dst, pI830->front_buffer->bo);
+
+ pI830->uxa_driver->prepare_copy(src, dst, -1, -1, GXcopy, FB_ALLONES);
+
+ pI830->uxa_driver->copy(dst, 0, 0, 0, 0,
+ pScrn->virtualX, pScrn->virtualY);
+
+ pI830->uxa_driver->done_copy(dst);
+
+ I830EmitFlush(pScrn);
+ intel_batch_flush(pScrn, TRUE);
+
+ (*pScreen->DestroyPixmap)(src);
+ (*pScreen->DestroyPixmap)(dst);
+}
+
#endif
diff --git a/src/i830.h b/src/i830.h
index cd9c38a..8651169 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -835,6 +835,7 @@ void I830DRI2CloseScreen(ScreenPtr pScreen);
extern Bool drmmode_pre_init(ScrnInfoPtr pScrn, int fd, int cpp);
extern Bool drmmode_is_rotate_pixmap(ScrnInfoPtr pScrn, pointer pPixData,
dri_bo **bo);
+extern void drmmode_copy_fb(ScrnInfoPtr pScrn);
#endif
extern Bool I830AccelInit(ScreenPtr pScreen);
diff --git a/src/i830_driver.c b/src/i830_driver.c
index f80ca69..0591db9 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -3725,6 +3725,8 @@ I830EnterVT(int scrnIndex, int flags)
/* Clear the framebuffer */
memset(pI830->FbBase + pScrn->fbOffset, 0,
pScrn->virtualY * pScrn->displayWidth * pI830->cpp);
+ } else {
+ drmmode_copy_fb(pScrn);
}
if (!xf86SetDesiredModes (pScrn))
++++++ eeetop_sdvo_lvds.patch ++++++
diff --git a/src/i830.h b/src/i830.h
index f933917..f703c7d 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -605,6 +605,9 @@ typedef struct _I830Rec {
Bool skip_panel_detect;
Bool integrated_lvds; /* LVDS config from driver feature BDB */
+ /* SDVO LVDS mode lists from bios */
+ DisplayModePtr sdvo_lvds_fixed_modes;
+
Bool tv_present; /* TV connector present (from VBIOS) */
/* Driver phase/state information */
diff --git a/src/i830_bios.c b/src/i830_bios.c
index 4f2355d..6672466 100644
--- a/src/i830_bios.c
+++ b/src/i830_bios.c
@@ -73,6 +73,36 @@ find_section(struct bdb_header *bdb, int section_id)
return NULL;
}
+static void
+fill_detail_timing_data(DisplayModePtr fixed_mode, unsigned char *timing_ptr)
+{
+ fixed_mode->HDisplay = _H_ACTIVE(timing_ptr);
+ fixed_mode->VDisplay = _V_ACTIVE(timing_ptr);
+ fixed_mode->HSyncStart = fixed_mode->HDisplay +
+ _H_SYNC_OFF(timing_ptr);
+ fixed_mode->HSyncEnd = fixed_mode->HSyncStart +
+ _H_SYNC_WIDTH(timing_ptr);
+ fixed_mode->HTotal = fixed_mode->HDisplay +
+ _H_BLANK(timing_ptr);
+ fixed_mode->VSyncStart = fixed_mode->VDisplay +
+ _V_SYNC_OFF(timing_ptr);
+ fixed_mode->VSyncEnd = fixed_mode->VSyncStart +
+ _V_SYNC_WIDTH(timing_ptr);
+ fixed_mode->VTotal = fixed_mode->VDisplay +
+ _V_BLANK(timing_ptr);
+ fixed_mode->Clock = _PIXEL_CLOCK(timing_ptr) / 1000;
+ fixed_mode->type = M_T_PREFERRED;
+
+ /* Some VBTs have bogus h/vtotal values */
+ if (fixed_mode->HSyncEnd > fixed_mode->HTotal)
+ fixed_mode->HTotal = fixed_mode->HSyncEnd + 1;
+ if (fixed_mode->VSyncEnd > fixed_mode->VTotal)
+ fixed_mode->VTotal = fixed_mode->VSyncEnd + 1;
+
+ xf86SetModeDefaultName(fixed_mode);
+
+}
+
/**
* Returns the BIOS's fixed panel mode.
*
@@ -82,7 +112,7 @@ find_section(struct bdb_header *bdb, int section_id)
* detecting the panel mode is preferable.
*/
static void
-parse_panel_data(I830Ptr pI830, struct bdb_header *bdb)
+parse_integrated_panel_data(I830Ptr pI830, struct bdb_header *bdb)
{
struct bdb_lvds_options *lvds_options;
struct bdb_lvds_lfp_data_ptrs *lvds_lfp_data_ptrs;
@@ -118,32 +148,45 @@ parse_panel_data(I830Ptr pI830, struct bdb_header *bdb)
/* Since lvds_bdb_2_fp_edid_dtd is just an EDID detailed timing
* block, pull the contents out using EDID macros.
*/
- fixed_mode->HDisplay = _H_ACTIVE(timing_ptr);
- fixed_mode->VDisplay = _V_ACTIVE(timing_ptr);
- fixed_mode->HSyncStart = fixed_mode->HDisplay +
- _H_SYNC_OFF(timing_ptr);
- fixed_mode->HSyncEnd = fixed_mode->HSyncStart +
- _H_SYNC_WIDTH(timing_ptr);
- fixed_mode->HTotal = fixed_mode->HDisplay +
- _H_BLANK(timing_ptr);
- fixed_mode->VSyncStart = fixed_mode->VDisplay +
- _V_SYNC_OFF(timing_ptr);
- fixed_mode->VSyncEnd = fixed_mode->VSyncStart +
- _V_SYNC_WIDTH(timing_ptr);
- fixed_mode->VTotal = fixed_mode->VDisplay +
- _V_BLANK(timing_ptr);
- fixed_mode->Clock = _PIXEL_CLOCK(timing_ptr) / 1000;
- fixed_mode->type = M_T_PREFERRED;
+ fill_detail_timing_data(fixed_mode, timing_ptr);
+ pI830->lvds_fixed_mode = fixed_mode;
+}
- /* Some VBTs have bogus h/vtotal values */
- if (fixed_mode->HSyncEnd > fixed_mode->HTotal)
- fixed_mode->HTotal = fixed_mode->HSyncEnd + 1;
- if (fixed_mode->VSyncEnd > fixed_mode->VTotal)
- fixed_mode->VTotal = fixed_mode->VSyncEnd + 1;
+static void
+parse_sdvo_panel_data(I830Ptr pI830, struct bdb_header *bdb)
+{
+ DisplayModePtr fixed_mode;
+ unsigned char *timing_ptr;
+ short dtd_size, dtd_num, i;
- xf86SetModeDefaultName(fixed_mode);
+ pI830->sdvo_lvds_fixed_modes = NULL;
- pI830->lvds_fixed_mode = fixed_mode;
+ timing_ptr = find_section(bdb, BDB_SDVO_PANEL_DTDS);
+ if (timing_ptr == NULL)
+ return;
+
+ dtd_size = *((short *)(timing_ptr - 2));
+
+ if (dtd_size == 0 || (dtd_num = dtd_size / DET_TIMING_INFO_LEN) == 0)
+ return;
+
+ for (i = 0; i < dtd_num; i = i + 1) {
+ fixed_mode = xnfalloc(sizeof(DisplayModeRec));
+ if (fixed_mode == NULL)
+ break;
+
+ memset(fixed_mode, 0, sizeof(DisplayModeRec));
+ fill_detail_timing_data(fixed_mode, timing_ptr);
+ pI830->sdvo_lvds_fixed_modes =
+ xf86ModesAdd(pI830->sdvo_lvds_fixed_modes, fixed_mode);
+ }
+}
+
+static void
+parse_panel_data(I830Ptr pI830, struct bdb_header *bdb)
+{
+ parse_integrated_panel_data(pI830, bdb);
+ parse_sdvo_panel_data(pI830, bdb);
}
static void
diff --git a/src/i830_quirks.c b/src/i830_quirks.c
index 78292f7..7f87d3f 100644
--- a/src/i830_quirks.c
+++ b/src/i830_quirks.c
@@ -386,6 +386,7 @@ static i830_quirk i830_quirk_list[] = {
/* Asus Eee Box has no LVDS */
{ PCI_CHIP_I945_GME, 0x1043, 0x1252, quirk_ignore_lvds },
+ { PCI_CHIP_I945_GME, 0x1043, 0x82d1, quirk_ignore_lvds },
/* #19239: Mirrus Centrino laptop */
{ PCI_CHIP_I915_GM, 0x1584, 0x9800, quirk_broken_acpi_lid },
diff --git a/src/i830_sdvo.c b/src/i830_sdvo.c
index 29ccd4e..798d93c 100644
--- a/src/i830_sdvo.c
+++ b/src/i830_sdvo.c
@@ -91,6 +91,10 @@ struct i830_sdvo_priv {
* This is set if we treat the device as HDMI, instead of DVI.
*/
Bool is_hdmi;
+ /**
+ * This is set if we detect output of sdvo device as LVDS.
+ */
+ Bool is_lvds;
/**
* Returned SDTV resolutions allowed for the current format, if the
@@ -1536,6 +1540,55 @@ i830_sdvo_check_hdmi_encode (xf86OutputPtr output)
return FALSE;
}
+/* This function will try to fetch native modes from sdvo device*/
+static DisplayModePtr i830_sdvo_lvds_fetch_modes(xf86OutputPtr output)
+{
+ I830OutputPrivatePtr intel_output = output->driver_private;
+ I830Ptr pI830 = I830PTR(output->scrn);
+ DisplayModePtr modes;
+ xf86CrtcPtr crtc;
+ uint32_t sdvox;
+ uint32_t pipe;
+ int output_device;
+
+ /*
+ * Attempt to get the mode list from DDC.
+ * Assume that the preferred modes are
+ * arranged in priority order,
+ */
+ modes = i830_ddc_get_modes(output);
+ if (modes != NULL)
+ goto end;
+
+ if (pI830->sdvo_lvds_fixed_modes) {
+ modes = xf86DuplicateModes(output->scrn, pI830->sdvo_lvds_fixed_modes);
+ goto end;
+ }
+
+ /* If we *still* don't have a mode, try checking if the panel is already
+ * turned on. If so, assume that whatever is currently programmed is the
+ * correct mode.
+ */
+ output_device = ((struct i830_sdvo_priv *)
+ (intel_output->dev_priv))->output_device;
+
+ sdvox = INREG(output_device);
+ pipe = (sdvox & SDVO_PIPE_B_SELECT) ? 1 : 0;
+ crtc = XF86_CRTC_CONFIG_PTR(output->scrn)->crtc[pipe];
+
+ if ((sdvox & SDVO_ENABLE) &&
+ (modes = i830_crtc_mode_get(output->scrn, crtc))) {
+ modes->type |= M_T_PREFERRED;
+ }
+
+end:
+
+ if (modes != NULL)
+ modes->type |= M_T_DRIVER | M_T_PREFERRED;
+
+ return modes;
+}
+
static void i830_sdvo_select_ddc_bus(struct i830_sdvo_priv *dev_priv);
static Bool
@@ -1554,6 +1607,7 @@ i830_sdvo_output_setup (xf86OutputPtr output, uint16_t flag)
/* clear up privates */
dev_priv->is_tv = FALSE;
intel_output->needs_tv_clock = FALSE;
+ dev_priv->is_lvds = FALSE;
if (flag & (SDVO_OUTPUT_TMDS0 | SDVO_OUTPUT_TMDS1))
{
@@ -1594,14 +1648,14 @@ i830_sdvo_output_setup (xf86OutputPtr output, uint16_t flag)
dev_priv->controlled_output = SDVO_OUTPUT_RGB1;
output->subpixel_order = SubPixelHorizontalRGB;
name_prefix="VGA";
- } else if (flag & SDVO_OUTPUT_LVDS0) {
- dev_priv->controlled_output = SDVO_OUTPUT_LVDS0;
- output->subpixel_order = SubPixelHorizontalRGB;
- name_prefix="LVDS";
- } else if (flag & SDVO_OUTPUT_LVDS1) {
- dev_priv->controlled_output = SDVO_OUTPUT_LVDS1;
- output->subpixel_order = SubPixelHorizontalRGB;
- name_prefix="LVDS";
+ } else if (flag & (SDVO_OUTPUT_LVDS0 | SDVO_OUTPUT_LVDS1)) {
+ if (flag & SDVO_OUTPUT_LVDS0)
+ dev_priv->controlled_output = SDVO_OUTPUT_LVDS0;
+ else
+ dev_priv->controlled_output = SDVO_OUTPUT_LVDS1;
+ output->subpixel_order = SubPixelHorizontalRGB;
+ name_prefix="LVDS";
+ dev_priv->is_lvds = TRUE;
} else {
unsigned char bytes[2];
@@ -1733,11 +1787,15 @@ i830_sdvo_get_ddc_modes(xf86OutputPtr output)
xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
DisplayModePtr modes = NULL;
xf86OutputPtr crt;
- I830OutputPrivatePtr intel_output;
+ I830OutputPrivatePtr intel_output =output->driver_private;
xf86MonPtr edid_mon = NULL;
- struct i830_sdvo_priv *dev_priv;
+ struct i830_sdvo_priv *dev_priv = intel_output->dev_priv;
+
+ if (dev_priv->is_lvds)
+ modes = i830_sdvo_lvds_fetch_modes(output);
+ else
+ modes = i830_ddc_get_modes(output);
- modes = i830_ddc_get_modes(output);
if (modes != NULL)
goto check_hdmi;
@@ -1761,9 +1819,6 @@ i830_sdvo_get_ddc_modes(xf86OutputPtr output)
check_hdmi:
/* Check if HDMI encode, setup it and set the flag for HDMI audio */
- intel_output = output->driver_private;
- dev_priv = intel_output->dev_priv;
-
if (dev_priv->caps.output_flags & (SDVO_OUTPUT_TMDS0 | SDVO_OUTPUT_TMDS1))
{
if (!i830_sdvo_check_hdmi_encode(output)) {
@@ -2091,7 +2146,6 @@ i830_sdvo_select_ddc_bus(struct i830_sdvo_priv *dev_priv)
dev_priv->ddc_bus = 1 << num_bits;
}
-
Bool
i830_sdvo_init(ScrnInfoPtr pScrn, int output_device)
{
++++++ Free-front-buffer-bo-when-X-exit.patch ++++++
From 865aa9354eb3d8f3e195b04fa01d35a23cf63ea6 Mon Sep 17 00:00:00 2001
From: Shuang He
Date: Sat, 18 Apr 2009 11:48:08 +0800
Subject: Free front buffer bo when X exit
It's needed when KMS or DRI2 is enabled, or there will be memory leak.
Also fixes a segfault at startup with fake bufmgr.
Signed-off-by: Eric Anholt
---
src/i830_driver.c | 6 ++++++
src/i830_exa.c | 6 ++++--
2 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 48e2351..0233da9 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -3713,6 +3713,12 @@ I830CloseScreen(int scrnIndex, ScreenPtr pScreen)
pI830->uxa_driver = NULL;
}
#endif
+ if (pI830->front_buffer) {
+ i830_set_pixmap_bo(pScreen->GetScreenPixmap(pScreen), NULL);
+ i830_free_memory(pScrn, pI830->front_buffer);
+ pI830->front_buffer = NULL;
+ }
+
xf86_cursors_fini (pScreen);
i830_allocator_fini(pScrn);
diff --git a/src/i830_exa.c b/src/i830_exa.c
index 39011bc..9c8a8af 100644
--- a/src/i830_exa.c
+++ b/src/i830_exa.c
@@ -812,7 +812,8 @@ i830_set_pixmap_bo(PixmapPtr pixmap, dri_bo *bo)
dri_bo_unreference (old_bo);
#if I830_USE_UXA
if (i830->accel == ACCEL_UXA) {
- dri_bo_reference(bo);
+ if (bo != NULL)
+ dri_bo_reference(bo);
dixSetPrivate(&pixmap->devPrivates, &uxa_pixmap_index, bo);
}
#endif
@@ -821,7 +822,8 @@ i830_set_pixmap_bo(PixmapPtr pixmap, dri_bo *bo)
struct i830_exa_pixmap_priv *driver_priv =
exaGetPixmapDriverPrivate(pixmap);
if (driver_priv) {
- dri_bo_reference(bo);
+ if (bo != NULL)
+ dri_bo_reference(bo);
driver_priv->bo = bo;
}
}
--
1.6.1.3
++++++ regdumper.patch ++++++
--- xf86-video-intel-2.6.1/src/reg_dumper/Makefile.am~ 2009-02-20 20:39:32.000000000 -0800
+++ xf86-video-intel-2.6.1/src/reg_dumper/Makefile.am 2009-02-20 20:39:32.000000000 -0800
@@ -1,4 +1,4 @@
-noinst_PROGRAMS = intel_reg_dumper \
+bin_PROGRAMS = intel_reg_dumper \
intel_gtt \
intel_idle \
intel_stepping \
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org