DCMD_FSYS_MOUNTED_AT, DCMD_FSYS_MOUNTED_BY, DCMD_FSYS_MOUNTED_ON

Get mount information

Synopsis:

#include <sys/dcmd_blk.h>

#define DCMD_FSYS_MOUNTED_ON   __DIOF(_DCMD_FSYS,  16, char[256])
#define DCMD_FSYS_MOUNTED_AT   __DIOF(_DCMD_FSYS,  17, char[256])
#define DCMD_FSYS_MOUNTED_BY   __DIOF(_DCMD_FSYS,  18, char[256])

Arguments to devctl():

Argument Value
filedes A file descriptor that you obtained by opening the device.
dcmd DCMD_FSYS_MOUNTED_AT, DCMD_FSYS_MOUNTED_BY, or DCMD_FSYS_MOUNTED_ON
dev_data_ptr A char[256] buffer
n_bytes The size of the buffer
dev_info_ptr NULL

Description:

These commands return 256 bytes of character data, giving information about the relationship of the filesystem associated with the given file descriptor to other filesystems:

This command: Asks:
DCMD_FSYS_MOUNTED_ON Who am I on top of?
DCMD_FSYS_MOUNTED_BY Who is on top of me?
DCMD_FSYS_MOUNTED_AT Where am I? Who is my owner?

Input:

None.

Output:

The associated path.

Errors:

The devctl() function can return the following, in addition to the error codes listed in its entry in the C Library Reference:

ENODEV
There is no such entity.

Example:

See "Mounting options" in the RAM-disk Filesystem chapter of The QNX Neutrino Cookbook.

See also:

devctl() in the QNX Neutrino C Library Reference