drm/amdkfd: Use correct major in devcgroup check
authorLorenz Brun <lorenz@brun.one>
Thu, 11 Jun 2020 20:11:21 +0000 (22:11 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 1 Jul 2020 05:59:21 +0000 (01:59 -0400)
commit7159562a1622806d1f37fa73e83463fa1a240f66
tree170f203e399c8b8f9c4c92e1e6079b9a38c33a73
parent54e7ebf9af39e7a8f61a0723af75a5954b82a8cc
drm/amdkfd: Use correct major in devcgroup check

The existing code used the major version number of the DRM driver
instead of the device major number of the DRM subsystem for
validating access for a devices cgroup.

This meant that accesses allowed by the devices cgroup weren't
permitted and certain accesses denied by the devices cgroup were
permitted (if they matched the wrong major device number).

Signed-off-by: Lorenz Brun <lorenz@brun.one>
Fixes: 6b855f7b83d2f ("drm/amdkfd: Check against device cgroup")
Reviewed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_priv.h