[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130116003530.GK2668@htj.dyndns.org>
Date: Tue, 15 Jan 2013 16:35:30 -0800
From: Tejun Heo <tj@...nel.org>
To: Arjan van de Ven <arjan@...ux.intel.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
Ming Lei <ming.lei@...onical.com>,
Alex Riesen <raa.lkml@...il.com>,
Alan Stern <stern@...land.harvard.edu>,
Jens Axboe <axboe@...nel.dk>,
USB list <linux-usb@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: USB device cannot be reconnected and khubd "blocked for more
than 120 seconds"
Hello, Arjan.
On Tue, Jan 15, 2013 at 04:25:54PM -0800, Arjan van de Ven wrote:
> async fundamentally had the concept of a monotonic increasing number,
> and that you could always wait for "everyone before me".
> then people (like me) wanted exceptions to what "everyone" means ;-(
> I'm ok with going back to a single space and simplify the world.
If we want (or need) finer grained operation, we'll probably have to
head the other direction, so that we can definitively tell that an
async operation belongs to domains system, module load A and B, so
that each waiter knows what to wait for.
The current domain implementation is somewhere inbetween. It's not
completely simplistic system and at the same time not developed enough
to do properly stacked flushing.
> the module wait case is tricky, and I wonder if there's deadlocks
> lurking even without async.
I don't think so. It's really an async job waiting for itself.
Working around just this case is mostly trivial (working on patches
now) but it really is putting kludges on top of shaky foundation.
Maybe this is the extent of complexity that we need to go given the
rather limited use cases of async. Let's hope so. I think we'll have
to reimplement synchronization scheme if we have to go further.
> at some point in the past we had the concept of "request a module
> but don't wait for it", and I wonder if that is what should have
> been used here.
We actually want to wait for it as it creates a userland visible
behavior difference otherwise. It's just that async's way of waiting
is too ham-fisted to be used properly in more complex scenarios.
Thanks.
--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists