]> git.baikalelectronics.ru Git - kernel.git/commit
drm/nouveau/drm/nouveau/mmu: fix odd_ptr_err.cocci warnings
authorChristoph Böhmwalder <christoph@boehmwalder.at>
Thu, 30 Nov 2017 19:53:54 +0000 (20:53 +0100)
committerBen Skeggs <bskeggs@redhat.com>
Fri, 2 Feb 2018 05:24:03 +0000 (15:24 +1000)
commite867f2796bb206c57b784a26db97e3ba86c5c3e2
tree06ca5aae8bfe7f775d3a93db09cd092881b9d637
parent194ff8bea0c5a0f6d43b050205540cf59852a2fe
drm/nouveau/drm/nouveau/mmu: fix odd_ptr_err.cocci warnings

The kbuild test bot complained about a new coccinelle warning nearby,
which sparked a discussion about the assignment to 'memory' inside of
the conditional expression.  See Link below for the original post.

Fix the assignment to silence the coccinelle warning and also make the
code look a little nicer.

Link: https://lists.freedesktop.org/archives/nouveau/2017-November/029242.html
Signed-off-by: Christoph Böhmwalder <christoph@boehmwalder.at>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
drivers/gpu/drm/nouveau/nvkm/subdev/mmu/uvmm.c