prctl: add PR_CAP_AMBIENT parser
* xlat/pr_cap_ambient.in: New file. * prctl.c: Include "xlat/pr_cap_ambient.h". (SYS_FUNC(prctl)): Handle PR_CAP_AMBIENT.
This commit is contained in:
parent
1b283307d1
commit
eb76c4be15
20
prctl.c
20
prctl.c
@ -3,11 +3,12 @@
|
|||||||
#include <sys/prctl.h>
|
#include <sys/prctl.h>
|
||||||
|
|
||||||
#include "xlat/prctl_options.h"
|
#include "xlat/prctl_options.h"
|
||||||
#include "xlat/pr_unalign_flags.h"
|
#include "xlat/pr_cap_ambient.h"
|
||||||
#include "xlat/pr_mce_kill.h"
|
#include "xlat/pr_mce_kill.h"
|
||||||
#include "xlat/pr_mce_kill_policy.h"
|
#include "xlat/pr_mce_kill_policy.h"
|
||||||
#include "xlat/pr_set_mm.h"
|
#include "xlat/pr_set_mm.h"
|
||||||
#include "xlat/pr_tsc.h"
|
#include "xlat/pr_tsc.h"
|
||||||
|
#include "xlat/pr_unalign_flags.h"
|
||||||
|
|
||||||
#ifndef TASK_COMM_LEN
|
#ifndef TASK_COMM_LEN
|
||||||
# define TASK_COMM_LEN 16
|
# define TASK_COMM_LEN 16
|
||||||
@ -142,6 +143,23 @@ SYS_FUNC(prctl)
|
|||||||
printxval(cap, tcp->u_arg[1], "CAP_???");
|
printxval(cap, tcp->u_arg[1], "CAP_???");
|
||||||
return RVAL_DECODED;
|
return RVAL_DECODED;
|
||||||
|
|
||||||
|
case PR_CAP_AMBIENT:
|
||||||
|
tprints(", ");
|
||||||
|
printxval(pr_cap_ambient, tcp->u_arg[1], "PR_CAP_AMBIENT_???");
|
||||||
|
switch (tcp->u_arg[1]) {
|
||||||
|
case PR_CAP_AMBIENT_RAISE:
|
||||||
|
case PR_CAP_AMBIENT_LOWER:
|
||||||
|
case PR_CAP_AMBIENT_IS_SET:
|
||||||
|
tprints(", ");
|
||||||
|
printxval(cap, tcp->u_arg[2], "CAP_???");
|
||||||
|
print_prctl_args(tcp, 3);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
print_prctl_args(tcp, 2);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return RVAL_DECODED;
|
||||||
|
|
||||||
case PR_MCE_KILL:
|
case PR_MCE_KILL:
|
||||||
tprints(", ");
|
tprints(", ");
|
||||||
printxval(pr_mce_kill, tcp->u_arg[1], "PR_MCE_KILL_???");
|
printxval(pr_mce_kill, tcp->u_arg[1], "PR_MCE_KILL_???");
|
||||||
|
4
xlat/pr_cap_ambient.in
Normal file
4
xlat/pr_cap_ambient.in
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
PR_CAP_AMBIENT_IS_SET 1
|
||||||
|
PR_CAP_AMBIENT_RAISE 2
|
||||||
|
PR_CAP_AMBIENT_LOWER 3
|
||||||
|
PR_CAP_AMBIENT_CLEAR_ALL 4
|
Loading…
Reference in New Issue
Block a user