Browse files

yaffs: Change all hex values to lower case

Signed-off-by: Charles Manning <cdhmanning@gmail.com>
  • Loading branch information...
1 parent 964b342 commit 7dea5fe7a9a58636b5ce32fdbd58541c95c4a37d @cdhmanning cdhmanning committed Feb 4, 2011
Showing with 26 additions and 26 deletions.
  1. +1 −1 yaffs_checkptrw.c
  2. +3 −3 yaffs_guts.c
  3. +5 −5 yaffs_guts.h
  4. +1 −1 yaffs_mtdif1_multi.c
  5. +1 −1 yaffs_mtdif1_single.c
  6. +2 −2 yaffs_packedtags1.c
  7. +4 −4 yaffs_packedtags2.c
  8. +4 −4 yaffs_tagscompat.c
  9. +1 −1 yaffs_tagsvalidity.c
  10. +2 −2 yaffs_trace.h
  11. +1 −1 yaffs_verify.c
  12. +1 −1 yaffs_yaffs2.c
View
2 yaffs_checkptrw.c
@@ -194,7 +194,7 @@ int yaffs2_get_checkpt_sum(struct yaffs_dev *dev, u32 * sum)
{
u32 composite_sum;
- composite_sum = (dev->checkpt_sum << 8) | (dev->checkpt_xor & 0xFF);
+ composite_sum = (dev->checkpt_sum << 8) | (dev->checkpt_xor & 0xff);
*sum = composite_sum;
return 1;
}
View
6 yaffs_guts.c
@@ -323,7 +323,7 @@ int yaffs_check_ff(u8 *buffer, int n_bytes)
{
/* Horrible, slow implementation */
while (n_bytes--) {
- if (*buffer != 0xFF)
+ if (*buffer != 0xff)
return 0;
buffer++;
}
@@ -3316,9 +3316,9 @@ int yaffs_update_oh(struct yaffs_obj *in, const YCHAR *name, int force,
yaffs_verify_oh(in, oh, &old_tags, 0);
memcpy(old_name, oh->name, sizeof(oh->name));
- memset(buffer, 0xFF, sizeof(struct yaffs_obj_hdr));
+ memset(buffer, 0xff, sizeof(struct yaffs_obj_hdr));
} else {
- memset(buffer, 0xFF, dev->data_bytes_per_chunk);
+ memset(buffer, 0xff, dev->data_bytes_per_chunk);
}
oh->type = in->variant_type;
View
10 yaffs_guts.h
@@ -23,11 +23,11 @@
/* Give us a Y=0x59,
* Give us an A=0x41,
- * Give us an FF=0xFF
+ * Give us an FF=0xff
* Give us an S=0x53
* And what have we got...
*/
-#define YAFFS_MAGIC 0x5941FF53
+#define YAFFS_MAGIC 0x5941ff53
#define YAFFS_NTNODES_LEVEL0 16
#define YAFFS_TNODES_LEVEL0_BITS 4
@@ -49,7 +49,7 @@
#define YAFFS_MIN_YAFFS2_CHUNK_SIZE 1024
#define YAFFS_MIN_YAFFS2_SPARE_SIZE 32
-#define YAFFS_MAX_CHUNK_ID 0x000FFFFF
+#define YAFFS_MAX_CHUNK_ID 0x000fffff
#define YAFFS_ALLOCATION_NOBJECTS 100
#define YAFFS_ALLOCATION_NTNODES 100
@@ -101,10 +101,10 @@
* and is a larger number than the lifetime of a 2GB device.
*/
#define YAFFS_LOWEST_SEQUENCE_NUMBER 0x00001000
-#define YAFFS_HIGHEST_SEQUENCE_NUMBER 0xEFFFFF00
+#define YAFFS_HIGHEST_SEQUENCE_NUMBER 0xefffff00
/* Special sequence number for bad block that failed to be marked bad */
-#define YAFFS_SEQUENCE_BAD_BLOCK 0xFFFF0000
+#define YAFFS_SEQUENCE_BAD_BLOCK 0xffff0000
/* ChunkCache is used for short read/write operations.*/
struct yaffs_cache {
View
2 yaffs_mtdif1_multi.c
@@ -263,7 +263,7 @@ int nandmtd1_read_chunk_tags(struct yaffs_dev *dev,
/* Unpack the tags to extended form and set ECC result.
* [set should_be_ff just to keep yaffs_unpack_tags1 happy]
*/
- pt1.should_be_ff = 0xFFFFFFFF;
+ pt1.should_be_ff = 0xffffffff;
yaffs_unpack_tags1(etags, &pt1);
etags->ecc_result = eccres;
View
2 yaffs_mtdif1_single.c
@@ -231,7 +231,7 @@ int nandmtd1_read_chunk_tags(struct yaffs_dev *dev,
/* Unpack the tags to extended form and set ECC result.
* [set should_be_ff just to keep yaffs_unpack_tags1 happy]
*/
- pt1.should_be_ff = 0xFFFFFFFF;
+ pt1.should_be_ff = 0xffffffff;
yaffs_unpack_tags1(etags, &pt1);
etags->ecc_result = eccres;
View
4 yaffs_packedtags1.c
@@ -32,7 +32,7 @@ void yaffs_pack_tags1(struct yaffs_packed_tags1 *pt,
pt->ecc = 0;
pt->deleted = (t->is_deleted) ? 0 : 1;
pt->unused_stuff = 0;
- pt->should_be_ff = 0xFFFFFFFF;
+ pt->should_be_ff = 0xffffffff;
}
void yaffs_unpack_tags1(struct yaffs_ext_tags *t,
@@ -41,7 +41,7 @@ void yaffs_unpack_tags1(struct yaffs_ext_tags *t,
if (memcmp(all_ff, pt, sizeof(struct yaffs_packed_tags1))) {
t->block_bad = 0;
- if (pt->should_be_ff != 0xFFFFFFFF)
+ if (pt->should_be_ff != 0xffffffff)
t->block_bad = 1;
t->chunk_used = 1;
t->obj_id = pt->obj_id;
View
8 yaffs_packedtags2.c
@@ -32,11 +32,11 @@
#define EXTRA_SHADOWS_FLAG 0x20000000
#define EXTRA_SPARE_FLAGS 0x10000000
-#define ALL_EXTRA_FLAGS 0xF0000000
+#define ALL_EXTRA_FLAGS 0xf0000000
/* Also, the top 4 bits of the object Id are set to the object type. */
#define EXTRA_OBJECT_TYPE_SHIFT (28)
-#define EXTRA_OBJECT_TYPE_MASK ((0x0F) << EXTRA_OBJECT_TYPE_SHIFT)
+#define EXTRA_OBJECT_TYPE_MASK ((0x0f) << EXTRA_OBJECT_TYPE_SHIFT)
static void yaffs_dump_packed_tags2_tags_only(
const struct yaffs_packed_tags2_tags_only *ptt)
@@ -110,7 +110,7 @@ void yaffs_unpack_tags2_tags_only(struct yaffs_ext_tags *t,
memset(t, 0, sizeof(struct yaffs_ext_tags));
yaffs_init_tags(t);
- if (ptt->seq_number == 0xFFFFFFFF)
+ if (ptt->seq_number == 0xffffffff)
return;
t->block_bad = 0;
@@ -148,7 +148,7 @@ void yaffs_unpack_tags2(struct yaffs_ext_tags *t, struct yaffs_packed_tags2 *pt,
{
enum yaffs_ecc_result ecc_result = YAFFS_ECC_RESULT_NO_ERROR;
- if (pt->t.seq_number != 0xFFFFFFFF && tags_ecc) {
+ if (pt->t.seq_number != 0xffffffff && tags_ecc) {
/* Chunk is in use and we need to do ECC */
struct yaffs_ecc_other ecc;
View
8 yaffs_tagscompat.c
@@ -120,7 +120,7 @@ static void yaffs_get_tags_from_spare(struct yaffs_dev *dev,
static void yaffs_spare_init(struct yaffs_spare *spare)
{
- memset(spare, 0xFF, sizeof(struct yaffs_spare));
+ memset(spare, 0xff, sizeof(struct yaffs_spare));
}
static int yaffs_wr_nand(struct yaffs_dev *dev,
@@ -292,7 +292,7 @@ int yaffs_tags_compat_wr(struct yaffs_dev *dev,
tags.obj_id = ext_tags->obj_id;
tags.chunk_id = ext_tags->chunk_id;
- tags.n_bytes_lsb = ext_tags->n_bytes & 0x3ff;
+ tags.n_bytes_lsb = ext_tags->n_bytes & (1024 - 1);
if (dev->data_bytes_per_chunk >= 1024)
tags.n_bytes_msb = (ext_tags->n_bytes >> 10) & 3;
@@ -321,7 +321,7 @@ int yaffs_tags_compat_rd(struct yaffs_dev *dev,
int deleted;
if (!init) {
- memset(&spare_ff, 0xFF, sizeof(spare_ff));
+ memset(&spare_ff, 0xff, sizeof(spare_ff));
init = 1;
}
@@ -385,7 +385,7 @@ int yaffs_tags_compat_query_block(struct yaffs_dev *dev,
enum yaffs_ecc_result dummy;
if (!init) {
- memset(&spare_ff, 0xFF, sizeof(spare_ff));
+ memset(&spare_ff, 0xff, sizeof(spare_ff));
init = 1;
}
View
2 yaffs_tagsvalidity.c
@@ -13,7 +13,7 @@
#include "yaffs_tagsvalidity.h"
-#define VALID0 0xAAAAAAAA
+#define VALID0 0xaaaaaaaa
#define VALID1 0x55555555
void yaffs_init_tags(struct yaffs_ext_tags *tags)
View
4 yaffs_trace.h
@@ -43,7 +43,7 @@ extern unsigned int yaffs_wr_attempts;
#define YAFFS_TRACE_VERIFY 0x00010000
#define YAFFS_TRACE_VERIFY_NAND 0x00020000
#define YAFFS_TRACE_VERIFY_FULL 0x00040000
-#define YAFFS_TRACE_VERIFY_ALL 0x000F0000
+#define YAFFS_TRACE_VERIFY_ALL 0x000f0000
#define YAFFS_TRACE_SYNC 0x00100000
#define YAFFS_TRACE_BACKGROUND 0x00200000
@@ -52,6 +52,6 @@ extern unsigned int yaffs_wr_attempts;
#define YAFFS_TRACE_ERROR 0x40000000
#define YAFFS_TRACE_BUG 0x80000000
-#define YAFFS_TRACE_ALWAYS 0xF0000000
+#define YAFFS_TRACE_ALWAYS 0xf0000000
#endif
View
2 yaffs_verify.c
@@ -216,7 +216,7 @@ void yaffs_verify_oh(struct yaffs_obj *obj, struct yaffs_obj_hdr *oh,
if (tags->obj_id > 1 && ((u8) (oh->name[0])) == 0xff) /* Junk name */
yaffs_trace(YAFFS_TRACE_VERIFY,
- "Obj %d header name is 0xFF",
+ "Obj %d header name is 0xff",
obj->obj_id);
}
View
2 yaffs_yaffs2.c
@@ -573,7 +573,7 @@ static int yaffs2_wr_checkpt_objs(struct yaffs_dev *dev)
}
/* Dump end of list */
- memset(&cp, 0xFF, sizeof(struct yaffs_checkpt_obj));
+ memset(&cp, 0xff, sizeof(struct yaffs_checkpt_obj));
cp.struct_type = sizeof(cp);
if (ok)

0 comments on commit 7dea5fe

Please sign in to comment.