From: Fergus Simpson <afe...@google.com>

Permissions are not currently implemented in Akaros. This change simply
makes it so that devpermcheck(...) always returns before throwing an
error that would result in permission being denied. This allows the
device to actually be used while even though permissions have not been
implemented.

Change-Id: Ic2f19071803bba497d916031a22bcbc0b70e8ffd
Signed-off-by: Fergus Simpson <afe...@google.com>
---
 kern/src/ns/dev.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/kern/src/ns/dev.c b/kern/src/ns/dev.c
index 496cf94..abf683a 100644
--- a/kern/src/ns/dev.c
+++ b/kern/src/ns/dev.c
@@ -388,6 +388,10 @@ devdirread(struct chan *c, char *d, long n,
 void devpermcheck(char *fileuid, uint32_t perm, int omode)
 {
        int rwx;
+
+       /* TODO: Implement permission checking, for now permission is always
+        * granted. */
+       return;
        /* select user, group, or other from the traditional rwxrwxrwx, shifting
         * into the upper-most position */
        if (strcmp(current->user, fileuid) == 0)
-- 
2.8.0.rc3.226.g39d4020

-- 
You received this message because you are subscribed to the Google Groups 
"Akaros" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to akaros+unsubscr...@googlegroups.com.
To post to this group, send email to akaros@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to