gpu: host1x: Refactor channel allocation code
authorMikko Perttunen <mperttunen@nvidia.com>
Wed, 14 Jun 2017 23:18:42 +0000 (02:18 +0300)
committerThierry Reding <treding@nvidia.com>
Thu, 15 Jun 2017 12:25:38 +0000 (14:25 +0200)
commit8474b02531c4881a762c52ef869c52429e38633f
tree41cdb37fa4e424170bd7670e07ca0981c9f6c81f
parent03f0de770eda7a3f2e3950ca9f15d73e1dfd4596
gpu: host1x: Refactor channel allocation code

This is largely a rewrite of the Host1x channel allocation code, bringing
several changes:

- The previous code could deadlock due to an interaction
  between the 'reflock' mutex and CDMA timeout handling.
  This gets rid of the mutex.
- Support for more than 32 channels, required for Tegra186
- General refactoring, including better encapsulation
  of channel ownership handling into channel.c

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Reviewed-by: Dmitry Osipenko <digetx@gmail.com>
Tested-by: Dmitry Osipenko <digetx@gmail.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
drivers/gpu/drm/tegra/gr2d.c
drivers/gpu/drm/tegra/gr3d.c
drivers/gpu/drm/tegra/vic.c
drivers/gpu/host1x/channel.c
drivers/gpu/host1x/channel.h
drivers/gpu/host1x/debug.c
drivers/gpu/host1x/dev.c
drivers/gpu/host1x/dev.h
drivers/gpu/host1x/hw/channel_hw.c
include/linux/host1x.h