X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Kernel%2Finclude%2Facess.h;h=6373cec51b3717520e0ed74fce3fdb528238907c;hb=0b24cbc2f18942b3d1d74efa025ecfa318ab35ec;hp=707ad7f3a794a77ec08389ba10c078074aafe8bd;hpb=930fe819133ddb444bc6c22df09baf788183f6ad;p=tpg%2Facess2.git diff --git a/Kernel/include/acess.h b/Kernel/include/acess.h index 707ad7f3..6373cec5 100644 --- a/Kernel/include/acess.h +++ b/Kernel/include/acess.h @@ -39,7 +39,7 @@ typedef struct sShortSpinlock tShortSpinlock; */ /** - * \name Per-Process Configuration Settings + * \name Per-Thread Configuration Settings * \{ */ enum eConfigTypes { @@ -52,10 +52,13 @@ enum eConfigs { CFG_VFS_CWD, CFG_VFS_MAXFILES, CFG_VFS_CHROOT, + CFG_ERRNO, NUM_CFG_ENTRIES }; #define CFGINT(id) (*Threads_GetCfgPtr(id)) #define CFGPTR(id) (*(void**)Threads_GetCfgPtr(id)) + +#define errno (CFGINT(CFG_ERRNO)) /** * \} */ @@ -277,25 +280,23 @@ extern void MM_DerefPhys(tPAddr PAddr); */ extern int MM_GetRefCount(tPAddr PAddr); /** - * \brief Set the node/offset associated with a page + * \brief Set the node associated with a page * \param PAddr Physical address of page * \param Node Node pointer (tVFS_Node) - * \param Offset File offset * \return Boolean failure * \retval 0 Success * \retval 1 Page not allocated */ -extern int MM_SetPageInfo(tPAddr PAddr, void *Node, Uint64 Offset); +extern int MM_SetPageNode(tPAddr PAddr, void *Node); /** - * \brief Get the node/offset associated with a page + * \brief Get the node associated with a page * \param PAddr Physical address of page * \param Node Node pointer (tVFS_Node) destination - * \param Offset File offset destination (pointer) * \return Boolean failure * \retval 0 Success * \retval 1 Page not allocated */ -extern int MM_GetPageInfo(tPAddr PAddr, void **Node, Uint64 *Offset); +extern int MM_GetPageNode(tPAddr PAddr, void **Node); /** * \} */ @@ -438,7 +439,7 @@ extern void Time_Delay(int Delay); * \{ */ extern int Proc_SpawnWorker(void); -extern int Proc_Spawn(char *Path); +extern int Proc_Spawn(const char *Path); extern void Threads_Exit(int TID, int Status); extern void Threads_Yield(void); extern void Threads_Sleep(void); @@ -459,7 +460,6 @@ extern int DivUp(int num, int dem); #include #include -#include #include #endif