mirror of
https://github.com/drasko/codezero.git
synced 2026-01-25 17:23:14 +01:00
Changed name of utcb get function to match with general name conventions in syslib.h
This commit is contained in:
@@ -27,21 +27,20 @@ struct utcb {
|
||||
unsigned long usr_handle;
|
||||
};
|
||||
|
||||
/* FIXME: LICENSE/LICENCE */
|
||||
static inline struct utcb *__L4_ARM_Utcb()
|
||||
static inline struct utcb *l4_get_utcb()
|
||||
{
|
||||
return (struct utcb *)(*(struct utcb **)USER_UTCB_REF);
|
||||
return *(struct utcb **)USER_UTCB_REF;
|
||||
}
|
||||
|
||||
/* Functions to read/write utcb registers */
|
||||
static inline unsigned int read_mr(int offset)
|
||||
{
|
||||
return __L4_ARM_Utcb()->mr[offset];
|
||||
return l4_get_utcb()->mr[offset];
|
||||
}
|
||||
|
||||
static inline void write_mr(unsigned int offset, unsigned int val)
|
||||
{
|
||||
__L4_ARM_Utcb()->mr[offset] = val;
|
||||
l4_get_utcb()->mr[offset] = val;
|
||||
}
|
||||
#endif /* !__ASSEMBLY__ */
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ void init_utcb(void)
|
||||
void *utcb_page = alloc_page(1); /* Allocate a utcb page */
|
||||
|
||||
l4_getid(&ids);
|
||||
l4_map(utcb_page, __L4_ARM_Utcb(), 1, MAP_USR_RW_FLAGS, ids.tid);
|
||||
l4_map(utcb_page, l4_get_utcb(), 1, MAP_USR_RW_FLAGS, ids.tid);
|
||||
}
|
||||
|
||||
void init_mm(struct initdata *initdata)
|
||||
|
||||
@@ -146,7 +146,7 @@ int start_boot_tasks(struct initdata *initdata, struct tcb_head *tcbs)
|
||||
}
|
||||
|
||||
/* mmap each task's utcb as single page anonymous memory. */
|
||||
if ((err = do_mmap(0, 0, task, (unsigned long)__L4_ARM_Utcb(),
|
||||
if ((err = do_mmap(0, 0, task, (unsigned long)l4_get_utcb(),
|
||||
VM_READ | VM_WRITE | VMA_ANON, 1) < 0)) {
|
||||
printf("do_mmap: Mapping utcb failed with %d.\n", err);
|
||||
goto error;
|
||||
|
||||
Reference in New Issue
Block a user