mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Whitehouse <swhiteho@redhat.com>
To: Jan Engelhardt <jengelh@linux01.gwdg.de>
Cc: linux-kernel@vger.kernel.org,
	Russell Cattelan <cattelan@redhat.com>,
	David Teigland <teigland@redhat.com>, Ingo Molnar <mingo@elte.hu>,
	hch@infradead.org
Subject: Re: [PATCH 08/16] GFS2: Resource group code
Date: Tue, 05 Sep 2006 11:36:13 +0100	[thread overview]
Message-ID: <1157452573.3384.984.camel@quoit.chygwyn.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0609041637500.17279@yvahk01.tjqt.qr>

Hi,

On Mon, 2006-09-04 at 16:50 +0200, Jan Engelhardt wrote:
> >+#define BFITNOENT 0xFFFFFFFF
> 
> See previous mail, (uint32_t)-1 / (uint32_t)~0 or leave it.
> 
ok.

> >+static inline int rgrp_contains_block(struct gfs2_rindex *ri, uint64_t block)
> >+{
> >+	uint64_t first = ri->ri_data0;
> >+	uint64_t last = first + ri->ri_data;
> >+	return !!(first <= block && block < last);
> >+}
> 
> No need for the !!, the expression !! is operating on is already a boolean.
> IOW,
> 
> 	return first <= block && block < last;
> 
Now fixed in:

http://www.kernel.org/git/?p=linux/kernel/git/steve/gfs2-2.6.git;a=commitdiff;h=16910427e1eb2a8069708ee24406d2d465381ebd

> 
> >+/**
> >+ * gfs2_alloc_put - throw away the struct gfs2_alloc for an inode
> >+ * @ip: the inode
> >+ *
> >+ */
> >+
> >+void gfs2_alloc_put(struct gfs2_inode *ip)
> >+{
> >+	return;
> >+}
> 
> Missing some code? Code that comes later?
> 
> 
> Jan Engelhardt

Well the allocation structure used to be kmalloc'ed and free'd by this
function and gfs2_alloc_get. I changed that to put it inline in the
struct gfs2_inode since there didn't seem a lot of point in having it
dynamically allocated. I had left this function though since it was
useful to have some demarcation points in the code which showed where
the structure was in use. My plan was to later add some debugging to
detect any use outside of those points, hence, I'd left in this
function.

It could be removed now, but I'd prefer to give it a stay of execution
for a little while at least if nobody has any strong objections to that,

Steve.



  reply	other threads:[~2006-09-05 10:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-31 13:35 Steven Whitehouse
2006-09-04 14:50 ` Jan Engelhardt
2006-09-05 10:36   ` Steven Whitehouse [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-04-21 16:17 Steven Whitehouse

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=1157452573.3384.984.camel@quoit.chygwyn.com \
    --to=swhiteho@redhat.com \
    --cc=cattelan@redhat.com \
    --cc=hch@infradead.org \
    --cc=jengelh@linux01.gwdg.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=teigland@redhat.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®