Re: [PATCH] fs/buffer: adjust the order of might_sleep() in __getblk_gfp()

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

 



>On Thu, Mar 23, 2023 at 05:37:52PM +0800, gouhao@xxxxxxxxxxxxx wrote:
>> From: Gou Hao <gouhao@xxxxxxxxxxxxx>
>> 
>> If 'bh' is found in cache, just return directly.
>> might_sleep() is only required on slow paths.
>
>You're missing the point.  The caller can't know whether the slow or
>fast path will be taken.  So it must _never_ call this function if it
>cannot sleep.
I see. Thank you for your explanation! :)



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux