Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 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 __NOUVEAU_DRM_H__ |
| 20 | #define __NOUVEAU_DRM_H__ |
| 21 | #define NOUVEAU_GEM_DOMAIN_CPU (1 << 0) |
| 22 | #define NOUVEAU_GEM_DOMAIN_VRAM (1 << 1) |
| 23 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 24 | #define NOUVEAU_GEM_DOMAIN_GART (1 << 2) |
| 25 | #define NOUVEAU_GEM_DOMAIN_MAPPABLE (1 << 3) |
| 26 | #define NOUVEAU_GEM_TILE_COMP 0x00030000 |
| 27 | #define NOUVEAU_GEM_TILE_LAYOUT_MASK 0x0000ff00 |
| 28 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 29 | #define NOUVEAU_GEM_TILE_16BPP 0x00000001 |
| 30 | #define NOUVEAU_GEM_TILE_32BPP 0x00000002 |
| 31 | #define NOUVEAU_GEM_TILE_ZETA 0x00000004 |
| 32 | #define NOUVEAU_GEM_TILE_NONCONTIG 0x00000008 |
| 33 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 34 | struct drm_nouveau_gem_info { |
| 35 | uint32_t handle; |
| 36 | uint32_t domain; |
| 37 | uint64_t size; |
| 38 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 39 | uint64_t offset; |
| 40 | uint64_t map_handle; |
| 41 | uint32_t tile_mode; |
| 42 | uint32_t tile_flags; |
| 43 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 44 | }; |
| 45 | struct drm_nouveau_gem_new { |
| 46 | struct drm_nouveau_gem_info info; |
| 47 | uint32_t channel_hint; |
| 48 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 49 | uint32_t align; |
| 50 | }; |
| 51 | #define NOUVEAU_GEM_MAX_BUFFERS 1024 |
| 52 | struct drm_nouveau_gem_pushbuf_bo_presumed { |
| 53 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 54 | uint32_t valid; |
| 55 | uint32_t domain; |
| 56 | uint64_t offset; |
| 57 | }; |
| 58 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 59 | struct drm_nouveau_gem_pushbuf_bo { |
| 60 | uint64_t user_priv; |
| 61 | uint32_t handle; |
| 62 | uint32_t read_domains; |
| 63 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 64 | uint32_t write_domains; |
| 65 | uint32_t valid_domains; |
| 66 | struct drm_nouveau_gem_pushbuf_bo_presumed presumed; |
| 67 | }; |
| 68 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 69 | #define NOUVEAU_GEM_RELOC_LOW (1 << 0) |
| 70 | #define NOUVEAU_GEM_RELOC_HIGH (1 << 1) |
| 71 | #define NOUVEAU_GEM_RELOC_OR (1 << 2) |
| 72 | #define NOUVEAU_GEM_MAX_RELOCS 1024 |
| 73 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 74 | struct drm_nouveau_gem_pushbuf_reloc { |
| 75 | uint32_t reloc_bo_index; |
| 76 | uint32_t reloc_bo_offset; |
| 77 | uint32_t bo_index; |
| 78 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 79 | uint32_t flags; |
| 80 | uint32_t data; |
| 81 | uint32_t vor; |
| 82 | uint32_t tor; |
| 83 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 84 | }; |
| 85 | #define NOUVEAU_GEM_MAX_PUSH 512 |
| 86 | struct drm_nouveau_gem_pushbuf_push { |
| 87 | uint32_t bo_index; |
| 88 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 89 | uint32_t pad; |
| 90 | uint64_t offset; |
| 91 | uint64_t length; |
| 92 | }; |
| 93 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 94 | struct drm_nouveau_gem_pushbuf { |
| 95 | uint32_t channel; |
| 96 | uint32_t nr_buffers; |
| 97 | uint64_t buffers; |
| 98 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 99 | uint32_t nr_relocs; |
| 100 | uint32_t nr_push; |
| 101 | uint64_t relocs; |
| 102 | uint64_t push; |
| 103 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 104 | uint32_t suffix0; |
| 105 | uint32_t suffix1; |
| 106 | uint64_t vram_available; |
| 107 | uint64_t gart_available; |
| 108 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 109 | }; |
| 110 | #define NOUVEAU_GEM_CPU_PREP_NOWAIT 0x00000001 |
| 111 | #define NOUVEAU_GEM_CPU_PREP_WRITE 0x00000004 |
| 112 | struct drm_nouveau_gem_cpu_prep { |
| 113 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 114 | uint32_t handle; |
| 115 | uint32_t flags; |
| 116 | }; |
| 117 | struct drm_nouveau_gem_cpu_fini { |
| 118 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 119 | uint32_t handle; |
| 120 | }; |
| 121 | #define DRM_NOUVEAU_GETPARAM 0x00 |
| 122 | #define DRM_NOUVEAU_SETPARAM 0x01 |
| 123 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 124 | #define DRM_NOUVEAU_CHANNEL_ALLOC 0x02 |
| 125 | #define DRM_NOUVEAU_CHANNEL_FREE 0x03 |
| 126 | #define DRM_NOUVEAU_GROBJ_ALLOC 0x04 |
| 127 | #define DRM_NOUVEAU_NOTIFIEROBJ_ALLOC 0x05 |
| 128 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 129 | #define DRM_NOUVEAU_GPUOBJ_FREE 0x06 |
| 130 | #define DRM_NOUVEAU_GEM_NEW 0x40 |
| 131 | #define DRM_NOUVEAU_GEM_PUSHBUF 0x41 |
| 132 | #define DRM_NOUVEAU_GEM_CPU_PREP 0x42 |
| 133 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 134 | #define DRM_NOUVEAU_GEM_CPU_FINI 0x43 |
| 135 | #define DRM_NOUVEAU_GEM_INFO 0x44 |
| 136 | #define DRM_IOCTL_NOUVEAU_GEM_NEW DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_NEW, struct drm_nouveau_gem_new) |
| 137 | #define DRM_IOCTL_NOUVEAU_GEM_PUSHBUF DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_PUSHBUF, struct drm_nouveau_gem_pushbuf) |
| 138 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
| 139 | #define DRM_IOCTL_NOUVEAU_GEM_CPU_PREP DRM_IOW (DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_CPU_PREP, struct drm_nouveau_gem_cpu_prep) |
| 140 | #define DRM_IOCTL_NOUVEAU_GEM_CPU_FINI DRM_IOW (DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_CPU_FINI, struct drm_nouveau_gem_cpu_fini) |
| 141 | #define DRM_IOCTL_NOUVEAU_GEM_INFO DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_INFO, struct drm_nouveau_gem_info) |
| 142 | #endif |
| 143 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |