Commit Graph

57 Commits

Author SHA1 Message Date
Volker Ruppert
b130bf671b - initial "log action by device" implementation added (TODO: check for
invalid module names, save log actions to bochsrc)
- added new member 'name' to the logfunctions class for the case the prefix
  is too short. Added to some devices with longer names.
2011-12-29 19:51:54 +00:00
Volker Ruppert
0de2516d05 - fixes to avoid crash after unloading plugins before simulation
- small cleanups
2011-12-26 20:32:56 +00:00
Volker Ruppert
11e9b12fbf - PIT must be connected to IOAPIC pin INTIN2
- converted tabs to spaces
2011-05-04 18:37:50 +00:00
Stanislav Shwartsman
00981cd7a6 Adding Id and Rev property to all files 2011-02-24 22:05:47 +00:00
Volker Ruppert
3ef57e9f7e - fixed some format warnings in the devices code 2011-01-02 16:51:08 +00:00
Volker Ruppert
cdb7e0eb96 - fixed usage of variable 'apic_id_mask' for compatibility with win32 plugin target 2010-05-15 09:23:50 +00:00
Stanislav Shwartsman
35f8e91cad APIC ID mask cleanup 2010-05-14 12:10:00 +00:00
Stanislav Shwartsman
e3a13a7a55 Make XAPIC runtime option as well 2010-02-28 14:52:17 +00:00
Stanislav Shwartsman
153d43520d change copyright to bochs project 2009-12-04 19:50:29 +00:00
Stanislav Shwartsman
30c63c773c apic.h is not needed for ioapic.cc 2009-02-22 17:37:09 +00:00
Volker Ruppert
790eec83ca - converted I/O APIC to a device plugin
- updated dependencies
2009-02-22 10:44:50 +00:00
Stanislav Shwartsman
31a367283a small optimizations for apic code 2009-02-19 23:19:11 +00:00
Stanislav Shwartsman
1b72e66bb3 support for apic global disable
separate between I/O apic and local apic
2009-02-18 22:25:04 +00:00
Volker Ruppert
e5eac65b59 - removed wrong character from FSF address (converted invisible and useless
2-byte character)
- updated FSF address in some files
- added license to some files
2009-02-08 09:05:52 +00:00
Stanislav Shwartsman
dd03e043a3 Updated FSF address 2009-02-07 21:05:31 +00:00
Stanislav Shwartsman
7d5e058dfe write to apic must be 16-byte aligned 2009-02-03 20:42:15 +00:00
Stanislav Shwartsman
30fec77004 faster i/o apic write access 2009-02-03 19:12:00 +00:00
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
Volker Ruppert
00d404809b - reduce some more dependencies
- iodev.h already includes bochs.h
2009-01-03 08:55:00 +00:00
Volker Ruppert
fd79c68d72 - fixed some warnings in iodev 2008-12-21 08:56:26 +00:00
Stanislav Shwartsman
83918212a6 Implemented HW reset for I/O APIC 2008-11-17 20:06:16 +00:00
Stanislav Shwartsman
297087fea9 fixed memory handler params - use bx_phy_address data type 2008-04-29 22:14:23 +00:00
Stanislav Shwartsman
ae35b0276e white space cleanups and coding style changes 2008-01-26 22:24:03 +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
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
8dfd8eefa7 - ExtINT implemented (some progress with FreeBSD 5.3 boot cd)
- fixed a warning
2006-10-02 15:08:21 +00:00
Stanislav Shwartsman
1aaf19cd09 Support for partial read/write in APIC space 2006-06-05 05:39:21 +00:00
Stanislav Shwartsman
fee48d74e0 Avoid doing strdup for param name field - most of the strdups elliminated ! 2006-05-29 22:33:38 +00:00
Stanislav Shwartsman
286b89d763 Several x86-64 MSRs were not-initilized !
Fixed small save-restore bug in dma.cc
First step to make save-restore code look better (only several files processed for example)
2006-05-28 17:07:57 +00:00
Stanislav Shwartsman
8b0df8e99b Merge SAVE_RESTORE branch to CVS 2006-05-27 15:54:49 +00:00
Stanislav Shwartsman
7b6c2587a9 Now devices could be compiled separatelly from CPU
Averything that required cpu.h include now has it explicitly and there are a lot of files not dependant by CPU at all which will compile a lot faster now ...
2006-03-06 22:03:16 +00:00
Stanislav Shwartsman
dfeaf141f0 Register I/O APIC as memory handler, optimize memory handlers array 2006-02-27 19:04:01 +00:00
Stanislav Shwartsman
2755fb02dd Different was to implement bx_io_redirect_entry_t.
Should be fastr (elliminate redundant parse_entry calls) and more correct (aware of R/O fields)
2006-02-24 09:46:10 +00:00
Stanislav Shwartsman
2c8f6f7720 Merged patch: determine number of processors to emulate through .bochsrc 2006-01-18 18:35:38 +00:00
Stanislav Shwartsman
5899932f0c Merge APIC patch to the CVS.
- Fix lowest priority interrupt delivery from I/O APIC
 - XAPIC support
 - Implemented APIC bus functionality
 - cleanup APIC code
2006-01-10 06:13:26 +00:00
Volker Ruppert
a7df662814 - only a change of the INTIN level should be handled by the I/O APIC
- removed I/O APIC IRQ0 hack from the PIC code
2006-01-08 12:01:25 +00:00
Volker Ruppert
97e1f39d8f - I/O APIC signal handling rewritten ("backported" from qemu)
- don't flood the logfile if APIC EOI has no effect
- fixed a warning in the APIC code
- TODO: fix IRQ 0 handling, implement ExtINT
2006-01-01 11:33:06 +00:00
Volker Ruppert
ff7f41541f - first attempt to fix the I/O APIC code
* IRQ 0, 2 and 13 are usually not connected to the I/O APIC INTIN pins
  * if the IRQ line is set to inactive, clear IRR bit (same as PIC, but that
    needs to be checked)
  * added symbols for I/O APIC input types according to the specs
  * TODO: PIC INTR is connected to INTIN0, edge/level handling in I/O APIC and
    APIC code, ...
2005-12-31 14:46:21 +00:00
Stanislav Shwartsman
90059c8faa Non-functional changes, little bit optimize ioapic code 2005-12-13 20:27:23 +00:00
Volker Ruppert
e98c100f74 - a bunch of warnings in MSVC fixed
- name of source file in wxworkspace.zip fixed
2005-06-04 17:44:59 +00:00
Stanislav Shwartsman
19750b0324 Fixed highest_priority_int calculation function
Fixed I/O APIC ID for 8CPU configuration to match BIOS tables
Remove I/O APIC initialization when INIT IPI received
2005-04-27 18:09:27 +00:00
Stanislav Shwartsman
8191e3f577 Rolled back mistakely committed I/O APIC experiment 2005-04-11 16:51:09 +00:00
Stanislav Shwartsman
1755589376 Separate pageWriteStamp from ICACHE. The pageWriteStamp has totally independant structure and could be used in future with icache structure. Also it could be significantly speeded up using BX_SMF analog constructions. 2005-04-10 19:42:48 +00:00
Stanislav Shwartsman
f77ddd9701 Remove cpu_onlline_map varaible, it wasn't initialized properly and might cause APIC problems 2005-03-19 18:43:00 +00:00
Stanislav Shwartsman
bbd55fe16f Merge and commit patch.apic-zwane from CVS patches directory.
the patch release notes by Zwane:

o Define symbols for constants like
o APIC arbitration
o Processor priority
o Various interrupt delivery fixes
o Focus processor checking
o ExtINT delivery

I need to release this now so that i don't fall too far behind CVS, when
it was part of the bochs-smp patch it could boot 2.4.18 4way. Apologies
for the whitespace changes.


Also remove patch.apic-ppr-zwane patch because it already included in
patch.apic-zwane.

I hope it will help to boot x86-64 or cmp systems required missed APIC
features !
2004-09-15 21:48:57 +00:00
Volker Ruppert
242b9a2c3a - level sensitive irq mode prepared
- pci reset mechanism implemented
- obsolete ResetSignal stuff removed
- ioapic: irq handling functions renamed to raise_irq/lower_irq
- pic: fixed two warnings
2004-07-06 19:59:10 +00:00
Stanislav Shwartsman
5873b26a82 Speed up compilation process.
bochs.h already not include iodev.h which reduces compilation dependences for almost all cpu and fpu files, now cpu files will not be recompiled if iodev includes was changed
2004-06-19 15:20:15 +00:00
Bryce Denney
0a7cb3a43c - apply patch.ifdef-disabled-options. Comments from that patch are below:
For a whole lot of configure options, I put #if...#endif around code that
  is specific to the option, even in files which are normally only compiled
  when the option is on.  This allows me to create a MS Visual C++ 6.0
  workspace that supports many of these options.  The workspace will basically
  compile every file all the time, but the code for disabled options will
  be commented out by the #if...#endif.

  This may one day lead to simplification of the Makefiles and configure
  scripts, but for the moment I'm leaving Makefiles and configure scripts
  alone.

  Affected options:
    BX_SUPPORT_APIC (cpu/apic.cc)
    BX_SUPPORT_X86_64 (cpu/*64.cc)
    BX_DEBUGGER (debug/*)
    BX_DISASM (disasm/*)
    BX_WITH_nameofgui (gui/*)
    BX_SUPPORT_CDROM (iodev/cdrom.cc)
    BX_NE2K_SUPPORT (iodev/eth*.cc, iodev/ne2k.cc)
    BX_SUPPORT_APIC (iodev/ioapic.cc)
    BX_IODEBUG_SUPPORT (iodev/iodebug.cc)
    BX_PCI_SUPPORT (iodev/pci*.cc)
    BX_SUPPORT_SB16 (iodev/sb*.cc)

Modified Files:
  cpu/apic.cc cpu/arith64.cc cpu/ctrl_xfer64.cc
  cpu/data_xfer64.cc cpu/fetchdecode64.cc cpu/logical64.cc
  cpu/mult64.cc cpu/resolve64.cc cpu/shift64.cc cpu/stack64.cc
  debug/Makefile.in debug/crc.cc debug/dbg_main.cc debug/lexer.l
  debug/linux.cc debug/parser.c debug/parser.y
  disasm/dis_decode.cc disasm/dis_groups.cc gui/amigaos.cc
  gui/beos.cc gui/carbon.cc gui/macintosh.cc gui/rfb.cc
  gui/sdl.cc gui/term.cc gui/win32.cc gui/wx.cc gui/wxdialog.cc
  gui/wxmain.cc gui/x.cc iodev/cdrom.cc iodev/eth.cc
  iodev/eth_arpback.cc iodev/eth_fbsd.cc iodev/eth_linux.cc
  iodev/eth_null.cc iodev/eth_packetmaker.cc iodev/eth_tap.cc
  iodev/eth_tuntap.cc iodev/eth_win32.cc iodev/ioapic.cc
  iodev/iodebug.cc iodev/ne2k.cc iodev/pci.cc iodev/pci2isa.cc
  iodev/sb16.cc iodev/soundlnx.cc iodev/soundwin.cc
2002-11-19 05:47:45 +00:00
Bryce Denney
cec9135e9f - Apply patch.replace-Boolean rev 1.3. Every "Boolean" is now changed to a
"bx_bool" which is always defined as Bit32u on all platforms.  In Carbon
  specific code, Boolean is still used because the Carbon header files
  define it to unsigned char.
- this fixes bug [ 623152 ] MacOSX: Triple Exception Booting win95.
  The bug was that some code in Bochs depends on Boolean to be a
  32 bit value.  (This should be fixed, but I don't know all the places
  where it needs to be fixed yet.)  Because Carbon defined Boolean as
  an unsigned char, Bochs just followed along and used the unsigned char
  definition to avoid compile problems.  This exposed the dependency
  on 32 bit Boolean on MacOS X only and led to major simulation problems,
  that could only be reproduced and debugged on that platform.
- On the mailing list we debated whether to make all Booleans into "bool" or
  our own type.  I chose bx_bool for several reasons.
  1. Unlike C++'s bool, we can guarantee that bx_bool is the same size on all
     platforms, which makes it much less likely to have more platform-specific
     simulation differences in the future.  (I spent hours on a borrowed
     MacOSX machine chasing bug 618388 before discovering that different sized
     Booleans were the problem, and I don't want to repeat that.)
  2. We still have at least one dependency on 32 bit Booleans which must be
     fixed some time, but I don't want to risk introducing new bugs into the
     simulation just before the 2.0 release.

Modified Files:
    bochs.h config.h.in gdbstub.cc logio.cc main.cc pc_system.cc
    pc_system.h plugin.cc plugin.h bios/rombios.c cpu/apic.cc
    cpu/arith16.cc cpu/arith32.cc cpu/arith64.cc cpu/arith8.cc
    cpu/cpu.cc cpu/cpu.h cpu/ctrl_xfer16.cc cpu/ctrl_xfer32.cc
    cpu/ctrl_xfer64.cc cpu/data_xfer16.cc cpu/data_xfer32.cc
    cpu/data_xfer64.cc cpu/debugstuff.cc cpu/exception.cc
    cpu/fetchdecode.cc cpu/flag_ctrl_pro.cc cpu/init.cc
    cpu/io_pro.cc cpu/lazy_flags.cc cpu/lazy_flags.h cpu/mult16.cc
    cpu/mult32.cc cpu/mult64.cc cpu/mult8.cc cpu/paging.cc
    cpu/proc_ctrl.cc cpu/segment_ctrl_pro.cc cpu/stack_pro.cc
    cpu/tasking.cc debug/dbg_main.cc debug/debug.h debug/sim2.cc
    disasm/dis_decode.cc disasm/disasm.h doc/docbook/Makefile
    docs-html/cosimulation.html fpu/wmFPUemu_glue.cc
    gui/amigaos.cc gui/beos.cc gui/carbon.cc gui/gui.cc gui/gui.h
    gui/keymap.cc gui/keymap.h gui/macintosh.cc gui/nogui.cc
    gui/rfb.cc gui/sdl.cc gui/siminterface.cc gui/siminterface.h
    gui/term.cc gui/win32.cc gui/wx.cc gui/wxmain.cc gui/wxmain.h
    gui/x.cc instrument/example0/instrument.cc
    instrument/example0/instrument.h
    instrument/example1/instrument.cc
    instrument/example1/instrument.h
    instrument/stubs/instrument.cc instrument/stubs/instrument.h
    iodev/cdrom.cc iodev/cdrom.h iodev/cdrom_osx.cc iodev/cmos.cc
    iodev/devices.cc iodev/dma.cc iodev/dma.h iodev/eth_arpback.cc
    iodev/eth_packetmaker.cc iodev/eth_packetmaker.h
    iodev/floppy.cc iodev/floppy.h iodev/guest2host.h
    iodev/harddrv.cc iodev/harddrv.h iodev/ioapic.cc
    iodev/ioapic.h iodev/iodebug.cc iodev/iodev.h
    iodev/keyboard.cc iodev/keyboard.h iodev/ne2k.h
    iodev/parallel.h iodev/pci.cc iodev/pci.h iodev/pic.h
    iodev/pit.cc iodev/pit.h iodev/pit_wrap.cc iodev/pit_wrap.h
    iodev/sb16.cc iodev/sb16.h iodev/serial.cc iodev/serial.h
    iodev/vga.cc iodev/vga.h memory/memory.h memory/misc_mem.cc
2002-10-25 11:44:41 +00:00
Bryce Denney
630d37269b - reset should have one arg, unsigned int type 2002-08-29 16:52:47 +00:00