How Fiasco reclaim task resources when the task exits (abnormally) ?

Adam Lackorzynski adam at
Tue Jun 11 22:54:10 CEST 2013

On Mon Jun 10, 2013 at 02:44:50 -0700, BogDan wrote:
> > FDs and caps are local to the task, so just memory.
> Hmm it must be a misunderstanding here, it can't be  just memory 
> because IMHO also FDs can't be local ... I can't image how they can
> be managed locally ... 

If the VFS is just local, the FDs are also just local. When considering
a VFS service with multiple clients, then yes, there's more to do.

> Let me give two (very similar) examples to be more clear:
> - when I open a file (exclusive mode) a VFS has to do something to 
> prevent other FDs to read/write into that file, so it creates and
> keeps a thing (FD, capability) inside it until the application close the 
> FD. Now the problem comes when the application exits (it crashes)
> without closing the FD, is there any way to notify the VFS server
> about it?
> - when I create a socket and listen on a port, other apps can't
> listen on the same port, meaning that there is another server which
> manage this resource. Like in the previous example I don't want to
> reboot my os to use that port after the application crashed :)
> > Providers need to
> > check whether there are any further users of their resource and if not
> > they can free it (the kernel provides support for doing so).
> > 
> The providers need to check or they are notified by the kernel when a
> resources is not referenced by anyone? I'm very interested in this topic,
> is there any example that I can check?

For example moe is doing this and ned too.

Adam                 adam at

More information about the l4-hackers mailing list