Re: [PATCH 1/3] mm/migrate: add might_sleep() on __migrate_folio()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 30 Mar 2025, Matthew Wilcox wrote:

We deliberately don't sleep when the folio is only a single page.
So this needs to be:

	might_sleep_if(folio_test_large(folio));

Along with willy's suggestion:

Acked-by: Davidlohr Bueso <dave@xxxxxxxxxxxx>

... and the same rules apply for copy_folio():

fs/aio.c: atomic context but no large folio: safe

fs/fuse/file.c: no large folio: safe

fs/nilfs2/page.c: blocking safe, has large folio: safe

mm/migrate_device.c: no large folio: safe

mm/shmem.c: blocking safe, has large folio: safe
shmem_replace_folio() could use a might_sleep() I guess.

Thanks,
Davidlohr




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux