mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Vaibhav Nagarnaik <vnagarnaik@google.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>,
	Ingo Molnar <mingo@redhat.com>,
	linux-kernel@vger.kernel.org, Michael Rubin <mrubin@google.com>,
	David Sharp <dhsharp@google.com>
Subject: Re: [PATCH] trace: Add a free on close control mechanism for buffer_size_kb
Date: Thu, 26 May 2011 14:23:48 -0400	[thread overview]
Message-ID: <1306434228.3857.5.camel@gandalf.stny.rr.com> (raw)
In-Reply-To: <BANLkTin+WYW6Eahgn+yw2eTX44Erc5yBMg@mail.gmail.com>

On Thu, 2011-05-26 at 11:00 -0700, Vaibhav Nagarnaik wrote:
> On Wed, May 25, 2011 at 8:29 PM, Steven Rostedt <rostedt@goodmis.org> wrote:

> >
> > What you should do is just check if ret is less than zero here.
> >
> >        if (ret < 0)
> >                ret = -ENOMEM;
> 
> Instead, I don't have to check/set the return value. I can just return
> "ret" to the caller.

Actually, ret could be -1, if we end up with a miss match in global vs
max buffers. But that is more of an anomaly. Maybe the solution there is
to have that return -ENOMEM as well?

-- Steve



  reply	other threads:[~2011-05-26 18:23 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-22 22:46 Vaibhav Nagarnaik
2011-04-28 23:14 ` Vaibhav Nagarnaik
2011-04-28 23:32 ` Steven Rostedt
2011-04-29 19:45   ` Vaibhav Nagarnaik
2011-04-29 20:01     ` Steven Rostedt
2011-04-29 23:15       ` Vaibhav Nagarnaik
2011-04-29 19:45 ` Vaibhav Nagarnaik
2011-04-29 23:16   ` Vaibhav Nagarnaik
2011-05-24 18:37     ` Vaibhav Nagarnaik
2011-05-24 18:48       ` Steven Rostedt
2011-05-26  3:29     ` Steven Rostedt
2011-05-26 18:00       ` Vaibhav Nagarnaik
2011-05-26 18:23         ` Steven Rostedt [this message]
2011-05-26 18:33           ` Vaibhav Nagarnaik
2011-05-26 18:16     ` [PATCH v2] " Vaibhav Nagarnaik
2011-05-26 18:34       ` Vaibhav Nagarnaik

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=1306434228.3857.5.camel@gandalf.stny.rr.com \
    --to=rostedt@goodmis.org \
    --cc=dhsharp@google.com \
    --cc=fweisbec@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=mrubin@google.com \
    --cc=vnagarnaik@google.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®