All of lore.kernel.org
 help / color / mirror / Atom feed
From: Robin Holt <holt@sgi.com>
To: Davide Libenzi <davidel@xmailserver.org>
Cc: Robin Holt <holt@sgi.com>,
	"Eric W. Biederman" <ebiederm@xmission.com>,
	Pekka Enberg <penberg@cs.helsinki.fi>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [Patch] Convert max_user_watches to long.
Date: Thu, 14 Oct 2010 12:15:04 -0500	[thread overview]
Message-ID: <20101014171504.GA14068@sgi.com> (raw)
In-Reply-To: <alpine.DEB.2.00.1010102148430.4151@davide-laptop>

On Sun, Oct 10, 2010 at 09:49:58PM -0700, Davide Libenzi wrote:
> On Sat, 9 Oct 2010, Robin Holt wrote:
> 
> > @@ -900,11 +902,12 @@ static int ep_insert(struct eventpoll *e
> >  {
> >  	int error, revents, pwake = 0;
> >  	unsigned long flags;
> > +	long user_watches;
> >  	struct epitem *epi;
> >  	struct ep_pqueue epq;
> >  
> > -	if (unlikely(atomic_read(&ep->user->epoll_watches) >=
> > -		     max_user_watches))
> > +	user_watches = atomic_long_read(&ep->user->epoll_watches);
> > +	if (user_watches >= max_user_watches)
> >  		return -ENOSPC;
> 
> Is there a particular reason for adding an extra, otherwise unused, 
> user_watches variable?

Keeps the line length and readability complaints down.  No other
reason.

Robin

  reply	other threads:[~2010-10-14 17:15 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-01 20:01 max_user_watches overflows on 16TB system Robin Holt
2010-10-01 20:37 ` Davide Libenzi
2010-10-02  3:04   ` Eric W. Biederman
2010-10-02 14:04     ` Davide Libenzi
2010-10-04 19:44       ` [Patch] Convert max_user_watches to long Robin Holt
2010-10-06  2:21         ` Davide Libenzi
2010-10-09  7:50           ` Robin Holt
2010-10-10 19:05             ` Randy Dunlap
2010-10-11  4:49             ` Davide Libenzi
2010-10-14 17:15               ` Robin Holt [this message]
     [not found] <20101027190914.146006767@gulag1.americas.sgi.com>
2010-10-27 19:09 ` Robin Holt
2010-10-27 19:31   ` Davide Libenzi
2010-10-27 23:45   ` Andrew Morton
2010-10-28  2:03     ` Davide Libenzi
2010-10-28  4:08       ` Andrew Morton

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=20101014171504.GA14068@sgi.com \
    --to=holt@sgi.com \
    --cc=davidel@xmailserver.org \
    --cc=ebiederm@xmission.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=penberg@cs.helsinki.fi \
    /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.