i8042.cc (12392:e0dbdf30a2a5) i8042.cc (12450:b5a0300fc327)
1/*
2 * Copyright (c) 2008 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 477 unchanged lines hidden (view full) ---

486 }
487 pkt->makeAtomicResponse();
488 return latency;
489}
490
491void
492X86ISA::I8042::serialize(CheckpointOut &cp) const
493{
1/*
2 * Copyright (c) 2008 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 477 unchanged lines hidden (view full) ---

486 }
487 pkt->makeAtomicResponse();
488 return latency;
489}
490
491void
492X86ISA::I8042::serialize(CheckpointOut &cp) const
493{
494 uint8_t statusRegData = statusReg.__data;
495 uint8_t commandByteData = commandByte.__data;
496
497 SERIALIZE_SCALAR(dataPort);
498 SERIALIZE_SCALAR(commandPort);
494 SERIALIZE_SCALAR(dataPort);
495 SERIALIZE_SCALAR(commandPort);
499 SERIALIZE_SCALAR(statusRegData);
500 SERIALIZE_SCALAR(commandByteData);
496 SERIALIZE_SCALAR(statusReg);
497 SERIALIZE_SCALAR(commandByte);
501 SERIALIZE_SCALAR(dataReg);
502 SERIALIZE_SCALAR(lastCommand);
503 mouse.serialize("mouse", cp);
504 keyboard.serialize("keyboard", cp);
505}
506
507void
508X86ISA::I8042::unserialize(CheckpointIn &cp)
509{
498 SERIALIZE_SCALAR(dataReg);
499 SERIALIZE_SCALAR(lastCommand);
500 mouse.serialize("mouse", cp);
501 keyboard.serialize("keyboard", cp);
502}
503
504void
505X86ISA::I8042::unserialize(CheckpointIn &cp)
506{
510 uint8_t statusRegData;
511 uint8_t commandByteData;
512
513 UNSERIALIZE_SCALAR(dataPort);
514 UNSERIALIZE_SCALAR(commandPort);
507 UNSERIALIZE_SCALAR(dataPort);
508 UNSERIALIZE_SCALAR(commandPort);
515 UNSERIALIZE_SCALAR(statusRegData);
516 UNSERIALIZE_SCALAR(commandByteData);
509 UNSERIALIZE_SCALAR(statusReg);
510 UNSERIALIZE_SCALAR(commandByte);
517 UNSERIALIZE_SCALAR(dataReg);
518 UNSERIALIZE_SCALAR(lastCommand);
519 mouse.unserialize("mouse", cp);
520 keyboard.unserialize("keyboard", cp);
511 UNSERIALIZE_SCALAR(dataReg);
512 UNSERIALIZE_SCALAR(lastCommand);
513 mouse.unserialize("mouse", cp);
514 keyboard.unserialize("keyboard", cp);
521
522 statusReg.__data = statusRegData;
523 commandByte.__data = commandByteData;
524}
525
526void
527X86ISA::PS2Mouse::serialize(const std::string &base, CheckpointOut &cp) const
528{
529 PS2Device::serialize(base, cp);
530
531 paramOut(cp, base + ".status", status);

--- 19 unchanged lines hidden ---
515}
516
517void
518X86ISA::PS2Mouse::serialize(const std::string &base, CheckpointOut &cp) const
519{
520 PS2Device::serialize(base, cp);
521
522 paramOut(cp, base + ".status", status);

--- 19 unchanged lines hidden ---