[PATCH] xf86: xf86ClearEntityListForScreen should take a pScrn
Dave Airlie
airlied at gmail.com
Thu May 24 12:14:55 PDT 2012
From: Dave Airlie <airlied at redhat.com>
When adding GPU screens this make life easier.
Signed-off-by: Dave Airlie <airlied at redhat.com>
---
hw/xfree86/common/xf86Bus.c | 3 +--
hw/xfree86/common/xf86Helper.c | 2 +-
hw/xfree86/common/xf86Priv.h | 2 +-
3 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/hw/xfree86/common/xf86Bus.c b/hw/xfree86/common/xf86Bus.c
index beb41c2..f158ac9 100644
--- a/hw/xfree86/common/xf86Bus.c
+++ b/hw/xfree86/common/xf86Bus.c
@@ -381,9 +381,8 @@ xf86RemoveEntityFromScreen(ScrnInfoPtr pScrn, int entityIndex)
* to mark it's entities unused. Called by xf86DeleteScreen().
*/
void
-xf86ClearEntityListForScreen(int scrnIndex)
+xf86ClearEntityListForScreen(ScrnInfoPtr pScrn)
{
- ScrnInfoPtr pScrn = xf86Screens[scrnIndex];
int i, entityIndex;
if (pScrn->entityList == NULL || pScrn->numEntities == 0)
diff --git a/hw/xfree86/common/xf86Helper.c b/hw/xfree86/common/xf86Helper.c
index a8f9fb5..9b23f9b 100644
--- a/hw/xfree86/common/xf86Helper.c
+++ b/hw/xfree86/common/xf86Helper.c
@@ -231,7 +231,7 @@ xf86DeleteScreen(ScrnInfoPtr pScrn, int flags)
free(pScrn->privates);
- xf86ClearEntityListForScreen(scrnIndex);
+ xf86ClearEntityListForScreen(pScrn);
free(pScrn);
diff --git a/hw/xfree86/common/xf86Priv.h b/hw/xfree86/common/xf86Priv.h
index 6c5efea..42a3b30 100644
--- a/hw/xfree86/common/xf86Priv.h
+++ b/hw/xfree86/common/xf86Priv.h
@@ -114,7 +114,7 @@ extern _X_EXPORT void xf86BusProbe(void);
extern _X_EXPORT void xf86AccessEnter(void);
extern _X_EXPORT void xf86AccessLeave(void);
extern _X_EXPORT void xf86PostProbe(void);
-extern _X_EXPORT void xf86ClearEntityListForScreen(int scrnIndex);
+extern _X_EXPORT void xf86ClearEntityListForScreen(ScrnInfoPtr pScrn);
extern _X_EXPORT void xf86AddDevToEntity(int entityIndex, GDevPtr dev);
extern _X_EXPORT void xf86RemoveDevFromEntity(int entityIndex, GDevPtr dev);
--
1.7.6
More information about the xorg-devel
mailing list