Few problems in mtd system

Michael Trimarchi trimarchi at gandalf.sssup.it
Tue Dec 22 15:32:53 EST 2009


Maxim Levitsky wrote:
> On Mon, 2009-12-21 at 15:00 +0100, Jörn Engel wrote: 
>   
>> On Sun, 20 December 2009 22:59:55 +0200, Maxim Levitsky wrote:
>>     
>>> I suspect that older non type M cards didn't have such emulation, but
>>> were real nand chips, bacause there are some references on the web about
>>> using XD card as a nand chip replacement.
>>> Such card as I have will really will make very poor nand replacement...
>>>       
>> If you want to know whether the cards or the readers are to blame, you
>> can try to buy an old alauda reader on ebay.  It is too slow to be
>> useful for most purposes, but I believe it did give me full access with
>> my cards.
>>
>>     
>>> Folks, could you review my other questions about bugs in mtd core, and
>>> tell your opinion?
>>>       
>
> I have several problems, more correctly bugs in mtd system I have to fix
> to make my driver work.
>
> Lets start from  the problem I face now.
>
> Problem is that add_mtd_blktrans_dev is called with mtd_table_mutex
> locked, but it calls add_disk which opens the block device if you
> specify that you need partitions on the disk. Open routine 'looks' at
> mtd table using get_mtd_device, and thus deadlocks.
>
> Do you have a clue how to fix that so it won't break anything?
>   
I try to follow the call, can you send the block stack trace?
just change the lock on get_mtd_device with a try_lock and BUG on
if it is taken

Michael
>
> Best regards,
> Maxim Levitsky
>
>
> ______________________________________________________
> Linux MTD discussion mailing list
> http://lists.infradead.org/mailman/listinfo/linux-mtd/
>   




More information about the linux-mtd mailing list