diff options
Diffstat (limited to 'include/linux/mtd/map.h')
-rw-r--r-- | include/linux/mtd/map.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/mtd/map.h b/include/linux/mtd/map.h index 4b02512e421c..5f487d776411 100644 --- a/include/linux/mtd/map.h +++ b/include/linux/mtd/map.h | |||
@@ -365,7 +365,7 @@ static inline map_word map_word_load_partial(struct map_info *map, map_word orig | |||
365 | bitpos = (map_bankwidth(map)-1-i)*8; | 365 | bitpos = (map_bankwidth(map)-1-i)*8; |
366 | #endif | 366 | #endif |
367 | orig.x[0] &= ~(0xff << bitpos); | 367 | orig.x[0] &= ~(0xff << bitpos); |
368 | orig.x[0] |= buf[i-start] << bitpos; | 368 | orig.x[0] |= (unsigned long)buf[i-start] << bitpos; |
369 | } | 369 | } |
370 | } | 370 | } |
371 | return orig; | 371 | return orig; |
@@ -384,7 +384,7 @@ static inline map_word map_word_ff(struct map_info *map) | |||
384 | 384 | ||
385 | if (map_bankwidth(map) < MAP_FF_LIMIT) { | 385 | if (map_bankwidth(map) < MAP_FF_LIMIT) { |
386 | int bw = 8 * map_bankwidth(map); | 386 | int bw = 8 * map_bankwidth(map); |
387 | r.x[0] = (1 << bw) - 1; | 387 | r.x[0] = (1UL << bw) - 1; |
388 | } else { | 388 | } else { |
389 | for (i=0; i<map_words(map); i++) | 389 | for (i=0; i<map_words(map); i++) |
390 | r.x[i] = ~0UL; | 390 | r.x[i] = ~0UL; |