root/include/linux/personality.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 #ifndef _PERSONALITY_H
   2 #define _PERSONALITY_H
   3 
   4 #include <linux/linkage.h>
   5 #include <linux/ptrace.h>
   6 
   7 
   8 /* Flags for bug emulation. These occupy the top three bytes. */
   9 #define STICKY_TIMEOUTS         0x4000000
  10 #define WHOLE_SECONDS           0x2000000
  11 
  12 /* Personality types. These go in the low byte. Avoid using the top bit,
  13  * it will conflict with error returns.
  14  */
  15 #define PER_MASK                (0x00ff)
  16 #define PER_LINUX               (0x0000)
  17 #define PER_SVR4                (0x0001 | STICKY_TIMEOUTS)
  18 #define PER_SVR3                (0x0002 | STICKY_TIMEOUTS)
  19 #define PER_SCOSVR3             (0x0003 | STICKY_TIMEOUTS | WHOLE_SECONDS)
  20 #define PER_WYSEV386            (0x0004 | STICKY_TIMEOUTS)
  21 #define PER_ISCR4               (0x0005 | STICKY_TIMEOUTS)
  22 #define PER_BSD                 (0x0006)
  23 #define PER_XENIX               (0x0007 | STICKY_TIMEOUTS)
  24 
  25 /* Prototype for an lcall7 syscall handler. */
  26 typedef asmlinkage void (*lcall7_func)(struct pt_regs *);
  27 
  28 
  29 /* Description of an execution domain - personality range supported,
  30  * lcall7 syscall handler, start up / shut down functions etc.
  31  * N.B. The name and lcall7 handler must be where they are since the
  32  * offset of the handler is hard coded in kernel/sys_call.S.
  33  */
  34 struct exec_domain {
  35         const char *name;
  36         lcall7_func handler;
  37         unsigned char pers_low, pers_high;
  38         unsigned long * signal_map;
  39         unsigned long * signal_invmap;
  40         int *use_count;
  41         struct exec_domain *next;
  42 };
  43 
  44 extern struct exec_domain default_exec_domain;
  45 
  46 extern struct exec_domain *lookup_exec_domain(unsigned long personality);
  47 extern int register_exec_domain(struct exec_domain *it);
  48 extern int unregister_exec_domain(struct exec_domain *it);
  49 extern asmlinkage int sys_personality(unsigned long personality);
  50 
  51 #endif /* _PERSONALITY_H */

/* [previous][next][first][last][top][bottom][index][help] */