lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Tue, 15 Jan 2013 16:53:33 +0800
From:	Huang Shijie <b32955@...escale.com>
To:	Matthieu CASTET <matthieu.castet@...rot.com>
CC:	"dwmw2@...radead.org" <dwmw2@...radead.org>,
	"linux-mtd@...ts.infradead.org" <linux-mtd@...ts.infradead.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"dedekind1@...il.com" <dedekind1@...il.com>
Subject: Re: [PATCH] mtd: apply tPROG delay for ONFI nand's page program

于 2013年01月14日 20:28, Matthieu CASTET 写道:
> Huang Shijie a écrit :
>> With some latest Micron's onfi nand(such as MT29F64G08CBABAWP),
>> I find that if we do not apply the tPROG delay as the datasheet tells us,
>> the page program may fails. You will read out the all 0xff from this page
>> in this case.
>>
>> This patch adds the tPROG delay for page program when it is an onfi nand.
>>
>> Signed-off-by: Huang Shijie<b32955@...escale.com>
>> ---
>>   drivers/mtd/nand/nand_base.c |    4 ++++
>>   1 files changed, 4 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c
>> index 8323ac9..b628dd5 100644
>> --- a/drivers/mtd/nand/nand_base.c
>> +++ b/drivers/mtd/nand/nand_base.c
>> @@ -841,6 +841,10 @@ static int nand_wait(struct mtd_info *mtd, struct nand_chip *chip)
>>   	 */
>>   	ndelay(100);
>>
>> +	/* Apply the tPROG delay for ONFI nand program. */
>> +	if (chip->onfi_version&&  state == FL_WRITING)
>> +		udelay(le16_to_cpu(chip->onfi_params.t_prog));
>> +
>>   	if ((state == FL_ERASING)&&  (chip->options&  NAND_IS_AND))
>>   		chip->cmdfunc(mtd, NAND_CMD_STATUS_MULTI, -1, -1);
>>   	else
> It looks wrong : why should be wait tPROG before using status command to monitor
> program end ?
>
> tPROG is the Page program time (Measured from the falling edge of SR[6] to the
> rising edge of SR[6]), but because we monitor SR[6] with status command, we
> already wait for that time.
>
thanks. you are right. Please ignore this patch.
> Are you sure that it is not a bug in your nand driver with status command ?
>
>
I will try to find the bug in the driver.

thanks
Huang Shijie
> Matthieu
>


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ