It's really rather odd that the userspace structures (assuming FreeBSD doesn't use the same header for the kernel too, which I'm not sure is right)
It does :-(
have such inconsistent and restrictive lengths compared with what's technically permitted by the actual mount/umount system calls.
The vfs_donmount() from
http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/kern/vfs_mount.c
/*
* Be ultra-paranoid about making sure the type and fspath
* variables will fit in our mp buffers, including the
* terminating NUL.
*/
if (fstypelen >= MFSNAMELEN - 1 || fspathlen >= MNAMELEN - 1) {
error = ENAMETOOLONG;
goto bail;
}
The restriction comes from kernel.
Petr