Add --enable-4meg-pages to configure
[pintos-anon] / src / misc / bochs-2.1.1.patch
index a88df1c0b2f18c223e339cf3bf940fac92d96e9a..0c233169c5feb6769b89d517ac6d7129ce0171f6 100644 (file)
@@ -29,7 +29,7 @@ unwanted patches, then follow the above instructions.
 
 Here's a ./configure invocation for Bochs that works optimally with
 the `pintos' utility:
-       ./configure --with-x --with-x11 --with-term --with-nogui
+       ./configure --enable-4meg-pages --with-x --with-x11 --with-term --with-nogui
 If you want the gdb stub, add --enable-gdb-stub
 If you want the internal debugger, add --enable-debugger
 
@@ -139,6 +139,8 @@ diff -urp orig/bochs-2.1.1/gdbstub.cc bochs-2.1.1/gdbstub.cc
              mem2hex((char *)registers, obuf, NUMREGSBYTES);
              put_reply(obuf);
              break;
+
+diff -u tmp/bochs-2.1.1/iodev/serial.cc bochs-2.1.1/iodev/serial.cc
 --- tmp/bochs-2.1.1/iodev/serial.cc    2004-02-11 14:28:54.000001000 -0800
 +++ bochs-2.1.1/iodev/serial.cc        2004-09-14 23:02:04.000001000 -0700
 @@ -53,7 +53,7 @@
@@ -196,8 +198,8 @@ diff -urp bochs-2.1.1.orig/iodev/pit82c54.cc bochs-2.1.1/iodev/pit82c54.cc
 +            unsigned n = thisctr.inlatch;
 +            if (jitter) {
 +                n *= (double) rand() / RAND_MAX;
-+                if (n < 1)
-+                    n = 1;
++                if (n < 5)
++                    n = 5;
 +            }
 +          set_count(thisctr, n);
            thisctr.next_change_time=(thisctr.count_binary-1) & 0xFFFF;