bug-hurd
[Top][All Lists]
Advanced

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

Re: [PATCH 2/3] trans: populate the mtab on demand


From: Justus Winter
Subject: Re: [PATCH 2/3] trans: populate the mtab on demand
Date: Wed, 20 Nov 2013 13:18:17 +0100
User-agent: alot/0.3.4

Quoting Richard Braun (2013-11-20 12:13:20)
> On Wed, Nov 20, 2013 at 11:10:07AM +0100, Justus Winter wrote:
> > Previously the mtab content was generated in the open hook. Delay this
> > until the data is needed. A follow up patch will take advantage of
> > this to both simplify the logic in mtab_populate and make it more
> > robust at the same time.
> 
> I'm not sure to grasp the relation between this patch and deadlock
> avoidance. I also don't see what's wrong with generating data at open
> time.

Suppose you have

  settrans -ac /foo /hurd/mtab /

If you now access /foo, the mtab translator will walk the tree of all
active translators starting from /. If it visits /foo, it will talk to
itself. Previously the translator migitated this by comparing the
control port of the translator with its own. This does not work if you
got two mtab translators like this:

  settrans -ac /foo /hurd/mtab /
  settrans -ac /bar /hurd/mtab /

With a single-threaded mtab server this results in a dead-lock, with a
multi-threaded server this will create more and more threads.

Delaying the data generation until it is really needed avoids this
problem.

Justus



reply via email to

[Prev in Thread] Current Thread [Next in Thread]