Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 4561
b: refs/heads/master
c: 3a3ab48
h: refs/heads/master
i:
  4559: 47c2abe
v: v3
  • Loading branch information
Thomas Gleixner authored and Thomas Gleixner committed May 24, 2005
1 parent 3bc79f2 commit b9f0d8f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 22fd9a8750bcad4999768aafc8fbd8a4bd6f5aa1
refs/heads/master: 3a3ab48c68de656736f091c6ed768fa8c110a7ab
17 changes: 13 additions & 4 deletions trunk/include/linux/mtd/map.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

/* Overhauled routines for dealing with different mmap regions of flash */
/* $Id: map.h,v 1.48 2005/02/16 15:54:59 nico Exp $ */
/* $Id: map.h,v 1.49 2005/05/24 18:45:15 gleixner Exp $ */

#ifndef __LINUX_MTD_MAP_H__
#define __LINUX_MTD_MAP_H__
Expand Down Expand Up @@ -340,13 +340,22 @@ static inline map_word map_word_load_partial(struct map_info *map, map_word orig
return orig;
}

#if BITS_PER_LONG < 64
#define MAP_FF_LIMIT 4
#else
#define MAP_FF_LIMIT 8
#endif

static inline map_word map_word_ff(struct map_info *map)
{
map_word r;
int i;

for (i=0; i<map_words(map); i++) {
r.x[i] = ~0UL;

if (map_bank_width(map) < MAP_FF_LIMIT) {
r.x[0] = (1 << (8*map_bank_width(map))) - 1;
} else {
for (i=0; i<map_words(map); i++)
r.x[i] = ~0UL;
}
return r;
}
Expand Down

0 comments on commit b9f0d8f

Please sign in to comment.