]> git.baikalelectronics.ru Git - kernel.git/commit
drm/nouveau/pmu/gm20b,gp10b: Fix Falcon bootstrapping
authorThierry Reding <treding@nvidia.com>
Wed, 15 Jan 2020 14:06:13 +0000 (15:06 +0100)
committerBen Skeggs <bskeggs@redhat.com>
Wed, 22 Jan 2020 22:56:51 +0000 (08:56 +1000)
commit039b3e66bdce71c1c2f09053dadb9182fc02ae0f
tree3c9759ba958adc9c85befd79f106105e1a7c1f08
parent4f4395256d2717fa33eba128fa4f92091632dff9
drm/nouveau/pmu/gm20b,gp10b: Fix Falcon bootstrapping

The low-level Falcon bootstrapping callbacks are expected to return 0 on
success or a negative error code on failure. However, the implementation
on Tegra returns the ID or mask of the Falcons that were bootstrapped on
success, thus breaking the calling code, which treats this as failure.

Fix this by making sure we only return 0 or a negative error code, just
like the code for discrete GPUs does.

Fixes: 062b2e0490a4 ("drm/nouveau/flcn/cmdq: move command generation to subdevs")
Signed-off-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gm20b.c
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp10b.c