view src/interface/fs.dg @ 323:f0b337cb6024 default tip

use goto err->panic
author anatofuz <anatofuz@cr.ie.u-ryukyu.ac.jp>
date Sat, 08 Feb 2020 20:37:42 +0900
parents 98902fad1e2e
children
line wrap: on
line source

typedef struct fs<Type,Impl> {
    union Data* fs;
    struct superblock* sb;
    uint dev;
    short type;
    struct inode* ip;
    struct stat* st;
    char* dst;
    uint off;
    uint n;
    const char* s;
    const char* t;
    struct inode* dp;
    char* name;
    uint* poff;
    uint inum;
    char* path;
    char* src;
    int namex_val;
    int strncmp_val;
    dirent* de;
    int ret;
    uint tot;
    __code readsb(Impl* fs, uint dev, struct superblock* sb, __code next(...));
    __code iinit(Impl* fs, __code next(...));
    __code ialloc(Impl* fs, uint dev, short type, __code next(...));
    __code iupdate(Impl* fs, struct inode* ip, __code next(...));
    __code idup(Impl* fs, struct inode* ip, __code next(...));
    __code ilock(Impl* fs, struct inode* ip, __code next(...));
    __code iunlock(Impl* fs, struct inode* ip, __code next(...));
    __code iput(Impl* fs, struct inode* ip, __code next(...));
    __code iunlockput(Impl* fs, struct inode* ip, __code next(...));
    __code stati(Impl* fs , struct inode* ip, struct stat* st, __code next(...));
    __code readi(Impl* fs, struct inode* ip, char* dst, uint off, uint tot, uint n, __code next(int ret, ...));
    __code writei(Impl* fs, struct inode* ip, char* src, uint off, uint tot, uint n, __code next(int ret, ...));
    __code namecmp(Impl* fs, const char* s, const char* t, __code next(int strncmp_val, ...));
    __code dirlookup(Impl* fs, struct inode* dp, char* name, uint off, uint* poff, dirent* de, __code next(int ret, ...));
    __code dirlink(struct fs_impl* fs, struct inode* ip, struct dirent* de, struct inode* dp, char* name, uint off, uint inum, __code next(...));
    __code namei(Impl* fs, char* path, __code next(int namex_val, ...));
    __code nameiparent(Impl* fs, char* path, char* name, __code next(int namex_val, ...));
    __code next(...);
} fs;