blob: 10c0c4789f8fb8d1aa8a09a9189d4b992e2d2169 [file] [log] [blame]
Ben Cheng655a7c02013-10-16 16:09:24 -07001/****************************************************************************
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 __LINUX_PUBLIC_PRIVCMD_H__
20#define __LINUX_PUBLIC_PRIVCMD_H__
21#include <linux/types.h>
22#include <linux/compiler.h>
23/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24#include <xen/interface/xen.h>
25struct privcmd_hypercall {
Tao Baod7db5942015-01-28 10:07:51 -080026 __u64 op;
27 __u64 arg[5];
Ben Cheng655a7c02013-10-16 16:09:24 -070028/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
29};
30struct privcmd_mmap_entry {
Tao Baod7db5942015-01-28 10:07:51 -080031 __u64 va;
32 __u64 mfn;
Ben Cheng655a7c02013-10-16 16:09:24 -070033/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080034 __u64 npages;
Ben Cheng655a7c02013-10-16 16:09:24 -070035};
36struct privcmd_mmap {
Tao Baod7db5942015-01-28 10:07:51 -080037 int num;
Ben Cheng655a7c02013-10-16 16:09:24 -070038/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080039 domid_t dom;
40 struct privcmd_mmap_entry __user * entry;
Ben Cheng655a7c02013-10-16 16:09:24 -070041};
42struct privcmd_mmapbatch {
43/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080044 int num;
45 domid_t dom;
46 __u64 addr;
47 xen_pfn_t __user * arr;
Ben Cheng655a7c02013-10-16 16:09:24 -070048/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49};
50#define PRIVCMD_MMAPBATCH_MFN_ERROR 0xf0000000U
51#define PRIVCMD_MMAPBATCH_PAGED_ERROR 0x80000000U
52struct privcmd_mmapbatch_v2 {
53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080054 unsigned int num;
55 domid_t dom;
56 __u64 addr;
57 const xen_pfn_t __user * arr;
Ben Cheng655a7c02013-10-16 16:09:24 -070058/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080059 int __user * err;
Ben Cheng655a7c02013-10-16 16:09:24 -070060};
Tao Baod7db5942015-01-28 10:07:51 -080061#define IOCTL_PRIVCMD_HYPERCALL _IOC(_IOC_NONE, 'P', 0, sizeof(struct privcmd_hypercall))
62#define IOCTL_PRIVCMD_MMAP _IOC(_IOC_NONE, 'P', 2, sizeof(struct privcmd_mmap))
Ben Cheng655a7c02013-10-16 16:09:24 -070063/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080064#define IOCTL_PRIVCMD_MMAPBATCH _IOC(_IOC_NONE, 'P', 3, sizeof(struct privcmd_mmapbatch))
65#define IOCTL_PRIVCMD_MMAPBATCH_V2 _IOC(_IOC_NONE, 'P', 4, sizeof(struct privcmd_mmapbatch_v2))
Ben Cheng655a7c02013-10-16 16:09:24 -070066#endif