VirtualBox

Changeset 35214 in vbox


Ignore:
Timestamp:
Dec 17, 2010 10:10:07 AM (14 years ago)
Author:
vboxsync
Message:

AHCI: Fix wrong Led assignments

Location:
trunk/src/VBox/Devices/Storage
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Storage/ATAController.cpp

    r34339 r35214  
    54435443}
    54445444
    5445 DECLCALLBACK(int) ataControllerInit(PPDMDEVINS pDevIns, PAHCIATACONTROLLER pCtl,
    5446                                     unsigned iLUNMaster, PPDMIBASE pDrvBaseMaster,
    5447                                     unsigned iLUNSlave, PPDMIBASE pDrvBaseSlave,
    5448                                     uint32_t *pcbSSMState, const char *szName, PPDMLED pLed,
    5449                                     PSTAMCOUNTER pStatBytesRead, PSTAMCOUNTER pStatBytesWritten)
     5445int ataControllerInit(PPDMDEVINS pDevIns, PAHCIATACONTROLLER pCtl,
     5446                      unsigned iLUNMaster, PPDMIBASE pDrvBaseMaster, PPDMLED pLedMaster,
     5447                      PSTAMCOUNTER pStatBytesReadMaster, PSTAMCOUNTER pStatBytesWrittenMaster,
     5448                      unsigned iLUNSlave, PPDMIBASE pDrvBaseSlave, PPDMLED pLedSlave,
     5449                      PSTAMCOUNTER pStatBytesReadSlave, PSTAMCOUNTER pStatBytesWrittenSlave,
     5450                      uint32_t *pcbSSMState, const char *szName)
    54505451{
    54515452    int      rc;
     
    54705471        pCtl->aIfs[j].pControllerR0     = MMHyperR3ToR0(PDMDevHlpGetVM(pDevIns), pCtl);
    54715472        pCtl->aIfs[j].pControllerRC     = MMHyperR3ToRC(PDMDevHlpGetVM(pDevIns), pCtl);
    5472         pCtl->aIfs[j].pLed              = pLed;
    5473         pCtl->aIfs[j].pStatBytesRead    = pStatBytesRead;
    5474         pCtl->aIfs[j].pStatBytesWritten = pStatBytesWritten;
     5473        pCtl->aIfs[j].pLed              = j == 0 ? pLedMaster : pLedSlave;
     5474        pCtl->aIfs[j].pStatBytesRead    = j == 0 ? pStatBytesReadMaster : pStatBytesReadSlave;
     5475        pCtl->aIfs[j].pStatBytesWritten = j == 0 ? pStatBytesWrittenMaster : pStatBytesWrittenSlave;
    54755476    }
    54765477
  • trunk/src/VBox/Devices/Storage/ATAController.h

    r33540 r35214  
    421421 */
    422422int ataControllerInit(PPDMDEVINS pDevIns, PAHCIATACONTROLLER pCtl,
    423                       unsigned iLUNMaster, PPDMIBASE pDrvBaseMaster,
    424                       unsigned iLUNSlave, PPDMIBASE pDrvBaseSlave,
    425                       uint32_t *pcbSSMState, const char *szName, PPDMLED pLed, PSTAMCOUNTER pStatBytesRead, PSTAMCOUNTER pStatBytesWritten);
     423                      unsigned iLUNMaster, PPDMIBASE pDrvBaseMaster, PPDMLED pLedMaster,
     424                      PSTAMCOUNTER pStatBytesReadMaster, PSTAMCOUNTER pStatBytesWrittenMaster,
     425                      unsigned iLUNSlave, PPDMIBASE pDrvBaseSlave, PPDMLED pLedSlave,
     426                      PSTAMCOUNTER pStatBytesReadSlave, PSTAMCOUNTER pStatBytesWrittenSlave,
     427                      uint32_t *pcbSSMState, const char *szName);
    426428
    427429/**
  • trunk/src/VBox/Devices/Storage/DevAHCI.cpp

    r34875 r35214  
    81718171            rc = ataControllerInit(pDevIns, pCtl,
    81728172                                   iPortMaster, pThis->ahciPort[iPortMaster].pDrvBase,
     8173                                   &pThis->ahciPort[iPortMaster].Led,
     8174                                   &pThis->ahciPort[iPortMaster].StatBytesRead,
     8175                                   &pThis->ahciPort[iPortMaster].StatBytesWritten,
    81738176                                   iPortSlave, pThis->ahciPort[iPortSlave].pDrvBase,
    8174                                    &cbSSMState, szName, &pThis->ahciPort[iPortMaster].Led,
    8175                                    &pThis->ahciPort[iPortMaster].StatBytesRead,
    8176                                    &pThis->ahciPort[iPortMaster].StatBytesWritten);
     8177                                   &pThis->ahciPort[iPortSlave].Led,
     8178                                   &pThis->ahciPort[iPortSlave].StatBytesRead,
     8179                                   &pThis->ahciPort[iPortSlave].StatBytesWritten,
     8180                                   &cbSSMState, szName);
    81778181            if (RT_FAILURE(rc))
    81788182                return rc;
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