From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 681B826ED58 for ; Sat, 20 Dec 2025 23:13:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766272384; cv=none; b=ugYEcEG5T69b2nLtTWuRv2HQ1q1V1k9KssmG8Q6XTp7w3dWYY4K2dsdi+PNNo/ZxoT3kcJupM5p9HRKQP/PBc7PEY39H4Psl1AWZMiQEZKEPL2ryoJZdIfQtjJ1p1eIJcVfBr/Xq7JDDmUtGVPze5snY9YSUGS2mmafdVOKUzEM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766272384; c=relaxed/simple; bh=+7nk84yUjtX0ynkF4hQkbgTB2Rrscujd1NJooTAi6Fk=; h=Date:From:To:Cc:Subject:Message-Id:In-Reply-To:References: Mime-Version:Content-Type; b=PjHK58/Qon5XZujJsvmuOkvXd2r8LX5xlDLnf8z/FUI+YBVmX7BJNRwFvXB2bu+vF92tPpLeA07YkmB+r5rWfsc/Xsjq/bpNnuDG2FExqm+C/a+mu8lh5cVVcwDzkVXIXIeCXXpYD+2rRwpbU5urZAEjtlrzrwjgAw+7OGHSF3I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=BlYuQm38; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="BlYuQm38" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6AD70C4CEF5; Sat, 20 Dec 2025 23:13:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1766272382; bh=+7nk84yUjtX0ynkF4hQkbgTB2Rrscujd1NJooTAi6Fk=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=BlYuQm3812gsBx6WgmIHXDSpCZ/iX8xx22AT56+umZu8ZkqhIZPTwLJwb7V6G5qiD L+7XZcPOKLjYNCGMq++4T+bFyPwQDPnElMgJ0L5wCsx3P467qtD3E4q1Y7IPUEoQDb V2GxbT9DwYeI4/RhpO6vZ6yCApk8BAck6+8vMZLQ= Date: Sat, 20 Dec 2025 15:13:01 -0800 From: Andrew Morton To: Jane Chu Cc: muchun.song@linux.dev, osalvador@suse.de, david@kernel.org, linmiaohe@huawei.com, jiaqiyan@google.com, william.roche@oracle.com, rientjes@google.com, lorenzo.stoakes@oracle.com, Liam.Howlett@Oracle.com, rppt@kernel.org, surenb@google.com, mhocko@suse.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm/memory-failure: teach kill_accessing_process to accept hugetlb tail page pfn Message-Id: <20251220151301.b0ec3c1aa6527b0b1bca1e4c@linux-foundation.org> In-Reply-To: <20251219062819.2499399-1-jane.chu@oracle.com> References: <20251219062819.2499399-1-jane.chu@oracle.com> X-Mailer: Sylpheed 3.8.0beta1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Thu, 18 Dec 2025 23:28:19 -0700 Jane Chu wrote: > When a hugetlb folio is being poisoned again, try_memory_failure_hugetlb() > passed head pfn to kill_accessing_process(), that is not right. > The precise pfn of the poisoned page should be used in order to > determine the precise vaddr as the SIGBUS payload. > > This issue has already been taken care of in the normal path, that is, > hwpoison_user_mappings(), see [1][2]. Further more, for [3] to work > correctly in the hugetlb repoisoning case, it's essential to inform > VM the precise poisoned page, not the head page. This conflicts with your "mm/memory-failure: fix missing ->mf_stats count in hugetlb poison". Also conflicts a bit with "mm: fixup pfnmap memory failure handling to use pgoff" but that one isn't cc:stable, so this patch (which *is* cc:stable) takes priority. Help?