18ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/****************************************************************************
28ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ****************************************************************************
38ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***
48ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   This header was automatically generated from a Linux kernel header
58ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   of the same name, to make information necessary for userspace to
68ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   call into the kernel available to libc.  It contains only constants,
78ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   structures, and macros generated from the original header, and thus,
88ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   contains no copyrightable information.
98ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***
108ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   To edit the content of this header, modify the corresponding
118ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   source file (e.g. under external/kernel-headers/original/) then
128ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   run bionic/libc/kernel/tools/update_all.py
138ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***
148ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   Any manual change here will be lost the next time this script will
158ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***   be run. You've been warned!
168ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ***
178ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ****************************************************************************
188ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ****************************************************************************/
198ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#ifndef _LINUX_ION_H
208ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define _LINUX_ION_H
218ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#include <linux/types.h>
228ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandstruct ion_handle;
238ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
248ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandtypedef struct ion_handle *ion_user_handle_t;
258ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandenum ion_heap_type {
268ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ION_HEAP_TYPE_SYSTEM,
278ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ION_HEAP_TYPE_SYSTEM_CONTIG,
288ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
298ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ION_HEAP_TYPE_CARVEOUT,
308ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ION_HEAP_TYPE_CUSTOM,
318ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ION_NUM_HEAPS = 16,
328ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand};
338ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
348ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_HEAP_SYSTEM_MASK (1 << ION_HEAP_TYPE_SYSTEM)
358ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_HEAP_SYSTEM_CONTIG_MASK (1 << ION_HEAP_TYPE_SYSTEM_CONTIG)
368ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_HEAP_CARVEOUT_MASK (1 << ION_HEAP_TYPE_CARVEOUT)
378ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_FLAG_CACHED 1
388ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
398ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_FLAG_CACHED_NEEDS_SYNC 2
408ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandstruct ion_allocation_data {
418ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand size_t len;
428ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand size_t align;
438ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
448ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand unsigned int heap_id_mask;
458ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand unsigned int flags;
468ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ion_user_handle_t handle;
478ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand};
488ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
498ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandstruct ion_fd_data {
508ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ion_user_handle_t handle;
518ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand int fd;
528ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand};
538ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
548ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandstruct ion_handle_data {
558ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand ion_user_handle_t handle;
568ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand};
578ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchandstruct ion_custom_data {
588ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
598ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand unsigned int cmd;
608ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand unsigned long arg;
618ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand};
628ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_MAGIC 'I'
638ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
648ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_ALLOC _IOWR(ION_IOC_MAGIC, 0,   struct ion_allocation_data)
658ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_FREE _IOWR(ION_IOC_MAGIC, 1, struct ion_handle_data)
668ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_MAP _IOWR(ION_IOC_MAGIC, 2, struct ion_fd_data)
678ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_SHARE _IOWR(ION_IOC_MAGIC, 4, struct ion_fd_data)
688ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
698ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_IMPORT _IOWR(ION_IOC_MAGIC, 5, struct ion_fd_data)
708ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_SYNC _IOWR(ION_IOC_MAGIC, 7, struct ion_fd_data)
718ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#define ION_IOC_CUSTOM _IOWR(ION_IOC_MAGIC, 6, struct ion_custom_data)
728ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand#endif
738ff5c0057cbdecfa09410c1710ba043e191a2862Rom Lemarchand/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74