diff options
author | Haiyang Zhang <haiyangz@microsoft.com> | 2010-05-05 19:23:46 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-05-11 11:36:15 -0700 |
commit | 39c4e9c37894feb1525fac4bb75e8c919042473b (patch) | |
tree | 4378aabc1d7319eedc703d2adb53c4e368bffc7a /drivers/staging/hv/utils.h | |
parent | e61fbe66cbe10fed6bcc2d07ac802a7386b93673 (diff) | |
download | op-kernel-dev-39c4e9c37894feb1525fac4bb75e8c919042473b.zip op-kernel-dev-39c4e9c37894feb1525fac4bb75e8c919042473b.tar.gz |
Staging: hv: Add Time Sync feature to hv_utils module.
The Time Sync feature synchronizes guest time to host UTC time after reboot,
and restore from saved/paused state.
Signed-off-by: Hank Janssen <hjanssen@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/hv/utils.h')
-rw-r--r-- | drivers/staging/hv/utils.h | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/drivers/staging/hv/utils.h b/drivers/staging/hv/utils.h index e404b21..d1d2f28 100644 --- a/drivers/staging/hv/utils.h +++ b/drivers/staging/hv/utils.h @@ -75,7 +75,30 @@ struct shutdown_msg_data { u8 display_message[2048]; } __attribute__((packed)); -#define HV_SHUTDOWN_MSG 0 + +/* Time Sync IC defs */ +#define ICTIMESYNCFLAG_PROBE 0 +#define ICTIMESYNCFLAG_SYNC 1 +#define ICTIMESYNCFLAG_SAMPLE 2 + +#ifdef __x86_64__ +#define WLTIMEDELTA 116444736000000000L /* in 100ns unit */ +#else +#define WLTIMEDELTA 116444736000000000LL +#endif + +typedef u64 winfiletime_t; /* Windows FILETIME type */ + +struct ictimesync_data{ + winfiletime_t parenttime; + winfiletime_t childtime; + winfiletime_t roundtriptime; + u8 flags; +} __attribute__((packed)); + +/* Index for each IC struct in array hv_cb_utils[] */ +#define HV_SHUTDOWN_MSG 0 +#define HV_TIMESYNC_MSG 1 struct hyperv_service_callback { u8 msg_type; |