Re: About mmc delayed workqueue.

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

 



Hi,

On Tue, Mar 29 2011, NamJae Jeon wrote:
> Dear. Chris, Ben.
>
> Thanks for your reply.
>
> As you know, booting time is important factor in embededd device.
>
> If rootdelay is set to 5, kernel will be waiting for 5 sec. root_wait
> is also looping per 100ms.

No.  It will wait for *up to* five seconds, but it will actually
continue as soon as the device has enumerated.  Same with rootwait,
of course.

MMC is by no means the only subsystem that behaves this way.  If you
were using a USB or SATA/AHCI device, amongst many others, you would
have exactly the same problem.

You can see http://lwn.net/Articles/330378/ for some background reading.

> I have a question. Why is  mmc using delayed workqueue ?

So that device enumeration can happen in the background, without
delaying the kernel boot while we wait for the controller to get all
the way to creating partitions.

If we didn't use a workqueue and you were working on an embedded project
that had an MMC slot that it *didn't* boot from, you'd be yelling at us
for instead wasting time holding up your non-mmc boot by not letting
userspace get going until we list MMC partitions.  We can't win.  :-)

In any case, I suspect that your system actually does boot faster than
it would if we didn't use a workqueue -- this way the delays in waiting
for the controller to come up are parallelized with other boot code.
That's good, right?

- Chris.
-- 
Chris Ball   <cjb@xxxxxxxxxx>   <http://printf.net/>
One Laptop Per Child
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux