linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Neil Brown <neilb@suse.de>
To: Akinobu Mita <akinobu.mita@gmail.com>
Cc: linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org,
	Arnd Bergmann <arnd@arndb.de>,
	Christoph Hellwig <hch@infradead.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-raid@vger.kernel.org
Subject: Re: [PATCH 18/22] md: use little endian bit operations
Date: Mon, 18 Oct 2010 13:41:27 +1100	[thread overview]
Message-ID: <20101018134127.5d1264fb@notabene> (raw)
In-Reply-To: <1287135981-17604-19-git-send-email-akinobu.mita@gmail.com>

On Fri, 15 Oct 2010 18:46:17 +0900
Akinobu Mita <akinobu.mita@gmail.com> wrote:

> As a preparation for removing ext2 non-atomic bit operations from
> asm/bitops.h. This converts ext2 non-atomic bit operations to
> little endian bit operations.

Looks good, thanks.

Acked-by: NeilBrown <neilb@suse.de>

NeilBrown

> 
> Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
> Cc: Neil Brown <neilb@suse.de>
> Cc: linux-raid@vger.kernel.org
> ---
>  drivers/md/bitmap.c |    6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/md/bitmap.c b/drivers/md/bitmap.c
> index e4fb58d..2a37051 100644
> --- a/drivers/md/bitmap.c
> +++ b/drivers/md/bitmap.c
> @@ -850,7 +850,7 @@ static void bitmap_file_set_bit(struct bitmap *bitmap, sector_t block)
>  		if (bitmap->flags & BITMAP_HOSTENDIAN)
>  			set_bit(bit, kaddr);
>  		else
> -			ext2_set_bit(bit, kaddr);
> +			__test_and_set_le_bit(bit, kaddr);
>  		kunmap_atomic(kaddr, KM_USER0);
>  		PRINTK("set file bit %lu page %lu\n", bit, page->index);
>  	}
> @@ -1046,7 +1046,7 @@ static int bitmap_init_from_disk(struct bitmap *bitmap, sector_t start)
>  		if (bitmap->flags & BITMAP_HOSTENDIAN)
>  			b = test_bit(bit, paddr);
>  		else
> -			b = ext2_test_bit(bit, paddr);
> +			b = test_le_bit(bit, paddr);
>  		kunmap_atomic(paddr, KM_USER0);
>  		if (b) {
>  			/* if the disk bit is set, set the memory bit */
> @@ -1222,7 +1222,7 @@ void bitmap_daemon_work(mddev_t *mddev)
>  						clear_bit(file_page_offset(bitmap, j),
>  							  paddr);
>  					else
> -						ext2_clear_bit(file_page_offset(bitmap, j),
> +						__test_and_clear_le_bit(file_page_offset(bitmap, j),
>  							       paddr);
>  					kunmap_atomic(paddr, KM_USER0);
>  				} else

      reply	other threads:[~2010-10-18  2:41 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1287135981-17604-1-git-send-email-akinobu.mita@gmail.com>
2010-10-15  9:46 ` [PATCH 18/22] md: use little endian bit operations Akinobu Mita
2010-10-18  2:41   ` Neil Brown [this message]

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=20101018134127.5d1264fb@notabene \
    --to=neilb@suse.de \
    --cc=akinobu.mita@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=hch@infradead.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-raid@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).