public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* Is realtime logging possible?
@ 2002-02-08 21:37 Derek Ross
  2002-02-09  1:31 ` David Woodhouse
  0 siblings, 1 reply; 5+ messages in thread
From: Derek Ross @ 2002-02-08 21:37 UTC (permalink / raw)
  To: linux-mtd

Hello,

Our product will have a slow-realtime logging
component in it, and I'm trying to find out if
flash will be capable of handling it.

We'll be logging about 6 bytes once a second into
flash.  The maximum blocking duration for a write
should be 0.1 second or less.

I understand that sector erases in flash take lots
of time, but it's possible to do erases in the 
background, so that if you organize the writes not
to interfere with the erases (always different sectors)
you won't have long blocking issues.

The technical details are:

CDB89712 (rev B) development board.

Flash TE28F320 B Jedec, not CFI
Will later be using C for final product, which is CFI

Kernel is 2.4.6-rmk1-rayl1, and we also have 2.4.16-rmk2
We can upgrade mtd drivers if necessary.


Thanks,
Derek Ross.

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

* Re: Is realtime logging possible?
  2002-02-08 21:37 Is realtime logging possible? Derek Ross
@ 2002-02-09  1:31 ` David Woodhouse
  2002-02-09 15:07   ` Derek Ross
  0 siblings, 1 reply; 5+ messages in thread
From: David Woodhouse @ 2002-02-09  1:31 UTC (permalink / raw)
  To: Derek Ross; +Cc: linux-mtd

On Fri, 8 Feb 2002, Derek Ross wrote:

> Hello,
> 
> Our product will have a slow-realtime logging
> component in it, and I'm trying to find out if
> flash will be capable of handling it.
> 
> We'll be logging about 6 bytes once a second into
> flash.  The maximum blocking duration for a write
> should be 0.1 second or less.

Does the write to flash really have to be done in the context of the 
realtime process? 

You probably don't want to use a filesystem for this - just log to the raw 
flash, using the mtd chardevice and issuing MEMERASE calls manually when 
necessary. 

> background, so that if you organize the writes not
> to interfere with the erases (always different sectors)
> you won't have long blocking issues.

IIRC that's not implemented completely for the Intel chips atm. Our state 
machine thinks the whole chip is busy whenever it's erasing any part, and 
won't attempt to write to it. We should fix the state machine so it keeps 
state for each individual region of the flash.

-- 
dwmw2

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

* Re: Is realtime logging possible?
  2002-02-09  1:31 ` David Woodhouse
@ 2002-02-09 15:07   ` Derek Ross
  2002-02-09 20:46     ` David Woodhouse
  2002-02-10 15:51     ` kira brown
  0 siblings, 2 replies; 5+ messages in thread
From: Derek Ross @ 2002-02-09 15:07 UTC (permalink / raw)
  To: David Woodhouse; +Cc: linux-mtd

> > We'll be logging about 6 bytes once a second into
> > flash.  The maximum blocking duration for a write
> > should be 0.1 second or less.
>
> You probably don't want to use a filesystem for this - just log to the raw 
> flash, using the mtd chardevice and issuing MEMERASE calls manually when 
> necessary. 

Yes, our logging structure will basically be some circular
buffers, so it will be easy to do that at the lower level.

However, we would still like to use the filesystem
capabilities of the flash during non-"realtime" modes,
like during configuration or initialization.

Is it possible for a filesystem to coexist with 
low-level reading, writing and erasing?  Maybe by
specifying in advance which sectors are forbidden
to the filesystem.

Or is it "never the twain shall meet"?

Derek.

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

* Re: Is realtime logging possible?
  2002-02-09 15:07   ` Derek Ross
@ 2002-02-09 20:46     ` David Woodhouse
  2002-02-10 15:51     ` kira brown
  1 sibling, 0 replies; 5+ messages in thread
From: David Woodhouse @ 2002-02-09 20:46 UTC (permalink / raw)
  To: Derek Ross; +Cc: linux-mtd

On Sat, 9 Feb 2002, Derek Ross wrote:

> Is it possible for a filesystem to coexist with 
> low-level reading, writing and erasing?  Maybe by
> specifying in advance which sectors are forbidden
> to the filesystem.

Yes, you can partition the flash however you like. As I mentioned before, 
you need to check that the chip driver won't make the RT process wait for 
writes to happen in the filesystem partition, because it thinks the whole 
_chip_ is busy not just one sector.

-- 
dwmw2

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

* Re: Is realtime logging possible?
  2002-02-09 15:07   ` Derek Ross
  2002-02-09 20:46     ` David Woodhouse
@ 2002-02-10 15:51     ` kira brown
  1 sibling, 0 replies; 5+ messages in thread
From: kira brown @ 2002-02-10 15:51 UTC (permalink / raw)
  To: Derek Ross; +Cc: David Woodhouse, linux-mtd


On Sat, 9 Feb 2002, Derek Ross wrote:

> Is it possible for a filesystem to coexist with
> low-level reading, writing and erasing?  Maybe by
> specifying in advance which sectors are forbidden
> to the filesystem.

or in other words, by partitioning the flash, which is supported by the
MTD stuff.

k.

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

end of thread, other threads:[~2002-02-10 15:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-02-08 21:37 Is realtime logging possible? Derek Ross
2002-02-09  1:31 ` David Woodhouse
2002-02-09 15:07   ` Derek Ross
2002-02-09 20:46     ` David Woodhouse
2002-02-10 15:51     ` kira brown

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