Skip to contentSkip to conversation

hugetlbfs: check for shareable lock before calling huge_pmd_unshare()

PATCH Deepanshu Kartikey 3 participants 4 messages Oct 13, 2025 Memory management

lore
Share & tools
lore
#0 lore raw

Hi David,

That makes a lot of sense - moving the assertions after the early return checks is cleaner since the locks are only needed when actual unsharing work happens.

Should I send a v5 with your suggested change?

Thanks,
Deepanshu

#1 lore raw
Quoted 7 lines · Deepanshu Kartikey

Hi David,

That makes a lot of sense - moving the assertions after the early return checks is cleaner since the locks are only needed when actual unsharing work happens.

Should I send a v5 with your suggested change?

Let's wait if the hugetlb maintainers have any preference.

Signature · 3 lines
Cheers

David / dhildenb
#2 lore raw
Quoted 10 lines · David Hildenbrand
Quoted 7 lines · Deepanshu Kartikey

Hi David,

That makes a lot of sense - moving the assertions after the early return checks is cleaner since the locks are only needed when actual unsharing work happens.

Should I send a v5 with your suggested change?

Let's wait if the hugetlb maintainers have any preference.

Yes, now that I look again I think your suggestion makes more sense and its much cleaner :-)

Signature · 2 lines
Oscar Salvador
SUSE Labs
#3 lore raw

Hi Oscar and David,

Since I've been working through the iterations on this fix, would it be okay if I send v5 with David's suggested change? I'd like to see this through to completion.

Thanks,
Deepanshu