Message ID | 20220428083441.37290-2-david@redhat.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 109F6C433F5 for <linux-mm@archiver.kernel.org>; Thu, 28 Apr 2022 08:35:00 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7D14B6B0072; Thu, 28 Apr 2022 04:35:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 77DE06B0073; Thu, 28 Apr 2022 04:35:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 61F216B0075; Thu, 28 Apr 2022 04:35:00 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.28]) by kanga.kvack.org (Postfix) with ESMTP id 5531E6B0072 for <linux-mm@kvack.org>; Thu, 28 Apr 2022 04:35:00 -0400 (EDT) Received: from smtpin30.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay12.hostedemail.com (Postfix) with ESMTP id 303F4121A9A for <linux-mm@kvack.org>; Thu, 28 Apr 2022 08:35:00 +0000 (UTC) X-FDA: 79405627560.30.9E9542D Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf03.hostedemail.com (Postfix) with ESMTP id BAF5020047 for <linux-mm@kvack.org>; Thu, 28 Apr 2022 08:34:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1651134899; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=5pSN8cSMrlmjclRV6stF62mOsP7NodWWP1XDBAD+Ds0=; b=YrlgUHvfvLbnT1G9oF/1IRxTtq7sQM1GsGY4IGAgx/P8s5BqoYchsMX3HTubFn25Afi/38 Wi4WnXSV+CHd9wap8xRGoVZ9sEMvqtv+Z3DwGycPydc/8rRKDwtzhi+x4V+Roa70ubKcnP rL3/WQsN2VG6ZVSq+q7yUdSZU15Lk4w= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-593-q-wuszA3OCyEKrkEfmaaDQ-1; Thu, 28 Apr 2022 04:34:54 -0400 X-MC-Unique: q-wuszA3OCyEKrkEfmaaDQ-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id CCF4E833966; Thu, 28 Apr 2022 08:34:53 +0000 (UTC) Received: from t480s.redhat.com (unknown [10.39.194.113]) by smtp.corp.redhat.com (Postfix) with ESMTP id C6611566A27; Thu, 28 Apr 2022 08:34:48 +0000 (UTC) From: David Hildenbrand <david@redhat.com> To: linux-kernel@vger.kernel.org Cc: Andrew Morton <akpm@linux-foundation.org>, Hugh Dickins <hughd@google.com>, Linus Torvalds <torvalds@linux-foundation.org>, David Rientjes <rientjes@google.com>, Shakeel Butt <shakeelb@google.com>, John Hubbard <jhubbard@nvidia.com>, Jason Gunthorpe <jgg@nvidia.com>, Mike Kravetz <mike.kravetz@oracle.com>, Mike Rapoport <rppt@linux.ibm.com>, Yang Shi <shy828301@gmail.com>, "Kirill A . Shutemov" <kirill.shutemov@linux.intel.com>, Matthew Wilcox <willy@infradead.org>, Vlastimil Babka <vbabka@suse.cz>, Jann Horn <jannh@google.com>, Michal Hocko <mhocko@kernel.org>, Nadav Amit <namit@vmware.com>, Rik van Riel <riel@surriel.com>, Roman Gushchin <guro@fb.com>, Andrea Arcangeli <aarcange@redhat.com>, Peter Xu <peterx@redhat.com>, Donald Dutile <ddutile@redhat.com>, Christoph Hellwig <hch@lst.de>, Oleg Nesterov <oleg@redhat.com>, Jan Kara <jack@suse.cz>, Liang Zhang <zhangliang5@huawei.com>, Pedro Gomes <pedrodemargomes@gmail.com>, Oded Gabbay <oded.gabbay@gmail.com>, linux-mm@kvack.org, David Hildenbrand <david@redhat.com>, Khalid Aziz <khalid.aziz@oracle.com> Subject: [PATCH v4 01/17] mm/rmap: fix missing swap_free() in try_to_unmap() after arch_unmap_one() failed Date: Thu, 28 Apr 2022 10:34:25 +0200 Message-Id: <20220428083441.37290-2-david@redhat.com> In-Reply-To: <20220428083441.37290-1-david@redhat.com> References: <20220428083441.37290-1-david@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.85 on 10.11.54.9 X-Rspam-User: X-Rspamd-Server: rspam11 X-Rspamd-Queue-Id: BAF5020047 X-Stat-Signature: 37hjmb6iigm9qrp4g8fmfwc68mnyrdbx Authentication-Results: imf03.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=YrlgUHvf; spf=none (imf03.hostedemail.com: domain of david@redhat.com has no SPF policy when checking 170.10.129.124) smtp.mailfrom=david@redhat.com; dmarc=pass (policy=none) header.from=redhat.com X-HE-Tag: 1651134895-251747 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
mm: COW fixes part 2: reliable GUP pins of anonymous pages
|
expand
|
diff --git a/mm/rmap.c b/mm/rmap.c index fedb82371efe..eb246fc8b089 100644 --- a/mm/rmap.c +++ b/mm/rmap.c @@ -1637,6 +1637,7 @@ static bool try_to_unmap_one(struct folio *folio, struct vm_area_struct *vma, break; } if (arch_unmap_one(mm, vma, address, pteval) < 0) { + swap_free(entry); set_pte_at(mm, address, pvmw.pte, pteval); ret = false; page_vma_mapped_walk_done(&pvmw);