Path: blob/21.2-virgl/include/winddk/winddk_compat.h
4547 views
/**************************************************************************1*2* Copyright 2009 VMware, Inc.3* All Rights Reserved.4*5* Permission is hereby granted, free of charge, to any person obtaining a6* copy of this software and associated documentation files (the7* "Software"), to deal in the Software without restriction, including8* without limitation the rights to use, copy, modify, merge, publish,9* distribute, sub license, and/or sell copies of the Software, and to10* permit persons to whom the Software is furnished to do so, subject to11* the following conditions:12*13* The above copyright notice and this permission notice (including the14* next paragraph) shall be included in all copies or substantial portions15* of the Software.16*17* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS18* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF19* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.20* IN NO EVENT SHALL VMWARE AND/OR ITS SUPPLIERS BE LIABLE FOR21* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,22* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE23* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.24*25**************************************************************************/2627/**28* @file29* SDK/DDK compatability.30*31* Different headers/defines on different Windows SDKs / DDKs, so define32* all used status here to keep the code portable.33*34* @author <[email protected]>35*/3637#ifndef VMW_WDDM_COMPAT_H_38#define VMW_WDDM_COMPAT_H_3940#ifndef __in41#define __in /**/42#endif4344#ifndef __out45#define __out /**/46#endif4748#ifndef __inout49#define __inout /**/50#endif5152#ifndef __in_opt53#define __in_opt /**/54#endif5556#ifndef __inout_opt57#define __inout_opt /**/58#endif5960#ifndef __ecount61#define __ecount(x) /**/62#endif6364#ifndef __in_ecount65#define __in_ecount(x) /**/66#endif6768#ifndef __deref_ecount69#define __deref_ecount(x) /**/70#endif7172#ifndef __in_bcount73#define __in_bcount(x) /**/74#endif7576#ifndef __out_bcount77#define __out_bcount(x) /**/78#endif7980#ifndef __out_ecount_opt81#define __out_ecount_opt(x) /**/82#endif8384#ifndef __deref_out85#define __deref_out /**/86#endif8788#ifndef __in_range89#define __in_range(x,y) /**/90#endif9192#ifndef __field_bcount93#define __field_bcount(x) /**/94#endif9596#ifndef __out_bcount97#define __out_bcount(x) /**/98#endif99100#ifndef __out_bcount_full_opt101#define __out_bcount_full_opt(x) /**/102#endif103104#ifndef __out_ecount_part_z_opt105#define __out_ecount_part_z_opt(x, y) /**/106#endif107108#ifndef __out_ecount_part_opt109#define __out_ecount_part_opt(x, y) /**/110#endif111112#ifndef __field_ecount113#define __field_ecount(x) /**/114#endif115116#ifndef __field_ecount_full117#define __field_ecount_full(x) /**/118#endif119120#ifndef __checkReturn121#define __checkReturn /**/122#endif123124#ifndef __drv_requiresIRQL125#define __drv_requiresIRQL(x) /**/126#endif127128#ifndef __drv_minIRQL129#define __drv_minIRQL(x) /**/130#endif131132#ifndef __drv_maxIRQL133#define __drv_maxIRQL(x) /**/134#endif135136#ifdef __MINGW32__137#define __inline static __inline__138#endif139140#ifndef EXTERN_C141#define EXTERN_C /**/142#endif143144#ifdef __MINGW32__145typedef unsigned char UINT8;146#endif147148149#ifndef NTSTATUS150#define NTSTATUS LONG151#endif152153typedef LARGE_INTEGER PHYSICAL_ADDRESS;154155#ifndef NT_SUCCESS156#define NT_SUCCESS(_status) ((_status) >= 0)157#endif158159#ifndef STATUS_SUCCESS160#define STATUS_SUCCESS ((NTSTATUS)0x00000000L)161#endif162163#ifndef STATUS_UNSUCCESSFUL164#define STATUS_UNSUCCESSFUL ((NTSTATUS)0xC0000001L)165#endif166167#ifndef STATUS_INVALID_PARAMETER168#define STATUS_INVALID_PARAMETER ((NTSTATUS)0xC000000DL)169#endif170171#ifndef STATUS_NO_MEMORY172#define STATUS_NO_MEMORY ((NTSTATUS)0xC0000017L)173#endif174175#ifndef STATUS_ILLEGAL_INSTRUCTION176#define STATUS_ILLEGAL_INSTRUCTION ((NTSTATUS)0xC000001DL)177#endif178179#ifndef STATUS_BUFFER_TOO_SMALL180#define STATUS_BUFFER_TOO_SMALL ((NTSTATUS)0xC0000023L)181#endif182183#ifndef STATUS_PRIVILEGED_INSTRUCTION184#define STATUS_PRIVILEGED_INSTRUCTION ((NTSTATUS)0xC0000096L)185#endif186187#ifndef STATUS_NOT_SUPPORTED188#define STATUS_NOT_SUPPORTED ((NTSTATUS)0xC00000BBL)189#endif190191#ifndef STATUS_DEVICE_REMOVED192#define STATUS_DEVICE_REMOVED ((NTSTATUS)0xC00002B6L)193#endif194195#ifndef STATUS_INVALID_USER_BUFFER196#define STATUS_INVALID_USER_BUFFER ((NTSTATUS)0xC00000E8L)197#endif198199#ifndef STATUS_GRAPHICS_NOT_EXCLUSIVE_MODE_OWNER200#define STATUS_GRAPHICS_NOT_EXCLUSIVE_MODE_OWNER ((NTSTATUS)0xC01E0000L)201#endif202203#ifndef STATUS_NO_VIDEO_MEMORY204#define STATUS_NO_VIDEO_MEMORY ((NTSTATUS)0xC01E0100L)205#endif206207#ifndef STATUS_GRAPHICS_ALLOCATION_BUSY208#define STATUS_GRAPHICS_ALLOCATION_BUSY ((NTSTATUS)0xC01E0102L)209#endif210211#ifndef STATUS_GRAPHICS_TOO_MANY_REFERENCES212#define STATUS_GRAPHICS_TOO_MANY_REFERENCES ((NTSTATUS)0xC01E0103L)213#endif214215#ifndef STATUS_GRAPHICS_ALLOCATION_INVALID216#define STATUS_GRAPHICS_ALLOCATION_INVALID ((NTSTATUS)0xC01E0106L)217#endif218219#ifndef STATUS_GRAPHICS_CANT_EVICT_PINNED_ALLOCATION220#define STATUS_GRAPHICS_CANT_EVICT_PINNED_ALLOCATION ((NTSTATUS)0xC01E0109L)221#endif222223#ifndef STATUS_GRAPHICS_CANT_RENDER_LOCKED_ALLOCATION224#define STATUS_GRAPHICS_CANT_RENDER_LOCKED_ALLOCATION ((NTSTATUS)0xC01E0111L)225#endif226227#ifndef STATUS_GRAPHICS_GPU_EXCEPTION_ON_DEVICE228#define STATUS_GRAPHICS_GPU_EXCEPTION_ON_DEVICE ((NTSTATUS)0xC01E0200L)229#endif230231#ifndef STATUS_GRAPHICS_NO_AVAILABLE_VIDPN_TARGET232#define STATUS_GRAPHICS_NO_AVAILABLE_VIDPN_TARGET ((NTSTATUS)0xC01E0333L)233#endif234235#endif /* VMW_WDDM_COMPAT_H_ */236237238