if flash_size is less than megabyte

Yong-iL Joh tolkien at mizi.com
Tue Aug 1 09:00:30 EDT 2000


I'm working on Intel BootBlock Flash.
if mtd->size is less than a megabyte, kernel panic. :(

in ftl.c, here is a tiny patch.

===================================================================
RCS file: /exports/misc/embedded/cvs/linux/drivers/mtd/ftl.c,v
retrieving revision 1.3
diff -r1.3 ftl.c
266c266
<     loff_t offset;
---
>     loff_t offset, max_offset;
268a269
>     max_offset = (0x100000<part->mtd->size)?0x100000:part->mtd->size;
271c272
<        offset < 0x100000;
---
>        offset < max_offset;
283c284
<     if (offset == 0x100000) {
---
>     if (offset == max_offset) {

-- 
Joh, Yong-iL
E-mail: tolkien at nownuri.net tolkien at mizi.com


To unsubscribe, send "unsubscribe mtd" to majordomo at infradead.org



More information about the linux-mtd mailing list