mount(2v)

David J. Bianco bianco at cs.odu.edu
Tue Feb 26 03:11:32 AEST 1991


I'm having a problem with the mount(2v) function call under SunOS 4.1.1.
Theoretically, they now have a feature to allow mounting of MSDOS floppy
disks in the Sparcstation's 3.5" drive.  From the shell, its simple, but
from my C code, I can't seem to get it to work.  Here's a fragment of my
code:
	caddr_t data;

	mount("pcfs", "/floppy", M_NEWTYPE|M_NOSUB|M_NOSUID, data);

I seem to be running into several problems here.  The first is that this
function always gives an EFAULT,which, according the the man page, means
that "/floppy" (the string, not the dir) is outside my allocated address
space.  I strongly suspect that this has something to do with my other 2
problems.
   The next problem is that the man page for mount(2v) does not
say what the first argument to the function should be for pcfs disks.
I made my best guess by looking at the other args.  Sun apparently didnt
feel it necessary to document pcfs file systems for some reason.  
   Finally, I haven't been able to determine if I actually need to fill
data with info before the call, or if it simply returns info about the mount
once it is made. 
   Has anyone successfully pulled this off? If so, I'd really like to hear
from you!

----------------
David J. Bianco	<bianco at cs.odu.edu>
Apprentice Systems Dude
My cute quote is on vacation this week....
----------------



More information about the Comp.unix.programmer mailing list