Documentation of the VNode system for IRIX (virtual FS layer)
#1
Documentation of the VNode system for IRIX (virtual FS layer)
This thread serves to combine my notes, and Solidcore's, on this topic. 

Notes regarding filesystem objects. 

https://wiki.irixnet.org/IRIX+Vnode

The functions are prefixed with the name of the FS/fs module file. 

Some relevant structures for IRIX's VFS are in the below codeblocks. These were RE'd by Endeavour and myself later on:

Code:
typedef struct vfsops {
Code:
    bhv_position_t    vf_position;   
Code:
    int    (*vfs_mount)(struct vfs *, struct vnode *,
Code:
                 struct mounta *, char *, struct cred *);
Code:
                   
Code:
    int    (*vfs_rootinit)(struct vfs *);
Code:
                   
Code:
    int    (*vfs_mntupdate)(bhv_desc_t *, struct vnode *,
Code:
                 struct mounta *, struct cred *);
Code:
    int    (*vfs_dounmount)(bhv_desc_t *, int, struct vnode *,
Code:
                 struct cred *);
Code:
    int    (*vfs_unmount)(bhv_desc_t *, int, struct cred *);
Code:
    int    (*vfs_root)(bhv_desc_t *, struct vnode **);
Code:
    int    (*vfs_statvfs)(bhv_desc_t *, struct statvfs *, struct vnode *);
Code:
    int    (*vfs_sync)(bhv_desc_t *, int, struct cred *);
Code:
    int    (*vfs_vget)(bhv_desc_t *, struct vnode **, struct fid *);
Code:
    int    (*vfs_mountroot)(bhv_desc_t *, enum whymountroot);
Code:
    int    (*vfs_realvfsops)(vfs_t *, struct mounta *, struct vfsops **);
Code:
        int     (*vfs_import)(vfs_t *);
Code:
   
Code:
    int    (*vfs_quotactl)(bhv_desc_t *, int, int, caddr_t);
Code:
    int    (*vfs_force_pinned)(bhv_desc_t *);
Code:
    int     vfs_ops_magic;         
Code:
        __uint64_t   vfs_ops_version;   
Code:
        __uint64_t   vfs_ops_flags;   
Code:
} vfsops_t;

typedef struct vfssw {
    char        *vsw_name;     
    int        (*vsw_init)(struct vfssw *, int);
    vfsops_t    *vsw_vfsops;       
    struct vnodeops    *vsw_vnodeops;       
    void        *vsw_fill;       
    long        vsw_flag;       
} vfssw_t

This is what we were able to find out. 


This is a companion thread to a new bounty replacing an abortive one.

I'm the system admin of this site. Private security technician, licensed locksmith, hack of a c developer and vintage computer enthusiast. 

https://contrib.irixnet.org/raion/ -- contributions and pieces that I'm working on currently. 

https://codeberg.org/SolusRaion -- Code repos I control

Technical problems should be sent my way.
Raion
Chief IRIX Officer

Trade Count: (9)
Posts: 4,252
Threads: 535
Joined: Nov 2017
Location: Eastern Virginia
Website Find Reply
11-11-2022, 12:31 AM


Forum Jump:


Users browsing this thread: 1 Guest(s)