lkml.org 
[lkml]   [2017]   [Dec]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RFC 2/6] x86/hyper-v: add a function to read both TSC and TSC page value simulateneously
On Fri,  1 Dec 2017 14:13:17 +0100
Vitaly Kuznetsov <vkuznets@redhat.com> wrote:

> +
> +static inline u64 hv_read_tsc_page_tsc(const struct ms_hyperv_tsc_page *tsc_pg,
> + u64 *cur_tsc)
> +{
> + *cur_tsc = rdtsc();
> +
> + return cur_tsc;

Why do return and setting by reference. Looks like an ugly API.

\
 
 \ /
  Last update: 2017-12-01 18:30    [W:0.080 / U:0.416 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site