* [PATCH v2 18/22] md: use little-endian bit operations
[not found] <1287672077-5797-1-git-send-email-akinobu.mita@gmail.com>
@ 2010-10-21 14:41 ` Akinobu Mita
0 siblings, 0 replies; only message in thread
From: Akinobu Mita @ 2010-10-21 14:41 UTC (permalink / raw)
To: linux-kernel, linux-arch, Arnd Bergmann, Christoph Hellwig,
Andrew Morton
Cc: Akinobu Mita, linux-raid
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.
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Acked-by: NeilBrown <neilb@suse.de>
Cc: linux-raid@vger.kernel.org
---
No change from previous submission
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
--
1.7.1.231.gd0b16
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-10-21 14:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1287672077-5797-1-git-send-email-akinobu.mita@gmail.com>
2010-10-21 14:41 ` [PATCH v2 18/22] md: use little-endian bit operations Akinobu Mita
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).