VirtualBox

Changeset 63409 in vbox for trunk/src/VBox/Additions/common


Ignore:
Timestamp:
Aug 13, 2016 1:53:02 AM (8 years ago)
Author:
vboxsync
Message:

VBoxGuest-netbsd.c: Use func in Log messages instead of hardcoding
the function name.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuest-netbsd.c

    r63408 r63409  
    257257     */
    258258    if (IOCPARM_LEN(command) != sizeof(VBGLBIGREQ)) {
    259         Log((DEVICE_NAME ": VBoxGuestFreeBSDIOCtl: bad request %lu size=%lu expected=%d\n", command, IOCPARM_LEN(command), sizeof(VBGLBIGREQ)));
     259        Log((DEVICE_NAME ": %s: bad request %lu size=%lu expected=%d\n",
     260             __func__, command, IOCPARM_LEN(command), sizeof(VBGLBIGREQ)));
    260261        return ENOTTY;
    261262    }
     
    264265    if (ReqWrap->u32Magic != VBGLBIGREQ_MAGIC)
    265266    {
    266         Log((DEVICE_NAME ": VBoxGuestNetBSDIOCtl: bad magic %#x; pArg=%p Cmd=%lu.\n", ReqWrap->u32Magic, data, command));
     267        Log((DEVICE_NAME ": %s: bad magic %#x; pArg=%p Cmd=%lu.\n",
     268             __func__, ReqWrap->u32Magic, data, command));
    267269        return EINVAL;
    268270    }
     
    280282    if (RT_UNLIKELY(!pvBuf))
    281283    {
    282         Log((DEVICE_NAME ":VBoxGuestNetBSDIOCtl: RTMemTmpAlloc failed to alloc %d bytes.\n", ReqWrap->cbData));
     284        Log((DEVICE_NAME ": %s: RTMemTmpAlloc failed to alloc %d bytes.\n",
     285             __func__, ReqWrap->cbData));
    283286        return ENOMEM;
    284287    }
     
    288291    {
    289292        RTMemTmpFree(pvBuf);
    290         Log((DEVICE_NAME ":VBoxGuestNetBSDIOCtl: copyin failed; pvBuf=%p pArg=%p Cmd=%lu. rc=%d\n", pvBuf, data, command, rc));
     293        Log((DEVICE_NAME ": %s: copyin failed; pvBuf=%p pArg=%p Cmd=%lu. rc=%d\n",
     294             __func__, pvBuf, data, command, rc));
    291295aprint_error_dev(vboxguest->sc_dev, "copyin failed\n");
    292296        return EFAULT;
     
    296300    {
    297301        RTMemTmpFree(pvBuf);
    298         Log((DEVICE_NAME ":VBoxGuestNetBSDIOCtl: pvBuf invalid pointer %p\n", pvBuf));
     302        Log((DEVICE_NAME ": %s: pvBuf invalid pointer %p\n",
     303             __func__, pvBuf));
    299304        return EINVAL;
    300305    }
     
    309314        if (RT_UNLIKELY(cbDataReturned > ReqWrap->cbData))
    310315        {
    311             Log((DEVICE_NAME ":VBoxGuestNetBSDIOCtl: too much output data %d expected %d\n", cbDataReturned, ReqWrap->cbData));
     316            Log((DEVICE_NAME ": %s: too much output data %d expected %d\n",
     317                 cbDataReturned, ReqWrap->cbData));
    312318            cbDataReturned = ReqWrap->cbData;
    313319        }
     
    317323            if (RT_UNLIKELY(rc))
    318324            {
    319                 Log((DEVICE_NAME ":VBoxGuestNetBSDIOCtl: copyout failed; pvBuf=%p pArg=%p. rc=%d\n", pvBuf, data, rc));
     325                Log((DEVICE_NAME ": %s: copyout failed; pvBuf=%p pArg=%p. rc=%d\n",
     326                     __func__, pvBuf, data, rc));
    320327            }
    321328        }
    322329    } else {
    323         Log((DEVICE_NAME ":VBoxGuestNetBSDIOCtl: VGDrvCommonIoCtl failed. rc=%d\n", rc));
     330        Log((DEVICE_NAME ": %s: VGDrvCommonIoCtl failed. rc=%d\n",
     331             __func__, rc));
    324332        rc = -rc;
    325333    }
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