- } else {
- /* legacy setup */
- /* calculate leftover flash, and assign it to the jffs2 partition */
- if (cfe_size != 384 * 1024) {
- adm5120_cfe_parts[4].offset = adm5120_cfe_parts[2].offset +
- adm5120_cfe_parts[2].size;
- if ((adm5120_cfe_parts[4].offset % mtd->erasesize) > 0) {
- adm5120_cfe_parts[4].offset += mtd->erasesize -
- (adm5120_cfe_parts[4].offset % mtd->erasesize);
- }
- adm5120_cfe_parts[4].size = adm5120_cfe_parts[3].offset -
- adm5120_cfe_parts[4].offset;
- } else {
- adm5120_cfe_parts[4].offset = adm5120_cfe_parts[2].offset +
- adm5120_cfe_parts[2].size;
- if ((adm5120_cfe_parts[4].offset % mtd->erasesize) > 0) {
- adm5120_cfe_parts[4].offset += mtd->erasesize -
- (adm5120_cfe_parts[4].offset % mtd->erasesize);
- }
- adm5120_cfe_parts[4].size = size - adm5120_cfe_parts[3].size -
- adm5120_cfe_parts[4].offset;
- }