VirtualBox

Ignore:
Timestamp:
May 5, 2009 5:12:48 PM (16 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
46899
Message:

IPRT: Implemented RTMpPokeCpu where it made sense (untested).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r0drv/freebsd/mp-r0drv-freebsd.c

    r19264 r19389  
    233233}
    234234
     235
     236#if __FreeBSD_version >= 700000
     237/**
     238 * Dummy callback for RTMpPokeCpu.
     239 * @param   pvArg   Ignored
     240 */
     241static void rtmpFreeBSDPokeCallback(void *pvArg)
     242{
     243    NOREF(pvArg);
     244}
     245
     246
     247RTDECL(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 */
     262RTDECL(int) RTMpPokeCpu(RTCPUID idCpu)
     263{
     264    return VERR_NOT_SUPPORTED;
     265}
     266#endif /* < 7.0 */
     267
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette