Re: [PATCH v4] ceph: drop the messages from MDS when unmounting

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

 



Xiubo Li <xiubli@xxxxxxxxxx> writes:
> On 29/03/2023 22:41, Luís Henriques wrote:
<...>
> This also looks good to me. As I remembered when reading the kernel code I just
> saw another place in VFS is also doing like this and I just followed it.
>> But... even with my suggestion, can't we deadlock here if we get preempted
>> just before the wait_for_completion() and ceph_dec_stopping_blocker() is
>> executed?
>
> Good question. Actually it won't.

Yeah, you're right.  Doh!

> The 'x->done' member in the completion will be initialized as 0, and the
> complete_all() will set it to 'UINT_MAX'. And only when 'x->done == 0' will the
> wait_for_completion() go to sleep and wait.

Cheers,
-- 
Luís




[Index of Archives]     [CEPH Users]     [Ceph Large]     [Ceph Dev]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux