diff mbox

[libdrm,05/24] radeon: remove more unused functions

Message ID 1427904935-14387-6-git-send-email-emil.l.velikov@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Emil Velikov April 1, 2015, 4:15 p.m. UTC
bof_array_{get,size} and bof_blob_{size,value}. All of which unused
since their introduction with commit 78de69713d7(drm/radeon: add new cs
command stream dumping facilities)

Cc: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 radeon/bof.c | 28 ----------------------------
 radeon/bof.h |  4 ----
 2 files changed, 32 deletions(-)

Comments

Jerome Glisse April 1, 2015, 5:32 p.m. UTC | #1
On Wed, Apr 01, 2015 at 05:15:16PM +0100, Emil Velikov wrote:
> bof_array_{get,size} and bof_blob_{size,value}. All of which unused
> since their introduction with commit 78de69713d7(drm/radeon: add new cs
> command stream dumping facilities)
> 
> Cc: Jerome Glisse <jglisse@redhat.com>
> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>

NAK

I use all this in tools to debug lockup. Best course of action is to
exclude bof.h from being distributed. My tools static link and i just
point them to libdrm git tree.

Cheers,
Jérôme
diff mbox

Patch

diff --git a/radeon/bof.c b/radeon/bof.c
index 20901a0..9c7997f 100644
--- a/radeon/bof.c
+++ b/radeon/bof.c
@@ -158,20 +158,6 @@  int bof_array_append(bof_t *array, bof_t *value)
 	return 0;
 }
 
-bof_t *bof_array_get(bof_t *bof, unsigned i)
-{
-	if (!bof_is_array(bof) || i >= bof->array_size)
-		return NULL;
-	return bof->array[i];
-}
-
-unsigned bof_array_size(bof_t *bof)
-{
-	if (!bof_is_array(bof))
-		return 0;
-	return bof->array_size;
-}
-
 /*
  * blob
  */
@@ -193,20 +179,6 @@  bof_t *bof_blob(unsigned size, void *value)
 	return blob;
 }
 
-unsigned bof_blob_size(bof_t *bof)
-{
-	if (!bof_is_blob(bof))
-		return 0;
-	return bof->size - 12;
-}
-
-void *bof_blob_value(bof_t *bof)
-{
-	if (!bof_is_blob(bof))
-		return NULL;
-	return bof->value;
-}
-
 /*
  *  int32
  */
diff --git a/radeon/bof.h b/radeon/bof.h
index 4dae923..8108dd5 100644
--- a/radeon/bof.h
+++ b/radeon/bof.h
@@ -57,12 +57,8 @@  extern int bof_object_set(bof_t *object, const char *keyname, bof_t *value);
 /* array */
 extern bof_t *bof_array(void);
 extern int bof_array_append(bof_t *array, bof_t *value);
-extern bof_t *bof_array_get(bof_t *bof, unsigned i);
-extern unsigned bof_array_size(bof_t *bof);
 /* blob */
 extern bof_t *bof_blob(unsigned size, void *value);
-extern unsigned bof_blob_size(bof_t *bof);
-extern void *bof_blob_value(bof_t *bof);
 /* int32 */
 extern bof_t *bof_int32(int32_t value);
 extern int32_t bof_int32_value(bof_t *bof);