We could add the function do_mygetpid to the misc.c file.
PUBLIC int do_mygetpid()
{
/**
* Global mp will point to the caller's process table entry.
* Lookup information in the process table.
* Insert this information in the reply message (also
* in the process table entry)
*/
return OK;
}
This needs explanation, but for the moment think of this as do_mygetpid is just building a reply message that will be sent back to the user process.