Write Protect a Compact Flash

How do I write protect a Compact Flash device in QNX6? I’ve done this on a HDD with QNX4 by using:
mount /dev/hd0t77 / -r
but that does not work in QNX6. I’ve also tried these:
mount -r /dev/hd0t77
mount /dev/hd0t77 -r
I would really like to have this protection activated during boot up. In QNX4 this can be done in the hard32.1 file, but this file doesn’t exist in QNX6. So, I’ll be putting it somewhere in the sysinit boot up sequence - comments welcome on this also.


If you check mount`s documentation, the options must be specified @before@ the mount points, hence

mount -r /dev/hdt077 /

should work.

If it`s already mounted use -u as well to refresh.

Thanks! Yes, it matters when you try to write protect. Here is how I got it to work in my boot image:

Start the hard disk, CF, CD Disk Driver.

display_msg …Start devb-eide…
devb-eide dos exec=all cam verbose &

display_msg …Wait for /dev/hd0t79…
waitfor /dev/hd0t79 10

display_msg …Write protect the Compact Flash…
mount -r /dev/hd0t79 /