[PATCH 1/1] mtd:nor:timeout:fix do_write_buffer() timeout error
Bean Huo 霍斌斌 (beanhuo)
beanhuo at micron.com
Tue Jun 3 02:30:44 PDT 2014
Hi,Christian
>>
>>
>> 1、MT28EW512ABA is Micron's parallel Norflash that use the cfi_cmdset_0002.c driver.
>Is it a new device? I can't find it on the Micron web site. If it is already there, could you please provide a link to the data sheet?
Yes,it is a new device that release this year.You must register an account at Micron web,at the same time, this account must be approved by micron, then you can find it.
>>
>> 2、yes,I am setting several parameters here(word_write_time_max、buffer_write_time_max、erase_time_max).For this patch,I only used buffer_write_time_max parameter.Because this patch is mainly focus on fix do_write_buffer() timeout error. If this patch is accepted, I will submit another patch that for fix single word program timeout error and erase timeout error.thanks.
>
>Ok. IMHO you should only set the parameters that you are actually using (and add word_write_time_max, erase_time_max etc later with the patches that actually use them). Otherwise we could end with lots of unused code if your later patches are not accepted. But I guess that's up to the maintainer to decide.
Ok,thanks for your advice,I will modify it and then submit patch V2
>> 3、The time unit of uWriteTimeout is ms. In order to achieve large
>> rather than small timeout ,so using following conversion,
>>
>>> + unsigned long uWriteTimeout = (chip->buffer_write_time_max % 1000) ?
>>> + (chip->buffer_write_time_max / 1000 + 1) :
>>> + (chip->buffer_write_time_max / 1000);
>But I think the result of usecs_to_jiffies would be the same, or am I wrong?
>If I understood the code of usecs_to_jiffies correctly, it returns at least one jiffy if the specified time is less than a jiffy.
Yes ,you are right.This will be modified in patch V2.
More information about the linux-mtd
mailing list