Subversion Repositories HelenOS-historic

Rev

Rev 1653 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1653 Rev 1719
Line 24... Line 24...
24
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
25
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
 */
27
 */
28
 
28
 
29
 /** @addtogroup libc
29
/** @addtogroup libc
30
 * @{
30
 * @{
31
 */
31
 */
32
/**
32
/**
33
 * @file    cap.c
33
 * @file    cap.c
34
 * @brief   Functions to grant/revoke capabilities to/from a task.
34
 * @brief   Functions to grant/revoke capabilities to/from a task.
Line 50... Line 50...
50
{
50
{
51
    sysarg64_t arg;
51
    sysarg64_t arg;
52
   
52
   
53
    arg.value = (unsigned long long) id;
53
    arg.value = (unsigned long long) id;
54
 
54
 
55
    __SYSCALL2(SYS_CAP_GRANT, (sysarg_t) &arg, (sysarg_t) caps);
55
    return __SYSCALL2(SYS_CAP_GRANT, (sysarg_t) &arg, (sysarg_t) caps);
56
}
56
}
57
 
57
 
58
/** Revoke capabilities from a task.
58
/** Revoke capabilities from a task.
59
 *
59
 *
60
 * @param id Destination task ID.
60
 * @param id Destination task ID.
Line 66... Line 66...
66
{
66
{
67
    sysarg64_t arg;
67
    sysarg64_t arg;
68
   
68
   
69
    arg.value = (unsigned long long) id;
69
    arg.value = (unsigned long long) id;
70
 
70
 
71
    __SYSCALL2(SYS_CAP_REVOKE, (sysarg_t) &arg, (sysarg_t) caps);
71
    return __SYSCALL2(SYS_CAP_REVOKE, (sysarg_t) &arg, (sysarg_t) caps);
72
}
72
}
73
 
73
 
74
 
74
 
75
 /** @}
75
/** @}
76
 */
76
 */
77
 
-
 
78
 
-