• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /****************************************************************************
2  ****************************************************************************
3  ***
4  ***   This header was automatically generated from a Linux kernel header
5  ***   of the same name, to make information necessary for userspace to
6  ***   call into the kernel available to libc.  It contains only constants,
7  ***   structures, and macros generated from the original header, and thus,
8  ***   contains no copyrightable information.
9  ***
10  ***   To edit the content of this header, modify the corresponding
11  ***   source file (e.g. under external/kernel-headers/original/) then
12  ***   run bionic/libc/kernel/tools/update_all.py
13  ***
14  ***   Any manual change here will be lost the next time this script will
15  ***   be run. You've been warned!
16  ***
17  ****************************************************************************
18  ****************************************************************************/
19 #ifndef _UAPI_AGP_H
20 #define _UAPI_AGP_H
21 #define AGPIOC_BASE 'A'
22 #define AGPIOC_INFO _IOR(AGPIOC_BASE, 0, struct agp_info *)
23 #define AGPIOC_ACQUIRE _IO(AGPIOC_BASE, 1)
24 #define AGPIOC_RELEASE _IO(AGPIOC_BASE, 2)
25 #define AGPIOC_SETUP _IOW(AGPIOC_BASE, 3, struct agp_setup *)
26 #define AGPIOC_RESERVE _IOW(AGPIOC_BASE, 4, struct agp_region *)
27 #define AGPIOC_PROTECT _IOW(AGPIOC_BASE, 5, struct agp_region *)
28 #define AGPIOC_ALLOCATE _IOWR(AGPIOC_BASE, 6, struct agp_allocate *)
29 #define AGPIOC_DEALLOCATE _IOW(AGPIOC_BASE, 7, int)
30 #define AGPIOC_BIND _IOW(AGPIOC_BASE, 8, struct agp_bind *)
31 #define AGPIOC_UNBIND _IOW(AGPIOC_BASE, 9, struct agp_unbind *)
32 #define AGPIOC_CHIPSET_FLUSH _IO(AGPIOC_BASE, 10)
33 #define AGP_DEVICE "/dev/agpgart"
34 #ifndef TRUE
35 #define TRUE 1
36 #endif
37 #ifndef FALSE
38 #define FALSE 0
39 #endif
40 #include <linux/types.h>
41 struct agp_version {
42   __u16 major;
43   __u16 minor;
44 };
45 typedef struct _agp_info {
46   struct agp_version version;
47   __u32 bridge_id;
48   __u32 agp_mode;
49   unsigned long aper_base;
50   __kernel_size_t aper_size;
51   __kernel_size_t pg_total;
52   __kernel_size_t pg_system;
53   __kernel_size_t pg_used;
54 } agp_info;
55 typedef struct _agp_setup {
56   __u32 agp_mode;
57 } agp_setup;
58 typedef struct _agp_segment {
59   __kernel_off_t pg_start;
60   __kernel_size_t pg_count;
61   int prot;
62 } agp_segment;
63 typedef struct _agp_region {
64   __kernel_pid_t pid;
65   __kernel_size_t seg_count;
66   struct _agp_segment * seg_list;
67 } agp_region;
68 typedef struct _agp_allocate {
69   int key;
70   __kernel_size_t pg_count;
71   __u32 type;
72   __u32 physical;
73 } agp_allocate;
74 typedef struct _agp_bind {
75   int key;
76   __kernel_off_t pg_start;
77 } agp_bind;
78 typedef struct _agp_unbind {
79   int key;
80   __u32 priority;
81 } agp_unbind;
82 #endif
83