summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2008-02-05 12:27:48 -0500
committerKristian Høgsberg <krh@sasori.boston.redhat.com>2008-02-13 13:34:02 -0500
commitee15459483d50b2efe630051b45f36cfbb351683 (patch)
tree5084a670cc31855445e6e9926809363ce855db3b
parent4feb0638f1a8eb8527647ff47312ee61e3f683f9 (diff)
i915: Add I915_PARAM_CHIPSET_ID param to get chipset ID.
-rw-r--r--shared-core/i915_dma.c3
-rw-r--r--shared-core/i915_drm.h1
2 files changed, 4 insertions, 0 deletions
diff --git a/shared-core/i915_dma.c b/shared-core/i915_dma.c
index 9619525d..0682a334 100644
--- a/shared-core/i915_dma.c
+++ b/shared-core/i915_dma.c
@@ -1210,6 +1210,9 @@ static int i915_getparam(struct drm_device *dev, void *data,
case I915_PARAM_LAST_DISPATCH:
value = READ_BREADCRUMB(dev_priv);
break;
+ case I915_PARAM_CHIPSET_ID:
+ value = dev->pci_device;
+ break;
default:
DRM_ERROR("Unknown parameter %d\n", param->param);
return -EINVAL;
diff --git a/shared-core/i915_drm.h b/shared-core/i915_drm.h
index c8a9cb76..ad0797c2 100644
--- a/shared-core/i915_drm.h
+++ b/shared-core/i915_drm.h
@@ -232,6 +232,7 @@ typedef struct drm_i915_irq_wait {
#define I915_PARAM_IRQ_ACTIVE 1
#define I915_PARAM_ALLOW_BATCHBUFFER 2
#define I915_PARAM_LAST_DISPATCH 3
+#define I915_PARAM_CHIPSET_ID 4
typedef struct drm_i915_getparam {
int param;