162306a36Sopenharmony_ci/* 262306a36Sopenharmony_ci * Copyright 2016 Intel Corporation 362306a36Sopenharmony_ci * All Rights Reserved. 462306a36Sopenharmony_ci * 562306a36Sopenharmony_ci * Permission is hereby granted, free of charge, to any person obtaining a 662306a36Sopenharmony_ci * copy of this software and associated documentation files (the 762306a36Sopenharmony_ci * "Software"), to deal in the Software without restriction, including 862306a36Sopenharmony_ci * without limitation the rights to use, copy, modify, merge, publish, 962306a36Sopenharmony_ci * distribute, sub license, and/or sell copies of the Software, and to 1062306a36Sopenharmony_ci * permit persons to whom the Software is furnished to do so, subject to 1162306a36Sopenharmony_ci * the following conditions: 1262306a36Sopenharmony_ci * 1362306a36Sopenharmony_ci * The above copyright notice and this permission notice (including the 1462306a36Sopenharmony_ci * next paragraph) shall be included in all copies or substantial portions 1562306a36Sopenharmony_ci * of the Software. 1662306a36Sopenharmony_ci * 1762306a36Sopenharmony_ci * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 1862306a36Sopenharmony_ci * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 1962306a36Sopenharmony_ci * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. 2062306a36Sopenharmony_ci * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR 2162306a36Sopenharmony_ci * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 2262306a36Sopenharmony_ci * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 2362306a36Sopenharmony_ci * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 2462306a36Sopenharmony_ci * 2562306a36Sopenharmony_ci */ 2662306a36Sopenharmony_ci 2762306a36Sopenharmony_ci#ifndef _UAPI_VGEM_DRM_H_ 2862306a36Sopenharmony_ci#define _UAPI_VGEM_DRM_H_ 2962306a36Sopenharmony_ci 3062306a36Sopenharmony_ci#include "drm.h" 3162306a36Sopenharmony_ci 3262306a36Sopenharmony_ci#if defined(__cplusplus) 3362306a36Sopenharmony_ciextern "C" { 3462306a36Sopenharmony_ci#endif 3562306a36Sopenharmony_ci 3662306a36Sopenharmony_ci/* Please note that modifications to all structs defined here are 3762306a36Sopenharmony_ci * subject to backwards-compatibility constraints. 3862306a36Sopenharmony_ci */ 3962306a36Sopenharmony_ci#define DRM_VGEM_FENCE_ATTACH 0x1 4062306a36Sopenharmony_ci#define DRM_VGEM_FENCE_SIGNAL 0x2 4162306a36Sopenharmony_ci 4262306a36Sopenharmony_ci#define DRM_IOCTL_VGEM_FENCE_ATTACH DRM_IOWR( DRM_COMMAND_BASE + DRM_VGEM_FENCE_ATTACH, struct drm_vgem_fence_attach) 4362306a36Sopenharmony_ci#define DRM_IOCTL_VGEM_FENCE_SIGNAL DRM_IOW( DRM_COMMAND_BASE + DRM_VGEM_FENCE_SIGNAL, struct drm_vgem_fence_signal) 4462306a36Sopenharmony_ci 4562306a36Sopenharmony_cistruct drm_vgem_fence_attach { 4662306a36Sopenharmony_ci __u32 handle; 4762306a36Sopenharmony_ci __u32 flags; 4862306a36Sopenharmony_ci#define VGEM_FENCE_WRITE 0x1 4962306a36Sopenharmony_ci __u32 out_fence; 5062306a36Sopenharmony_ci __u32 pad; 5162306a36Sopenharmony_ci}; 5262306a36Sopenharmony_ci 5362306a36Sopenharmony_cistruct drm_vgem_fence_signal { 5462306a36Sopenharmony_ci __u32 fence; 5562306a36Sopenharmony_ci __u32 flags; 5662306a36Sopenharmony_ci}; 5762306a36Sopenharmony_ci 5862306a36Sopenharmony_ci#if defined(__cplusplus) 5962306a36Sopenharmony_ci} 6062306a36Sopenharmony_ci#endif 6162306a36Sopenharmony_ci 6262306a36Sopenharmony_ci#endif /* _UAPI_VGEM_DRM_H_ */ 63