aboutsummaryrefslogtreecommitdiff
path: root/emulators/kqemu-kmod-devel/files
diff options
context:
space:
mode:
authorJuergen Lock <nox@FreeBSD.org>2010-01-30 17:04:34 +0000
committerJuergen Lock <nox@FreeBSD.org>2010-01-30 17:04:34 +0000
commit44c9d661ba41b52cd7351c8ff7985ff5614fd10e (patch)
treec30653a85b74da5ccc0bdb81e880d06dfb5f9621 /emulators/kqemu-kmod-devel/files
parent66d6245dbe4339de6cc23a5aa651df6ad1ce767c (diff)
downloadports-44c9d661ba41b52cd7351c8ff7985ff5614fd10e.tar.gz
ports-44c9d661ba41b52cd7351c8ff7985ff5614fd10e.zip
Notes
Diffstat (limited to 'emulators/kqemu-kmod-devel/files')
-rw-r--r--emulators/kqemu-kmod-devel/files/patch-kqemu-timeout25
1 files changed, 25 insertions, 0 deletions
diff --git a/emulators/kqemu-kmod-devel/files/patch-kqemu-timeout b/emulators/kqemu-kmod-devel/files/patch-kqemu-timeout
new file mode 100644
index 000000000000..ed53e1a18b69
--- /dev/null
+++ b/emulators/kqemu-kmod-devel/files/patch-kqemu-timeout
@@ -0,0 +1,25 @@
+Index: common/kernel.c
+@@ -1079,6 +1079,10 @@ long kqemu_exec(struct kqemu_state *s)
+ uint16_t saved_ds, saved_es;
+ unsigned long fs_base, gs_base;
+ #endif
++#if defined(__FreeBSD__)
++ extern int ticks;
++ int tstart = ticks;
++#endif
+
+ #ifdef PROFILE
+ s->nb_profile_ts = 0;
+@@ -1252,7 +1256,11 @@ long kqemu_exec(struct kqemu_state *s)
+ /* if interrupting user code, we schedule to give time
+ to the other processes. We can be interrupted by a
+ signal a that case. */
+- if (kqemu_schedule()) {
++ if (kqemu_schedule()
++#if defined(__FreeBSD__)
++ || ticks - tstart > 1
++#endif
++ ) {
+ restore_cpu_state_from_regs(s, r);
+ ret = KQEMU_RET_INTR;
+ break;