|
@@ -254,7 +254,6 @@ int dfu_fill_entity_mtd(struct dfu_entity *dfu, char *devstr, char *s)
|
|
|
{
|
|
|
char *st;
|
|
|
struct mtd_info *mtd;
|
|
|
- bool has_pages;
|
|
|
int ret, part;
|
|
|
|
|
|
mtd = get_mtd_device_nm(devstr);
|
|
@@ -264,9 +263,7 @@ int dfu_fill_entity_mtd(struct dfu_entity *dfu, char *devstr, char *s)
|
|
|
|
|
|
dfu->dev_type = DFU_DEV_MTD;
|
|
|
dfu->data.mtd.info = mtd;
|
|
|
-
|
|
|
- has_pages = mtd->type == MTD_NANDFLASH || mtd->type == MTD_MLCNANDFLASH;
|
|
|
- dfu->max_buf_size = has_pages ? mtd->erasesize : 0;
|
|
|
+ dfu->max_buf_size = mtd->erasesize;
|
|
|
|
|
|
st = strsep(&s, " ");
|
|
|
if (!strcmp(st, "raw")) {
|