All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Tzvetomir Stoyanov <tz.stoyanov@gmail.com>
Cc: Linux Trace Devel <linux-trace-devel@vger.kernel.org>
Subject: Re: [PATCH 1/2] trace-cmd: Add validation for reading and writing trace.dat files
Date: Wed, 17 Feb 2021 13:27:49 -0500	[thread overview]
Message-ID: <20210217132749.70281f99@gandalf.local.home> (raw)
In-Reply-To: <CAPpZLN4EoCES6CHo8uoyOoFr9nopOkQZKVF5voFPCYM4pnzyhg@mail.gmail.com>

On Wed, 17 Feb 2021 18:33:32 +0200
Tzvetomir Stoyanov <tz.stoyanov@gmail.com> wrote:
> >
> > Why did you use bits, and not just a number?
> >

> 
> I use these flags to track what is in the file, not just a state. The
> state is the most significant bit which is set,
> but that way there is information for all passed states. I use the
> same logic when reading the file, to verify if
> all required information is in the file.

Of course if this is done via states, entering one state assumes that all
previous states have been entered (and thus must be set). For cases of
FLYRECORD and LATENCY, those two would diverge in states (basically like
branches in a tree), but still maintain that being in any given state,
stores the information that all previous states have been hit.

Or do you know of a situation where that is not the case?

-- Steve

  reply	other threads:[~2021-02-17 18:28 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-17  4:23 [PATCH 0/2] Fix listener and add trace file validation Tzvetomir Stoyanov (VMware)
2021-02-17  4:23 ` [PATCH 1/2] trace-cmd: Add validation for reading and writing trace.dat files Tzvetomir Stoyanov (VMware)
2021-02-17 16:00   ` Steven Rostedt
2021-02-17 16:33     ` Tzvetomir Stoyanov
2021-02-17 18:27       ` Steven Rostedt [this message]
2021-02-18  3:49         ` Tzvetomir Stoyanov
2021-02-18 14:23           ` Steven Rostedt
2021-02-17  4:23 ` [PATCH 2/2] trace-cmd: Fix broken listener and add error checks Tzvetomir Stoyanov (VMware)
2021-02-17 19:46   ` Steven Rostedt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210217132749.70281f99@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=linux-trace-devel@vger.kernel.org \
    --cc=tz.stoyanov@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.