mirror of
https://github.com/mariusgreuel/avrdude.git
synced 2025-12-16 02:31:06 +00:00
* avr.c: compare page_size > 1 instead of != 0 * stk500v2.c: (Ditto.) git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1452 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
8
avr.c
8
avr.c
@@ -330,7 +330,7 @@ int avr_read(PROGRAMMER * pgm, AVRPART * p, char * memtype,
|
||||
memset(mem->buf, 0xff, mem->size);
|
||||
|
||||
/* supports "paged load" thru post-increment */
|
||||
if ((p->flags & AVRPART_HAS_TPI) && mem->page_size != 0 &&
|
||||
if ((p->flags & AVRPART_HAS_TPI) && mem->page_size > 1 &&
|
||||
pgm->cmd_tpi != NULL) {
|
||||
|
||||
while (avr_tpi_poll_nvmbsy(pgm));
|
||||
@@ -361,7 +361,7 @@ int avr_read(PROGRAMMER * pgm, AVRPART * p, char * memtype,
|
||||
return avr_mem_hiaddr(mem);
|
||||
}
|
||||
|
||||
if (pgm->paged_load != NULL && mem->page_size != 0) {
|
||||
if (pgm->paged_load != NULL && mem->page_size > 1) {
|
||||
/*
|
||||
* the programmer supports a paged mode read
|
||||
*/
|
||||
@@ -863,7 +863,7 @@ int avr_write(PROGRAMMER * pgm, AVRPART * p, char * memtype, int size,
|
||||
}
|
||||
|
||||
|
||||
if ((p->flags & AVRPART_HAS_TPI) && m->page_size != 0 &&
|
||||
if ((p->flags & AVRPART_HAS_TPI) && m->page_size > 1 &&
|
||||
pgm->cmd_tpi != NULL) {
|
||||
|
||||
while (avr_tpi_poll_nvmbsy(pgm));
|
||||
@@ -903,7 +903,7 @@ int avr_write(PROGRAMMER * pgm, AVRPART * p, char * memtype, int size,
|
||||
return i;
|
||||
}
|
||||
|
||||
if (pgm->paged_write != NULL && m->page_size != 0) {
|
||||
if (pgm->paged_write != NULL && m->page_size > 1) {
|
||||
/*
|
||||
* the programmer supports a paged mode write
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user