CD-ROM code clean-ups, also reduces memory usage by a further about 2 MB.
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
*
|
||||
* Common code to handle all sorts of disk controllers.
|
||||
*
|
||||
* Version: @(#)hdc.c 1.0.9 2018/02/14
|
||||
* Version: @(#)hdc.c 1.0.10 2018/03/17
|
||||
*
|
||||
* Authors: Miran Grca, <mgrca8@gmail.com>
|
||||
* Fred N. van Kempen, <decwiz@yahoo.com>
|
||||
@@ -24,6 +24,7 @@
|
||||
#include "../machine/machine.h"
|
||||
#include "../device.h"
|
||||
#include "hdc.h"
|
||||
#include "hdc_ide.h"
|
||||
|
||||
|
||||
char *hdc_name; /* configured HDC name */
|
||||
@@ -158,6 +159,15 @@ hdc_reset(void)
|
||||
/* If we have a valid controller, add its device. */
|
||||
if (hdc_current > 1)
|
||||
device_add(controllers[hdc_current].device);
|
||||
|
||||
/* Reconfire and reset the IDE layer. */
|
||||
ide_ter_disable();
|
||||
ide_qua_disable();
|
||||
if (ide_enable[2])
|
||||
ide_ter_init();
|
||||
if (ide_enable[3])
|
||||
ide_qua_init();
|
||||
ide_reset_hard();
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user