diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2014-02-12 06:43:40 -0500 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2014-02-21 02:50:20 -0500 |
commit | db85eaeb52637eb91a7bbc70f6684f5563b983e9 (patch) | |
tree | 5e39493f8d878f4325c346563e96128ef76b8d86 | |
parent | deedabb2b4a68a63351a949b1abcf73fc97eb406 (diff) |
s390/bitops: fix comment
Fix some numbers in the comments describing the layout of the bit maps.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
-rw-r--r-- | arch/s390/include/asm/bitops.h | 8 | ||||
-rw-r--r-- | arch/s390/lib/find.c | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/arch/s390/include/asm/bitops.h b/arch/s390/include/asm/bitops.h index 6e6ad0680829..ec5ef891db6b 100644 --- a/arch/s390/include/asm/bitops.h +++ b/arch/s390/include/asm/bitops.h | |||
@@ -13,9 +13,9 @@ | |||
13 | * | 13 | * |
14 | * The bitop functions are defined to work on unsigned longs, so for an | 14 | * The bitop functions are defined to work on unsigned longs, so for an |
15 | * s390x system the bits end up numbered: | 15 | * s390x system the bits end up numbered: |
16 | * |63..............0|127............64|191...........128|255...........196| | 16 | * |63..............0|127............64|191...........128|255...........192| |
17 | * and on s390: | 17 | * and on s390: |
18 | * |31.....0|63....31|95....64|127...96|159..128|191..160|223..192|255..224| | 18 | * |31.....0|63....32|95....64|127...96|159..128|191..160|223..192|255..224| |
19 | * | 19 | * |
20 | * There are a few little-endian macros used mostly for filesystem | 20 | * There are a few little-endian macros used mostly for filesystem |
21 | * bitmaps, these work on similar bit arrays layouts, but | 21 | * bitmaps, these work on similar bit arrays layouts, but |
@@ -30,7 +30,7 @@ | |||
30 | * on an s390x system the bits are numbered: | 30 | * on an s390x system the bits are numbered: |
31 | * |0..............63|64............127|128...........191|192...........255| | 31 | * |0..............63|64............127|128...........191|192...........255| |
32 | * and on s390: | 32 | * and on s390: |
33 | * |0.....31|31....63|64....95|96...127|128..159|160..191|192..223|224..255| | 33 | * |0.....31|32....63|64....95|96...127|128..159|160..191|192..223|224..255| |
34 | * | 34 | * |
35 | * The main difference is that bit 0-63 (64b) or 0-31 (32b) in the bit | 35 | * The main difference is that bit 0-63 (64b) or 0-31 (32b) in the bit |
36 | * number field needs to be reversed compared to the LSB0 encoded bit | 36 | * number field needs to be reversed compared to the LSB0 encoded bit |
@@ -304,7 +304,7 @@ static inline int test_bit(unsigned long nr, const volatile unsigned long *ptr) | |||
304 | * On an s390x system the bits are numbered: | 304 | * On an s390x system the bits are numbered: |
305 | * |0..............63|64............127|128...........191|192...........255| | 305 | * |0..............63|64............127|128...........191|192...........255| |
306 | * and on s390: | 306 | * and on s390: |
307 | * |0.....31|31....63|64....95|96...127|128..159|160..191|192..223|224..255| | 307 | * |0.....31|32....63|64....95|96...127|128..159|160..191|192..223|224..255| |
308 | */ | 308 | */ |
309 | unsigned long find_first_bit_inv(const unsigned long *addr, unsigned long size); | 309 | unsigned long find_first_bit_inv(const unsigned long *addr, unsigned long size); |
310 | unsigned long find_next_bit_inv(const unsigned long *addr, unsigned long size, | 310 | unsigned long find_next_bit_inv(const unsigned long *addr, unsigned long size, |
diff --git a/arch/s390/lib/find.c b/arch/s390/lib/find.c index 620d34d6487e..922003c1b90d 100644 --- a/arch/s390/lib/find.c +++ b/arch/s390/lib/find.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * On s390x the bits are numbered: | 4 | * On s390x the bits are numbered: |
5 | * |0..............63|64............127|128...........191|192...........255| | 5 | * |0..............63|64............127|128...........191|192...........255| |
6 | * and on s390: | 6 | * and on s390: |
7 | * |0.....31|31....63|64....95|96...127|128..159|160..191|192..223|224..255| | 7 | * |0.....31|32....63|64....95|96...127|128..159|160..191|192..223|224..255| |
8 | * | 8 | * |
9 | * The reason for this bit numbering is the fact that the hardware sets bits | 9 | * The reason for this bit numbering is the fact that the hardware sets bits |
10 | * in a bitmap starting at bit 0 (MSB) and we don't want to scan the bitmap | 10 | * in a bitmap starting at bit 0 (MSB) and we don't want to scan the bitmap |