VirtualBox

Changeset 44521 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Feb 1, 2013 11:14:54 PM (12 years ago)
Author:
vboxsync
Message:

tstSSM: Fixed the testcase after the device critsect change.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified trunk/src/VBox/VMM/testcase/tstSSM.cpp

    r41965 r44521  
    55
    66/*
    7  * Copyright (C) 2006-2007 Oracle Corporation
     7 * Copyright (C) 2006-2013 Oracle Corporation
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    9999 *
    100100 * @returns VBox status code.
    101  * @param   pDevIns         Device instance of the device which registered the data unit.
     101 * @param   pVM             The cross context VM handle.
    102102 * @param   pSSM            SSM operation handle.
    103103 */
    104 DECLCALLBACK(int) Item01Save(PPDMDEVINS pDevIns, PSSMHANDLE pSSM)
     104DECLCALLBACK(int) Item01Save(PVM pVM, PSSMHANDLE pSSM)
    105105{
    106106    uint64_t u64Start = RTTimeNanoTS();
    107     NOREF(pDevIns);
     107    NOREF(pVM);
    108108
    109109    /*
     
    182182 *
    183183 * @returns VBox status code.
    184  * @param   pDevIns         Device instance of the device which registered the data unit.
     184 * @param   pVM             The cross context VM handle.
    185185 * @param   pSSM            SSM operation handle.
    186186 * @param   uVersion        The data layout version.
    187187 * @param   uPass           The data pass.
    188188 */
    189 DECLCALLBACK(int) Item01Load(PPDMDEVINS pDevIns, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
    190 {
    191     NOREF(pDevIns); NOREF(uPass);
     189DECLCALLBACK(int) Item01Load(PVM pVM, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
     190{
     191    NOREF(pVM); NOREF(uPass);
    192192    if (uVersion != 0)
    193193    {
     
    278278 *
    279279 * @returns VBox status code.
    280  * @param   pDevIns         Device instance of the device which registered the data unit.
     280 * @param   pVM             The cross context VM handle.
    281281 * @param   pSSM            SSM operation handle.
    282282 */
    283 DECLCALLBACK(int) Item02Save(PPDMDEVINS pDevIns, PSSMHANDLE pSSM)
    284 {
    285     NOREF(pDevIns);
     283DECLCALLBACK(int) Item02Save(PVM pVM, PSSMHANDLE pSSM)
     284{
     285    NOREF(pVM);
    286286    uint64_t u64Start = RTTimeNanoTS();
    287287
     
    340340 *
    341341 * @returns VBox status code.
    342  * @param   pDevIns         Device instance of the device which registered the data unit.
     342 * @param   pVM             The cross context VM handle.
    343343 * @param   pSSM            SSM operation handle.
    344344 * @param   uVersion        The data layout version.
    345345 * @param   uPass           The data pass.
    346346 */
    347 DECLCALLBACK(int) Item02Load(PPDMDEVINS pDevIns, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
    348 {
    349     NOREF(pDevIns); NOREF(uPass);
     347DECLCALLBACK(int) Item02Load(PVM pVM, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
     348{
     349    NOREF(pVM); NOREF(uPass);
    350350    if (uVersion != 0)
    351351    {
     
    408408 *
    409409 * @returns VBox status code.
    410  * @param   pDevIns         Device instance of the device which registered the data unit.
     410 * @param   pVM             The cross context VM handle.
    411411 * @param   pSSM            SSM operation handle.
    412412 */
    413 DECLCALLBACK(int) Item03Save(PPDMDEVINS pDevIns, PSSMHANDLE pSSM)
    414 {
    415     NOREF(pDevIns);
     413DECLCALLBACK(int) Item03Save(PVM pVM, PSSMHANDLE pSSM)
     414{
     415    NOREF(pVM);
    416416    uint64_t u64Start = RTTimeNanoTS();
    417417
     
    456456 *
    457457 * @returns VBox status code.
    458  * @param   pDevIns         Device instance of the device which registered the data unit.
     458 * @param   pVM             The cross context VM handle.
    459459 * @param   pSSM            SSM operation handle.
    460460 * @param   uVersion        The data layout version.
    461461 * @param   uPass           The data pass.
    462462 */
    463 DECLCALLBACK(int) Item03Load(PPDMDEVINS pDevIns, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
    464 {
    465     NOREF(pDevIns); NOREF(uPass);
     463DECLCALLBACK(int) Item03Load(PVM pVM, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
     464{
     465    NOREF(pVM); NOREF(uPass);
    466466    if (uVersion != 123)
    467467    {
     
    520520 *
    521521 * @returns VBox status code.
    522  * @param   pDevIns         Device instance of the device which registered the data unit.
     522 * @param   pVM             The cross context VM handle.
    523523 * @param   pSSM            SSM operation handle.
    524524 */
    525 DECLCALLBACK(int) Item04Save(PPDMDEVINS pDevIns, PSSMHANDLE pSSM)
    526 {
    527     NOREF(pDevIns);
     525DECLCALLBACK(int) Item04Save(PVM pVM, PSSMHANDLE pSSM)
     526{
     527    NOREF(pVM);
    528528    uint64_t u64Start = RTTimeNanoTS();
    529529
     
    564564 *
    565565 * @returns VBox status code.
    566  * @param   pDevIns         Device instance of the device which registered the data unit.
     566 * @param   pVM             The cross context VM handle.
    567567 * @param   pSSM            SSM operation handle.
    568568 * @param   uVersion        The data layout version.
    569569 * @param   uPass           The data pass.
    570570 */
    571 DECLCALLBACK(int) Item04Load(PPDMDEVINS pDevIns, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
    572 {
    573     NOREF(pDevIns); NOREF(uPass);
     571DECLCALLBACK(int) Item04Load(PVM pVM, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
     572{
     573    NOREF(pVM); NOREF(uPass);
    574574    if (uVersion != 42)
    575575    {
     
    710710     * Register a few callbacks.
    711711     */
    712     rc = SSMR3RegisterDevice(pVM, NULL, "SSM Testcase Data Item no.1 (all types)", 1, 0, 256, NULL,
    713                              NULL, NULL, NULL,
    714                              NULL, Item01Save, NULL,
    715                              NULL, Item01Load, NULL);
     712    rc = SSMR3RegisterInternal(pVM, "SSM Testcase Data Item no.1 (all types)", 1, 0, 256,
     713                               NULL, NULL, NULL,
     714                               NULL, Item01Save, NULL,
     715                               NULL, Item01Load, NULL);
    716716    if (RT_FAILURE(rc))
    717717    {
     
    720720    }
    721721
    722     rc = SSMR3RegisterDevice(pVM, NULL, "SSM Testcase Data Item no.2 (rand mem)", 2, 0, _1M * 8, NULL,
    723                              NULL, NULL, NULL,
    724                              NULL, Item02Save, NULL,
    725                              NULL, Item02Load, NULL);
     722    rc = SSMR3RegisterInternal(pVM, "SSM Testcase Data Item no.2 (rand mem)", 2, 0, _1M * 8,
     723                               NULL, NULL, NULL,
     724                               NULL, Item02Save, NULL,
     725                               NULL, Item02Load, NULL);
    726726    if (RT_FAILURE(rc))
    727727    {
     
    730730    }
    731731
    732     rc = SSMR3RegisterDevice(pVM, NULL, "SSM Testcase Data Item no.3 (big mem)", 0, 123, 512*_1M, NULL,
    733                              NULL, NULL, NULL,
    734                              NULL, Item03Save, NULL,
    735                              NULL, Item03Load, NULL);
     732    rc = SSMR3RegisterInternal(pVM, "SSM Testcase Data Item no.3 (big mem)", 0, 123, 512*_1M,
     733                               NULL, NULL, NULL,
     734                               NULL, Item03Save, NULL,
     735                               NULL, Item03Load, NULL);
    736736    if (RT_FAILURE(rc))
    737737    {
     
    740740    }
    741741
    742     rc = SSMR3RegisterDevice(pVM, NULL, "SSM Testcase Data Item no.4 (big zero mem)", 0, 42, 512*_1M, NULL,
    743                              NULL, NULL, NULL,
    744                              NULL, Item04Save, NULL,
    745                              NULL, Item04Load, NULL);
     742    rc = SSMR3RegisterInternal(pVM, "SSM Testcase Data Item no.4 (big zero mem)", 0, 42, 512*_1M,
     743                               NULL, NULL, NULL,
     744                               NULL, Item04Save, NULL,
     745                               NULL, Item04Load, NULL);
    746746    if (RT_FAILURE(rc))
    747747    {
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