This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Block device IO
- From: Savin Zlobec <savin at elatec dot si>
- To: ecos-discuss at sources dot redhat dot com
- Date: Tue, 19 Aug 2003 16:09:13 +0200
- Subject: [ECOS] Block device IO
Hello,
I've just finished writting the basic block device IO stuff.
It consists of 3 layers:
1. layer just reads and writtes blocks through cyg_io_bread/write (len
and pos being in blocks)
2. layer does the block caching on top of first one - access is also
trough cyg_io_bread/write (len and pos being in blocks)
3. layer does byte access trough cyg_io_bread/write (len and pos being
in bytes,
block number set/get is done trough cyg_io_set/get_config - you only
need
to set block numbers if you get over the 32 bit boundary since the
block number
is adjusted according to the position)
the layering method used is the same as the one used in serial - tty -
termios drivers, so
they can also be used separatly.
There are probably some bugs and holes around the code, but if anyone is
interested in finding bugs, extending or commenting I can post it on
discuss or better on devel list.
savin
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss