diff options
author | Jesse Barnes <jbarnes@virtuousgeek.org> | 2009-01-26 20:10:45 -0500 |
---|---|---|
committer | Dave Airlie <airlied@linux.ie> | 2009-02-08 06:38:02 -0500 |
commit | 0f973f27888e4664b253ab2cf69c67c2eb80ab1b (patch) | |
tree | 1f921af14dff65311dd10106dfc10778e3730b1e /drivers/gpu/drm/i915/i915_drv.h | |
parent | d9ddcb96e05cfbadf3dbf66859bcaf5eae25af0b (diff) |
drm/i915: add fence register management to execbuf
Adds code to set up fence registers at execbuf time on pre-965 chips as
necessary. Also fixes up a few bugs in the pre-965 tile register support
(get_order != ffs). The number of fences available to the kernel defaults
to the hw limit minus 3 (for legacy X front/back/depth), but a new parameter
allows userspace to override that as needed.
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_drv.h')
-rw-r--r-- | drivers/gpu/drm/i915/i915_drv.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index f471d218b89a..a70bf77290fc 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h | |||
@@ -602,6 +602,7 @@ int i915_gem_init_object(struct drm_gem_object *obj); | |||
602 | void i915_gem_free_object(struct drm_gem_object *obj); | 602 | void i915_gem_free_object(struct drm_gem_object *obj); |
603 | int i915_gem_object_pin(struct drm_gem_object *obj, uint32_t alignment); | 603 | int i915_gem_object_pin(struct drm_gem_object *obj, uint32_t alignment); |
604 | void i915_gem_object_unpin(struct drm_gem_object *obj); | 604 | void i915_gem_object_unpin(struct drm_gem_object *obj); |
605 | int i915_gem_object_unbind(struct drm_gem_object *obj); | ||
605 | void i915_gem_lastclose(struct drm_device *dev); | 606 | void i915_gem_lastclose(struct drm_device *dev); |
606 | uint32_t i915_get_gem_seqno(struct drm_device *dev); | 607 | uint32_t i915_get_gem_seqno(struct drm_device *dev); |
607 | void i915_gem_retire_requests(struct drm_device *dev); | 608 | void i915_gem_retire_requests(struct drm_device *dev); |
@@ -785,6 +786,11 @@ extern int i915_wait_ring(struct drm_device * dev, int n, const char *caller); | |||
785 | IS_I945GM(dev) || IS_I965GM(dev) || IS_GM45(dev)) | 786 | IS_I945GM(dev) || IS_I965GM(dev) || IS_GM45(dev)) |
786 | 787 | ||
787 | #define I915_NEED_GFX_HWS(dev) (IS_G33(dev) || IS_GM45(dev) || IS_G4X(dev)) | 788 | #define I915_NEED_GFX_HWS(dev) (IS_G33(dev) || IS_GM45(dev) || IS_G4X(dev)) |
789 | /* With the 945 and later, Y tiling got adjusted so that it was 32 128-byte | ||
790 | * rows, which changed the alignment requirements and fence programming. | ||
791 | */ | ||
792 | #define HAS_128_BYTE_Y_TILING(dev) (IS_I9XX(dev) && !(IS_I915G(dev) || \ | ||
793 | IS_I915GM(dev))) | ||
788 | #define SUPPORTS_INTEGRATED_HDMI(dev) (IS_G4X(dev)) | 794 | #define SUPPORTS_INTEGRATED_HDMI(dev) (IS_G4X(dev)) |
789 | 795 | ||
790 | #define PRIMARY_RINGBUFFER_SIZE (128*1024) | 796 | #define PRIMARY_RINGBUFFER_SIZE (128*1024) |