fet: change block size to 64 bytes.

Have observed crashes of the FET when programming some devices using
128-byte blocks.
This commit is contained in:
Sören Höckner 2010-09-14 14:56:10 +12:00 committed by Daniel Beer
parent 218ead5fe5
commit ecccfb5a64
1 changed files with 3 additions and 2 deletions

5
fet.c
View File

@ -34,6 +34,7 @@
#include "output.h"
#define MAX_PARAMS 16
#define BLOCK_SIZE 64
struct fet_device {
struct device base;
@ -756,7 +757,7 @@ int fet_readmem(device_t dev_base, address_t addr, uint8_t *buffer,
}
while (count > 1) {
int plen = count > 128 ? 128 : count;
int plen = count > BLOCK_SIZE ? BLOCK_SIZE : count;
plen &= ~0x1;
@ -798,7 +799,7 @@ int fet_writemem(device_t dev_base, address_t addr,
}
while (count > 1) {
int plen = count > 128 ? 128 : count;
int plen = count > BLOCK_SIZE ? BLOCK_SIZE : count;
int ret;
plen &= ~0x1;