mirror of
https://github.com/drasko/codezero.git
synced 2026-01-12 02:43:15 +01:00
Clean up to kernel code, Added `used' field to capabilities
With the addition of used field, capability structure can be used for resource accounting over the capability.
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
#include INC_API(syscall.h)
|
||||
|
||||
|
||||
int task_read_capabilities(void *userbuf)
|
||||
int read_task_capabilities(void *userbuf)
|
||||
{
|
||||
int copy_size, copy_offset = 0;
|
||||
struct capability *cap;
|
||||
@@ -69,7 +69,7 @@ int sys_capability_control(unsigned int req, unsigned int flags, void *userbuf)
|
||||
|
||||
/* Return all capabilities as an array of capabilities */
|
||||
case CAP_CONTROL_READ_CAPS:
|
||||
err = task_read_capabilities(userbuf);
|
||||
err = read_task_capabilities(userbuf);
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
@@ -9,13 +9,6 @@
|
||||
#include <l4/api/errno.h>
|
||||
#include <l4/api/space.h>
|
||||
|
||||
/* NOTE:
|
||||
* For lazy mm switching, a list of newly created mappings that are common to
|
||||
* all tasks (e.g. any mapping done in the kernel) can be kept here so that when
|
||||
* a new task is scheduled, the same mappings are copied to its page tables as
|
||||
* well. struct link new_mappings;
|
||||
*/
|
||||
|
||||
int sys_map(unsigned long phys, unsigned long virt, unsigned long npages,
|
||||
unsigned long flags, unsigned int tid)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user