Refactor system call comments for accuracy and grammar
This commit is contained in:
@@ -91,7 +91,7 @@ syscall_init (void)
|
||||
lock_init (&filesys_lock);
|
||||
}
|
||||
|
||||
/* Function that takes a interrupt frame containing a syscall and its args.
|
||||
/* Function that takes an interrupt frame containing a syscall and its args.
|
||||
Validates the arguments and pointers before calling the relevant
|
||||
high-level system call function, storing its output (if any) in f->eax */
|
||||
static void
|
||||
@@ -138,8 +138,7 @@ syscall_exit (int status)
|
||||
}
|
||||
|
||||
/* Executes a given command with the relevant args, by calling process_execute.
|
||||
Returns PID for the process that is running the CMD_LINE
|
||||
*/
|
||||
Returns PID for the process that is running the CMD_LINE. */
|
||||
static pid_t
|
||||
syscall_exec (const char *cmd_line)
|
||||
{
|
||||
@@ -416,8 +415,8 @@ fd_get_file (int fd)
|
||||
}
|
||||
|
||||
/* Validates if a block of memory starting at START and of size SIZE bytes is
|
||||
fully contained within user virtual memory. Kills the thread (by calling
|
||||
thread_exit) if the memory is invalid. Otherwise, returns (nothing) normally.
|
||||
fully contained within user virtual memory. Kills the thread (by exiting with
|
||||
failure) if the memory is invalid. Otherwise, returns (nothing) normally.
|
||||
If the size is 0, the function does no checks and returns the given ptr. */
|
||||
static void
|
||||
validate_user_pointer (const void *start, size_t size)
|
||||
@@ -438,7 +437,7 @@ validate_user_pointer (const void *start, size_t size)
|
||||
}
|
||||
|
||||
/* Validates if a string is fully contained within user virtual memory. Kills
|
||||
the thread (by calling thread_exit) if the memory is invalid. Otherwise,
|
||||
the thread (by exiting with failure) if the memory is invalid. Otherwise,
|
||||
returns (nothing) normally. */
|
||||
static void
|
||||
validate_user_string (const char *str)
|
||||
|
||||
Reference in New Issue
Block a user