summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--freedreno/freedreno_bo.c2
-rw-r--r--freedreno/freedreno_device.c2
-rw-r--r--freedreno/freedreno_priv.h4
-rw-r--r--freedreno/kgsl/kgsl_bo.c11
-rw-r--r--freedreno/kgsl/kgsl_device.c2
-rw-r--r--freedreno/kgsl/kgsl_pipe.c18
-rw-r--r--freedreno/kgsl/kgsl_priv.h33
-rw-r--r--freedreno/kgsl/kgsl_ringbuffer.c2
-rw-r--r--freedreno/msm/msm_bo.c4
-rw-r--r--freedreno/msm/msm_device.c2
-rw-r--r--freedreno/msm/msm_pipe.c3
-rw-r--r--freedreno/msm/msm_priv.h11
-rw-r--r--freedreno/msm/msm_ringbuffer.c2
13 files changed, 54 insertions, 42 deletions
diff --git a/freedreno/freedreno_bo.c b/freedreno/freedreno_bo.c
index 9089c931..c56fdbd9 100644
--- a/freedreno/freedreno_bo.c
+++ b/freedreno/freedreno_bo.c
@@ -81,7 +81,7 @@ static struct fd_bo * bo_from_handle(struct fd_device *dev,
}
/* Frees older cached buffers. Called under table_lock */
-void fd_cleanup_bo_cache(struct fd_device *dev, time_t time)
+drm_private void fd_cleanup_bo_cache(struct fd_device *dev, time_t time)
{
int i;
diff --git a/freedreno/freedreno_device.c b/freedreno/freedreno_device.c
index e8b5f60f..09b2302c 100644
--- a/freedreno/freedreno_device.c
+++ b/freedreno/freedreno_device.c
@@ -145,7 +145,7 @@ static void fd_device_del_impl(struct fd_device *dev)
dev->funcs->destroy(dev);
}
-void fd_device_del_locked(struct fd_device *dev)
+drm_private void fd_device_del_locked(struct fd_device *dev)
{
if (!atomic_dec_and_test(&dev->refcnt))
return;
diff --git a/freedreno/freedreno_priv.h b/freedreno/freedreno_priv.h
index 8e072d96..2d0fa6d0 100644
--- a/freedreno/freedreno_priv.h
+++ b/freedreno/freedreno_priv.h
@@ -92,10 +92,10 @@ struct fd_device {
int closefd; /* call close(fd) upon destruction */
};
-void fd_cleanup_bo_cache(struct fd_device *dev, time_t time);
+drm_private void fd_cleanup_bo_cache(struct fd_device *dev, time_t time);
/* for where @table_lock is already held: */
-void fd_device_del_locked(struct fd_device *dev);
+drm_private void fd_device_del_locked(struct fd_device *dev);
struct fd_pipe_funcs {
struct fd_ringbuffer * (*ringbuffer_new)(struct fd_pipe *pipe, uint32_t size);
diff --git a/freedreno/kgsl/kgsl_bo.c b/freedreno/kgsl/kgsl_bo.c
index fab33500..f1511864 100644
--- a/freedreno/kgsl/kgsl_bo.c
+++ b/freedreno/kgsl/kgsl_bo.c
@@ -131,7 +131,7 @@ static struct fd_bo_funcs funcs = {
};
/* allocate a buffer handle: */
-int kgsl_bo_new_handle(struct fd_device *dev,
+drm_private int kgsl_bo_new_handle(struct fd_device *dev,
uint32_t size, uint32_t flags, uint32_t *handle)
{
struct drm_kgsl_gem_create req = {
@@ -155,7 +155,7 @@ int kgsl_bo_new_handle(struct fd_device *dev,
}
/* allocate a new buffer object */
-struct fd_bo * kgsl_bo_from_handle(struct fd_device *dev,
+drm_private struct fd_bo * kgsl_bo_from_handle(struct fd_device *dev,
uint32_t size, uint32_t handle)
{
struct kgsl_bo *kgsl_bo;
@@ -218,7 +218,7 @@ fail:
return NULL;
}
-uint32_t kgsl_bo_gpuaddr(struct kgsl_bo *kgsl_bo, uint32_t offset)
+drm_private uint32_t kgsl_bo_gpuaddr(struct kgsl_bo *kgsl_bo, uint32_t offset)
{
struct fd_bo *bo = &kgsl_bo->base;
if (!kgsl_bo->gpuaddr) {
@@ -267,7 +267,8 @@ uint32_t kgsl_bo_gpuaddr(struct kgsl_bo *kgsl_bo, uint32_t offset)
* _emit_reloc()..
*/
-void kgsl_bo_set_timestamp(struct kgsl_bo *kgsl_bo, uint32_t timestamp)
+drm_private void kgsl_bo_set_timestamp(struct kgsl_bo *kgsl_bo,
+ uint32_t timestamp)
{
struct fd_bo *bo = &kgsl_bo->base;
if (bo->name) {
@@ -285,7 +286,7 @@ void kgsl_bo_set_timestamp(struct kgsl_bo *kgsl_bo, uint32_t timestamp)
}
}
-uint32_t kgsl_bo_get_timestamp(struct kgsl_bo *kgsl_bo)
+drm_private uint32_t kgsl_bo_get_timestamp(struct kgsl_bo *kgsl_bo)
{
struct fd_bo *bo = &kgsl_bo->base;
uint32_t timestamp = 0;
diff --git a/freedreno/kgsl/kgsl_device.c b/freedreno/kgsl/kgsl_device.c
index 5f2dfea4..8352d605 100644
--- a/freedreno/kgsl/kgsl_device.c
+++ b/freedreno/kgsl/kgsl_device.c
@@ -49,7 +49,7 @@ static struct fd_device_funcs funcs = {
.destroy = kgsl_device_destroy,
};
-struct fd_device * kgsl_device_new(int fd)
+drm_private struct fd_device * kgsl_device_new(int fd)
{
struct kgsl_device *kgsl_dev;
struct fd_device *dev;
diff --git a/freedreno/kgsl/kgsl_pipe.c b/freedreno/kgsl/kgsl_pipe.c
index 1a795ba3..fc76b2b8 100644
--- a/freedreno/kgsl/kgsl_pipe.c
+++ b/freedreno/kgsl/kgsl_pipe.c
@@ -75,7 +75,8 @@ static int kgsl_pipe_wait(struct fd_pipe *pipe, uint32_t timestamp)
return ret;
}
-int kgsl_pipe_timestamp(struct kgsl_pipe *kgsl_pipe, uint32_t *timestamp)
+drm_private int kgsl_pipe_timestamp(struct kgsl_pipe *kgsl_pipe,
+ uint32_t *timestamp)
{
struct kgsl_cmdstream_readtimestamp req = {
.type = KGSL_TIMESTAMP_RETIRED
@@ -113,13 +114,13 @@ static struct fd_pipe_funcs funcs = {
.destroy = kgsl_pipe_destroy,
};
-int is_kgsl_pipe(struct fd_pipe *pipe)
+drm_private int is_kgsl_pipe(struct fd_pipe *pipe)
{
return pipe->funcs == &funcs;
}
/* add buffer to submit list when it is referenced in cmdstream: */
-void kgsl_pipe_add_submit(struct kgsl_pipe *kgsl_pipe,
+drm_private void kgsl_pipe_add_submit(struct kgsl_pipe *kgsl_pipe,
struct kgsl_bo *kgsl_bo)
{
struct fd_pipe *pipe = &kgsl_pipe->base;
@@ -134,7 +135,7 @@ void kgsl_pipe_add_submit(struct kgsl_pipe *kgsl_pipe,
}
/* prepare buffers on submit list before flush: */
-void kgsl_pipe_pre_submit(struct kgsl_pipe *kgsl_pipe)
+drm_private void kgsl_pipe_pre_submit(struct kgsl_pipe *kgsl_pipe)
{
struct fd_pipe *pipe = &kgsl_pipe->base;
struct kgsl_bo *kgsl_bo = NULL;
@@ -150,7 +151,8 @@ void kgsl_pipe_pre_submit(struct kgsl_pipe *kgsl_pipe)
}
/* process buffers on submit list after flush: */
-void kgsl_pipe_post_submit(struct kgsl_pipe *kgsl_pipe, uint32_t timestamp)
+drm_private void kgsl_pipe_post_submit(struct kgsl_pipe *kgsl_pipe,
+ uint32_t timestamp)
{
struct fd_pipe *pipe = &kgsl_pipe->base;
struct kgsl_bo *kgsl_bo = NULL, *tmp;
@@ -168,7 +170,8 @@ void kgsl_pipe_post_submit(struct kgsl_pipe *kgsl_pipe, uint32_t timestamp)
kgsl_pipe_process_pending(kgsl_pipe, timestamp);
}
-void kgsl_pipe_process_pending(struct kgsl_pipe *kgsl_pipe, uint32_t timestamp)
+drm_private void kgsl_pipe_process_pending(struct kgsl_pipe *kgsl_pipe,
+ uint32_t timestamp)
{
struct fd_pipe *pipe = &kgsl_pipe->base;
struct kgsl_bo *kgsl_bo = NULL, *tmp;
@@ -201,7 +204,8 @@ static int getprop(int fd, enum kgsl_property_type type,
} } while (0)
-struct fd_pipe * kgsl_pipe_new(struct fd_device *dev, enum fd_pipe_id id)
+drm_private struct fd_pipe * kgsl_pipe_new(struct fd_device *dev,
+ enum fd_pipe_id id)
{
static const char *paths[] = {
[FD_PIPE_3D] = "/dev/kgsl-3d0",
diff --git a/freedreno/kgsl/kgsl_priv.h b/freedreno/kgsl/kgsl_priv.h
index 56dc21a5..6ab64965 100644
--- a/freedreno/kgsl/kgsl_priv.h
+++ b/freedreno/kgsl/kgsl_priv.h
@@ -73,7 +73,7 @@ static inline struct kgsl_pipe * to_kgsl_pipe(struct fd_pipe *x)
return (struct kgsl_pipe *)x;
}
-int is_kgsl_pipe(struct fd_pipe *pipe);
+drm_private int is_kgsl_pipe(struct fd_pipe *pipe);
struct kgsl_bo {
struct fd_bo base;
@@ -91,25 +91,30 @@ static inline struct kgsl_bo * to_kgsl_bo(struct fd_bo *x)
}
-struct fd_device * kgsl_device_new(int fd);
+drm_private struct fd_device * kgsl_device_new(int fd);
-int kgsl_pipe_timestamp(struct kgsl_pipe *kgsl_pipe, uint32_t *timestamp);
-void kgsl_pipe_add_submit(struct kgsl_pipe *pipe, struct kgsl_bo *bo);
-void kgsl_pipe_pre_submit(struct kgsl_pipe *pipe);
-void kgsl_pipe_post_submit(struct kgsl_pipe *pipe, uint32_t timestamp);
-void kgsl_pipe_process_pending(struct kgsl_pipe *pipe, uint32_t timestamp);
-struct fd_pipe * kgsl_pipe_new(struct fd_device *dev, enum fd_pipe_id id);
+drm_private int kgsl_pipe_timestamp(struct kgsl_pipe *kgsl_pipe,
+ uint32_t *timestamp);
+drm_private void kgsl_pipe_add_submit(struct kgsl_pipe *pipe,
+ struct kgsl_bo *bo);
+drm_private void kgsl_pipe_pre_submit(struct kgsl_pipe *pipe);
+drm_private void kgsl_pipe_post_submit(struct kgsl_pipe *pipe,
+ uint32_t timestamp);
+drm_private void kgsl_pipe_process_pending(struct kgsl_pipe *pipe,
+ uint32_t timestamp);
+drm_private struct fd_pipe * kgsl_pipe_new(struct fd_device *dev,
+ enum fd_pipe_id id);
-struct fd_ringbuffer * kgsl_ringbuffer_new(struct fd_pipe *pipe,
+drm_private struct fd_ringbuffer * kgsl_ringbuffer_new(struct fd_pipe *pipe,
uint32_t size);
-int kgsl_bo_new_handle(struct fd_device *dev,
+drm_private int kgsl_bo_new_handle(struct fd_device *dev,
uint32_t size, uint32_t flags, uint32_t *handle);
-struct fd_bo * kgsl_bo_from_handle(struct fd_device *dev,
+drm_private struct fd_bo * kgsl_bo_from_handle(struct fd_device *dev,
uint32_t size, uint32_t handle);
-uint32_t kgsl_bo_gpuaddr(struct kgsl_bo *bo, uint32_t offset);
-void kgsl_bo_set_timestamp(struct kgsl_bo *bo, uint32_t timestamp);
-uint32_t kgsl_bo_get_timestamp(struct kgsl_bo *bo);
+drm_private uint32_t kgsl_bo_gpuaddr(struct kgsl_bo *bo, uint32_t offset);
+drm_private void kgsl_bo_set_timestamp(struct kgsl_bo *bo, uint32_t timestamp);
+drm_private uint32_t kgsl_bo_get_timestamp(struct kgsl_bo *bo);
#endif /* KGSL_PRIV_H_ */
diff --git a/freedreno/kgsl/kgsl_ringbuffer.c b/freedreno/kgsl/kgsl_ringbuffer.c
index d1e8321e..f0133078 100644
--- a/freedreno/kgsl/kgsl_ringbuffer.c
+++ b/freedreno/kgsl/kgsl_ringbuffer.c
@@ -199,7 +199,7 @@ static struct fd_ringbuffer_funcs funcs = {
.destroy = kgsl_ringbuffer_destroy,
};
-struct fd_ringbuffer * kgsl_ringbuffer_new(struct fd_pipe *pipe,
+drm_private struct fd_ringbuffer * kgsl_ringbuffer_new(struct fd_pipe *pipe,
uint32_t size)
{
struct kgsl_ringbuffer *kgsl_ring;
diff --git a/freedreno/msm/msm_bo.c b/freedreno/msm/msm_bo.c
index 0cac1c60..fbd82df7 100644
--- a/freedreno/msm/msm_bo.c
+++ b/freedreno/msm/msm_bo.c
@@ -104,7 +104,7 @@ static struct fd_bo_funcs funcs = {
};
/* allocate a buffer handle: */
-int msm_bo_new_handle(struct fd_device *dev,
+drm_private int msm_bo_new_handle(struct fd_device *dev,
uint32_t size, uint32_t flags, uint32_t *handle)
{
struct drm_msm_gem_new req = {
@@ -124,7 +124,7 @@ int msm_bo_new_handle(struct fd_device *dev,
}
/* allocate a new buffer object */
-struct fd_bo * msm_bo_from_handle(struct fd_device *dev,
+drm_private struct fd_bo * msm_bo_from_handle(struct fd_device *dev,
uint32_t size, uint32_t handle)
{
struct msm_bo *msm_bo;
diff --git a/freedreno/msm/msm_device.c b/freedreno/msm/msm_device.c
index b9c5a3e3..81077e1a 100644
--- a/freedreno/msm/msm_device.c
+++ b/freedreno/msm/msm_device.c
@@ -49,7 +49,7 @@ static struct fd_device_funcs funcs = {
.destroy = msm_device_destroy,
};
-struct fd_device * msm_device_new(int fd)
+drm_private struct fd_device * msm_device_new(int fd)
{
struct msm_device *msm_dev;
struct fd_device *dev;
diff --git a/freedreno/msm/msm_pipe.c b/freedreno/msm/msm_pipe.c
index 6955f2c9..ddc975ed 100644
--- a/freedreno/msm/msm_pipe.c
+++ b/freedreno/msm/msm_pipe.c
@@ -103,7 +103,8 @@ static uint64_t get_param(struct fd_device *dev, uint32_t pipe, uint32_t param)
return req.value;
}
-struct fd_pipe * msm_pipe_new(struct fd_device *dev, enum fd_pipe_id id)
+drm_private struct fd_pipe * msm_pipe_new(struct fd_device *dev,
+ enum fd_pipe_id id)
{
static const uint32_t pipe_id[] = {
[FD_PIPE_3D] = MSM_PIPE_3D0,
diff --git a/freedreno/msm/msm_priv.h b/freedreno/msm/msm_priv.h
index 75ae883f..94d23579 100644
--- a/freedreno/msm/msm_priv.h
+++ b/freedreno/msm/msm_priv.h
@@ -46,7 +46,7 @@ static inline struct msm_device * to_msm_device(struct fd_device *x)
return (struct msm_device *)x;
}
-struct fd_device * msm_device_new(int fd);
+drm_private struct fd_device * msm_device_new(int fd);
struct msm_pipe {
struct fd_pipe base;
@@ -61,9 +61,10 @@ static inline struct msm_pipe * to_msm_pipe(struct fd_pipe *x)
return (struct msm_pipe *)x;
}
-struct fd_pipe * msm_pipe_new(struct fd_device *dev, enum fd_pipe_id id);
+drm_private struct fd_pipe * msm_pipe_new(struct fd_device *dev,
+ enum fd_pipe_id id);
-struct fd_ringbuffer * msm_ringbuffer_new(struct fd_pipe *pipe,
+drm_private struct fd_ringbuffer * msm_ringbuffer_new(struct fd_pipe *pipe,
uint32_t size);
struct msm_bo {
@@ -79,9 +80,9 @@ static inline struct msm_bo * to_msm_bo(struct fd_bo *x)
return (struct msm_bo *)x;
}
-int msm_bo_new_handle(struct fd_device *dev,
+drm_private int msm_bo_new_handle(struct fd_device *dev,
uint32_t size, uint32_t flags, uint32_t *handle);
-struct fd_bo * msm_bo_from_handle(struct fd_device *dev,
+drm_private struct fd_bo * msm_bo_from_handle(struct fd_device *dev,
uint32_t size, uint32_t handle);
static inline void get_abs_timeout(struct drm_msm_timespec *tv, uint32_t ms)
diff --git a/freedreno/msm/msm_ringbuffer.c b/freedreno/msm/msm_ringbuffer.c
index 6a4043fb..6ee85bdd 100644
--- a/freedreno/msm/msm_ringbuffer.c
+++ b/freedreno/msm/msm_ringbuffer.c
@@ -318,7 +318,7 @@ static struct fd_ringbuffer_funcs funcs = {
.destroy = msm_ringbuffer_destroy,
};
-struct fd_ringbuffer * msm_ringbuffer_new(struct fd_pipe *pipe,
+drm_private struct fd_ringbuffer * msm_ringbuffer_new(struct fd_pipe *pipe,
uint32_t size)
{
struct msm_ringbuffer *msm_ring;