hole in passregister?

Scott Long scottl at samsco.org
Wed Feb 20 15:32:29 UTC 2008


Matthew Jacob wrote:
> 
> ...
>         mtx_unlock(periph->sim->mtx);
>     ...
>         mtx_lock(periph->sim->mtx);
>         softc->dev->si_drv1 = periph;
> 
>         /*
>          * Add an async callback so that we get
>          * notified if this device goes away.
>          */
>         xpt_register_async(AC_LOST_DEVICE, passasync, periph, 
> periph->path);
> ....
> the device can go away prior to xpt_register_async being called I think.
> 

Yeah, it's a known problem that I was hoping wouldn't be too risky until
I could come up with a better fix.  The root of the problem is the poor
design choice by the devfs crowd to use sleepable semantics within the
make_dev and disk_create API's.  I've been debating how to effectively
work around this, but haven't gotten very far yet.

Scott


More information about the freebsd-scsi mailing list