Home | History | Annotate | Download | only in mtd

Lines Matching refs:cfi

4  * $Id: cfi.h,v 1.57 2005/11/15 23:28:17 tpoynor Exp $
18 #define cfi_interleave(cfi) 1
19 #define cfi_interleave_is_1(cfi) (cfi_interleave(cfi) == 1)
21 #define cfi_interleave_is_1(cfi) (0)
27 # define cfi_interleave(cfi) ((cfi)->interleave)
29 # define cfi_interleave(cfi) 2
31 #define cfi_interleave_is_2(cfi) (cfi_interleave(cfi) == 2)
33 #define cfi_interleave_is_2(cfi) (0)
39 # define cfi_interleave(cfi) ((cfi)->interleave)
41 # define cfi_interleave(cfi) 4
43 #define cfi_interleave_is_4(cfi) (cfi_interleave(cfi) == 4)
45 #define cfi_interleave_is_4(cfi) (0)
51 # define cfi_interleave(cfi) ((cfi)->interleave)
53 # define cfi_interleave(cfi) 8
55 #define cfi_interleave_is_8(cfi) (cfi_interleave(cfi) == 8)
57 #define cfi_interleave_is_8(cfi) (0)
248 int cfi_mode; /* Are we a JEDEC device pretending to be CFI? */
270 * Transforms the CFI command for the given geometry (bus width & interleave).
274 static inline map_word cfi_build_cmd(u_long cmd, struct map_info *map, struct cfi_private *cfi)
293 chip_mode = map_bankwidth(map) / cfi_interleave(cfi);
294 chips_per_word = wordwidth * cfi_interleave(cfi) / map_bankwidth(map);
335 #define CMD(x) cfi_build_cmd((x), map, cfi)
339 struct cfi_private *cfi)
357 chip_mode = map_bankwidth(map) / cfi_interleave(cfi);
358 chips_per_word = wordwidth * cfi_interleave(cfi) / map_bankwidth(map);
397 #define MERGESTATUS(x) cfi_merge_status((x), map, cfi)
401 * Sends a CFI command to a bank of flash for the given geometry.
408 struct map_info *map, struct cfi_private *cfi,
412 uint32_t addr = base + cfi_build_cmd_addr(cmd_addr, cfi_interleave(cfi), type);
414 val = cfi_build_cmd(cmd, map, cfi);