From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 AA1DBCD1288 for ; Sat, 30 Mar 2024 09:20:35 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 37E3F6B0095; Sat, 30 Mar 2024 05:20:35 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 32DF26B0096; Sat, 30 Mar 2024 05:20:35 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1F7256B0098; Sat, 30 Mar 2024 05:20:35 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id F2D566B0095 for ; Sat, 30 Mar 2024 05:20:34 -0400 (EDT) Received: from smtpin24.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id B42D3C122B for ; Sat, 30 Mar 2024 09:20:34 +0000 (UTC) X-FDA: 81953159988.24.5634440 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by imf20.hostedemail.com (Postfix) with ESMTP id CAF4F1C001E for ; Sat, 30 Mar 2024 09:20:32 +0000 (UTC) Authentication-Results: imf20.hostedemail.com; dkim=pass header.d=linuxfoundation.org header.s=korg header.b=ZKG8jrbm; dmarc=pass (policy=none) header.from=linuxfoundation.org; spf=pass (imf20.hostedemail.com: domain of gregkh@linuxfoundation.org designates 145.40.73.55 as permitted sender) smtp.mailfrom=gregkh@linuxfoundation.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1711790433; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:dkim-signature; bh=pPv+AfujqlWobeCDAUWa1YJVD6TGsArHRyv6QnP6A+U=; b=q5aZkwd2YprIvAIn5+z6WLGBrnpBNqcbOs7X3mQNb2h8330YihHz+D0PHfovkph4bACvc0 0/mCzh6F8IrfBekWQY5iRKioE/l7grvelqPPPpLh7NC5/9kVKJ+CMtb0vpLaC46HlVWrXy bozuIYzkZlYNLOLGAjzGH/lhkrhohsA= ARC-Authentication-Results: i=1; imf20.hostedemail.com; dkim=pass header.d=linuxfoundation.org header.s=korg header.b=ZKG8jrbm; dmarc=pass (policy=none) header.from=linuxfoundation.org; spf=pass (imf20.hostedemail.com: domain of gregkh@linuxfoundation.org designates 145.40.73.55 as permitted sender) smtp.mailfrom=gregkh@linuxfoundation.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1711790433; a=rsa-sha256; cv=none; b=gyURqNkvrew3Md5RBwnHHyYiJPGjx0u9FxEE8GPZEyB9IjKW92qJPNdu8hUy73BSD6+CN8 7Pn3KEIwWZ1RnJ8So4WEkTBzbGAcYs09VdM8/nEevR2u2T0dU3lVLg8orgtv4V9Fxa8+yS AaoZYsEX20i9kg9NOMNgR9kexelH/RA= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id 2E1E4CE01BC; Sat, 30 Mar 2024 09:20:30 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 11DD1C433C7; Sat, 30 Mar 2024 09:20:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1711790429; bh=rvtMv5S9OsFyyGmoBrFbWSbL+b73tu5WLTyZV2FTGfA=; h=Subject:To:Cc:From:Date:In-Reply-To:From; b=ZKG8jrbmDBYjzURr/UkOvjN9YjyJvByEwSsVqetFFDC4YGnnGSlmUhDcIKo31Cbjz HzhTG+fjRPsX5vQYQcc7N+uLUlvVXeeN14qYEgE84vDr2U44cyPo5muSNhEGfI8H3O kJu0k4RvZzbD7KCC1zZ7/JgWoqdwNWfdxLLVkYpY= Subject: Patch "mm/memory-failure: fix an incorrect use of tail pages" has been added to the 5.4-stable tree To: akpm@linux-foundation.org,dan.j.williams@intel.com,gregkh@linuxfoundation.org,linux-mm@kvack.org,liushixin2@huawei.com,n-horiguchi@ah.jp.nec.com,sashal@kernel.org,willy@infradead.org Cc: From: Date: Sat, 30 Mar 2024 10:20:20 +0100 In-Reply-To: <20240307125053.2847205-1-liushixin2@huawei.com> Message-ID: <2024033020-encourage-expansive-4395@gregkh> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit X-stable: commit X-Patchwork-Hint: ignore X-Rspam-User: X-Stat-Signature: xn5p7yd41ecotiqgrx58gajrxdx5hdgt X-Rspamd-Server: rspam07 X-Rspamd-Queue-Id: CAF4F1C001E X-HE-Tag: 1711790432-109358 X-HE-Meta: U2FsdGVkX1+MeTpgiyISYMtgU8tXqhEzG2uIW4PRPbgFFCRKim5ABb+o2mb6LBUnna9j6PRbY0wW7jyNdYkXWukLRsOorqWitxrWQnEsXS8F+KR/mfUztX2v95apDHWbn1alLWzVkKTbpwmDD93ZfO9g+V6fcw02yuQ5IsUX8R/V/OPRbjLSKLBq8QSjNbT+Ifswj/FvqaFU5B2keDBSNXT93I7imElodUTQBo9mXdo7pi9oYLrCgB14I3fR1AOsenAfq/L+SfurXHhOSqkLNDAMOD70rP++q3y3xQDTtV6ltods9GLjEgAAxEwlIBaLmU3TviBBqXLuUd1Kbf7GKpMOlChnTq31XdbfYuWnATVOoquKrAGflHsZKtd4EZNJzytSCLGKPNfiX0ux+OOXefuoGUvRtgOqAtG5DFHPDoDxanYDHz/8uAqYztFj525SX6vQK5XTKIHyXaRwA4oZ7GkH70u2mjRMrYQQLvSLG2u+lP+O73WJJcZh17FBUlV5mXnJAz8F77ZMkiW8VzwZpDs/Da5bsP78rY59ioPTaUq6uKfqyuFsxFp9kkmfwDX+pMFtflrmnpOaiJjCq2LVY2LqTGAhBLfJELUpEpe9bCH3GSAhqvy/xkn9+eEL5Ot6OwZwdbi0Vtwb7YKTk0o1IHoeAfEQWG4SxsLbrGVHcitlw2Iub+2yJhXVNVBM1jXDu9sITjo2W2ePlOXFcBDwbq9KL9irH/YysBKBemOWViihKYiARy/CwQLIgIM3nv0bVfdbKr+jSyPw7Z6qUgjAgoaZv9+KHNaPiv0PSCsNIm5UHMR4sb6/kHq8F3u7T4W4EavwdMMhPKdlOFW8f5WL5nkOvQuE2+3grBlle7f8dKBsF1tRlbojjBgXN+k/44mWjl0ATNXl4wN4XiARE0CYLYeniBC290HJ 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: List-Subscribe: List-Unsubscribe: This is a note to let you know that I've just added the patch titled mm/memory-failure: fix an incorrect use of tail pages to the 5.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: mm-memory-failure-fix-an-incorrect-use-of-tail-pages.patch and it can be found in the queue-5.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >From liushixin2@huawei.com Sat Mar 30 10:11:30 2024 From: Liu Shixin Date: Thu, 7 Mar 2024 20:50:53 +0800 Subject: mm/memory-failure: fix an incorrect use of tail pages To: Matthew Wilcox , Andrew Morton , Sasha Levin , Dan Williams , Naoya Horiguchi Cc: , , , Liu Shixin Message-ID: <20240307125053.2847205-1-liushixin2@huawei.com> From: Liu Shixin When backport commit c79c5a0a00a9 to 5.4-stable, there is a mistake change. The head page instead of tail page should be passed to try_to_unmap(), otherwise unmap will failed as follows. Memory failure: 0x121c10: failed to unmap page (mapcount=1) Memory failure: 0x121c10: recovery action for unmapping failed page: Ignored Fixes: 85015a96bc24 ("mm/memory-failure: check the mapcount of the precise page") Signed-off-by: Liu Shixin Signed-off-by: Greg Kroah-Hartman --- mm/memory-failure.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/mm/memory-failure.c +++ b/mm/memory-failure.c @@ -1030,7 +1030,7 @@ static bool hwpoison_user_mappings(struc if (kill) collect_procs(hpage, &tokill, flags & MF_ACTION_REQUIRED); - unmap_success = try_to_unmap(p, ttu); + unmap_success = try_to_unmap(hpage, ttu); if (!unmap_success) pr_err("Memory failure: %#lx: failed to unmap page (mapcount=%d)\n", pfn, page_mapcount(p)); Patches currently in stable-queue which might be from liushixin2@huawei.com are queue-5.4/mm-memory-failure-fix-an-incorrect-use-of-tail-pages.patch