VirtualBox

Changeset 81600 in vbox


Ignore:
Timestamp:
Oct 30, 2019 8:58:44 PM (5 years ago)
Author:
vboxsync
Message:

VBoxApfsJmpStartDxe: Make cl.exe happy

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/EFI/Firmware/VBoxPkg/VBoxApfsJmpStartDxe/VBoxApfsJmpStartDxe.c

    r81598 r81600  
    116116static EFI_STATUS vboxApfsJmpStartLoadAndExecEfiDriver(IN PAPFSJMPSTARTCTX pCtx, IN PCAPFSNXSUPERBLOCK pSb)
    117117{
    118     uint32_t cbReadLeft = RT_LE2H_U32(pCtx->JmpStart.Hdr.cbEfiFile);
     118    UINTN cbReadLeft = RT_LE2H_U32(pCtx->JmpStart.Hdr.cbEfiFile);
    119119    EFI_STATUS rc = EFI_SUCCESS;
    120120
     
    122122    if (pvApfsDrv)
    123123    {
     124        uint32_t i = 0;
    124125        uint8_t *pbBuf = (uint8_t *)pvApfsDrv;
    125126
    126         for (uint32_t i = 0; i < RT_LE2H_U32(pCtx->JmpStart.Hdr.cExtents) && !EFI_ERROR(rc) && cbReadLeft; i++)
     127        for (i = 0; i < RT_LE2H_U32(pCtx->JmpStart.Hdr.cExtents) && !EFI_ERROR(rc) && cbReadLeft; i++)
    127128        {
    128129            PCAPFSPRANGE pRange = &pCtx->JmpStart.aExtents[i];
    129             size_t cbRead = RT_MIN(cbReadLeft, RT_LE2H_U64(pRange->cBlocks) * pCtx->cbBlock);
     130            UINTN cbRead = RT_MIN(cbReadLeft, RT_LE2H_U64(pRange->cBlocks) * pCtx->cbBlock);
    130131
    131132            rc = vboxApfsJmpStartRead(pCtx, RT_LE2H_U64(pRange->PAddrStart), pbBuf, cbRead);
     
    247248                       IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath OPTIONAL)
    248249{
     250    APFSJMPSTARTCTX Ctx;
     251
    249252    /* Check whether the driver was already loaded from this controller. */
    250253    EFI_STATUS rc = gBS->OpenProtocol(ControllerHandle,
     
    257260        return EFI_UNSUPPORTED;
    258261
    259     APFSJMPSTARTCTX Ctx;
    260262    Ctx.cbBlock = 0; /* Will get filled when the superblock was read (starting at 0 anyway). */
    261263    Ctx.hController = ControllerHandle;
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