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 12C601FF7B3 for ; Thu, 13 Nov 2025 12:07:36 +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=1763035657; cv=none; b=YWXr+SArabN1g3DpBXXIToS6Jsarh7/RXWtSpTG3avMBiuke4PUz5nnBKvqayvPKD45Ob90qpf6yb3lGjjuDBJwZNQ0tv22axpluCHB9+ujBEtliivnvb+ZYR7duuf/R43ygbmZ1T+KrpOnXmA6Ku+83N/L0/9cwQ0Tcp+PeYso= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763035657; c=relaxed/simple; bh=vzK+e/EERdiP7f4QpvpjeauHoZUwHHPjc798dHm05QE=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=rkHChdOviEMYVqlNU5rgK25DXM6nobq65m2ybKsvoyf7/S7wmyRvK+y/tj/m/udgXAzvysO69KZT7gbS1tfudHHvKwfsKPXjxcgF8SDqgkPmNQutj4L8zeJSBSCKkHsOKsKDnIRPLNSHG8ZdxZyRe75Pf6He3II4R516bL5h+l0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=NQYyO0ey; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="NQYyO0ey" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 76980C4CEF5; Thu, 13 Nov 2025 12:07:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1763035656; bh=vzK+e/EERdiP7f4QpvpjeauHoZUwHHPjc798dHm05QE=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=NQYyO0eyge9WGW2PKiUyuk73zZNfAKP/4yF22e+iiE4+ZoATBpS39Y9dSy2zdmsiE 5Al/pFilhBVSHupdRPoEgD7+yr3QfGDxOVhAV13hBA3SIx51DW5L21QdZBLjuJNGLF Cf+k4Oc+D3yp4Uc0OM9b/cnX2BgbM5DRCBQV3LTA/m1dzn3sKBbXdNgk0x7zmf8qjJ RiO4Xi7c9KsGYXWD+J28jnr1E15IwCizP4Go15vpDP3OtmmbVdtQuuhduY76yMCHRi /tHEDf6lp2icY4aJO1D9P1udVnJPj7rn1ND7/QFKA3WvWT1yb1fmMa7OZ3zTG8BUXE BX7Mh9TSvB/IA== Message-ID: Date: Thu, 13 Nov 2025 13:07:28 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] mm/huge_memory: fix override of entry in remove_migration_pmd To: Lorenzo Stoakes , Balbir Singh Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, dri-devel@lists.freedesktop.org, Andrew Morton , Zi Yan , Joshua Hahn , Rakie Kim , Byungchul Park , Gregory Price , Ying Huang , Alistair Popple , Oscar Salvador , Baolin Wang , "Liam R. Howlett" , Nico Pache , Ryan Roberts , Dev Jain , Barry Song , Lyude Paul , Danilo Krummrich , David Airlie , Simona Vetter , Ralph Campbell , =?UTF-8?Q?Mika_Penttil=C3=A4?= , Matthew Brost , Francois Dugast References: <20251113051352.1753714-1-balbirs@nvidia.com> From: "David Hildenbrand (Red Hat)" Content-Language: en-US In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 13.11.25 12:56, Lorenzo Stoakes wrote: > On Thu, Nov 13, 2025 at 04:13:52PM +1100, Balbir Singh wrote: >> The softleaf changes exposed a BUG in remove_rmap_pmd() where the >> migration entry was being overridden when the folio is device private. >> >> Use scope local entry for creating the device private pmde. Make the >> pmde writable if the migration entry is writable by moving the check >> softleaf_is_migration_write() prior to creating the device private entry. >> >> Cc: Andrew Morton >> Cc: David Hildenbrand >> Cc: Zi Yan >> Cc: Joshua Hahn >> Cc: Rakie Kim >> Cc: Byungchul Park >> Cc: Gregory Price >> Cc: Ying Huang >> Cc: Alistair Popple >> Cc: Oscar Salvador >> Cc: Lorenzo Stoakes >> Cc: Baolin Wang >> Cc: "Liam R. Howlett" >> Cc: Nico Pache >> Cc: Ryan Roberts >> Cc: Dev Jain >> Cc: Barry Song >> Cc: Lyude Paul >> Cc: Danilo Krummrich >> Cc: David Airlie >> Cc: Simona Vetter >> Cc: Ralph Campbell >> Cc: Mika Penttilä >> Cc: Matthew Brost >> Cc: Francois Dugast >> >> Signed-off-by: Balbir Singh > > THe logic LGTM but we don't want to have a bisect hazard here by having the bug > introduced earlier then resolved here. Exactly. -- Cheers David