Date: Wed, 29 Aug 2012 17:23:43 -0700 From: Vijay Singh <vijju.singh@gmail.com> To: net@freebsd.org Subject: sorele() and ACCEPT_LOCK() Message-ID: <CALCNsJTQNkPv41M0vBMoQJpFFLFHw7Q4Pf__rOmO%2BXADxAGi4g@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Is there any reason why sorele() needs the accept lock to be held? 231 #define sorele(so) do { \ 232 ACCEPT_LOCK_ASSERT(); \ 233 SOCK_LOCK_ASSERT(so); \ 234 if ((so)->so_count <= 0) \ 235 panic("sorele"); \ 236 if (--(so)->so_count == 0) \ 237 sofree(so); \ 238 else { \ 239 SOCK_UNLOCK(so); \ 240 ACCEPT_UNLOCK(); \ 241 } \ 242 } while (0) -vijay
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALCNsJTQNkPv41M0vBMoQJpFFLFHw7Q4Pf__rOmO%2BXADxAGi4g>