summaryrefslogtreecommitdiff
path: root/SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch
diff options
context:
space:
mode:
authorSentry <sentry@Sentry-Desktop-Fedora.local>2020-07-14 15:58:43 +0200
committerJan200101 <sentrycraft123@gmail.com>2020-12-05 19:40:07 +0100
commit391fe055c943e33e9c191dbeeb21995c0d54ccd9 (patch)
tree04bbfbe91a73cc0d47c2d70235c8ca365eaa9c3d /SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch
downloadkernel-fsync-391fe055c943e33e9c191dbeeb21995c0d54ccd9.tar.gz
kernel-fsync-391fe055c943e33e9c191dbeeb21995c0d54ccd9.zip
kernel 5.7.8
Diffstat (limited to 'SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch')
-rw-r--r--SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch b/SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch
new file mode 100644
index 0000000..d490d68
--- /dev/null
+++ b/SOURCES/0001-core-memory-remove-redundant-assignments-to-variable.patch
@@ -0,0 +1,32 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Colin Ian King <colin.king@canonical.com>
+Date: Sat, 29 Feb 2020 00:53:07 +0000
+Subject: [PATCH] core/memory: remove redundant assignments to variable ret
+
+The variable ret is being initialized with a value that is never
+read and it is being updated later with a new value. The initialization
+is redundant and can be removed.
+
+Addresses-Coverity: ("Unused value")
+Signed-off-by: Colin Ian King <colin.king@canonical.com>
+Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
+---
+ drivers/gpu/drm/nouveau/nvkm/core/memory.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/gpu/drm/nouveau/nvkm/core/memory.c b/drivers/gpu/drm/nouveau/nvkm/core/memory.c
+index 4cc186262d34..38130ef272d6 100644
+--- a/drivers/gpu/drm/nouveau/nvkm/core/memory.c
++++ b/drivers/gpu/drm/nouveau/nvkm/core/memory.c
+@@ -140,7 +140,7 @@ nvkm_memory_new(struct nvkm_device *device, enum nvkm_memory_target target,
+ {
+ struct nvkm_instmem *imem = device->imem;
+ struct nvkm_memory *memory;
+- int ret = -ENOSYS;
++ int ret;
+
+ if (unlikely(target != NVKM_MEM_TARGET_INST || !imem))
+ return -ENOSYS;
+--
+2.26.2
+