diff options
| author | Rodney W. Grimes <rgrimes@FreeBSD.org> | 1995-04-06 07:20:16 +0000 |
|---|---|---|
| committer | Rodney W. Grimes <rgrimes@FreeBSD.org> | 1995-04-06 07:20:16 +0000 |
| commit | 74fa89f4f54bd5c6f8daba3ccfc6bb48f8878dd8 (patch) | |
| tree | cd5e8cfc46a699dbc60a3be6b988618f10e914f1 /sys/dev/fdc | |
| parent | d31b19afb1f91bbebc5f2a9a66353509a0de6ffa (diff) | |
Notes
Diffstat (limited to 'sys/dev/fdc')
| -rw-r--r-- | sys/dev/fdc/fdc.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/sys/dev/fdc/fdc.c b/sys/dev/fdc/fdc.c index 8330f4fde0ab..9a6816f189b7 100644 --- a/sys/dev/fdc/fdc.c +++ b/sys/dev/fdc/fdc.c @@ -43,7 +43,7 @@ * SUCH DAMAGE. * * from: @(#)fd.c 7.4 (Berkeley) 5/25/91 - * $Id: fd.c,v 1.54 1995/03/16 18:11:59 bde Exp $ + * $Id: fd.c,v 1.55 1995/03/26 19:28:18 rgrimes Exp $ * */ @@ -262,7 +262,7 @@ void ftstrategy(struct buf *); int ftioctl(dev_t, int, caddr_t, int, struct proc *); int ftdump(dev_t); int ftsize(dev_t); -int ftattach(struct isa_device *, struct isa_device *); +int ftattach(struct isa_device *, struct isa_device *, int); #endif /* autoconfig functions */ @@ -549,7 +549,7 @@ fdattach(struct isa_device *dev) fdcu_t fdcu = dev->id_unit; fdc_p fdc = fdc_data + fdcu; fd_p fd; - int fdsu, st0, st3, i; + int fdsu, st0, st3, i, unithasfd; struct isa_device *fdup; int ic_type = 0; @@ -591,7 +591,14 @@ fdattach(struct isa_device *dev) #if NFT > 0 /* If BIOS says no floppy, or > 2nd device */ /* Probe for and attach a floppy tape. */ - if ((dev->id_flags & FT_PROBE) && ftattach(dev, fdup)) + /* Tell FT if there was already a disk */ + /* with this unit number found. */ + + unithasfd = 0; + if (fdu < NFD && fd->type != NO_TYPE) + unithasfd = 1; + if ((dev->id_flags & FT_PROBE) && + ftattach(dev, fdup, unithasfd)) continue; if (fdsu < DRVS_PER_CTLR) fd->type = NO_TYPE; |
