- new functions raise_irq() and lower_irq()
- all trigger_irq() / untrigger_irq() calls are replaced by the new functions
- REMARK: timer IRQ handling is not correct but it works
- TODO: IOAPIC IRQ handling needs to be changed
- length of 'configure' floppy command fixed
- busy flag is set until the result of a read/write command is complete
- read/write access to unsupported address causes a BX_ERROR, not a BX_PANIC
- commented BX_INFO statements removed
* floppy command 'format track' implemented
* read and write operations with MT=0 are working now
(function 'increment_sector()' updated)
* result code of floppy command 'get status' fixed
* flag FS_MS_DIO is not set while the 'configure' floppy command is pending
* diskette controller data register returns last result if no new data
is available
* reset will be activated when the reset bit is changed to normal operation
* reset sets the error bits in status register 0
* write access to port 0x3f4 will cause a BX_ERROR now
* unsupported and invalid floppy commands are setting the error status bit
'invalid command' - BX_PANIC not necessary
* flag FS_MS_DIO is not set while a floppy command is pending
* floppy command 'specify': cause a BX_ERROR when non-DMA mode is selected
* floppy command 'sense interrupt status' returns an error is no interrupt
is pending
* floppy command 'read ID' sets the 'busy' flag and returns no data if the
motor is not on
* removed SIMX86 section (not defined in bochs)
* define variable 'sTemp' for win32 only
been converted into parameters temporarily have the letter "O" appended
to their name. I don't want to keep it this way, but it has helped
in the conversion process because the compiler refuses to compile the
old uses of the name. Before I started using the "O" trick, there were
many bugs like this: if (bx_options.diskc.present) {...}
This was legal with the new parameters, but it was testing whether the
parameter structure had been created, instead of testing the value of
the present parameter. Renaming present to Opresent turns this into
a compile error, which points out the incorrect use of the param.
- the "--disable-control-panel" no longer works, I'm afraid. I can no
longer support this and continue progress.
a read-only disk image. For systems such as DOS that actually use the
BIOS services, it was also necessary to add code in int13_diskette_function
to recognize a write-protected error and return the correct error
status code (AH=3, Carry Set).
now floppy.cc no longer crashes if you try to open a write-protected
disk or read-only disk image. Instead, it tries a second time to
open the image read-only and only panics if this also fails. If the
image is opened read-only, a readonly flag is set
(bx_floppy.s.media[drive].read_only). If you try to write the floppy
when this flag is set, the write silently fails except for some messages
into the log. Instead of failing silently we should learn what the
floppy controller would really do in this situation and emulate it.
To see the commit logs for this use either cvsweb or
cvs update -r BRANCH-io-cleanup and then 'cvs log' the various files.
In general this provides a generic interface for logging.
logfunctions:: is a class that is inherited by some classes, and also
. allocated as a standalone global called 'genlog'. All logging uses
. one of the ::info(), ::error(), ::ldebug(), ::panic() methods of this
. class through 'BX_INFO(), BX_ERROR(), BX_DEBUG(), BX_PANIC()' macros
. respectively.
.
. An example usage:
. BX_INFO(("Hello, World!\n"));
iofunctions:: is a class that is allocated once by default, and assigned
as the iofunction of each logfunctions instance. It is this class that
maintains the file descriptor and other output related code, at this
point using vfprintf(). At some future point, someone may choose to
write a gui 'console' for bochs to which messages would be redirected
simply by assigning a different iofunction class to the various logfunctions
objects.
More cleanup is coming, but this works for now. If you want to see alot
of debugging output, in main.cc, change onoff[LOGLEV_DEBUG]=0 to =1.
Comments, bugs, flames, to me: todd@fries.net