Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
Qubes Linux Kernel
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Third Party
Qubes Linux Kernel
Commits
6db73aa1
Unverified
Commit
6db73aa1
authored
4 years ago
by
Marek Marczykowski-Górecki
Browse files
Options
Downloads
Patches
Plain Diff
Drop patch included upstream already
parent
4f4b12f4
Branches
Branches containing commit
Tags
v5.12.5-1-latest
Tags containing commit
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
0001-xen-gntdev-fix-gntdev_mmap-error-exit-path.patch
+0
-43
0 additions, 43 deletions
0001-xen-gntdev-fix-gntdev_mmap-error-exit-path.patch
kernel.spec.in
+0
-1
0 additions, 1 deletion
kernel.spec.in
with
0 additions
and
44 deletions
0001-xen-gntdev-fix-gntdev_mmap-error-exit-path.patch
deleted
100644 → 0
+
0
−
43
View file @
4f4b12f4
From 7ff3c32b36279aacef9cf80f4103fc6050759c10 Mon Sep 17 00:00:00 2001
From: Juergen Gross <jgross@suse.com>
Date: Mon, 19 Apr 2021 11:15:59 +0200
Subject: [PATCH] xen/gntdev: fix gntdev_mmap() error exit path
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Commit d3eeb1d77c5d0af ("xen/gntdev: use mmu_interval_notifier_insert")
introduced an error in gntdev_mmap(): in case the call of
mmu_interval_notifier_insert_locked() fails the exit path should not
call mmu_interval_notifier_remove().
One reason for failure is e.g. a signal pending for the running
process.
Fixes: d3eeb1d77c5d0af ("xen/gntdev: use mmu_interval_notifier_insert")
Cc: stable@vger.kernel.org
Reported-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Signed-off-by: Juergen Gross <jgross@suse.com>
---
drivers/xen/gntdev.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c
index f01d58c7a042..a3e7be96527d 100644
--- a/drivers/xen/gntdev.c
+++ b/drivers/xen/gntdev.c
@@ -1017,8 +1017,10 @@
static int gntdev_mmap(struct file *flip, struct vm_area_struct *vma)
err = mmu_interval_notifier_insert_locked(
&map->notifier, vma->vm_mm, vma->vm_start,
vma->vm_end - vma->vm_start, &gntdev_mmu_ops);
- if (err)
+ if (err) {
+ map->vma = NULL;
goto out_unlock_put;
+ }
}
mutex_unlock(&priv->lock);
--
2.26.2
This diff is collapsed.
Click to expand it.
kernel.spec.in
+
0
−
1
View file @
6db73aa1
...
...
@@ -135,7 +135,6 @@ Patch9: 0010-xen-netfront-add-range-check-for-Tx-response-id.patch
Patch10: 0011-xen-blkfront-make-local-copy-of-response-before-usin.patch
Patch11: 0012-xen-blkfront-prepare-request-locally-only-then-put-i.patch
Patch12: 0013-xen-pcifront-pciback-Update-pciif.h-with-err-and-res.patch
Patch13: 0001-xen-gntdev-fix-gntdev_mmap-error-exit-path.patch
Patch14: 0001-Revert-xen-netback-Check-for-hotplug-status-existenc.patch
Patch15: 0002-Revert-xen-netback-remove-hotplug-status-once-it-has.patch
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment