[4930] Add OneNAND Unlock All command (Kyungmin Park).
Revision: 4930
http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=4930 Author: balrog Date: 2008-07-23 16:35:45 +0000 (Wed, 23 Jul 2008)
Log Message:
-----------
Add OneNAND Unlock All command (Kyungmin Park).
Modified Paths:
--------------
trunk/hw/onenand.c
Modified: trunk/hw/onenand.c
===================================================================
hw/onenand.c +15 -0
@@ -355,6 +355,21 @@ s->wpstatus = s->blockwp[b] =ONEN_LOCK_UNLOCKED ; }break ; +case 0x27 :/* Unlock All NAND array blocks */ + s->intstatus |=ONEN_INT ; + +for (b =0 ; b < s->blocks; b ++) { +if (b >= s->blocks) { + s->status |=ONEN_ERR_CMD ; +break ; + } +if (s->blockwp[b] ==ONEN_LOCK_LOCKTIGHTEN ) +break ; + + s->wpstatus = s->blockwp[b] =ONEN_LOCK_UNLOCKED ; + } +break ; +case 0x2a :/* Lock NAND array block(s) */ s->intstatus |=ONEN_INT ;