diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2009-12-11 00:13:00 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-12-11 00:14:36 -0500 |
commit | d1ede145cea25c5b6d2ebb19b167af14e374bb45 (patch) | |
tree | 221e7b912000645dc7775e32bb08a85fad8997b9 | |
parent | 9062fa6612958f35f41379425bcae9c9b4ccd68e (diff) |
drm/ttm: export some functions useful to drivers using ttm
These are functions required by nouveau which will be merged later.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
-rw-r--r-- | drivers/gpu/drm/ttm/ttm_bo.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index fae5c158351..1fbb2eea5e8 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c | |||
@@ -185,6 +185,7 @@ int ttm_bo_wait_unreserved(struct ttm_buffer_object *bo, bool interruptible) | |||
185 | } | 185 | } |
186 | return 0; | 186 | return 0; |
187 | } | 187 | } |
188 | EXPORT_SYMBOL(ttm_bo_wait_unreserved); | ||
188 | 189 | ||
189 | static void ttm_bo_add_to_lru(struct ttm_buffer_object *bo) | 190 | static void ttm_bo_add_to_lru(struct ttm_buffer_object *bo) |
190 | { | 191 | { |
@@ -946,6 +947,7 @@ int ttm_bo_wait_cpu(struct ttm_buffer_object *bo, bool no_wait) | |||
946 | return wait_event_interruptible(bo->event_queue, | 947 | return wait_event_interruptible(bo->event_queue, |
947 | atomic_read(&bo->cpu_writers) == 0); | 948 | atomic_read(&bo->cpu_writers) == 0); |
948 | } | 949 | } |
950 | EXPORT_SYMBOL(ttm_bo_wait_cpu); | ||
949 | 951 | ||
950 | int ttm_bo_move_buffer(struct ttm_buffer_object *bo, | 952 | int ttm_bo_move_buffer(struct ttm_buffer_object *bo, |
951 | struct ttm_placement *placement, | 953 | struct ttm_placement *placement, |
@@ -1727,12 +1729,14 @@ int ttm_bo_synccpu_write_grab(struct ttm_buffer_object *bo, bool no_wait) | |||
1727 | ttm_bo_unreserve(bo); | 1729 | ttm_bo_unreserve(bo); |
1728 | return ret; | 1730 | return ret; |
1729 | } | 1731 | } |
1732 | EXPORT_SYMBOL(ttm_bo_synccpu_write_grab); | ||
1730 | 1733 | ||
1731 | void ttm_bo_synccpu_write_release(struct ttm_buffer_object *bo) | 1734 | void ttm_bo_synccpu_write_release(struct ttm_buffer_object *bo) |
1732 | { | 1735 | { |
1733 | if (atomic_dec_and_test(&bo->cpu_writers)) | 1736 | if (atomic_dec_and_test(&bo->cpu_writers)) |
1734 | wake_up_all(&bo->event_queue); | 1737 | wake_up_all(&bo->event_queue); |
1735 | } | 1738 | } |
1739 | EXPORT_SYMBOL(ttm_bo_synccpu_write_release); | ||
1736 | 1740 | ||
1737 | /** | 1741 | /** |
1738 | * A buffer object shrink method that tries to swap out the first | 1742 | * A buffer object shrink method that tries to swap out the first |