VirtualBox

Ignore:
Timestamp:
Mar 5, 2018 10:59:17 AM (7 years ago)
Author:
vboxsync
Message:

SUPDrv,VMMR0: Prepped for extending the fast I/O control interface a bit for NEM; SUPDRV version increment. bugref:9044

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/solaris/SUPDrv-solaris.c

    r69500 r71198  
    664664 *
    665665 * @param   Dev             Device number
    666  * @param   Cmd             Operation identifier
     666 * @param   iCmd            Operation identifier
    667667 * @param   pArgs           Arguments from user to driver
    668668 * @param   Mode            Information bitfield (read/write, address space etc.)
     
    672672 * @return  corresponding solaris error code.
    673673 */
    674 static int VBoxDrvSolarisIOCtl(dev_t Dev, int Cmd, intptr_t pArgs, int Mode, cred_t *pCred, int *pVal)
     674static int VBoxDrvSolarisIOCtl(dev_t Dev, int iCmd, intptr_t pArgs, int Mode, cred_t *pCred, int *pVal)
    675675{
    676676#ifndef USE_SESSION_HASH
     
    708708    {
    709709        LogRel(("VBoxSupDrvIOCtl: WHAT?!? pSession == NULL! This must be a mistake... pid=%d iCmd=%#x Dev=%#x\n",
    710                     (int)Process, Cmd, (int)Dev));
     710                    (int)Process, iCmd, (int)Dev));
    711711        return EINVAL;
    712712    }
     
    717717     * the session and iCmd, and only returns a VBox status code.
    718718     */
    719     if (   (   Cmd == SUP_IOCTL_FAST_DO_RAW_RUN
    720             || Cmd == SUP_IOCTL_FAST_DO_HM_RUN
    721             || Cmd == SUP_IOCTL_FAST_DO_NOP)
     719    AssertCompile((SUP_IOCTL_FAST_DO_FIRST & 0xff) == (SUP_IOCTL_FLAG | 64));
     720    if (   (unsigned)(iCmd - SUP_IOCTL_FAST_DO_FIRST) < (unsigned)32
    722721        && pSession->fUnrestricted)
    723722    {
    724         *pVal = supdrvIOCtlFast(Cmd, pArgs, &g_DevExt, pSession);
     723        *pVal = supdrvIOCtlFast(iCmd - SUP_IOCTL_FAST_DO_FIRST, pArgs, &g_DevExt, pSession);
    725724        return 0;
    726725    }
    727726
    728     return VBoxDrvSolarisIOCtlSlow(pSession, Cmd, Mode, pArgs);
     727    return VBoxDrvSolarisIOCtlSlow(pSession, iCmd, Mode, pArgs);
    729728}
    730729
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