Lines Matching full:adr

99 static int chip_ready (struct map_info *map, struct flchip *chip, unsigned long adr, int mode);
100 static int get_chip(struct map_info *map, struct flchip *chip, unsigned long adr, int mode);
101 static void put_chip(struct map_info *map, struct flchip *chip, unsigned long adr);
393 read_pri_intelext(struct map_info *map, __u16 adr) in read_pri_intelext() argument
401 extp = (struct cfi_pri_intelext *)cfi_read_pri(map, adr, extp_size, "Intel/Sharp"); in read_pri_intelext()
533 __u16 adr = primary?cfi->cfiq->P_ADR:cfi->cfiq->A_ADR; in cfi_cmdset_0001() local
536 extp = read_pri_intelext(map, adr); in cfi_cmdset_0001()
827 static int chip_ready (struct map_info *map, struct flchip *chip, unsigned long adr, int mode) in chip_ready() argument
843 status = map_read(map, adr); in chip_ready()
872 if ((adr & chip->in_progress_block_mask) == in chip_ready()
901 put_chip(map, chip, adr); in chip_ready()
944 static int get_chip(struct map_info *map, struct flchip *chip, unsigned long adr, int mode) in get_chip() argument
1033 ret = chip_ready(map, chip, adr, mode); in get_chip()
1040 static void put_chip(struct map_info *map, struct flchip *chip, unsigned long adr) in put_chip() argument
1125 unsigned long adr) in xip_disable() argument
1128 (void) map_read(map, adr); /* ensure mmu mapping is up to date */ in xip_disable()
1133 unsigned long adr) in xip_enable() argument
1137 map_write(map, CMD(0xff), adr); in xip_enable()
1140 (void) map_read(map, adr); in xip_enable()
1160 unsigned long adr, unsigned int chip_op_time_max) in xip_wait_for_operation() argument
1191 map_write(map, CMD(0xb0), adr); in xip_wait_for_operation()
1192 map_write(map, CMD(0x70), adr); in xip_wait_for_operation()
1204 status = map_read(map, adr); in xip_wait_for_operation()
1221 map_write(map, CMD(0xff), adr); in xip_wait_for_operation()
1222 (void) map_read(map, adr); in xip_wait_for_operation()
1249 map_write(map, CMD(0xd0), adr); in xip_wait_for_operation()
1250 map_write(map, CMD(0x70), adr); in xip_wait_for_operation()
1261 status = map_read(map, adr); in xip_wait_for_operation()
1284 #define xip_disable(map, chip, adr) argument
1285 #define xip_enable(map, chip, adr) argument
1369 #define WAIT_TIMEOUT(map, chip, adr, udelay, udelay_max) \ argument
1370 INVAL_CACHE_AND_WAIT(map, chip, adr, 0, 0, udelay, udelay_max);
1373 static int do_point_onechip (struct map_info *map, struct flchip *chip, loff_t adr, size_t len) in do_point_onechip() argument
1379 adr += chip->start; in do_point_onechip()
1382 cmd_addr = adr & ~(map_bankwidth(map)-1); in do_point_onechip()
1500 static inline int do_read_onechip(struct map_info *map, struct flchip *chip, loff_t adr, size_t len… in do_read_onechip() argument
1506 adr += chip->start; in do_read_onechip()
1509 cmd_addr = adr & ~(map_bankwidth(map)-1); in do_read_onechip()
1524 map_copy_from(map, buf, adr, len); in do_read_onechip()
1570 unsigned long adr, map_word datum, int mode) in do_write_oneword() argument
1576 adr += chip->start; in do_write_oneword()
1590 ret = get_chip(map, chip, adr, mode); in do_write_oneword()
1596 XIP_INVAL_CACHED_RANGE(map, adr, map_bankwidth(map)); in do_write_oneword()
1598 xip_disable(map, chip, adr); in do_write_oneword()
1599 map_write(map, write_cmd, adr); in do_write_oneword()
1600 map_write(map, datum, adr); in do_write_oneword()
1603 ret = INVAL_CACHE_AND_WAIT(map, chip, adr, in do_write_oneword()
1604 adr, map_bankwidth(map), in do_write_oneword()
1608 xip_enable(map, chip, adr); in do_write_oneword()
1614 status = map_read(map, adr); in do_write_oneword()
1619 map_write(map, CMD(0x50), adr); in do_write_oneword()
1620 map_write(map, CMD(0x70), adr); in do_write_oneword()
1621 xip_enable(map, chip, adr); in do_write_oneword()
1636 xip_enable(map, chip, adr); in do_write_oneword()
1638 put_chip(map, chip, adr); in do_write_oneword()
1724 unsigned long adr, const struct kvec **pvec, in do_write_buffer() argument
1737 adr += chip->start; in do_write_buffer()
1738 initial_adr = adr; in do_write_buffer()
1739 cmd_adr = adr & ~(wbufsize-1); in do_write_buffer()
1745 cmd_adr = adr; in do_write_buffer()
1796 word_gap = (-adr & (map_bankwidth(map)-1)); in do_write_buffer()
1802 adr -= word_gap; in do_write_buffer()
1829 map_write(map, datum, adr); in do_write_buffer()
1830 adr += map_bankwidth(map); in do_write_buffer()
1953 unsigned long adr, int len, void *thunk) in do_erase_oneblock() argument
1960 adr += chip->start; in do_erase_oneblock()
1964 ret = get_chip(map, chip, adr, FL_ERASING); in do_erase_oneblock()
1970 XIP_INVAL_CACHED_RANGE(map, adr, len); in do_erase_oneblock()
1972 xip_disable(map, chip, adr); in do_erase_oneblock()
1975 map_write(map, CMD(0x50), adr); in do_erase_oneblock()
1978 map_write(map, CMD(0x20), adr); in do_erase_oneblock()
1979 map_write(map, CMD(0xD0), adr); in do_erase_oneblock()
1982 chip->in_progress_block_addr = adr; in do_erase_oneblock()
1985 ret = INVAL_CACHE_AND_WAIT(map, chip, adr, in do_erase_oneblock()
1986 adr, len, in do_erase_oneblock()
1990 map_write(map, CMD(0x70), adr); in do_erase_oneblock()
1992 xip_enable(map, chip, adr); in do_erase_oneblock()
1998 map_write(map, CMD(0x70), adr); in do_erase_oneblock()
2000 status = map_read(map, adr); in do_erase_oneblock()
2007 map_write(map, CMD(0x50), adr); in do_erase_oneblock()
2008 map_write(map, CMD(0x70), adr); in do_erase_oneblock()
2009 xip_enable(map, chip, adr); in do_erase_oneblock()
2022 printk(KERN_DEBUG "block erase failed at 0x%08lx: status 0x%lx. Retrying...\n", adr, chipstatus); in do_erase_oneblock()
2024 put_chip(map, chip, adr); in do_erase_oneblock()
2028 … printk(KERN_ERR "%s: block erase failed at 0x%08lx (status 0x%lx)\n", map->name, adr, chipstatus); in do_erase_oneblock()
2035 xip_enable(map, chip, adr); in do_erase_oneblock()
2037 put_chip(map, chip, adr); in do_erase_oneblock()
2091 unsigned long adr, in do_getlockstatus_oneblock() argument
2097 adr += chip->start; in do_getlockstatus_oneblock()
2098 xip_disable(map, chip, adr+(2*ofs_factor)); in do_getlockstatus_oneblock()
2099 map_write(map, CMD(0x90), adr+(2*ofs_factor)); in do_getlockstatus_oneblock()
2101 status = cfi_read_query(map, adr+(2*ofs_factor)); in do_getlockstatus_oneblock()
2109 unsigned long adr, in do_printlockstatus_oneblock() argument
2113 adr, do_getlockstatus_oneblock(map, chip, adr, len, thunk)); in do_printlockstatus_oneblock()
2122 unsigned long adr, int len, void *thunk) in do_xxlock_oneblock() argument
2129 adr += chip->start; in do_xxlock_oneblock()
2132 ret = get_chip(map, chip, adr, FL_LOCKING); in do_xxlock_oneblock()
2139 xip_disable(map, chip, adr); in do_xxlock_oneblock()
2141 map_write(map, CMD(0x60), adr); in do_xxlock_oneblock()
2143 map_write(map, CMD(0x01), adr); in do_xxlock_oneblock()
2146 map_write(map, CMD(0xD0), adr); in do_xxlock_oneblock()
2165 ret = WAIT_TIMEOUT(map, chip, adr, mdelay, mdelay * 1000); in do_xxlock_oneblock()
2167 map_write(map, CMD(0x70), adr); in do_xxlock_oneblock()
2169 xip_enable(map, chip, adr); in do_xxlock_oneblock()
2174 xip_enable(map, chip, adr); in do_xxlock_oneblock()
2176 put_chip(map, chip, adr); in do_xxlock_oneblock()
2503 unsigned long adr; in cfi_intelext_save_locks() local
2513 adr = region->offset + block * len; in cfi_intelext_save_locks()
2516 do_getlockstatus_oneblock, adr, len, NULL); in cfi_intelext_save_locks()
2604 unsigned long adr; in cfi_intelext_restore_locks() local
2614 adr = region->offset + block * len; in cfi_intelext_restore_locks()
2615 cfi_intelext_unlock(mtd, adr, len); in cfi_intelext_restore_locks()