diff options
author | Daniel Stone <daniel@fooishbar.org> | 2009-01-05 11:24:24 +0200 |
---|---|---|
committer | Daniel Stone <daniel@fooishbar.org> | 2009-01-05 11:24:24 +0200 |
commit | 55c4ec0a1ef78481b4d82153c19c20fbf88f1624 (patch) | |
tree | 20e7771bdbd0f90bfe09a99883ee44f7f7fcfe6e | |
parent | 7da4e901e078e5597b8dbcb7ee39b949edf7ef03 (diff) |
XFree86: fbdevhw: Add helper function to get fd
Most devices need to do custom weird ioctls, so let them know what the
fd is.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
-rw-r--r-- | hw/xfree86/fbdevhw/fbdevhw.c | 8 | ||||
-rw-r--r-- | hw/xfree86/fbdevhw/fbdevhw.h | 2 |
2 files changed, 10 insertions, 0 deletions
diff --git a/hw/xfree86/fbdevhw/fbdevhw.c b/hw/xfree86/fbdevhw/fbdevhw.c index 5269277ef..495d88b90 100644 --- a/hw/xfree86/fbdevhw/fbdevhw.c +++ b/hw/xfree86/fbdevhw/fbdevhw.c @@ -152,6 +152,14 @@ fbdevHWFreeRec(ScrnInfoPtr pScrn) FBDEVHWPTRLVAL(pScrn) = NULL; } +int +fbdevHWGetFD(ScrnInfoPtr pScrn) +{ + fbdevHWPtr fPtr = fbdevHWGetRec(pScrn); + + return fPtr->fd; +} + /* -------------------------------------------------------------------- */ /* some helpers for printing debug informations */ diff --git a/hw/xfree86/fbdevhw/fbdevhw.h b/hw/xfree86/fbdevhw/fbdevhw.h index 41c3e339a..bc46b9c4f 100644 --- a/hw/xfree86/fbdevhw/fbdevhw.h +++ b/hw/xfree86/fbdevhw/fbdevhw.h @@ -16,6 +16,8 @@ extern _X_EXPORT Bool fbdevHWGetRec(ScrnInfoPtr pScrn); extern _X_EXPORT void fbdevHWFreeRec(ScrnInfoPtr pScrn); +extern _X_EXPORT int fbdevHWGetFD(ScrnInfoPtr pScrn); + extern _X_EXPORT Bool fbdevHWProbe(struct pci_device * pPci, char *device, char **namep); extern _X_EXPORT Bool fbdevHWInit(ScrnInfoPtr pScrn, struct pci_device * pPci, char *device); |