On Wed, 24 Mar 2021 14:32:07 -0400 Steven Rostedt <rostedt@xxxxxxxxxxx> wrote: > On Wed, 24 Mar 2021 15:04:01 +0200 > "Tzvetomir Stoyanov (VMware)" <tz.stoyanov@xxxxxxxxx> wrote: > > > +static void get_tsc_offset(struct common_record_context *ctx) > > +{ > > + struct buffer_instance *instance; > > + > > + for_all_instances(instance) { > > + if (is_guest(instance) || !instance->clock) > > + return; ^^^^^^^ That's the return I was talking about. -- Steve > > + > > + ctx->tsc2nsec.offset = get_clock_now(instance->clock); > > + return; > > + } > > + > > + ctx->tsc2nsec.offset = get_clock_now(NULL); > > +} > > Why is the above "return" and not "continue"? > > It seems inconsistent depending on the order. If the first instance found > is a guest or does not have a clock set, then we don't get the tsc offset, > but if the first instance is something else we do, even if a guest or an > instance exists. > > -- Steve > > > > + > > /* > > * This function contains common code for the following commands: > > * record, start, stream, profile.