On 11/13/25 23:07, David Hildenbrand (Red Hat) wrote:
> 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 <[email protected]>
>>> Cc: David Hildenbrand <[email protected]>
>>> Cc: Zi Yan <[email protected]>
>>> Cc: Joshua Hahn <[email protected]>
>>> Cc: Rakie Kim <[email protected]>
>>> Cc: Byungchul Park <[email protected]>
>>> Cc: Gregory Price <[email protected]>
>>> Cc: Ying Huang <[email protected]>
>>> Cc: Alistair Popple <[email protected]>
>>> Cc: Oscar Salvador <[email protected]>
>>> Cc: Lorenzo Stoakes <[email protected]>
>>> Cc: Baolin Wang <[email protected]>
>>> Cc: "Liam R. Howlett" <[email protected]>
>>> Cc: Nico Pache <[email protected]>
>>> Cc: Ryan Roberts <[email protected]>
>>> Cc: Dev Jain <[email protected]>
>>> Cc: Barry Song <[email protected]>
>>> Cc: Lyude Paul <[email protected]>
>>> Cc: Danilo Krummrich <[email protected]>
>>> Cc: David Airlie <[email protected]>
>>> Cc: Simona Vetter <[email protected]>
>>> Cc: Ralph Campbell <[email protected]>
>>> Cc: Mika Penttilä <[email protected]>
>>> Cc: Matthew Brost <[email protected]>
>>> Cc: Francois Dugast <[email protected]>
>>>
>>> Signed-off-by: Balbir Singh <[email protected]>
>>
>> THe logic LGTM but we don't want to have a bisect hazard here by having the 
>> bug
>> introduced earlier then resolved here.
> 
> Exactly.
> 

The hazard is a VM_WARN_ON() that checks for is_migration_entry() in the
call to softleaf_is_migration_young(). I am happy to go down that path,
let me send out the fixups, it felt weird to break the rebase, but I
am sure Andrew has a better way of dealing with this stuff.

Balbir

Reply via email to