[PATCH] Fix for USB media not found at boot

Scott Long scottl at samsco.org
Sat Oct 3 15:45:10 UTC 2009


On Oct 3, 2009, at 9:05 AM, Scott Long wrote:

> On Oct 3, 2009, at 4:30 AM, Hans Petter Selasky wrote:
>> On Saturday 03 October 2009 10:19:57 Scott Long wrote:
>>> config_intrhook system will sleep after all
>>
>> Then why do you need the intr hook callback?
>>
>
> The config_intrhook lets you know that interrupts are enabled, the  
> scheduler is running, and mountroot hasn't run yet.  It provides a  
> very convenient and standard way to do exactly what we want with USB  
> enumeration.
>

Now that I'm awake, let me explain more.  I'm moving USB from the  
mount_root_hold() API to the config_intrhook() API because the latter  
provides proper boot ordering with CAM, which the former does not.   
Though my published patch doesn't rely on the CAM system in order to  
function, if you want umass devices to be discovered in time, you need  
it.  What I didn't realize when I published my patch is that my  
approach is incomplete; I'm working to fix that, but it will likely  
require some significant work inside of USB.

Scott



More information about the freebsd-current mailing list