VirtualBox

Changeset 62885 in vbox for trunk


Ignore:
Timestamp:
Aug 2, 2016 4:21:40 PM (8 years ago)
Author:
vboxsync
Message:

Devices: gcc warnings

Location:
trunk/src/VBox/Devices
Files:
15 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Bus/DevPCI.cpp

    r62629 r62885  
    21412141static DECLCALLBACK(int)   pciR3Construct(PPDMDEVINS pDevIns, int iInstance, PCFGMNODE pCfg)
    21422142{
     2143    RT_NOREF1(iInstance);
    21432144    Assert(iInstance == 0);
    21442145    PDMDEV_CHECK_VERSIONS_RETURN(pDevIns);
  • trunk/src/VBox/Devices/Bus/DevPciIch9.cpp

    r62631 r62885  
    19431943{
    19441944    PICH9PCIGLOBALS pGlobals = PDMINS_2_DATA(pDevIns, PICH9PCIGLOBALS);
    1945     PVM             pVM = PDMDevHlpGetVM(pDevIns);
    1946     Assert(pVM);
    19471945
    19481946    /*
     
    19631961     */
    19641962    for (int i = 0; i < 256; i++)
    1965     {
    19661963        ich9pciBiosInitDevice(pGlobals, 0, i);
    1967     }
    19681964
    19691965    return VINF_SUCCESS;
     
    25172513
    25182514
    2519 static DECLCALLBACK(int) ich9pciConstruct(PPDMDEVINS pDevIns,
    2520                                           int        iInstance,
    2521                                           PCFGMNODE  pCfg)
    2522 {
     2515static DECLCALLBACK(int) ich9pciConstruct(PPDMDEVINS pDevIns, int iInstance, PCFGMNODE  pCfg)
     2516{
     2517    RT_NOREF1(iInstance);
    25232518    Assert(iInstance == 0);
    25242519    PDMDEV_CHECK_VERSIONS_RETURN(pDevIns);
  • trunk/src/VBox/Devices/Bus/MsiCommon.cpp

    r62518 r62885  
    201201uint32_t MsiPciConfigRead (PPDMDEVINS pDevIns, PPCIDEVICE pDev, uint32_t u32Address, unsigned len)
    202202{
    203     int32_t iOff = u32Address - pDev->Int.s.u8MsiCapOffset;
    204 
    205     Assert(iOff >= 0 && (pciDevIsMsiCapable(pDev) && iOff < pDev->Int.s.u8MsiCapSize));
     203    RT_NOREF1(pDevIns);
     204#if defined(LOG_ENABLED) || defined(VBOX_STRICT)
     205    int32_t off = u32Address - pDev->Int.s.u8MsiCapOffset;
     206    Assert(off >= 0 && (pciDevIsMsiCapable(pDev) && off < pDev->Int.s.u8MsiCapSize));
     207#endif
    206208    uint32_t rv = 0;
    207209
     
    221223    }
    222224
    223     Log2(("MsiPciConfigRead: %d (%d) -> %x\n", iOff, len, rv));
     225    Log2(("MsiPciConfigRead: %d (%d) -> %x\n", off, len, rv));
    224226
    225227    return rv;
  • trunk/src/VBox/Devices/EFI/DevSmc.cpp

    r62610 r62885  
    582582static uint8_t scmKeyGetOSKs(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    583583{
     584    RT_NOREF1(bCmd);
    584585    Assert(SMC4CH_EQ(&pKeyDesc->Key, "OSK0") || SMC4CH_EQ(&pKeyDesc->Key, "OSK1"));
    585586    const char *pszSrc = pThis->szOsk0And1;
     
    594595static uint8_t scmKeyGetKeyCount(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    595596{
     597    RT_NOREF3(pThis, bCmd, pKeyDesc);
    596598    Assert(pKeyDesc == &g_aSmcKeys[SMC_KEYIDX_FIRST_ENUM]);
    597599    uint32_t cKeys = RT_ELEMENTS(g_aSmcKeys) - SMC_KEYIDX_FIRST_ENUM;
     
    604606static uint8_t scmKeyGetRevision(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    605607{
     608    RT_NOREF3(pThis, bCmd, pKeyDesc);
    606609#ifdef VBOX_WITH_SMC_2_x
    607610    pCurKey->Value.ab[0] = 0x02;
     
    627630static uint8_t scmKeyGetDollarAddress(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    628631{
     632    RT_NOREF3(pThis, bCmd, pKeyDesc);
    629633    pCurKey->Value.u32 = RT_H2BE_U32(SMC_PORT_FIRST);
    630634    return VINF_SUCCESS;
     
    635639static uint8_t scmKeyGetDollarNumber(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    636640{
     641    RT_NOREF2(bCmd, pKeyDesc);
    637642    pCurKey->Value.ab[0] = pThis->bDollaryNumber;
    638643    return VINF_SUCCESS;
     
    642647static uint8_t scmKeyPutDollarNumber(PDEVSMC pThis, PCDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    643648{
     649    RT_NOREF2(bCmd, pKeyDesc);
    644650    Log(("scmKeyPutDollarNumber: %#x -> %#x\n", pThis->bDollaryNumber, pCurKey->Value.ab[0]));
    645651    pThis->bDollaryNumber = pCurKey->Value.ab[0];
     
    652658static uint8_t scmKeyGetShutdownReason(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    653659{
     660    RT_NOREF2(bCmd, pKeyDesc);
    654661    pCurKey->Value.ab[0] = pThis->bShutdownReason;
    655662    return SMC_STATUS_CD_SUCCESS;
     
    660667static uint8_t scmKeyPutShutdownReason(PDEVSMC pThis, PCDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    661668{
     669    RT_NOREF2(bCmd, pKeyDesc);
    662670    Log(("scmKeyPutShutdownReason: %#x -> %#x\n", pThis->bShutdownReason, pCurKey->Value.ab[0]));
    663671    pThis->bShutdownReason = pCurKey->Value.ab[0];
     
    669677static uint8_t scmKeyGetNinjaTimerAction(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    670678{
     679    RT_NOREF2(bCmd, pKeyDesc);
    671680    pCurKey->Value.ab[0] = pThis->bNinjaActionTimerJob;
    672681    return SMC_STATUS_CD_SUCCESS;
     
    677686static uint8_t scmKeyPutNinjaTimerAction(PDEVSMC pThis, PCDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    678687{
     688    RT_NOREF2(bCmd, pKeyDesc);
    679689    Log(("scmKeyPutNinjaTimerAction: %#x -> %#x\n", pThis->bNinjaActionTimerJob, pCurKey->Value.ab[0]));
    680690    pThis->bNinjaActionTimerJob = pCurKey->Value.ab[0];
     
    687697static uint8_t scmKeyGetOne(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    688698{
     699    RT_NOREF2(pThis, bCmd);
    689700    memset(&pCurKey->Value.ab[0], 0, pKeyDesc->cbValue);
    690701    pCurKey->Value.ab[pKeyDesc->cbValue - 1] = 1;
     
    697708static uint8_t scmKeyGetZero(PDEVSMC pThis, PDEVSMCCURKEY pCurKey, uint8_t bCmd, PCDEVSMCKEYDESC pKeyDesc)
    698709{
     710    RT_NOREF2(pThis, bCmd);
    699711    memset(&pCurKey->Value.ab[0], 0, pKeyDesc->cbValue);
    700712    return SMC_STATUS_CD_SUCCESS;
     
    706718 *
    707719 * @returns Key index on success, UINT32_MAX on failure.
    708  * @param   pThis       The SMC instance data.
    709720 * @param   uKeyValue   The key value (DEVSMC4CHID.u32).
    710721 */
    711 static uint32_t smcKeyLookup(PDEVSMC pThis, uint32_t uKeyValue)
     722static uint32_t smcKeyLookup(uint32_t uKeyValue)
    712723{
    713724    uint32_t iKey = RT_ELEMENTS(g_aSmcKeys);
     
    731742    uint32_t const uKeyValueLog = RT_H2LE_U32(pThis->CurKey.Key.u32);
    732743#endif
    733     uint32_t iKey = smcKeyLookup(pThis, pThis->CurKey.Key.u32);
     744    uint32_t iKey = smcKeyLookup(pThis->CurKey.Key.u32);
    734745    if (iKey != UINT32_MAX)
    735746    {
     
    818829    uint32_t const uKeyValueLog = RT_H2LE_U32(pThis->CurKey.Key.u32);
    819830#endif
    820     uint32_t iKey = smcKeyLookup(pThis, pThis->CurKey.Key.u32);
     831    uint32_t iKey = smcKeyLookup(pThis->CurKey.Key.u32);
    821832    if (iKey != UINT32_MAX)
    822833    {
     
    851862static uint8_t smcKeyPutPrepare(PDEVSMC pThis)
    852863{
     864    RT_NOREF1(pThis);
    853865    return 0;
    854866}
     
    856868static uint8_t smcKeyPutValue(PDEVSMC pThis)
    857869{
     870    RT_NOREF1(pThis);
    858871    return 0;
    859872}
     
    869882static int smcRegData_r(PDEVSMC pThis, uint8_t uReg, uint8_t *pbValue)
    870883{
     884    RT_NOREF1(uReg);
    871885    switch (pThis->bCmd)
    872886    {
     
    958972static int smcRegData_w(PDEVSMC pThis, uint8_t uReg, uint8_t bValue)
    959973{
     974    RT_NOREF1(uReg);
    960975    switch (pThis->bCmd)
    961976    {
     
    11431158static int smcRegFF_w(PDEVSMC pThis, uint8_t uReg, uint8_t bValue)
    11441159{
     1160    RT_NOREF3(pThis, uReg, bValue);
    11451161    Log(("SMC: %#04x: Writing %#x to unknown register!\n", uReg, bValue));
    11461162    return VINF_SUCCESS;
     
    11571173static int smcRegFF_r(PDEVSMC pThis, uint8_t uReg, uint8_t *pbValue)
    11581174{
     1175    RT_NOREF2(pThis, uReg);
    11591176    Log(("SMC: %#04x: Reading from unknown register!\n", uReg));
    11601177    *pbValue = 0xff;
     
    12601277PDMBOTHCBDECL(int) smcIoPortWrite(PPDMDEVINS pDevIns, void *pvUser, RTIOPORT Port, uint32_t u32, unsigned cb)
    12611278{
     1279    RT_NOREF1(pvUser);
    12621280#ifndef IN_RING3
    12631281    if (cb > 1)
     
    13011319PDMBOTHCBDECL(int) smcIoPortRead(PPDMDEVINS pDevIns, void *pvUser, RTIOPORT Port, uint32_t *pu32, unsigned cb)
    13021320{
     1321    RT_NOREF1(pvUser);
    13031322#ifndef IN_RING3
    13041323    if (cb > 1)
     
    13521371{
    13531372    PDEVSMC pThis = PDMINS_2_DATA(pDevIns, PDEVSMC);
     1373    RT_NOREF2(pSSM, pThis);
    13541374
    13551375    /** @todo */
     
    13641384    PDEVSMC pThis = PDMINS_2_DATA(pDevIns, PDEVSMC);
    13651385    Assert(uPass == SSM_PASS_FINAL); NOREF(uPass);
     1386    RT_NOREF2(pSSM, pThis);
    13661387
    13671388    /* Fend off unsupported versions. */
     
    13881409static DECLCALLBACK(int)  smcConstruct(PPDMDEVINS pDevIns, int iInstance, PCFGMNODE pCfg)
    13891410{
     1411    RT_NOREF1(iInstance);
    13901412    PDMDEV_CHECK_VERSIONS_RETURN(pDevIns);
    13911413    PDEVSMC pThis = PDMINS_2_DATA(pDevIns, PDEVSMC);
  • trunk/src/VBox/Devices/Graphics/DevVGA.cpp

    r62632 r62885  
    22332233                               PDMIDISPLAYCONNECTOR *pDrv)
    22342234{
     2235    RT_NOREF1(fFailOnResize);
    22352236    int y, page_min, page_max, linesize, y_start;
    22362237    int width, height, page0, page1, bwidth, bits;
     
    35583559        PDMCritSectLeave(&pThis->CritSect);
    35593560        Assert(GCPtr == 0);
     3561        RT_NOREF1(GCPtr);
    35603562#endif
    35613563        return VINF_SUCCESS;
     
    54105412 * @param   enmType         One of the PCI_ADDRESS_SPACE_* values.
    54115413 */
    5412 static DECLCALLBACK(int) vgaR3IORegionMap(PPCIDEVICE pPciDev, /*unsigned*/ int iRegion, RTGCPHYS GCPhysAddress, uint32_t cb, PCIADDRESSSPACE enmType)
    5413 {
     5414static DECLCALLBACK(int) vgaR3IORegionMap(PPCIDEVICE pPciDev, /*unsigned*/ int iRegion, RTGCPHYS GCPhysAddress, uint32_t cb,
     5415                                          PCIADDRESSSPACE enmType)
     5416{
     5417    RT_NOREF1(cb);
    54145418    int         rc;
    54155419    PPDMDEVINS  pDevIns = pPciDev->pDevIns;
     
    54175421    Log(("vgaR3IORegionMap: iRegion=%d GCPhysAddress=%RGp cb=%#x enmType=%d\n", iRegion, GCPhysAddress, cb, enmType));
    54185422#ifdef VBOX_WITH_VMSVGA
    5419     AssertReturn((iRegion == ((pThis->fVMSVGAEnabled) ? 1 : 0)) && (enmType == ((pThis->fVMSVGAEnabled) ? PCI_ADDRESS_SPACE_MEM : PCI_ADDRESS_SPACE_MEM_PREFETCH)), VERR_INTERNAL_ERROR);
     5423    AssertReturn(   (iRegion == ((pThis->fVMSVGAEnabled) ? 1 : 0))
     5424                 && (enmType == ((pThis->fVMSVGAEnabled) ? PCI_ADDRESS_SPACE_MEM : PCI_ADDRESS_SPACE_MEM_PREFETCH)),
     5425                 VERR_INTERNAL_ERROR);
    54205426#else
    54215427    AssertReturn(iRegion == 0 && enmType == PCI_ADDRESS_SPACE_MEM_PREFETCH, VERR_INTERNAL_ERROR);
     
    54615467        {
    54625468#endif
    5463         rc = PGMHandlerPhysicalDeregister(PDMDevHlpGetVM(pDevIns), pThis->GCPhysVRAM);
    5464         AssertRC(rc);
     5469            rc = PGMHandlerPhysicalDeregister(PDMDevHlpGetVM(pDevIns), pThis->GCPhysVRAM);
     5470            AssertRC(rc);
    54655471#ifdef VBOX_WITH_VMSVGA
    54665472        }
     
    58915897static DECLCALLBACK(void)  vgaDetach(PPDMDEVINS pDevIns, unsigned iLUN, uint32_t fFlags)
    58925898{
     5899    RT_NOREF1(fFlags);
     5900    PVGASTATE   pThis = PDMINS_2_DATA(pDevIns, PVGASTATE);
     5901    AssertMsg(fFlags & PDM_TACH_FLAGS_NOT_HOT_PLUG, ("VGA device does not support hotplugging\n"));
     5902
    58935903    /*
    58945904     * Reset the interfaces and update the controller state.
    58955905     */
    5896     PVGASTATE   pThis = PDMINS_2_DATA(pDevIns, PVGASTATE);
    5897 
    5898     AssertMsg(fFlags & PDM_TACH_FLAGS_NOT_HOT_PLUG,
    5899               ("VGA device does not support hotplugging\n"));
    5900 
    59015906    switch (iLUN)
    59025907    {
  • trunk/src/VBox/Devices/Graphics/DevVGASavedState.h

    r62514 r62885  
    3838            uint64_t uMarker; \
    3939            int rcMarker = SSMR3GetU64(pSSM, &uMarker); \
    40             AssertLogRelRCReturn(rc, rc); \
     40            AssertLogRelRCReturn(rcMarker, rcMarker); \
    4141            AssertLogRelMsgReturn(uMarker == VGA_SAVED_STATE_MAKE_MARKER(uSub), \
    4242                                  ("Bad VGA marker: expected %llx, got %llx\n", VGA_SAVED_STATE_MAKE_MARKER(uSub), uMarker), \
  • trunk/src/VBox/Devices/Input/PS2K.cpp

    r62513 r62885  
    10131013static DECLCALLBACK(void) ps2kTypematicTimer(PPDMDEVINS pDevIns, PTMTIMER pTimer, void *pvUser)
    10141014{
    1015     PPS2K pThis = (PS2K *)pvUser; NOREF(pDevIns);
     1015    RT_NOREF2(pDevIns, pTimer);
     1016    PPS2K pThis = (PS2K *)pvUser;
    10161017    LogFlowFunc(("Typematic state=%d, key %02X\n", pThis->enmTypematicState, pThis->u8TypematicKey));
    10171018
     
    10371038static DECLCALLBACK(void) ps2kDelayTimer(PPDMDEVINS pDevIns, PTMTIMER pTimer, void *pvUser)
    10381039{
    1039     PPS2K pThis = (PS2K *)pvUser; NOREF(pDevIns);
     1040    RT_NOREF2(pDevIns, pTimer);
     1041    PPS2K pThis = (PS2K *)pvUser;
    10401042
    10411043    LogFlowFunc(("Delay timer: cmd %02X\n", pThis->u8CurrCmd));
     
    13491351int PS2KLoadDone(PPS2K pThis, PSSMHANDLE pSSM)
    13501352{
     1353    RT_NOREF1(pSSM);
     1354
    13511355    /* This *must* be done after the inital load because it may trigger
    13521356     * interrupts and change the interrupt controller state.
     
    13801384void PS2KRelocate(PPS2K pThis, RTGCINTPTR offDelta, PPDMDEVINS pDevIns)
    13811385{
     1386    RT_NOREF1(pDevIns);
    13821387    LogFlowFunc(("Relocating PS2K\n"));
    13831388    pThis->pKbdDelayTimerRC     = TMTimerRCPtr(pThis->pKbdDelayTimerR3);
     
    13881393int PS2KConstruct(PPS2K pThis, PPDMDEVINS pDevIns, void *pParent, int iInstance)
    13891394{
    1390     int     rc;
    1391 
     1395    RT_NOREF2(pDevIns, iInstance);
    13921396    LogFlowFunc(("iInstance=%d\n", iInstance));
    13931397
     
    14101414     */
    14111415    PTMTIMER pTimer;
    1412     rc = PDMDevHlpTMTimerCreate(pDevIns, TMCLOCK_REAL, ps2kTypematicTimer, pThis,
    1413                                 TMTIMER_FLAGS_DEFAULT_CRIT_SECT, "PS2K Typematic Timer", &pTimer);
     1416    int rc = PDMDevHlpTMTimerCreate(pDevIns, TMCLOCK_REAL, ps2kTypematicTimer, pThis,
     1417                                    TMTIMER_FLAGS_DEFAULT_CRIT_SECT, "PS2K Typematic Timer", &pTimer);
    14141418    if (RT_FAILURE(rc))
    14151419        return rc;
  • trunk/src/VBox/Devices/Input/PS2M.cpp

    r62513 r62885  
    835835static DECLCALLBACK(void) ps2mThrottleTimer(PPDMDEVINS pDevIns, PTMTIMER pTimer, void *pvUser)
    836836{
    837     PPS2M       pThis = (PS2M *)pvUser; NOREF(pDevIns);
     837    RT_NOREF2(pDevIns, pTimer);
     838    PPS2M       pThis = (PS2M *)pvUser;
    838839    uint32_t    uHaveEvents;
    839840
     
    868869static DECLCALLBACK(void) ps2mDelayTimer(PPDMDEVINS pDevIns, PTMTIMER pTimer, void *pvUser)
    869870{
    870     PPS2M pThis = (PS2M *)pvUser; NOREF(pDevIns);
     871    RT_NOREF2(pDevIns, pTimer);
     872    PPS2M pThis = (PS2M *)pvUser;
    871873
    872874    LogFlowFunc(("Delay timer: cmd %02X\n", pThis->u8CurrCmd));
     
    942944                              int32_t dz, int32_t dw, uint32_t fButtons)
    943945{
     946    RT_NOREF1(dw);
    944947    int             rc = VINF_SUCCESS;
    945948
     
    10791082void PS2MSaveState(PPS2M pThis, PSSMHANDLE pSSM)
    10801083{
    1081     uint32_t    cPressed = 0;
    1082 
    10831084    LogFlowFunc(("Saving PS2M state\n"));
    10841085
     
    11721173void PS2MRelocate(PPS2M pThis, RTGCINTPTR offDelta, PPDMDEVINS pDevIns)
    11731174{
     1175    RT_NOREF2(pDevIns, offDelta);
    11741176    LogFlowFunc(("Relocating PS2M\n"));
    11751177    pThis->pDelayTimerRC    = TMTimerRCPtr(pThis->pDelayTimerR3);
    11761178    pThis->pThrottleTimerRC = TMTimerRCPtr(pThis->pThrottleTimerR3);
    1177     NOREF(offDelta);
    11781179}
    11791180
    11801181int PS2MConstruct(PPS2M pThis, PPDMDEVINS pDevIns, void *pParent, int iInstance)
    11811182{
    1182     int     rc;
     1183    RT_NOREF1(iInstance);
    11831184
    11841185    LogFlowFunc(("iInstance=%d\n", iInstance));
     
    12041205     */
    12051206    PTMTIMER pTimer;
    1206     rc = PDMDevHlpTMTimerCreate(pDevIns, TMCLOCK_REAL, ps2mThrottleTimer, pThis,
    1207                                 TMTIMER_FLAGS_DEFAULT_CRIT_SECT, "PS2M Throttle Timer", &pTimer);
     1207    int rc = PDMDevHlpTMTimerCreate(pDevIns, TMCLOCK_REAL, ps2mThrottleTimer, pThis,
     1208                                    TMTIMER_FLAGS_DEFAULT_CRIT_SECT, "PS2M Throttle Timer", &pTimer);
    12081209    if (RT_FAILURE(rc))
    12091210        return rc;
  • trunk/src/VBox/Devices/Input/UsbKbd.cpp

    r62513 r62885  
    498498static int usbHidCompleteStall(PUSBHID pThis, PUSBHIDEP pEp, PVUSBURB pUrb, const char *pszWhy)
    499499{
     500    RT_NOREF1(pszWhy);
    500501    Log(("usbHidCompleteStall/#%u: pUrb=%p:%s: %s\n", pThis->pUsbIns->iInstance, pUrb, pUrb->pszDesc, pszWhy));
    501502
     
    11511152static DECLCALLBACK(int) usbHidUsbSetInterface(PPDMUSBINS pUsbIns, uint8_t bInterfaceNumber, uint8_t bAlternateSetting)
    11521153{
     1154    RT_NOREF3(pUsbIns, bInterfaceNumber, bAlternateSetting);
    11531155    LogFlow(("usbHidUsbSetInterface/#%u: bInterfaceNumber=%u bAlternateSetting=%u\n", pUsbIns->iInstance, bInterfaceNumber, bAlternateSetting));
    11541156    Assert(bAlternateSetting == 0);
     
    11631165                                                   const void *pvOldCfgDesc, const void *pvOldIfState, const void *pvNewCfgDesc)
    11641166{
     1167    RT_NOREF3(pvOldCfgDesc, pvOldIfState, pvNewCfgDesc);
    11651168    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    11661169    LogFlow(("usbHidUsbSetConfiguration/#%u: bConfigurationValue=%u\n", pUsbIns->iInstance, bConfigurationValue));
     
    11911194static DECLCALLBACK(PCPDMUSBDESCCACHE) usbHidUsbGetDescriptorCache(PPDMUSBINS pUsbIns)
    11921195{
    1193     PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
     1196    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID); RT_NOREF_PV(pThis);
    11941197    LogFlow(("usbHidUsbGetDescriptorCache/#%u:\n", pUsbIns->iInstance));
    11951198    return &g_UsbHidDescCache;
     
    12021205static DECLCALLBACK(int) usbHidUsbReset(PPDMUSBINS pUsbIns, bool fResetOnLinux)
    12031206{
     1207    RT_NOREF1(fResetOnLinux);
    12041208    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    12051209    LogFlow(("usbHidUsbReset/#%u:\n", pUsbIns->iInstance));
     
    12181222static DECLCALLBACK(void) usbHidDestruct(PPDMUSBINS pUsbIns)
    12191223{
     1224    PDMUSB_CHECK_VERSIONS_RETURN_VOID(pUsbIns);
    12201225    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    12211226    LogFlow(("usbHidDestruct/#%u:\n", pUsbIns->iInstance));
     
    12421247static DECLCALLBACK(int) usbHidConstruct(PPDMUSBINS pUsbIns, int iInstance, PCFGMNODE pCfg, PCFGMNODE pCfgGlobal)
    12431248{
     1249    RT_NOREF1(pCfgGlobal);
     1250    PDMUSB_CHECK_VERSIONS_RETURN(pUsbIns);
    12441251    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    12451252    Log(("usbHidConstruct/#%u:\n", iInstance));
  • trunk/src/VBox/Devices/Input/UsbMouse.cpp

    r62513 r62885  
    14401440 * @interface_method_impl{PDMIMOUSEPORT,pfnPutEvent}
    14411441 */
    1442 static DECLCALLBACK(int) usbHidMousePutEvent(PPDMIMOUSEPORT pInterface,
    1443                                              int32_t dx, int32_t dy, int32_t dz,
    1444                                              int32_t dw, uint32_t fButtons)
    1445 {
     1442static DECLCALLBACK(int) usbHidMousePutEvent(PPDMIMOUSEPORT pInterface, int32_t dx, int32_t dy,
     1443                                             int32_t dz, int32_t dw, uint32_t fButtons)
     1444{
     1445    RT_NOREF1(dw);
    14461446    PUSBHID pThis = RT_FROM_MEMBER(pInterface, USBHID, Lun0.IPort);
    14471447    RTCritSectEnter(&pThis->CritSect);
     
    17961796#define SET_PROTOCOL 0x0B
    17971797
    1798 static uint8_t sau8QASampleBlob[256] =
     1798static uint8_t const g_abQASampleBlob[256] =
    17991799{
    18001800    0xfc, 0x28, 0xfe, 0x84, 0x40, 0xcb, 0x9a, 0x87,
     
    18881888                else if (u8ReportType == 3 && u8ReportID == REPORTID_TOUCH_QABLOB)
    18891889                {
    1890                     uint32_t cbLeft = pUrb->cbData;
    18911890                    pUrb->abData[sizeof(VUSBSETUP) + 0] = REPORTID_TOUCH_QABLOB;  /* Report Id. */
    18921891                    memcpy(&pUrb->abData[sizeof(VUSBSETUP) + 1],
    1893                            sau8QASampleBlob, sizeof(sau8QASampleBlob));
    1894                     cbData = sizeof(sau8QASampleBlob) + 1;
     1892                           g_abQASampleBlob, sizeof(g_abQASampleBlob));
     1893                    cbData = sizeof(g_abQASampleBlob) + 1;
    18951894                }
    18961895                else if (u8ReportType == 3 && u8ReportID == REPORTID_TOUCH_DEVCONFIG)
     
    22222221                                                   const void *pvOldCfgDesc, const void *pvOldIfState, const void *pvNewCfgDesc)
    22232222{
     2223    RT_NOREF3(pvOldCfgDesc, pvOldIfState, pvNewCfgDesc);
    22242224    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    22252225    LogRelFlow(("usbHidUsbSetConfiguration/#%u: bConfigurationValue=%u\n",
     
    22742274static DECLCALLBACK(int) usbHidUsbReset(PPDMUSBINS pUsbIns, bool fResetOnLinux)
    22752275{
     2276    RT_NOREF1(fResetOnLinux);
    22762277    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    22772278    LogRelFlow(("usbHidUsbReset/#%u:\n", pUsbIns->iInstance));
     
    22902291static DECLCALLBACK(void) usbHidDestruct(PPDMUSBINS pUsbIns)
    22912292{
     2293    PDMUSB_CHECK_VERSIONS_RETURN_VOID(pUsbIns);
    22922294    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    22932295    LogRelFlow(("usbHidDestruct/#%u:\n", pUsbIns->iInstance));
     
    23132315static DECLCALLBACK(int) usbHidConstruct(PPDMUSBINS pUsbIns, int iInstance, PCFGMNODE pCfg, PCFGMNODE pCfgGlobal)
    23142316{
     2317    RT_NOREF1(pCfgGlobal);
     2318    PDMUSB_CHECK_VERSIONS_RETURN(pUsbIns);
    23152319    PUSBHID pThis = PDMINS_2_DATA(pUsbIns, PUSBHID);
    23162320    char szMode[64];
  • trunk/src/VBox/Devices/PC/DevLPC.cpp

    r62509 r62885  
    7979static uint32_t rcba_ram_readl(LPCState* s, RTGCPHYS addr)
    8080{
     81    RT_NOREF1(s);
    8182    Log(("rcba_read at %llx\n", (uint64_t)addr));
    8283    int32_t iIndex = (addr - RCBA_BASE);
     
    105106static void rcba_ram_writel(LPCState* s, RTGCPHYS addr, uint32_t value)
    106107{
     108    RT_NOREF2(s, value);
    107109    Log(("rcba_write %llx = %#x\n", (uint64_t)addr, value));
    108110    int32_t iIndex = (addr - RCBA_BASE);
     
    133135PDMBOTHCBDECL(int)  lpcMMIORead(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void *pv, unsigned cb)
    134136{
     137    RT_NOREF2(pvUser, cb);
    135138    LPCState *s = PDMINS_2_DATA(pDevIns, LPCState*);
    136139    Assert(cb == 4); Assert(!(GCPhysAddr & 3));
     
    153156PDMBOTHCBDECL(int) lpcMMIOWrite(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void const *pv, unsigned cb)
    154157{
     158    RT_NOREF1(pvUser);
    155159    LPCState *s = PDMINS_2_DATA(pDevIns, LPCState*);
    156160
     
    182186static DECLCALLBACK(void) lpcInfo(PPDMDEVINS pDevIns, PCDBGFINFOHLP pHlp, const char *pszArgs)
    183187{
     188    RT_NOREF1(pszArgs);
    184189    LPCState   *pThis = PDMINS_2_DATA(pDevIns, LPCState *);
    185190    LogFlow(("lpcInfo: \n"));
     
    210215static DECLCALLBACK(int) lpcConstruct(PPDMDEVINS pDevIns, int iInstance, PCFGMNODE pCfg)
    211216{
     217    RT_NOREF2(iInstance, pCfg);
     218    PDMDEV_CHECK_VERSIONS_RETURN(pDevIns);
    212219    LPCState   *pThis = PDMINS_2_DATA(pDevIns, LPCState *);
    213220    int         rc;
  • trunk/src/VBox/Devices/Storage/VSCSI/VSCSIDevice.cpp

    r62506 r62885  
    325325                                       size_t cbSense, void *pvVScsiReqUser)
    326326{
     327    RT_NOREF1(cbSGList);
    327328    PVSCSIDEVICEINT pVScsiDevice = (PVSCSIDEVICEINT)hVScsiDevice;
    328329    PVSCSIREQINT    pVScsiReq    = NULL;
  • trunk/src/VBox/Devices/Storage/VSCSI/VSCSILunMmc.cpp

    r62506 r62885  
    128128static int mmcReadTOCMulti(PVSCSILUNINT pVScsiLun, PVSCSIREQINT pVScsiReq, uint16_t cbMaxTransfer, bool fMSF)
    129129{
    130     PVSCSILUNMMC    pVScsiLunMmc = (PVSCSILUNMMC)pVScsiLun;
     130    RT_NOREF1(cbMaxTransfer);
    131131    uint8_t         aReply[32];
    132132    uint8_t         *pbBuf = aReply;
     
    172172static DECLCALLBACK(int) vscsiLunMmcDestroy(PVSCSILUNINT pVScsiLun)
    173173{
    174     PVSCSILUNMMC    pVScsiLunMmc = (PVSCSILUNMMC)pVScsiLun;
    175 
     174    RT_NOREF1(pVScsiLun);
    176175    return VINF_SUCCESS;
    177176}
     
    368367        case SCSI_LOG_SENSE:
    369368        {
    370             uint16_t cbMax = vscsiBE2HU16(&pVScsiReq->pbCDB[7]);
    371369            uint8_t uPageCode = pVScsiReq->pbCDB[2] & 0x3f;
    372370            uint8_t uSubPageCode = pVScsiReq->pbCDB[3];
  • trunk/src/VBox/Devices/Storage/VSCSI/VSCSILunSbc.cpp

    r62506 r62885  
    428428        case SCSI_LOG_SENSE:
    429429        {
    430             uint16_t cbMax = vscsiBE2HU16(&pVScsiReq->pbCDB[7]);
    431430            uint8_t uPageCode = pVScsiReq->pbCDB[2] & 0x3f;
    432431            uint8_t uSubPageCode = pVScsiReq->pbCDB[3];
  • trunk/src/VBox/Devices/build/VBoxDD.cpp

    r62586 r62885  
    384384{
    385385    int rc = VINF_SUCCESS;
     386    RT_NOREF1(u32Version);
    386387
    387388#ifdef VBOX_WITH_USB
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