openbsd-ports/emulators/bochs/patches/patch-iodev_guest2host_cc
todd 923f7975fe o take over maintainership
o too many changes to mention specifically, but amongst them:
	- better error reporting
	- openbsd boots, freebsd boots
	- new 'term' flavor, I added a textmode interface, the only drawback
	  is that control-c is intercepted, and you must kill -9 it from
	  another tty if it doesn't exit normally
	- new flavors:
		- debugger -> debug (for shortness)
		- i386
		- pci
		- smp
		- net (compiles, does not yet provide networking, if anyone
			wants to help, I'd be ELATED to have this fixed!)
		- no_x11 (made it actually work)
		- term (make sure to use 'log: /dev/null' or something else
		  on the cmdline, otherwise, debugging and the screen will
		  start getting quite confusing!)
	- better error reporting (and no error reporting where it is not
	  necessary; a typicall boot of cdrom28.fs is a screenful of output now)
	- in general, if the hardware reaches an unknown state, fail
	  gracefully instead of calling exit(1) .. are we trying to work or
	  are we trying to .. fail?  I like working myself.
2001-02-02 16:59:05 +00:00

66 lines
2.4 KiB
Plaintext

$OpenBSD: patch-iodev_guest2host_cc,v 1.1 2001/02/02 16:59:11 todd Exp $
--- iodev/guest2host.cc.orig Sat Mar 25 21:28:49 2000
+++ iodev/guest2host.cc Tue Oct 17 12:04:02 2000
@@ -72,7 +72,7 @@ bx_g2h_c::aquire_channel(bx_g2h_callback
}
}
- bx_printf("g2h: attempt to aquire channel: maxed out\n");
+ bio->printf("g2h: attempt to aquire channel: maxed out\n");
return(BX_G2H_ERROR); // No more free channels
}
@@ -81,7 +81,7 @@ bx_g2h_c::deaquire_channel(unsigned chan
{
if ( (channel >= BX_MAX_G2H_CHANNELS) ||
(bx_g2h.s.callback[channel].used==0) ) {
- bx_panic("g2h: attempt to deaquire channel %u: not aquired\n",
+ bio->panic("g2h: attempt to deaquire channel %u: not aquired\n",
channel);
}
bx_g2h.s.callback[channel].used = 0;
@@ -99,11 +99,11 @@ bx_g2h_c::inp_handler(void *this_ptr, Bi
UNUSED(this_ptr);
if (addr != BX_G2H_PORT)
- bx_panic("g2h: IO read not aligned on dword boundary.\n");
+ bio->panic("g2h: IO read not aligned on dword boundary.\n");
if (io_len != 4)
- bx_panic("g2h: IO read not dword.\n");
+ bio->panic("g2h: IO read not dword.\n");
- bx_panic("g2h: IO read not complete.\n");
+ bio->panic("g2h: IO read not complete.\n");
return(0);
}
@@ -116,12 +116,12 @@ bx_g2h_c::outp_handler(void *this_ptr, B
UNUSED(this_ptr);
if (addr != BX_G2H_PORT)
- bx_panic("g2h: IO write not aligned on dword boundary.\n");
+ bio->panic("g2h: IO write not aligned on dword boundary.\n");
if (io_len != 4)
- bx_panic("g2h: IO write not dword.\n");
+ bio->panic("g2h: IO write not dword.\n");
if ( (bx_g2h.s.packet_count==0) && (val32!=BX_G2H_MAGIC) ) {
- bx_printf("g2h: IO W: Not magic header.\n");
+ bio->printf("g2h: IO W: Not magic header.\n");
return;
}
bx_g2h.s.guest_packet[bx_g2h.s.packet_count++] = val32;
@@ -131,10 +131,10 @@ bx_g2h_c::outp_handler(void *this_ptr, B
// Full packet received from guest. Pass on to the host code.
channel = bx_g2h.s.guest_packet[1];
if (channel >= BX_MAX_G2H_CHANNELS) {
- bx_panic("g2h: channel (%u) out of bounds\n", channel);
+ bio->panic("g2h: channel (%u) out of bounds\n", channel);
}
if (bx_g2h.s.callback[channel].used==0) {
- bx_panic("g2h: channel (%u) not active\n", channel);
+ bio->panic("g2h: channel (%u) not active\n", channel);
}
bx_g2h.s.callback[channel].f(&bx_g2h.s.guest_packet);
bx_g2h.s.packet_count = 0; // Ready for next packet