Re: LOR: /sys/ufs/ffs/ffs_snapshot.c:1893 /sys/vm/vm_map.c:2206

From: Robert Watson <rwatson_at_FreeBSD.org>
Date: Fri, 30 Apr 2004 22:13:17 -0400 (EDT)
On Fri, 30 Apr 2004, Brian Fundakowski Feldman wrote:

> I haven't seen it myself, but it seems like it's only going to happen
> sometimes (when a full page is freed).  There's really no technical
> reason you'd ever want to do a free(9) with locks held, so I suggest
> fixing it in the straightforward way. 

While I sympathize with this point, I don't think it's realistic to assert
that free() will never be called while helding a lock.  Once the mbuf
allocator backs into regular malloc() and free(); the network stack relies
on being able to perform wait-free allocation and free while locks are
held, since it uses locks as a light-weight form of reference-counting.

Robert N M Watson             FreeBSD Core Team, TrustedBSD Projects
robert_at_fledge.watson.org      Senior Research Scientist, McAfee Research
Received on Fri Apr 30 2004 - 17:13:25 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:52 UTC