Re: [PATCH bpf-next v5 07/11] af_unix: implement unix_dgram_bpf_recvmsg()

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

 



On Sun, Jul 18, 2021 at 10:49 AM Eric Dumazet <eric.dumazet@xxxxxxxxx> wrote:
>
>
>
> On 7/4/21 9:02 PM, Cong Wang wrote:
> > From: Cong Wang <cong.wang@xxxxxxxxxxxxx>
> > +     mutex_lock(&u->iolock);
>
> u->iolock mutex is owned here.
>
> > +     if (!skb_queue_empty(&sk->sk_receive_queue) &&
> > +         sk_psock_queue_empty(psock)) {
> > +             ret = __unix_dgram_recvmsg(sk, msg, len, flags);
>
> But __unix_dgram_recvmsg() will also try to grab this mutex ?

Good catch. I should release the lock before calling it. I will send
a patch.

Thanks.



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux