which notifies them that the mouse_enabled bit has changed. Now that
mouse_enabled can be initialized or modified by parameter events in
addition to GUI events, the guis must be prepared for it. I have pasted
empty method definitions into mouse_enabled_changed_specific for all
guis except for X11, which I did the right way. The implementation
of this function must use the argument "val" rather than reading the
parameter.
which notifies them that the mouse_enabled bit has changed. Now that
mouse_enabled can be initialized or modified by parameter events in
addition to GUI events, the guis must be prepared for it. I have pasted
empty method definitions into mouse_enabled_changed_specific for all
guis except for X11, which I did the right way. The implementation
of this function must use the argument "val" rather than reading the
parameter.
goes in/out of mouse capture mode. This is critical because
bx_options.Omouse_enabled is used to control whether the mouse
events are sent into the hardware queue or not (keyboard.cc).
This is only a partial fix though, because changing the mouse
enabled setting in the control panel has no effect on the gui.
> The Linux 2.4.5 CD-ROM driver sends a READ_DISC_INFO command which caused
> an "unrecognized ATAPI command" panic. Looks like READ_DISC_INFO is only
> recognized by CD-R and CD-RW drives, so I ignore it for now. (I don't
> know if ASC_INV_FIELD_IN_CMD_PACKET is the right code, but it shouldn't
> matter to Linux anyway.)
control panel are all implemented as bx_list_c, and look much like
they did before.
- removed many hardcoded UI functions from control.cc, since the
much more general "text_ask" methods have replaced them.
- add range checking on integer parameter values. This exposed several
cases where my initial value for an integer parameter was not in range.
- cleaned up behavior of get/set methods. The get/set methods allow the
handler to override the value that is returned/set, or perform side
effects.
- the title parameter of a bx_list_c now defaults to the name.
- now bx_param_c fields that used to be private are protected instead
- removed references to bx_any
- moved definition of set_handler from siminterface.h to siminterface.cc.
I was considering with doing a "set" of the old value when the
handler is first installed, but that remains commented out.
- BX_BOOT_DISKA and BX_BOOT_DISKC are now 0,1 so that they can correspond
with the values of a bx_param_enum_c. For a while they were 0x00 and 0x80
corresponding to the numbering convention of the bios, but it didn't
really matter.
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.
crash in the mouse code. The particular problem was that init_done
was never initialized to zero, but it always turned out to be zero
on my system. This may explain why it worked for me but crashed
for him.
bochs debugger needed to be updated in the same way. Instead of
using "bx_options.rom.path" as a string, it's now
bx_options.rom.path->getptr () to get the value of the parameter.
data structures, see bx_init_options in main.cc. The implementation
of this menu and all its choices is 17 lines long, see do_mem_options_menu
in gui/control.cc.
now the whole "Bochs Memory Options" menu uses new style parameters.
The next step is to remove the hardcoded stuff that generates and runs
this menu, and replace it with general menu building code. All you should
need to create this menu is the string "Bochs Memory Options", and the
IDs of the bx_param_c options that should appear on the menu. The
bx_param_c structure for each parameter tell what type it is, how to
display it, constraints on the value, what to do when the parameter
changes.
declared as bx_param_c * types in the bx_options structure. They are
initialized in main.cc (bx_init_options) with default values.
Access to parameters of this type should always be like this:
bx_options.mouse_enabled->get ();
bx_options.mouse_enabled->set (newval);
Eventually I will be transferring all options to this format.
when main.cc no longer had one. Now compiling with debugger is working
with the control panel. To get the control panel, you have to click
the snapshot button, and to get the debugger, you have to press ^C.
These should be better integrated (maybe a control panel menu choice
that jumps into the debugger and a debugger command that starts the
runtime control panel...)
better name given what the options actually are.
- now runtime menu behaves more like the others: it updates its floppy
disk image, etc.
- add "ask" as a legal choice for log action
- now runtime menu has both ways of editing log options
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.
just being careful what I wrote in the Makefile.in. But now configure
itself is substituting values for prefix and exec-prefix that include
curly brackets, so being careful was no longer good enough. If you
run .conf.win32-vcpp it will remove them.
BX_SUPPORT_APIC were used. To follow the pattern used by other
names like this, I changed them all to BX_SUPPORT_APIC.
Thanks to Tom Lindström for chasing this down!
panel. It gives the user the option of continue this time, continue
and never ask again for this type of log message, or die.
- the communication between control.cc and siminterface.cc is still
somewhat crude. I'm trying to implement it so that a network
protocol based on this interface will be simple. I'll get this cleaned
up soon.
BX_USE_CONTROL_PANEL is set. I put the #if...#endif thing around
the entire file in siminterface.cc and control.cc so that it's safe
to compile them in either case.
writes a bochsrc for you.
- since there were two options related to logging, I moved them both
into a new struct called bx_log_options. This follows the pattern
used by other devices.
- in control.cc: removed option 1 from main menu, the one that said
"Read options from bochsrc.txt." This was identical to choosing
the next option, "Read options from..." and only saved you one
keystroke, so I removed it.
an fpos_t, use ftell which returns an int. Without the patch,
Bochs gets an fpos_t and assumes it is an integer type, but
on some systems (like linux with newer glibc libraries) this
assumption is wrong. Malte Cornils <malte@cornils.net> first
reported this bug, and he warned me that ftell may not be portable
to some platforms which treat binary and ascii streams differently.
I haven't found any alternative yet.
gui/control.cc and the simulator. Now all communication between
the control panel and the rest of bochs goes through an object
called bx_simulator_interface_c.
[ #430472 ] DOS HIMEM "A20 line" error
All I've done is moved the call to print_bios_banner later in the
boot process, and the A20 problem goes away. I wanted it early so
that it would get printed before any panic or halt could happen.
Oh well.
- remove --enable-external-cpu-memory
- Neither of these options were compiling anymore, and Kevin suggested:
> My advice would be to scrap both of these options. I hadn't used
> those in some time. The way to implement 'external' devices
> would be via a modular plugin architecture, which both bochs
> and plex86 should implement.
by BCC generated data. This was pointed out by Tom Lindström
<tom@debet.shh.fi>, and I took his suggestion of moving the MP structures
to the end of the file.
I don't have to list them, and also apparantly fixes a mysterious problem
which occurred when Anders Nielsen was trying to build the RPM for
PPC: his rpm appears to gzip the man pages automatically, and then
complains that /usr/man/man1/bochs.1 is not found!
- start using autoconf/configure's standard of prefix, exec_prefix, bindir,
mandir to control where make install puts things
- added script install-x11-fonts
- make install no longer tries to install DLXlinux (since not everyone will
want it). Now you must do make install_dlx if you want it.
- renamed erase_install to uninstall
- in RPM spec file:
- run .conf.linux instead of .conf.linux-x86. This is just a name change.
- build directory hierarchy in the buildroot
- patch up broken symbolic links in buildroot (ugly)
- run font install script in %post
- clean up dlxlinux directory in %preun to avoid warning about not
removing /usr/local/bochs/dlxlinux/bochsout.txt
- remove /usr/local/bochs if nothing left in it
BX_CPU_C bx_cpu;
BX_MEM_C bx_mem;
and when more than one processor, use
BX_CPU_C *bx_cpu_array[BX_SMP_PROCESSORS];
BX_MEM_C *bx_mem_array[BX_ADDRESS_SPACES];
The changeover is controlled by BX_SMP_PROCESSORS, but there are only
a few code changes since nearly all code uses the BX_CPU(n) and BX_MEM(n)
macros.
- This turns out to make a 10% speed difference! With this revision,
the CVS version now gets 95% of the performance of the 3/25/2000
snapshot, which I've been using as my baseline.
is the first attempt to regain the performance of pre-SMP bochs
(1.1.2). When simulating only one processor, stay in cpu_loop forever
as pre-SMP versions did. The overhead of returning from cpu_loop over
and over was slowing us down.
- all bochsrc option names changed to lower case, since the uppercase
versions will not be recognized.
- BIOS is now named BIOS-bochs-latest instead of by date.
patch.linux-mouse can be applied to current CVS
patch.linux-mouse-for-1.1.2 is what Robb sent originally, which can
be applied to version 1.1.2 (bugfix3)
removed unused variables, initialized things that I had missed before,
added a missing arg to sprintf, and a return at the end of int main.
That's all.
- now the HALT macro in rombios.c writes to panic port but does not actually
execute a "hlt" instruction. This allows the .bochsrc to control
whether the BIOS panic is fatal or not.