VirtualBox

Changeset 50965 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Apr 3, 2014 2:34:51 PM (11 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
93123
Message:

DevPS2: Saved state update for new PS/2 mouse emulation. Curretly disabled.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Input/DevPS2.cpp

    r49886 r50965  
    5353#include "PS2Dev.h"
    5454
    55 /* Do not remove this (unless eliminating the corresponding ifdefs), it willi
     55/* Do not remove this (unless eliminating the corresponding ifdefs), it will
    5656 * cause instant triple faults when booting Windows VMs. */
    5757#define TARGET_I386
    5858
     59#ifndef VBOX_WITH_NEW_PS2M
    5960#define PCKBD_SAVED_STATE_VERSION 7
    60 
     61#else
     62#define PCKBD_SAVED_STATE_VERSION 8
     63#endif
    6164
    6265#ifndef VBOX_DEVICE_STRUCT_TESTCASE
     
    11811184    s->mouse_event_queue.rptr = 0;
    11821185    s->mouse_event_queue.wptr = 0;
     1186#else
     1187    if (version_id <= 7)
     1188    {
     1189        int32_t     i32Dummy;
     1190        SSMR3GetU32(pSSM, &u32Dummy);
     1191        SSMR3GetU8(pSSM, &u8Dummy);
     1192        SSMR3GetU8(pSSM, &u8Dummy);
     1193        SSMR3GetU8(pSSM, &u8Dummy);
     1194        SSMR3GetU8(pSSM, &u8Dummy);
     1195        SSMR3GetU8(pSSM, &u8Dummy);
     1196        SSMR3GetU8(pSSM, &u8Dummy);
     1197        SSMR3GetS32(pSSM, &i32Dummy);
     1198        SSMR3GetS32(pSSM, &i32Dummy);
     1199        SSMR3GetS32(pSSM, &i32Dummy);
     1200        if (version_id > 2)
     1201        {
     1202            SSMR3GetS32(pSSM, &i32Dummy);
     1203            SSMR3GetS32(pSSM, &i32Dummy);
     1204        }
     1205        SSMR3GetU8(pSSM, &u8Dummy);
     1206        if (version_id == 4)
     1207        {
     1208            SSMR3GetU32(pSSM, &u32Dummy);
     1209            SSMR3GetU32(pSSM, &u32Dummy);
     1210        }
     1211        if (version_id > 3)
     1212            SSMR3GetU8(pSSM, &u8Dummy);
     1213        if (version_id == 4)
     1214            SSMR3GetU8(pSSM, &u8Dummy);
     1215    }
    11831216#endif
    11841217
     
    12401273    Log(("kbd_load: %d mouse event queue items loaded\n", u32));
    12411274#else
    1242     if (version_id <= 6)
     1275    if (version_id <= 7)
    12431276    {
    12441277        rc = SSMR3GetU32(pSSM, &u32);
     
    12521285        }
    12531286        Log(("kbd_load: %d mouse event queue items discarded from old saved state\n", u32));
     1287
     1288        rc = SSMR3GetU32(pSSM, &u32);
     1289        if (RT_FAILURE(rc))
     1290            return rc;
     1291        for (i = 0; i < u32; i++)
     1292        {
     1293            rc = SSMR3GetU8(pSSM, &u8Dummy);
     1294            if (RT_FAILURE(rc))
     1295                return rc;
     1296        }
     1297        Log(("kbd_load: %d mouse command queue items discarded from old saved state\n", u32));
    12541298    }
    12551299#endif
     
    14191463        rc = PS2KLoadState(&pThis->Kbd, pSSM, uVersion);
    14201464#ifdef VBOX_WITH_NEW_PS2M
    1421     if (uVersion >= 7)
     1465    if (uVersion >= 8)
    14221466        rc = PS2MLoadState(&pThis->Aux, pSSM, uVersion);
    14231467#endif
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette