Lines Matching refs:map
2 * Common code to handle map devices which are simple RAM
15 #include <linux/mtd/map.h>
22 static struct mtd_info *map_ram_probe(struct map_info *map);
33 static struct mtd_info *map_ram_probe(struct map_info *map)
39 map_write8(map, 0x55, 0);
40 if (map_read8(map, 0) != 0x55)
43 map_write8(map, 0xAA, 0);
44 if (map_read8(map, 0) != 0xAA)
48 map_write8(map, 0x55, map->size-1);
49 if (map_read8(map, map->size-1) != 0x55)
52 map_write8(map, 0xAA, map->size-1);
53 if (map_read8(map, map->size-1) != 0xAA)
62 map->fldrv = &mapram_chipdrv;
63 mtd->priv = map;
64 mtd->name = map->name;
66 mtd->size = map->size;
85 * Allow NOMMU mmap() to directly map the device (if not NULL)
94 struct map_info *map = mtd->priv;
95 return (unsigned long) map->virt + offset;
100 struct map_info *map = mtd->priv;
102 map_copy_from(map, buf, from, len);
109 struct map_info *map = mtd->priv;
111 map_copy_to(map, to, buf, len);
120 struct map_info *map = mtd->priv;
124 allff = map_word_ff(map);
126 for (i=0; i<instr->len; i += map_bankwidth(map))
127 map_write(map, allff, instr->addr + i);