search for: winfiletime_t

Displaying 2 results from an estimated 2 matches for "winfiletime_t".

2010 May 05
1
[PATCH 1/1] staging: hv: Add Time Sync feature to hv_utils module
...9174f79 100644 --- a/drivers/staging/hv/hyperv_utils.c +++ b/drivers/staging/hv/hyperv_utils.c @@ -106,6 +106,82 @@ static void shutdown_onchannelcallback(void *context) orderly_poweroff(false); } + +/* + * Synchronize time with host after reboot, restore, etc. + */ +static void adj_guesttime(winfiletime_t hosttime, u8 flags) +{ + s64 host_tns; + struct timespec host_ts; + static s32 scnt = 50; + + host_tns = (hosttime - WLTIMEDELTA) * 100; + host_ts = ns_to_timespec(host_tns); + + if ((flags & ICTIMESYNCFLAG_SYNC) != 0) { + do_settimeofday(&host_ts); + return; + } + + if ((flags & ICTI...
2010 May 05
1
[PATCH 1/1] staging: hv: Add Time Sync feature to hv_utils module
...9174f79 100644 --- a/drivers/staging/hv/hyperv_utils.c +++ b/drivers/staging/hv/hyperv_utils.c @@ -106,6 +106,82 @@ static void shutdown_onchannelcallback(void *context) orderly_poweroff(false); } + +/* + * Synchronize time with host after reboot, restore, etc. + */ +static void adj_guesttime(winfiletime_t hosttime, u8 flags) +{ + s64 host_tns; + struct timespec host_ts; + static s32 scnt = 50; + + host_tns = (hosttime - WLTIMEDELTA) * 100; + host_ts = ns_to_timespec(host_tns); + + if ((flags & ICTIMESYNCFLAG_SYNC) != 0) { + do_settimeofday(&host_ts); + return; + } + + if ((flags & ICTI...