summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2013-10-03 13:36:46 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2013-10-03 13:38:06 +0100
commitb7d5292e01fb43d93c13c60a3cef16d352307bdf (patch)
treeafa348fbdd0625ed2511bf96bc921f033f936956 /src
parentadbf01306a9f42efb26a485a80c3c7f3918a48ba (diff)
intel: Fix fallout from accident push of ODEV_ATTRIB_FD
This is WIP for passing along a hosted fd. It wasn't meant to be pushed along with the bug fix this morning. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src')
-rw-r--r--src/intel_device.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/src/intel_device.c b/src/intel_device.c
index 450e6f5f..c41179a4 100644
--- a/src/intel_device.c
+++ b/src/intel_device.c
@@ -220,17 +220,23 @@ static char *find_render_node(int fd)
return NULL;
}
-#ifdef XSERVER_PLATFORM_BUS
-
-#define ODEV_ATTRIB_PATH 0
-#define ODEV_ATTRIB_FD 4
-
+#if defined(ODEV_ATTRIB_PATH)
static char *get_path(struct xf86_platform_device *dev)
{
const char *path = xf86_get_platform_device_attrib(dev, ODEV_ATTRIB_PATH);
return path ? strdup(path) : NULL;
}
+#else
+
+static char *get_path(struct xf86_platform_device *dev)
+{
+ return NULL;
+}
+#endif
+
+
+#if defined(ODEV_ATTRIB_FD) && 0
static int get_fd(struct xf86_platform_device *dev)
{
const char *str = xf86_get_platform_device_attrib(dev, ODEV_ATTRIB_FD);
@@ -241,11 +247,6 @@ static int get_fd(struct xf86_platform_device *dev)
#else
-static char *get_path(struct xf86_platform_device *dev)
-{
- return NULL;
-}
-
static int get_fd(struct xf86_platform_device *dev)
{
return -1;