diff options
author | Arnd Bergmann <arnd@arndb.de> | 2018-12-11 00:51:04 +0300 |
---|---|---|
committer | Thierry Reding <treding@nvidia.com> | 2019-02-04 10:35:54 +0300 |
commit | 0747a672a32829809675028ba396f394b104ee31 (patch) | |
tree | 2b77877421b339cc552c12df7ae9ce23009bfead /drivers/gpu/host1x/cdma.h | |
parent | db5adf4d6dced4e3326ce369fe0c213c968095f4 (diff) | |
download | linux-0747a672a32829809675028ba396f394b104ee31.tar.xz |
gpu: host1x: Use completion instead of semaphore
In this usage, the two are completely equivalent, but the completion
documents better what is going on, and we generally try to avoid
semaphores these days.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/gpu/host1x/cdma.h')
-rw-r--r-- | drivers/gpu/host1x/cdma.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/host1x/cdma.h b/drivers/gpu/host1x/cdma.h index e97e17b82370..71078359c626 100644 --- a/drivers/gpu/host1x/cdma.h +++ b/drivers/gpu/host1x/cdma.h @@ -20,7 +20,7 @@ #define __HOST1X_CDMA_H #include <linux/sched.h> -#include <linux/semaphore.h> +#include <linux/completion.h> #include <linux/list.h> struct host1x_syncpt; @@ -69,8 +69,8 @@ enum cdma_event { struct host1x_cdma { struct mutex lock; /* controls access to shared state */ - struct semaphore sem; /* signalled when event occurs */ - enum cdma_event event; /* event that sem is waiting for */ + struct completion complete; /* signalled when event occurs */ + enum cdma_event event; /* event that complete is waiting for */ unsigned int slots_used; /* pb slots used in current submit */ unsigned int slots_free; /* pb slots free in current submit */ unsigned int first_get; /* DMAGET value, where submit begins */ |