On 2010-04-05 at 11:37:02 [+0200], Axel Dörfler <axeld@xxxxxxxxxxxxxxxx> wrote: > ingo_weinhold@xxxxxx wrote: > > +struct VMAreaWiredRange : SinglyLinkedListLinkImpl<VMAreaWiredRange> > > { > > + VMArea* area; > > + addr_t base; > > + size_t size; > > + bool writable; > > + bool implicit; // range created > > automatically > > + VMAreaUnwiredWaiterList waiters; > > Don't we need reference counting as well? At least I'm not sure if we > can easily forbid nested lock_memory() calls. That's not a problem. Each lock_memory_etc() creates a VMAreaWiredRange per concerned area. Any number of overlapping or even identical ranges can be added to an area. Ref counting could be introduced to avoid creation of multiple objects for identical ranges, but I don't think that happens particularly often and would only unnecessarily complicate the code. CU, Ingo