blob: c2cdf7963fd715fed670d3d9f083fd5055b8feec (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
Index: src/VBox/Runtime/r0drv/freebsd/semevent-r0drv-freebsd.c
@@ -205,15 +205,23 @@ static int rtSemEventWait(RTSEMEVENT Eve
RTSpinlockRelease(pEventInt->hSpinLock, &Tmp);
+#if __FreeBSD_version >=800026
if (fInterruptible)
rc = sleepq_timedwait_sig(pEventInt, 0);
else
rc = sleepq_timedwait(pEventInt, 0);
+#else
+ if (fInterruptible)
+ rc = sleepq_timedwait_sig(pEventInt);
+ else
+ rc = sleepq_timedwait(pEventInt);
+#endif
}
else
{
RTSpinlockRelease(pEventInt->hSpinLock, &Tmp);
+#if __FreeBSD_version >=800026
if (fInterruptible)
rc = sleepq_wait_sig(pEventInt, 0);
else
@@ -221,6 +229,15 @@ static int rtSemEventWait(RTSEMEVENT Eve
rc = 0;
sleepq_wait(pEventInt, 0);
}
+#else
+ if (fInterruptible)
+ rc = sleepq_wait_sig(pEventInt);
+ else
+ {
+ rc = 0;
+ sleepq_wait(pEventInt);
+ }
+#endif
}
RTSpinlockAcquire(pEventInt->hSpinLock, &Tmp);
|