mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 10:34:43 +03:00
gpu: nvgpu: make os_fence_android_syncpt common
The differences between sync_fence ("android sync") and dma_fence are
abstracted away by nvhost in the nvhost_fence interface. There is no
need to have separate android and dma os fences for syncpoints; unify
the general implementation so that it's always used when requested for
the build.
Jira NVGPU-5386
Change-Id: Ia829e93e18d03064ff46ab1271547de2d1fb1cae
Signed-off-by: Konsta Hölttä <kholtta@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2356158
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
Alex Waterman
parent
4e241d5974
commit
98335c29b2
@@ -20,6 +20,8 @@
|
||||
#include <nvgpu/channel.h>
|
||||
#include <nvgpu/nvhost.h>
|
||||
|
||||
#include "os_fence_priv.h"
|
||||
|
||||
#include "../drivers/staging/android/sync.h"
|
||||
|
||||
inline struct sync_fence *nvgpu_get_sync_fence(struct nvgpu_os_fence *s)
|
||||
@@ -28,22 +30,6 @@ inline struct sync_fence *nvgpu_get_sync_fence(struct nvgpu_os_fence *s)
|
||||
return fence;
|
||||
}
|
||||
|
||||
static void nvgpu_os_fence_clear(struct nvgpu_os_fence *fence_out)
|
||||
{
|
||||
fence_out->priv = NULL;
|
||||
fence_out->g = NULL;
|
||||
fence_out->ops = NULL;
|
||||
}
|
||||
|
||||
void nvgpu_os_fence_init(struct nvgpu_os_fence *fence_out,
|
||||
struct gk20a *g, const struct nvgpu_os_fence_ops *fops,
|
||||
void *fence)
|
||||
{
|
||||
fence_out->g = g;
|
||||
fence_out->ops = fops;
|
||||
fence_out->priv = fence;
|
||||
}
|
||||
|
||||
void nvgpu_os_fence_android_drop_ref(struct nvgpu_os_fence *s)
|
||||
{
|
||||
struct sync_fence *fence = nvgpu_get_sync_fence(s);
|
||||
|
||||
Reference in New Issue
Block a user