diff --git a/fs/lxfs/src/dirent.c b/fs/lxfs/src/dirent.c index d89c40b..de1ddc9 100644 --- a/fs/lxfs/src/dirent.c +++ b/fs/lxfs/src/dirent.c @@ -23,21 +23,21 @@ void lxfsOpendir(OpendirCommand *ocmd) { Mountpoint *mp = findMP(ocmd->device); if(!mp) { ocmd->header.header.status = -EIO; // device doesn't exist - luxSendDependency(ocmd); + luxSendKernel(ocmd); return; } LXFSDirectoryEntry entry; if(!lxfsFind(&entry, mp, ocmd->path)) { ocmd->header.header.status = -ENOENT; // file doesn't exist - luxSendDependency(ocmd); + luxSendKernel(ocmd); return; } // ensure this is a directory if(((entry.flags >> LXFS_DIR_TYPE_SHIFT) & LXFS_DIR_TYPE_MASK) != LXFS_DIR_TYPE_DIR) { ocmd->header.header.status = -ENOTDIR; - luxSendDependency(ocmd); + luxSendKernel(ocmd); return; } @@ -50,7 +50,7 @@ void lxfsOpendir(OpendirCommand *ocmd) { else if(!(entry.permissions & LXFS_PERMS_OTHER_X)) ocmd->header.header.status = -EPERM; - luxSendDependency(ocmd); + luxSendKernel(ocmd); } /* lxfsReaddir(): reads a directory entry from an lxfs volume @@ -65,21 +65,21 @@ void lxfsReaddir(ReaddirCommand *rcmd) { Mountpoint *mp = findMP(rcmd->device); if(!mp) { rcmd->header.header.status = -EIO; // device doesn't exist - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } LXFSDirectoryEntry entry; if(!lxfsFind(&entry, mp, rcmd->path)) { rcmd->header.header.status = -ENOENT; // file doesn't exist - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } // ensure this is a directory if(((entry.flags >> LXFS_DIR_TYPE_SHIFT) & LXFS_DIR_TYPE_MASK) != LXFS_DIR_TYPE_DIR) { rcmd->header.header.status = -ENOTDIR; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -90,7 +90,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { rcmd->position++; rcmd->end = 0; rcmd->header.header.status = 0; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } else if(rcmd->position == 1) { strcpy(rcmd->entry.d_name, ".."); @@ -98,7 +98,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { rcmd->position++; rcmd->end = 0; rcmd->header.header.status = 0; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -109,7 +109,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { if(lxfsReadBlock(mp, next, mp->dataBuffer)) { rcmd->header.header.status = -EIO; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -117,7 +117,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { next = lxfsReadNextBlock(mp, next, mp->dataBuffer); if(!next) { rcmd->header.header.status = -EIO; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -135,7 +135,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { rcmd->position++; rcmd->end = 0; rcmd->header.header.status = 0; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -146,7 +146,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { if(!oldSize) { rcmd->header.header.status = 0; rcmd->end = 1; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -162,7 +162,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { if(!dir->entrySize) { rcmd->header.header.status = 0; rcmd->end = 1; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -170,7 +170,7 @@ void lxfsReaddir(ReaddirCommand *rcmd) { next = lxfsReadNextBlock(mp, next, mp->dataBuffer); if(!next) { rcmd->header.header.status = -EIO; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } } @@ -179,6 +179,6 @@ void lxfsReaddir(ReaddirCommand *rcmd) { rcmd->header.header.status = 0; rcmd->end = 1; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } \ No newline at end of file diff --git a/fs/lxfs/src/open.c b/fs/lxfs/src/open.c index c77c923..d79f3b8 100644 --- a/fs/lxfs/src/open.c +++ b/fs/lxfs/src/open.c @@ -26,21 +26,21 @@ void lxfsOpen(OpenCommand *ocmd) { Mountpoint *mp = findMP(ocmd->device); if(!mp) { ocmd->header.header.status = -EIO; // device doesn't exist - luxSendDependency(ocmd); + luxSendKernel(ocmd); return; } LXFSDirectoryEntry entry; if(!lxfsFind(&entry, mp, ocmd->path)) { ocmd->header.header.status = -ENOENT; // file doesn't exist - luxSendDependency(ocmd); + luxSendKernel(ocmd); return; } // ensure this is a file if(((entry.flags >> LXFS_DIR_TYPE_SHIFT) & LXFS_DIR_TYPE_MASK) != LXFS_DIR_TYPE_FILE) { ocmd->header.header.status = -EISDIR; - luxSendDependency(ocmd); + luxSendKernel(ocmd); return; } @@ -57,5 +57,5 @@ void lxfsOpen(OpenCommand *ocmd) { if((ocmd->flags & O_WRONLY) && !(entry.permissions & LXFS_PERMS_OTHER_W)) ocmd->header.header.status = -EACCES; } - luxSendDependency(ocmd); + luxSendKernel(ocmd); } \ No newline at end of file diff --git a/fs/lxfs/src/read.c b/fs/lxfs/src/read.c index bf256f3..7a3b441 100644 --- a/fs/lxfs/src/read.c +++ b/fs/lxfs/src/read.c @@ -27,7 +27,7 @@ void lxfsRead(RWCommand *rcmd) { Mountpoint *mp = findMP(rcmd->device); if(!mp) { rcmd->header.header.status = -EIO; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -35,7 +35,7 @@ void lxfsRead(RWCommand *rcmd) { LXFSDirectoryEntry entry; if(!lxfsFind(&entry, mp, rcmd->path)) { rcmd->header.header.status = -ENOENT; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -43,7 +43,7 @@ void lxfsRead(RWCommand *rcmd) { uint64_t first = lxfsReadNextBlock(mp, entry.block, mp->meta); if(!first) { rcmd->header.header.status = -EIO; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -52,7 +52,7 @@ void lxfsRead(RWCommand *rcmd) { // input validation if(rcmd->position >= metadata->size) { rcmd->header.header.status = -EOVERFLOW; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -65,7 +65,7 @@ void lxfsRead(RWCommand *rcmd) { RWCommand *res = calloc(1, sizeof(RWCommand) + truelen); if(!res) { rcmd->header.header.status = -ENOMEM; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -83,7 +83,7 @@ void lxfsRead(RWCommand *rcmd) { if(!block) { free(res); rcmd->header.header.status = -EIO; - luxSendDependency(rcmd); + luxSendKernel(rcmd); return; } @@ -133,6 +133,6 @@ void lxfsRead(RWCommand *rcmd) { res->header.header.status = -EIO; } - luxSendDependency(res); + luxSendKernel(res); free(res); } \ No newline at end of file diff --git a/fs/lxfs/src/stat.c b/fs/lxfs/src/stat.c index dd23dfa..3902c86 100644 --- a/fs/lxfs/src/stat.c +++ b/fs/lxfs/src/stat.c @@ -19,7 +19,7 @@ void lxfsStat(StatCommand *cmd) { Mountpoint *mp = findMP(cmd->source); if(!mp) { cmd->header.header.status = -EIO; - luxSendDependency(cmd); + luxSendKernel(cmd); return; } @@ -27,7 +27,7 @@ void lxfsStat(StatCommand *cmd) { LXFSDirectoryEntry entry; if(!lxfsFind(&entry, mp, cmd->path)) { cmd->header.header.status = -ENOENT; - luxSendDependency(cmd); + luxSendKernel(cmd); return; } @@ -35,7 +35,7 @@ void lxfsStat(StatCommand *cmd) { uint64_t first = lxfsReadNextBlock(mp, entry.block, mp->meta); if(!first) { cmd->header.header.status = -EIO; - luxSendDependency(cmd); + luxSendKernel(cmd); return; } @@ -84,5 +84,5 @@ void lxfsStat(StatCommand *cmd) { // and we're done, relay the response cmd->header.header.status = 0; - luxSendDependency(cmd); + luxSendKernel(cmd); } \ No newline at end of file