Commit Graph

219 Commits

Author SHA1 Message Date
Volker Ruppert
501952efdd - removed unused logfunctions member 'type' and related method 'settype()'
- updated FSF address in copyright
2009-01-10 11:30:20 +00:00
Stanislav Shwartsman
d56c3a18aa reduce include dependencies in iodev.h
Makefile.in in iodev folder have to be regerated !
2008-12-29 20:16:08 +00:00
Volker Ruppert
fd79c68d72 - fixed some warnings in iodev 2008-12-21 08:56:26 +00:00
Volker Ruppert
ed90f8dd93 - fixed a bunch of warnings 2008-12-11 18:01:56 +00:00
Stanislav Shwartsman
0df223d363 Merged patch with blinking HDD led in RED color when HDD write occurs (GREEN when HDD read) 2008-10-06 22:00:11 +00:00
Volker Ruppert
61f51bc8af - minor ATA/ATAPI model string fixes
* cut model string on boot screen if larger than 36 characters to make one
    "ata" message fit in one line
  * config parameter for model string needs one more byte
  * harddrive: terminate model string with null
2008-07-27 08:06:52 +00:00
Volker Ruppert
b3b95e0d84 - ATAPI command 0x1A added (based on the Qemu implementation)
- simplified media presence check for ATAPI 'mode sense' commands (accessing
  parameter tree not required)
2008-07-07 18:36:07 +00:00
Volker Ruppert
46265689aa - PACKET-DMA feature now supported by all ATAPI commands
* don't panic if byte count is zero in PACKET-DMA mode (the specs say that
    byte count is used for PIO modes. The behaviour in DMA mode is not
    mentioned, but seems to be ignored in that case.)
  * pci_ide: initialize sector size with the BM-DMA byte count (disk read
    commands will overwrite this value, some ATAPI commands are using the
    original one.)
  * non-disk-read ATAPI commands simply copy the buffer in DMA mode
2008-07-06 14:15:41 +00:00
Stanislav Shwartsman
fda4d38959 32-bit systems have a problem to allocate large amount of physical memory for Bochs simulation which makes simulation with 4G address space virtually impossible. But in most of the cases when 4G physical address space defined - it is not touched by default on every run so it is possible to allocate only really accessed blocks. This commit made all necessary preparations for it. 2008-04-17 14:39:33 +00:00
Volker Ruppert
a1950bb565 - fixed compilation error: "jump to case label crosses initialization of `Bit32u drvsel'" 2008-03-30 08:32:57 +00:00
Stanislav Shwartsman
75f18c4f99 mostly indent changes 2008-03-29 17:44:13 +00:00
Stanislav Shwartsman
a459a64f3e whispace, tab2space, indent, dos2unix and other cleanups 2008-02-15 22:05:43 +00:00
Stanislav Shwartsman
063d896226 Optimization in 16-bit resolve functions
Fixes for hosts which can't support misaligned memory access
2008-02-07 20:43:13 +00:00
Stanislav Shwartsman
ae35b0276e white space cleanups and coding style changes 2008-01-26 22:24:03 +00:00
Stanislav Shwartsman
08eb75d985 Some workaround for bug report
1824189  Qemu hard disk image not reckognized
2008-01-14 20:47:11 +00:00
Volker Ruppert
afbb8fb8d4 - ATA command "execute device diagnostic" raises interrupt at completion 2007-12-17 18:08:27 +00:00
Stanislav Shwartsman
72af550a0f Some indent fixes + speed up hardware read by using inline functions 2007-11-12 21:04:17 +00:00
Stanislav Shwartsman
c8b4b32826 Merged harddrive patch from #SF tracker 2007-10-08 19:33:08 +00:00
Stanislav Shwartsman
071c5c1a26 A lot of changes but everything is really trivial.
Make save/restore default feature, the configure option for save/restore removed from configure script and save/restore made available forever. All code now assume it is exists. Bochs save/restore tree previosly called "save_restore" renamed to "bochs" tree and it will be havily used everywhere, starting from save/restore and ending by various bochs debugger functions. I am going to rework debugger code to get rid of debug CPU access functions and use this "bochs" param tree instead
2007-09-28 19:52:08 +00:00
Volker Ruppert
674fbc24ab - compare disk size with the size calculated from geometry to avoid image
corruption (if "mode" is not specified and image is not "flat")
- some message fixes
2007-09-07 10:54:19 +00:00
Stanislav Shwartsman
752ab9c4ae Woraround for large files problem I used to install Vista
When it PANICs with 8G large disk image file - just press continue and it will work
2007-08-09 14:04:51 +00:00
Volker Ruppert
6606627f4b - fixed harddisk signature (drive select bit must be cleared for devices not
implementing the PACKET command)
2007-08-04 17:01:04 +00:00
Volker Ruppert
8792936c44 - fixed ATA channel save/restore list size (no space for 'drive_select') 2007-04-06 07:13:19 +00:00
Stanislav Shwartsman
9d907b5f65 Try to specify everywhere the list size in bx_list_c constructor 2007-04-03 22:38:49 +00:00
Volker Ruppert
a3b352d4fd - don't abort command when setting maximum logical head number to 0 (Linux 2.6.x
kernels use this value when LBA48 support is available)
2007-02-27 18:16:20 +00:00
Volker Ruppert
795d07e90f - hard drive id now reports UDMA supported and ATA version 6
- setting transfer mode to UDMA now supported (no effect on the emulation speed)
- drive id arrays now initialized with memset()
2006-12-29 11:57:04 +00:00
Volker Ruppert
ee6bd95cfc - ATA/ATAPI identify device methods must now be called only one time per device in
a Bochs session unless the configuration (transfer mode) changes. Then the
  "drive id" data is simply copied to the output buffer.
- removed unused "drive id" example (Conner CFA540A)
- added stubs for the ATA flush cache commands
- converted some tabs to spaces
2006-12-26 17:08:12 +00:00
Volker Ruppert
fa43431365 - LBA48 support implemented (tested with Linux - TODO: readback of hob* values) 2006-12-25 09:34:32 +00:00
Volker Ruppert
f1799211ae - identify_drive() returns max. 16383 cylinders (higher values are usually
calculated using the total number of sectors, heads and sectors per track)
2006-12-18 17:56:05 +00:00
Volker Ruppert
9c8b9eae6a - support for VMWare version 4 disk image format implemented (patch by Sharvil
Nanavati)
- siminterface + wx code cleanup (removed unused stuff and wx log messages,
  floppy media type name handling simplified)
2006-12-17 08:17:28 +00:00
Volker Ruppert
d363ceef3b - the ATA command "verify without retries" works the same was as the normal
verify command (should fix SVR4/386 installation)
2006-12-13 16:59:29 +00:00
Volker Ruppert
0a174516ff - fixed type conflicts in hdimage lseek() methods. Now using always Bit64s for
the lseek() methods and off_t is only used for the lowlevel lseek() function.
- fixed indent mode and removed unnecessary spaces
2006-11-18 11:51:07 +00:00
Volker Ruppert
72283f6760 - delete i/o handlers before unloading plugins
- memory for i/o handler name is now dynamicly allocated (strdup's in harddrv
  code removed)
2006-09-20 18:24:17 +00:00
Volker Ruppert
fdefdc5b9f - remove logfunction from list when device is deleted
- fixed typos in harddrv code
2006-09-17 18:09:33 +00:00
Volker Ruppert
647b0e3e6c - removed exit() method from the devmodel object, since all that stuff can be
done by the object destructor (changes in cmos, hard drive and keyboard)
- bx_unload_plugins() now deletes the devmodel object in non-plugin mode
- CMOS device now prints the time on exit in human-readable format
2006-09-16 14:47:40 +00:00
Volker Ruppert
38caf3bf19 - allocate memory for the IRQ handler name in register_irq() and free it in
unregister_irq(). This is required since there are some devices that don't
  use a string constant for the handler name.
- replaced true / false by portable 0 / 1 values.
2006-09-13 18:51:25 +00:00
Volker Ruppert
190b9391cf - delete the device object in the plugin_fini() function of each plugin device
(TODO: find a way to call plugin_fini() for non-core devices if plugins are
   disabled)
- set the device pointers back to stubs after unloading plugins
- added debug message "Exit" in all device plugin destructors
2006-09-10 17:18:44 +00:00
Volker Ruppert
cb7db12ab2 - missing 32-bit support for the PACKET command added
- improved debug messages
2006-08-23 17:19:03 +00:00
Volker Ruppert
3ef9b08908 - using a unique name for ATAPI 'inquiry' makes Win98 report two cdroms on one
controller correctly in the device manager
- ATAPI 'identify' now also uses the 'inquiry' device number for the serial number
2006-08-05 07:49:31 +00:00
Volker Ruppert
df3fcfd180 - ignore writes to command register with BSY bit set and replaced BX_PANIC by
BX_ERROR
- removed duplicate and wrong BSY bit error handling
- init drive params: changed BX_PANIC to BX_ERROR (aborting command is okay here)
2006-08-02 17:47:09 +00:00
Volker Ruppert
18df6f6a0e - the ERR status bit is always cleared when the drive accepts a new command, but
not when reading the error register
- the DSC status bit is not cleared in case of an error
- a not existing drive does not set the ERR status bit and the error register
- all messages related to correctly aborted commands on non-disk devices changed
  to type BX_INFO
- some other log message output cleanups
2006-07-26 19:09:51 +00:00
Volker Ruppert
c6b080733b - fixed MSVC warning 2006-07-23 16:31:28 +00:00
Volker Ruppert
8f8c4db97d - report selected multiword DMA mode in the 'identify device' block
- set initial and reset value of multiple sector count to 0
- abort multi sector read/write commands if multiple sector count is not valid
2006-07-19 19:18:42 +00:00
Volker Ruppert
92412a3fee - multi sector read/write commands implemented
- ATA command 'set multiple mode' fixed (missing interrupt and value check)
- hard disk sector read/write rewritten and simplified
- hard disk now reporting ATA-3 supported
- updated drive buffer size for save/restore
2006-07-17 18:40:26 +00:00
Volker Ruppert
d18be4f084 - ATA command 'read multiple sectors' prepared (not working properly with Linux
guest and some work in the hdimage code is required)
2006-07-14 17:23:58 +00:00
Volker Ruppert
10a49f6d1c - fixed implementation of the ATA command "set multiple mode" (TODO: multi sector
read/write commands)
- prepared i/o buffer for multi sector transfers
- power management commands "standby now" and "idle immediate" now returning success
2006-07-13 17:34:44 +00:00
Volker Ruppert
dbfc8f42c8 - always use geometry detection for 'vmware3' images
- updated documentation for hard disk images
- user.dbk: added save/restore config option and removed obsolete one
2006-06-17 07:45:27 +00:00
Volker Ruppert
075ee17ac9 - geometry autodetection for 'sparse' mode hard disk images added
- store size of virtual disk in sparse header to simplify geometry detection/check
- enabling geometry autodetection causes a panic if not supported by image
2006-06-16 07:29:33 +00:00
Volker Ruppert
02fbf84630 - geometry autodetection for 'vmware3' mode hard disk images added
- simplified geometry detection code
- unsupported ATAPI commands now cause a BX_DEBUG message and no addtional
  error code info (avoid flooding log file)
2006-06-15 09:44:37 +00:00
Volker Ruppert
f2f80f7542 - geometry autodetection for 'undoable' and 'volatile' mode hard disk images added
- a bunch of image size handling changes
  * 'hd_size' contains the size of the virtual hard disk (for geometry check/detection)
  * passing the size calculated from the geometry not needed in some cases
- indent mode changes
2006-06-08 20:32:00 +00:00