From a412b0709245cc6b453de50a03d7f5bfff6267ef Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Mon, 6 Nov 2023 21:14:53 -0800 Subject: [PATCH] Move Disabling drive motor out of ScanRDSK We want non-RDSK drives turn off as well, ie. CDROM drives. --- mounter.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/mounter.c b/mounter.c index ffee610..631b6e0 100644 --- a/mounter.c +++ b/mounter.c @@ -876,9 +876,6 @@ static LONG ScanRDSK(struct MountData *md) } } } - md->request->iotd_Req.io_Command = TD_MOTOR; - md->request->iotd_Req.io_Length = 0; - DoIO((struct IORequest*)md->request); return ret; } @@ -1144,6 +1141,11 @@ LONG MountDrive(struct MountStruct *ms) } } + // Disable motor after probing + md->request->iotd_Req.io_Command = TD_MOTOR; + md->request->iotd_Req.io_Length = 0; + DoIO((struct IORequest*)md->request); + CloseDevice((struct IORequest*)request); if (ms->luns && (lun++ < 8) && (!md->wasLastLun)) {