From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from www.tglx.de ([213.239.205.147] helo=mail.tglx.de) by canuck.infradead.org with esmtp (Exim 4.62 #1 (Red Hat Linux)) id 1G0xxr-0003Pr-Uk for linux-mtd@lists.infradead.org; Thu, 13 Jul 2006 05:58:43 -0400 Date: Thu, 13 Jul 2006 11:58:34 +0200 Message-ID: <87bqrt967p.wl%tglx@linutronix.de> From: Thomas Gleixner To: Vitaly Wool Subject: Re: Nand read/write In-Reply-To: <44B616F0.3050409@ru.mvista.com> References: <44B616F0.3050409@ru.mvista.com> MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Cc: M Sudharshana-A18475 , linux-mtd@lists.infradead.org List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , At Thu, 13 Jul 2006 13:48:32 +0400, Vitaly Wool wrote: > > M Sudharshana-A18475 wrote: > > It is a flash partition where no file system is defined for that > > mount-able partition. Read/write operations are performed on /dev/mtd0 > > (place where memory partition is mounted > Ok, then the answer is yes, unless your board driver selects > NAND_ECC_NONE for ECC calculation. > > I'd also expect to hear a lection on top-posting if I were you. And you get a lesson for the wrong answer. :) The question was if bad blocks are handled when he accesses the FLASH via /dev/mtdX. The answer is: It's not possible to write / erase bad blocks. But there is no bad block replacement functionality when you access the FLASH through the raw MTD interface. Neither MTD nor NAND provide anything like this. Raw access has to take care of this itself. Therefor we require that images are written with nandwrite instead of dd or cp. nandwrite has the simplest form of bad block handling (skip it). tglx