public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* Re: Finalized TODO list for NAND and JFFS...
       [not found] ` <21835.969974378@passion.cygnus.co.uk>
@ 2000-09-27 11:35   ` Nick
  2000-09-27 11:57     ` David Woodhouse
  0 siblings, 1 reply; 3+ messages in thread
From: Nick @ 2000-09-27 11:35 UTC (permalink / raw)
  To: David Woodhouse; +Cc: jffs-dev, mtd

David Woodhouse wrote:

> Also add a checkpointing system or some way of removing the necessity of
> scanning the whole of the flash on mount.
>
> For a 21MB filesystem, that takes over a minute.
>
> --
> dwmw2

By the way, can't we shorten mount time for Intel chips by rewriting read
routines in such a way that they don't send Read Status Register command when
chip->status is FL_READY?

I think we can. Acually, I have tried already and it shortens mount time
dramatically.

So the question, as I can see it, is can we be sure that Status Register has
7th bit set when chip->status == FL_READY?

Any comments?

Nick



To unsubscribe, send "unsubscribe mtd" to majordomo@infradead.org

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Finalized TODO list for NAND and JFFS...
  2000-09-27 11:35   ` Finalized TODO list for NAND and JFFS Nick
@ 2000-09-27 11:57     ` David Woodhouse
  2000-09-27 13:21       ` Nick Ivanter
  0 siblings, 1 reply; 3+ messages in thread
From: David Woodhouse @ 2000-09-27 11:57 UTC (permalink / raw)
  To: Nick; +Cc: jffs-dev, mtd


nick@auriga.ru said:
>  By the way, can't we shorten mount time for Intel chips by rewriting
> read routines in such a way that they don't send Read Status Register
> command when chip->status is FL_READY?

Yes - well spotted.

nick@auriga.ru said:
>  So the question, as I can see it, is can we be sure that Status
> Register has 7th bit set when chip->status == FL_READY?

Yes. If that's ever _not_ the case, then consider it a bug in whatever code 
is setting the state to FL_READY.

Please supply either a SSH public key, so I can give you write access to 
CVS, or a patch that I can apply. The former is probably better.


--
dwmw2




To unsubscribe, send "unsubscribe mtd" to majordomo@infradead.org

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Finalized TODO list for NAND and JFFS...
  2000-09-27 11:57     ` David Woodhouse
@ 2000-09-27 13:21       ` Nick Ivanter
  0 siblings, 0 replies; 3+ messages in thread
From: Nick Ivanter @ 2000-09-27 13:21 UTC (permalink / raw)
  To: David Woodhouse; +Cc: jffs-dev, mtd

[-- Attachment #1: Type: text/plain, Size: 795 bytes --]

Please, find the patch attached.

David Woodhouse wrote:

> nick@auriga.ru said:
> >  By the way, can't we shorten mount time for Intel chips by rewriting
> > read routines in such a way that they don't send Read Status Register
> > command when chip->status is FL_READY?
>
> Yes - well spotted.
>
> nick@auriga.ru said:
> >  So the question, as I can see it, is can we be sure that Status
> > Register has 7th bit set when chip->status == FL_READY?
>
> Yes. If that's ever _not_ the case, then consider it a bug in whatever code
> is setting the state to FL_READY.
>
> Please supply either a SSH public key, so I can give you write access to
> CVS, or a patch that I can apply. The former is probably better.
>
> --
> dwmw2
>
> To unsubscribe, send "unsubscribe mtd" to majordomo@infradead.org

[-- Attachment #2: cfi_cmdset0001.patch --]
[-- Type: text/plain, Size: 1553 bytes --]

--- cfi_cmdset_0001.c	2000/09/15 14:35:22	1.34
+++ cfi_cmdset_0001.c	2000/09/27 13:17:39
@@ -271,15 +271,18 @@
 		/* Remember the status so we know whether to restart
 		   the erase later */
 		suspendedstate = status;
+		map->write16(map, cpu_to_le16(0x00ff), cmd_addr);
+		chip->state = FL_READY;
 		break;
 #if 0
 	case FL_WRITING:
 		/* Not quite yet */
 #endif
 
+	case FL_READY:
+		break;
 	case FL_CFI_QUERY:
 	case FL_JEDEC_QUERY:
-	case FL_READY:
 		map->write16(map, cpu_to_le16(0x0070), cmd_addr);
 		chip->state = FL_STATUS;
 
@@ -306,6 +309,8 @@
 
 			goto retry;
 		}
+		map->write16(map, cpu_to_le16(0x00ff), cmd_addr);
+		chip->state = FL_READY;
 		break;
 
 	default:
@@ -330,9 +335,6 @@
 		goto retry;
 	}
 
-	map->write16(map, cpu_to_le16(0x00ff), cmd_addr);
-	chip->state = FL_READY;
-
 	map->copy_from(map, buf, adr, len);
 
 	if (suspendedstate) {
@@ -1247,15 +1249,18 @@
 		/* Remember the status so we know whether to restart
 		   the erase later */
 		suspendedstate = status;
+		map->write8(map, 0xff, adr);
+		chip->state = FL_READY;
 		break;
 #if 0
 	case FL_WRITING:
 		/* Not quite yet */
 #endif
 
+	case FL_READY:
+		break;
 	case FL_CFI_QUERY:
 	case FL_JEDEC_QUERY:
-	case FL_READY:
 		map->write8(map, 0x70, adr);
 		chip->state = FL_STATUS;
 
@@ -1282,6 +1287,8 @@
 
 			goto retry;
 		}
+		map->write8(map, 0xff, adr);
+		chip->state = FL_READY;
 		break;
 
 	default:
@@ -1305,9 +1312,6 @@
 
 		goto retry;
 	}
-
-	map->write8(map, 0xff, adr);
-	chip->state = FL_READY;
 
 	map->copy_from(map, buf, adr, len);
 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2000-09-27 13:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <39D091DC.3218DE2D@cotw.com>
     [not found] ` <21835.969974378@passion.cygnus.co.uk>
2000-09-27 11:35   ` Finalized TODO list for NAND and JFFS Nick
2000-09-27 11:57     ` David Woodhouse
2000-09-27 13:21       ` Nick Ivanter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox