aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArnd Bergmann <[email protected]>2023-01-26 17:37:55 +0100
committerThomas Zimmermann <[email protected]>2023-02-01 11:20:17 +0100
commit4739e893a1f3cde2790946b8a7e6c2c3d8680054 (patch)
treee902e84fbca0d4315da95b10dc0c9f0b16be0d04
parent9f20c9f4b1e17e83e9ccc247cfdc0b61041bff3d (diff)
accel/ivpu: avoid duplicate assignment
With extra warnings enabled, gcc warns about two assignments of the same .mmap callback: In file included from drivers/accel/ivpu/ivpu_drv.c:10: include/drm/drm_accel.h:31:27: error: initialized field overwritten [-Werror=override-init] 31 | .mmap = drm_gem_mmap | ^~~~~~~~~~~~ drivers/accel/ivpu/ivpu_drv.c:360:9: note: in expansion of macro 'DRM_ACCEL_FOPS' 360 | DRM_ACCEL_FOPS, | ^~~~~~~~~~~~~~ Remove the unused local assignment. Fixes: e868cc591e89 ("accel: Add .mmap to DRM_ACCEL_FOPS") Signed-off-by: Arnd Bergmann <[email protected]> Reviewed-by: Jeffrey Hugo <[email protected]> Signed-off-by: Jacek Lawrynowicz <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] (cherry picked from commit 918b8f7eeea1c9f7f54b3d8ea74e8c6fa68e5a9d) Signed-off-by: Thomas Zimmermann <[email protected]>
-rw-r--r--drivers/accel/ivpu/ivpu_drv.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/accel/ivpu/ivpu_drv.c b/drivers/accel/ivpu/ivpu_drv.c
index 2bc2f1b90671..a29e8ee0dce6 100644
--- a/drivers/accel/ivpu/ivpu_drv.c
+++ b/drivers/accel/ivpu/ivpu_drv.c
@@ -356,7 +356,6 @@ int ivpu_shutdown(struct ivpu_device *vdev)
static const struct file_operations ivpu_fops = {
.owner = THIS_MODULE,
- .mmap = drm_gem_mmap,
DRM_ACCEL_FOPS,
};