From: Kevin Cernekee Date: Sat, 10 Apr 2010 18:18:58 +0000 (-0700) Subject: mtd: suppress warnings in inline_map_read() X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=9ea5973883bbe26372f45d99eb3a500f08d966f9;p=linux-beck.git mtd: suppress warnings in inline_map_read() With gcc 4.4.3 -O2 on MIPS32: drivers/mtd/chips/cfi_util.c: In function 'cfi_qry_present': include/linux/mtd/map.h:390: warning: 'r' may be used uninitialized in this function include/linux/mtd/map.h:375: note: 'r' was declared here include/linux/mtd/map.h:390: warning: 'r' may be used uninitialized in this function include/linux/mtd/map.h:375: note: 'r' was declared here Signed-off-by: Kevin Cernekee Signed-off-by: Artem Bityutskiy Signed-off-by: David Woodhouse --- diff --git a/include/linux/mtd/map.h b/include/linux/mtd/map.h index 01703d425986..de89eca864ce 100644 --- a/include/linux/mtd/map.h +++ b/include/linux/mtd/map.h @@ -387,6 +387,8 @@ static inline map_word inline_map_read(struct map_info *map, unsigned long ofs) #endif else if (map_bankwidth_is_large(map)) memcpy_fromio(r.x, map->virt+ofs, map->bankwidth); + else + BUG(); return r; }