diff options
Diffstat (limited to 'sys/scsi/sd.c')
-rw-r--r-- | sys/scsi/sd.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/scsi/sd.c b/sys/scsi/sd.c index c38bef7..c47e71b 100644 --- a/sys/scsi/sd.c +++ b/sys/scsi/sd.c @@ -281,7 +281,7 @@ sd_open(dev, mode, fmt, p, sc_link) * If it's been invalidated, then forget the label */ sc_link->flags |= SDEV_OPEN; /* unit attn becomes an err now */ - if (!(sc_link->flags & SDEV_MEDIA_LOADED)) { + if (!(sc_link->flags & SDEV_MEDIA_LOADED) && sd->dk_slices != NULL) { /* * If somebody still has it open, then forbid re-entry. */ @@ -290,10 +290,7 @@ sd_open(dev, mode, fmt, p, sc_link) goto bad; } - if (sd->dk_slices == NULL) - Debugger("sdopen: no slices"); - else - dsgone(&sd->dk_slices); + dsgone(&sd->dk_slices); } /* * In case it is a funny one, tell it to start |