X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?p=palacios.git;a=blobdiff_plain;f=palacios%2Fsrc%2Fdevices%2Fkeyboard.c;h=5943fd330a45c761bc6a7aec5804ed3fb88e7063;hp=f8786e204c29504adcd8ec4bf60f777188f68343;hb=504a6fd3bf01d7299ec69f80d5117dea3014ea28;hpb=ed58e44a111e3bb28e1b2fefd93fe7955962d682 diff --git a/palacios/src/devices/keyboard.c b/palacios/src/devices/keyboard.c index f8786e2..5943fd3 100644 --- a/palacios/src/devices/keyboard.c +++ b/palacios/src/devices/keyboard.c @@ -1051,9 +1051,27 @@ static int keyboard_reset_device(struct keyboard_internal * kbd) { } +#ifdef V3_CONFIG_CHECKPOINT +static int keyboard_save(struct v3_chkpt_ctx * ctx, void * private_data) { + return 0; +} + + +static int keyboard_load(struct v3_chkpt_ctx * ctx, void * private_data) { + struct keyboard_internal * kbd = (struct keyboard_internal *)private_data; + keyboard_reset_device(kbd); + return 0; +} + +#endif + + static struct v3_device_ops dev_ops = { .free = (int (*)(void *))keyboard_free, - +#ifdef V3_CONFIG_CHECKPOINT + .save = keyboard_save, + .load = keyboard_load +#endif };