Mesa (master): turnip: drop dead close(master_fd)
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Apr 26 10:27:06 UTC 2019
Module: Mesa
Branch: master
Commit: 1a9367c13455e6ecff39ec04351d557cf5cf59e4
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=1a9367c13455e6ecff39ec04351d557cf5cf59e4
Author: Emil Velikov <emil.velikov at collabora.com>
Date: Fri Apr 19 11:47:34 2019 +0100
turnip: drop dead close(master_fd)
The fd is -1, thus the block of if (fd != -1) close(fd) is dead code.
Cc: Chad Versace <chadversary at chromium.org>
Reviewed-by: Chia-I Wu <olvaffe at gmail.com>
Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
---
src/freedreno/vulkan/tu_device.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/src/freedreno/vulkan/tu_device.c b/src/freedreno/vulkan/tu_device.c
index c7f4d0b26eb..1268624bd8d 100644
--- a/src/freedreno/vulkan/tu_device.c
+++ b/src/freedreno/vulkan/tu_device.c
@@ -198,8 +198,6 @@ tu_physical_device_init(struct tu_physical_device *device,
if (strcmp(version->name, "msm")) {
drmFreeVersion(version);
- if (master_fd != -1)
- close(master_fd);
close(fd);
return vk_errorf(instance, VK_ERROR_INCOMPATIBLE_DRIVER,
"device %s does not use the msm kernel driver", path);
More information about the mesa-commit
mailing list