devf-* memory size questions

Hi,

what are the minimum memory requirements for devf-ram?. I’d like to use it
to access a 32 K Byte Zero Power SRAM (CMOS-RAM). But the created partition
is always 64 K byte in size even if I say ‘devf-ram -a -s,32k’. Is it intended to work only with 64 K byte and more?

Next I tried to use devf-generic for a 128 K byte flash memory. This works
with one partition, but I can’t set it up to use more than one partition,
let’s say 2 x 64 K Byte or even 4 x 32 K Byte. How can I setup devf-generic
to have more than one partition?

I think I understood the socked and partition philosophy of the devf-*
drivers. But I now than I did not understood the -s option! What means
, , and ? I tried to
figure this out by reading the sources of the ddk, but most of the code is
within libraries for which I don’t have the sources.

So I hope someone from QSSL can help me.

I use QNX 6.2.1

TIA
Peter

Sorry for the strange kind of posting. I can’t get this MS stuff under
control.

Peter

“Peter Stöckigt” <stoeckigt.p@stn-atlas.de> wrote in message
news:bcbv6u$76a$2@inn.qnx.com

Hi,

what are the minimum memory requirements for devf-ram?. I’d like to use it
to access a 32 K Byte Zero Power SRAM (CMOS-RAM). But the created
partition
is always 64 K byte in size even if I say ‘devf-ram -a -s,32k’. Is it intended to work only with 64 K byte and more?

devf-ram uses a 32K erase block size, which means a filesystem must be
divisable by 32K. But a filesystem requires a reclaim block, so the smallest
filesystem is 64K (with devf-ram).

Next I tried to use devf-generic for a 128 K byte flash memory. This works
with one partition, but I can’t set it up to use more than one partition,
let’s say 2 x 64 K Byte or even 4 x 32 K Byte. How can I setup
devf-generic
to have more than one partition?

The first time you start the driver on any flash it will only show one
partition. You need to use flashctl to make new partitions. So if I had 32M
of flash and I wanted to put a partitoion in the middle for 16M I would do
it like this

flashctl -p /dev/fs0p0 -vef -o8M -l16M -n/flash
slay devf-???
retsart the driver

you should now see in your /dev directory 3 partitions

/dev/fs0p0 8M of raw flash
/dev/fs0p1 16M flash filesystem that is mount at /flash
/dev/fs0p2 8M if raw flash

I think I understood the socked and partition philosophy of the devf-*
drivers. But I now than I did not understood the -s option! What means
window size>, , and ? I tried to
figure this out by reading the sources of the ddk, but most of the code is
within libraries for which I don’t have the sources.

ignore most of those option, just tell the driver the physical start of the
flash and whole size.

i.e. devf-generic -s0x80000000,32M


So I hope someone from QSSL can help me.

I use QNX 6.2.1

TIA
Peter

\

OK, thanks for the reply, it works.

Is it possible to have a special devf-ram with a smaller block size, i. e.
1, 2 or 4 Kbytes?
I think I found then entry in the f3s_dbase_t structure, but I can’t build a
new devf-smalram.
I created a new directory under
/usr/src/bsp-6.2.1/libs/src/hardware/flash/mdt-flash/ by copying
the sram directory. The docs are very sparse about building a new devf-x
(Customizing the Flash File System).
At least the main function is missing. Do I need to install an additional
package?

TIA
Peter (still running QNX 6.2.1, selfhosted)

“Jason Clarke” <jclarke@qnx.com> schrieb im Newsbeitrag
news:bcckc5$mge$1@nntp.qnx.com

“Peter Stöckigt” <> stoeckigt.p@stn-atlas.de> > wrote in message
news:bcbv6u$76a$> 2@inn.qnx.com> …
Hi,

what are the minimum memory requirements for devf-ram?. I’d like to use
it
to access a 32 K Byte Zero Power SRAM (CMOS-RAM). But the created
partition
is always 64 K byte in size even if I say ‘devf-ram -a -s,32k’. Is it intended to work only with 64 K byte and more?

devf-ram uses a 32K erase block size, which means a filesystem must be
divisable by 32K. But a filesystem requires a reclaim block, so the
smallest
filesystem is 64K (with devf-ram).

Next I tried to use devf-generic for a 128 K byte flash memory. This
works
with one partition, but I can’t set it up to use more than one
partition,
let’s say 2 x 64 K Byte or even 4 x 32 K Byte. How can I setup
devf-generic
to have more than one partition?

The first time you start the driver on any flash it will only show one
partition. You need to use flashctl to make new partitions. So if I had
32M
of flash and I wanted to put a partitoion in the middle for 16M I would do
it like this

flashctl -p /dev/fs0p0 -vef -o8M -l16M -n/flash
slay devf-???
retsart the driver

you should now see in your /dev directory 3 partitions

/dev/fs0p0 8M of raw flash
/dev/fs0p1 16M flash filesystem that is mount at /flash
/dev/fs0p2 8M if raw flash


I think I understood the socked and partition philosophy of the devf-*
drivers. But I now than I did not understood the -s option! What means
window size>, , and ? I tried to
figure this out by reading the sources of the ddk, but most of the code
is
within libraries for which I don’t have the sources.


ignore most of those option, just tell the driver the physical start of
the
flash and whole size.

i.e. devf-generic -s0x80000000,32M


So I hope someone from QSSL can help me.

I use QNX 6.2.1

TIA
Peter



\

You should have everything there to create a new devf-smalram driver, but it
would probably be easier with the source to devf-ram since there is some
extra stuff such as setting up some shared memory. If you want to go this
route you should ask your sales rep about getting the source.

I might just be easier to use devb-ram. It mimics a block filesystem, so the
block size is 512bytes


“Peter Stöckigt” <stoeckigt.p@stn-atlas.de> wrote in message
news:bcmiin$590$1@inn.qnx.com

OK, thanks for the reply, it works.

Is it possible to have a special devf-ram with a smaller block size, i. e.
1, 2 or 4 Kbytes?
I think I found then entry in the f3s_dbase_t structure, but I can’t build
a
new devf-smalram.
I created a new directory under
/usr/src/bsp-6.2.1/libs/src/hardware/flash/mdt-flash/ by copying
the sram directory. The docs are very sparse about building a new devf-x
(Customizing the Flash File System).
At least the main function is missing. Do I need to install an additional
package?

TIA
Peter (still running QNX 6.2.1, selfhosted)

“Jason Clarke” <> jclarke@qnx.com> > schrieb im Newsbeitrag
news:bcckc5$mge$> 1@nntp.qnx.com> …

“Peter Stöckigt” <> stoeckigt.p@stn-atlas.de> > wrote in message
news:bcbv6u$76a$> 2@inn.qnx.com> …
Hi,

what are the minimum memory requirements for devf-ram?. I’d like to
use
it
to access a 32 K Byte Zero Power SRAM (CMOS-RAM). But the created
partition
is always 64 K byte in size even if I say ‘devf-ram -a -s,32k’. Is it intended to work only with 64 K byte and more?

devf-ram uses a 32K erase block size, which means a filesystem must be
divisable by 32K. But a filesystem requires a reclaim block, so the
smallest
filesystem is 64K (with devf-ram).

Next I tried to use devf-generic for a 128 K byte flash memory. This
works
with one partition, but I can’t set it up to use more than one
partition,
let’s say 2 x 64 K Byte or even 4 x 32 K Byte. How can I setup
devf-generic
to have more than one partition?

The first time you start the driver on any flash it will only show one
partition. You need to use flashctl to make new partitions. So if I had
32M
of flash and I wanted to put a partitoion in the middle for 16M I would
do
it like this

flashctl -p /dev/fs0p0 -vef -o8M -l16M -n/flash
slay devf-???
retsart the driver

you should now see in your /dev directory 3 partitions

/dev/fs0p0 8M of raw flash
/dev/fs0p1 16M flash filesystem that is mount at /flash
/dev/fs0p2 8M if raw flash


I think I understood the socked and partition philosophy of the devf-*
drivers. But I now than I did not understood the -s option! What means
window size>, , and ? I tried
to
figure this out by reading the sources of the ddk, but most of the
code
is
within libraries for which I don’t have the sources.


ignore most of those option, just tell the driver the physical start of
the
flash and whole size.

i.e. devf-generic -s0x80000000,32M


So I hope someone from QSSL can help me.

I use QNX 6.2.1

TIA
Peter





\

Actually you can’t use devb-ram, the meta data for the filesystem is greater
then or really close to 32K

“Jason Clarke” <jclarke@qnx.com> wrote in message
news:bcn5f0$928$1@nntp.qnx.com

You should have everything there to create a new devf-smalram driver, but
it
would probably be easier with the source to devf-ram since there is some
extra stuff such as setting up some shared memory. If you want to go this
route you should ask your sales rep about getting the source.

I might just be easier to use devb-ram. It mimics a block filesystem, so
the
block size is 512bytes


“Peter Stöckigt” <> stoeckigt.p@stn-atlas.de> > wrote in message
news:bcmiin$590$> 1@inn.qnx.com> …
OK, thanks for the reply, it works.

Is it possible to have a special devf-ram with a smaller block size, i.
e.
1, 2 or 4 Kbytes?
I think I found then entry in the f3s_dbase_t structure, but I can’t
build
a
new devf-smalram.
I created a new directory under
/usr/src/bsp-6.2.1/libs/src/hardware/flash/mdt-flash/ by copying
the sram directory. The docs are very sparse about building a new devf-x
(Customizing the Flash File System).
At least the main function is missing. Do I need to install an
additional
package?

TIA
Peter (still running QNX 6.2.1, selfhosted)

“Jason Clarke” <> jclarke@qnx.com> > schrieb im Newsbeitrag
news:bcckc5$mge$> 1@nntp.qnx.com> …

“Peter Stöckigt” <> stoeckigt.p@stn-atlas.de> > wrote in message
news:bcbv6u$76a$> 2@inn.qnx.com> …
Hi,

what are the minimum memory requirements for devf-ram?. I’d like to
use
it
to access a 32 K Byte Zero Power SRAM (CMOS-RAM). But the created
partition
is always 64 K byte in size even if I say ‘devf-ram -a -s,32k’. Is it intended to work only with 64 K byte and more?

devf-ram uses a 32K erase block size, which means a filesystem must be
divisable by 32K. But a filesystem requires a reclaim block, so the
smallest
filesystem is 64K (with devf-ram).

Next I tried to use devf-generic for a 128 K byte flash memory. This
works
with one partition, but I can’t set it up to use more than one
partition,
let’s say 2 x 64 K Byte or even 4 x 32 K Byte. How can I setup
devf-generic
to have more than one partition?

The first time you start the driver on any flash it will only show one
partition. You need to use flashctl to make new partitions. So if I
had
32M
of flash and I wanted to put a partitoion in the middle for 16M I
would
do
it like this

flashctl -p /dev/fs0p0 -vef -o8M -l16M -n/flash
slay devf-???
retsart the driver

you should now see in your /dev directory 3 partitions

/dev/fs0p0 8M of raw flash
/dev/fs0p1 16M flash filesystem that is mount at /flash
/dev/fs0p2 8M if raw flash


I think I understood the socked and partition philosophy of the
devf-*
drivers. But I now than I did not understood the -s option! What
means
window size>, , and ? I tried
to
figure this out by reading the sources of the ddk, but most of the
code
is
within libraries for which I don’t have the sources.


ignore most of those option, just tell the driver the physical start
of
the
flash and whole size.

i.e. devf-generic -s0x80000000,32M


So I hope someone from QSSL can help me.

I use QNX 6.2.1

TIA
Peter







\

OK, I have my devf-smalram driver running (with a block size of 1 Kbytes).

There are still some topics I do not understand:

  1. What for are the geometry vectors ( number an size) in the fs3_dbase_t
    structure
    exactly? And how do they relate to the unit_size entry in the
    fs3_socket_t structure?

  2. Can I have different erase block and file system block sizes?

  3. Are the files or blocks stored on the flash file system secured by CRCs
    or
    checksums (i.e. if an alpha particle hits the device and toggles a bit
    :slight_smile:?
    Will the user be informed about accidental corrupted blocks? And if so,
    how?

“Jason Clarke” <jclarke@qnx.com> schrieb im Newsbeitrag
news:bcn5f0$928$1@nntp.qnx.com

You should have everything there to create a new devf-smalram driver, but
it
would probably be easier with the source to devf-ram since there is some
extra stuff such as setting up some shared memory. If you want to go this
route you should ask your sales rep about getting the source.

I might just be easier to use devb-ram. It mimics a block filesystem, so
the
block size is 512bytes


“Peter Stöckigt” <> stoeckigt.p@stn-atlas.de> > wrote in message
news:bcmiin$590$> 1@inn.qnx.com> …
OK, thanks for the reply, it works.

Is it possible to have a special devf-ram with a smaller block size, i.
e.
1, 2 or 4 Kbytes?
I think I found then entry in the f3s_dbase_t structure, but I can’t
build
a
new devf-smalram.
I created a new directory under
/usr/src/bsp-6.2.1/libs/src/hardware/flash/mdt-flash/ by copying
the sram directory. The docs are very sparse about building a new devf-x
(Customizing the Flash File System).
At least the main function is missing. Do I need to install an
additional
package?

TIA
Peter (still running QNX 6.2.1, selfhosted)

“Jason Clarke” <> jclarke@qnx.com> > schrieb im Newsbeitrag
news:bcckc5$mge$> 1@nntp.qnx.com> …

“Peter Stöckigt” <> stoeckigt.p@stn-atlas.de> > wrote in message
news:bcbv6u$76a$> 2@inn.qnx.com> …
Hi,

what are the minimum memory requirements for devf-ram?. I’d like to
use
it
to access a 32 K Byte Zero Power SRAM (CMOS-RAM). But the created
partition
is always 64 K byte in size even if I say ‘devf-ram -a -s,32k’. Is it intended to work only with 64 K byte and more?

devf-ram uses a 32K erase block size, which means a filesystem must be
divisable by 32K. But a filesystem requires a reclaim block, so the
smallest
filesystem is 64K (with devf-ram).

Next I tried to use devf-generic for a 128 K byte flash memory. This
works
with one partition, but I can’t set it up to use more than one
partition,
let’s say 2 x 64 K Byte or even 4 x 32 K Byte. How can I setup
devf-generic
to have more than one partition?

The first time you start the driver on any flash it will only show one
partition. You need to use flashctl to make new partitions. So if I
had
32M
of flash and I wanted to put a partitoion in the middle for 16M I
would
do
it like this

flashctl -p /dev/fs0p0 -vef -o8M -l16M -n/flash
slay devf-???
retsart the driver

you should now see in your /dev directory 3 partitions

/dev/fs0p0 8M of raw flash
/dev/fs0p1 16M flash filesystem that is mount at /flash
/dev/fs0p2 8M if raw flash


I think I understood the socked and partition philosophy of the
devf-*
drivers. But I now than I did not understood the -s option! What
means
window size>, , and ? I tried
to
figure this out by reading the sources of the ddk, but most of the
code
is
within libraries for which I don’t have the sources.


ignore most of those option, just tell the driver the physical start
of
the
flash and whole size.

i.e. devf-generic -s0x80000000,32M


So I hope someone from QSSL can help me.

I use QNX 6.2.1

TIA
Peter







\