]> 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)
commita8db29c4a37b8f851c7e93d58124548f1f6cc4d5
tree06ca5aae8bfe7f775d3a93db09cd092881b9d637
parent6fce42534fe185af4ee78e9a9b260134dc83b1ed
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