9.91 listmounts

struct mountinfo {
    uint32_t fs_type;
    uint32_t flags;
    char source[20];
    uint32_t source_len;
    char location[20];
    uint32_t location_len;
    uint64_t block_size;
    uint64_t fragment_size;
    uint64_t size_in_frags;
    uint64_t free_blocks;
    uint64_t free_blocks_user;
    uint64_t inode_count;
    uint64_t free_inodes;
    uint64_t free_inodes_user;
    uint64_t max_filename_len;
} __attribute__((packed));

size_t listmounts(struct mountinfo *addr, size_t len);

This syscall writes a list of all mounts currently in use in the system to addr, which contains len items.

The number of mounts in the system is returned in success, and -1 in failure, with the following errno: