linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Theodore Ts'o <tytso@mit.edu>
To: "Lukáš Czerner" <lczerner@redhat.com>
Cc: Ext4 Developers List <linux-ext4@vger.kernel.org>
Subject: Re: [PATCH 3/6] libext2fs: add ext2fs_bitcount() function
Date: Mon, 26 Nov 2012 09:06:38 -0500	[thread overview]
Message-ID: <20121126140638.GC31891@thunk.org> (raw)
In-Reply-To: <alpine.LFD.2.00.1211261123400.18234@localhost>

On Mon, Nov 26, 2012 at 11:30:55AM +0100, Lukáš Czerner wrote:
> > +unsigned int ext2fs_bitcount(const void *addr, unsigned int count)
> > +{
> > +	const unsigned char *cp = addr;
> > +	const __u32 *p = addr;
> > +	unsigned int res = 0;
> > +
> 
> Again it is assumed that 8 will always be aliquot of 'count', but
> it might be worth having a check for that ?

In this case "count" is in bytes, since that's the only thing that
makes sense.  I'll rename the variable to nbytes to make this clear.

      	      	   	      	       	  	    - Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2012-11-26 14:06 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-25  0:36 [RFC PATCH 0/6] Optimize e2fsck for large file systems Theodore Ts'o
2012-11-25  0:36 ` [PATCH 1/6] libext2fs: optimize rb_set_bmap_range() Theodore Ts'o
2012-11-26  9:40   ` Lukáš Czerner
2012-11-26 13:36     ` Theodore Ts'o
2012-11-25  0:36 ` [PATCH 2/6] e2fsck: optimize pass1 for CPU time Theodore Ts'o
2012-11-26 10:06   ` Lukáš Czerner
2012-11-25  0:36 ` [PATCH 3/6] libext2fs: add ext2fs_bitcount() function Theodore Ts'o
2012-11-26 10:30   ` Lukáš Czerner
2012-11-26 14:06     ` Theodore Ts'o [this message]
2012-11-26 14:10       ` [PATCH 3/6 -v2] " Theodore Ts'o
2012-11-26 14:12         ` [PATCH 4/6 -v3] " Theodore Ts'o
2012-11-25  0:36 ` [PATCH 4/6] libext2fs: optimize rb_get_bmap_range() Theodore Ts'o
2012-11-26 10:46   ` Lukáš Czerner
2012-11-25  0:36 ` [PATCH 5/6] libext2fs: optimize rb_get_bmap_range() for mostly allocated bmaps Theodore Ts'o
2012-11-26 11:22   ` Lukáš Czerner
2012-11-26 14:17     ` Theodore Ts'o
2012-11-25  0:36 ` [PATCH 6/6] e2fsck: optimize pass 5 for CPU utilization Theodore Ts'o
2012-11-26 11:59   ` Lukáš Czerner
2012-11-25  5:09 ` [RFC PATCH 0/6] Optimize e2fsck for large file systems Theodore Ts'o
2012-11-26  9:19 ` Lukáš Czerner

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=20121126140638.GC31891@thunk.org \
    --to=tytso@mit.edu \
    --cc=lczerner@redhat.com \
    --cc=linux-ext4@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).