From: Andrew Morton <akpm@linux-foundation.org>
To: mm-commits@vger.kernel.org, peterx@redhat.com,
dan.carpenter@linaro.org, axelrasmussen@google.com,
hughd@google.com, akpm@linux-foundation.org
Subject: [merged mm-stable] mm-userfaultfd-add-new-uffdio_poison-ioctl-fix.patch removed from -mm tree
Date: Fri, 11 Aug 2023 15:59:54 -0700 [thread overview]
Message-ID: <20230811225955.2273EC433C7@smtp.kernel.org> (raw)
The quilt patch titled
Subject: mm: userfaultfd: add new UFFDIO_POISON ioctl: fix
has been removed from the -mm tree. Its filename was
mm-userfaultfd-add-new-uffdio_poison-ioctl-fix.patch
This patch was dropped because it was merged into the mm-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
------------------------------------------------------
From: Hugh Dickins <hughd@google.com>
Subject: mm: userfaultfd: add new UFFDIO_POISON ioctl: fix
Date: Tue, 11 Jul 2023 18:27:17 -0700 (PDT)
Smatch has observed that pte_offset_map_lock() is now allowed to fail, and
then ptl should not be unlocked. Use -EAGAIN here like elsewhere.
Link: https://lkml.kernel.org/r/bc7bba61-d34f-ad3a-ccf1-c191585ef851@google.com
Signed-off-by: Hugh Dickins <hughd@google.com>
Reviewed-by: Axel Rasmussen <axelrasmussen@google.com>
Cc: Dan Carpenter <dan.carpenter@linaro.org>
Cc: Peter Xu <peterx@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/userfaultfd.c | 4 ++++
1 file changed, 4 insertions(+)
--- a/mm/userfaultfd.c~mm-userfaultfd-add-new-uffdio_poison-ioctl-fix
+++ a/mm/userfaultfd.c
@@ -300,7 +300,10 @@ static int mfill_atomic_pte_poison(pmd_t
spinlock_t *ptl;
_dst_pte = make_pte_marker(PTE_MARKER_POISONED);
+ ret = -EAGAIN;
dst_pte = pte_offset_map_lock(dst_mm, dst_pmd, dst_addr, &ptl);
+ if (!dst_pte)
+ goto out;
if (mfill_file_over_size(dst_vma, dst_addr)) {
ret = -EFAULT;
@@ -319,6 +322,7 @@ static int mfill_atomic_pte_poison(pmd_t
ret = 0;
out_unlock:
pte_unmap_unlock(dst_pte, ptl);
+out:
return ret;
}
_
Patches currently in -mm which might be from hughd@google.com are
reply other threads:[~2023-08-11 23:01 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230811225955.2273EC433C7@smtp.kernel.org \
--to=akpm@linux-foundation.org \
--cc=axelrasmussen@google.com \
--cc=dan.carpenter@linaro.org \
--cc=hughd@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mm-commits@vger.kernel.org \
--cc=peterx@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.