Changeset 19389 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- May 5, 2009 5:12:48 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 46899
- Location:
- trunk/src/VBox/Runtime
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/Makefile.kmk
r19387 r19389 1109 1109 generic/mppresent-generic.cpp \ 1110 1110 nt/RTErrConvertFromNtStatus.cpp \ 1111 r0drv/generic/RTMpPokeCpu-r0drv-generic.cpp \ 1111 1112 r0drv/memobj-r0drv.cpp \ 1112 1113 r0drv/mpnotification-r0drv.c \ … … 1315 1316 ifdef VBOX_WITH_SOLARIS_VBI 1316 1317 RuntimeR0Drv_SOURCES.solaris += \ 1318 r0drv/generic/RTMpPokeCpu-r0drv-generic.cpp \ 1317 1319 r0drv/solaris/vbi/mpnotification-r0drv-solaris.c \ 1318 1320 r0drv/solaris/vbi/alloc-r0drv-solaris.c \ … … 1351 1353 generic/RTMpIsCpuOnline-generic.cpp \ 1352 1354 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \ 1353 r0drv/generic/RTMpOn-r0drv-generic.cpp 1355 r0drv/generic/RTMpOn-r0drv-generic.cpp \ 1356 r0drv/generic/RTMpPokeCpu-r0drv-generic.cpp 1354 1357 else 1355 1358 # Use mp-r0drv-solaris.c. 1356 1359 RuntimeR0Drv_SOURCES.solaris += \ 1357 r0drv/solaris/mp-r0drv-solaris.c 1360 r0drv/solaris/mp-r0drv-solaris.c \ 1361 r0drv/generic/RTMpPokeCpu-r0drv-generic.cpp 1358 1362 # r0drv/solaris/mpnotification-r0drv-solaris.c 1359 1363 endif … … 1399 1403 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \ 1400 1404 r0drv/generic/RTMpOn-r0drv-generic.cpp \ 1405 r0drv/generic/RTMpPokeCpu-r0drv-generic.cpp \ 1401 1406 r0drv/generic/mpnotification-r0drv-generic.cpp \ 1402 1407 r0drv/solaris/alloc-r0drv-solaris.c \ -
trunk/src/VBox/Runtime/r0drv/darwin/mp-r0drv-darwin.cpp
r19056 r19389 275 275 } 276 276 277 278 RTDECL(int) RTMpPokeCpu(RTCPUID idCpu) 279 { 280 /* no unicast IPI */ 281 return VERR_NOT_SUPPORTED; 282 } 283 -
trunk/src/VBox/Runtime/r0drv/freebsd/mp-r0drv-freebsd.c
r19264 r19389 233 233 } 234 234 235 236 #if __FreeBSD_version >= 700000 237 /** 238 * Dummy callback for RTMpPokeCpu. 239 * @param pvArg Ignored 240 */ 241 static void rtmpFreeBSDPokeCallback(void *pvArg) 242 { 243 NOREF(pvArg); 244 } 245 246 247 RTDECL(int) RTMpPokeCpu(RTCPUID idCpu) 248 { 249 cpumask_t Mask; 250 251 /* Will panic if no rendezvouing cpus, so make sure the cpu is online. */ 252 if (!RTMpIsCpuOnline(idCpu)) 253 return VERR_CPU_NOT_FOUND; 254 255 Mask = (cpumask_t)1 << idCpu; 256 smp_rendezvous_cpus(Mask, NULL, rtmpFreeBSDPokeCallback, NULL, NULL); 257 258 return VINF_SUCCESS; 259 } 260 261 #else /* < 7.0 */ 262 RTDECL(int) RTMpPokeCpu(RTCPUID idCpu) 263 { 264 return VERR_NOT_SUPPORTED; 265 } 266 #endif /* < 7.0 */ 267 -
trunk/src/VBox/Runtime/r0drv/linux/mp-r0drv-linux.c
r15843 r19389 320 320 } 321 321 322 323 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19) 324 /** 325 * Dummy callback used by RTMpPokeCpu. 326 * 327 * @param pvInfo Ignored. 328 */ 329 static void rtmpLinuxPokeCpuCallback(void *pvInfo) 330 { 331 NOREF(pvInfo); 332 } 333 #endif 334 335 336 RTDECL(int) RTMpPokeCpu(RTCPUID idCpu) 337 { 338 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19) 339 int rc; 340 341 if (!RTMpIsCpuPossible(idCpu)) 342 return VERR_CPU_NOT_FOUND; 343 if (!RTMpIsCpuOnline(idCpu)) 344 return VERR_CPU_OFFLINE; 345 346 # if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27) 347 rc = smp_call_function_single(idCpu, rtmpLinuxPokeCpuCallback, NULL, 0 /* wait */); 348 # elif LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19) 349 rc = smp_call_function_single(idCpu, rtmpLinuxPokeCpuCallback, NULL, 0 /* retry */, 0 /* wait */); 350 # else /* older kernels */ 351 # error oops 352 # endif /* older kernels */ 353 Assert(rc == 0); 354 return VINF_SUCCESS; 355 356 #else /* older kernels */ 357 /* no unicast here? */ 358 return VERR_NOT_SUPPORTED; 359 #endif /* older kernels */ 360 } 361
Note:
See TracChangeset
for help on using the changeset viewer.