Author: tkreuzer
Date: Fri Jan 13 19:01:47 2012
New Revision: 54940
URL:
http://svn.reactos.org/svn/reactos?rev=54940&view=rev
Log:
[PSDK]
- add missing stubs to driverspecs.h
- Add concurrencysal.h
- add some missing definitions to sal.h and specstrings.h
Added:
trunk/reactos/include/psdk/concurrencysal.h (with props)
Modified:
trunk/reactos/include/psdk/driverspecs.h
trunk/reactos/include/psdk/sal.h
trunk/reactos/include/psdk/specstrings.h
Added: trunk/reactos/include/psdk/concurrencysal.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/concurrencysa…
==============================================================================
--- trunk/reactos/include/psdk/concurrencysal.h (added)
+++ trunk/reactos/include/psdk/concurrencysal.h [iso-8859-1] Fri Jan 13 19:01:47 2012
@@ -1,0 +1,32 @@
+/*
+ * concurrencysal.h
+ *
+ * Standard Annotation Language (SAL) definitions for synchronisation
+ *
+ * This file is part of the ReactOS PSDK package.
+ *
+ * Contributors:
+ * Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ *
+ * THIS SOFTWARE IS NOT COPYRIGHTED
+ *
+ * This source code is offered for use in the public domain. You may
+ * use, modify or distribute it freely.
+ *
+ * This code is distributed in the hope that it will be useful but
+ * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
+ * DISCLAIMED. This includes but is not limited to warranties of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ *
+ */
+
+
+
+#define _Requires_lock_held_(lock)
+#define _Requires_lock_not_held_(lock)
+#define _Acquires_lock_(lock)
+#define _Acquires_shared_lock_(lock)
+#define _Acquires_exclusive_lock_(lock)
+#define _Releases_lock_(lock)
+#define _Post_same_lock_(lock1,lock2)
+
Propchange: trunk/reactos/include/psdk/concurrencysal.h
------------------------------------------------------------------------------
svn:eol-style = native
Modified: trunk/reactos/include/psdk/driverspecs.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/driverspecs.h…
==============================================================================
--- trunk/reactos/include/psdk/driverspecs.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/driverspecs.h [iso-8859-1] Fri Jan 13 19:01:47 2012
@@ -6,24 +6,136 @@
* allow drivers using them to compile with our header set.
*/
+#pragma once
+#define DRIVERSPECS_H
+
+#ifndef SPECSTRINGS_H
+#include <specstrings.h>
+#endif
+
+#include <concurrencysal.h>
+
//
// Stubs
//
+#define ___drv_unit_internal_kernel_driver
+#define ___drv_unit_kernel_code
+#define ___drv_unit_kernel_driver
+#define ___drv_unit_user_code
+#define ___drv_unit_user_driver
+#define __drv_acquiresCancelSpinLock
+#define __drv_acquiresCriticalRegion
+#define __drv_acquiresExclusiveResource(kind)
+#define __drv_acquiresExclusiveResourceGlobal(kind,param)
+#define __drv_acquiresPriorityRegion
+#define __drv_acquiresResource(kind)
+#define __drv_acquiresResourceGlobal(kind,param)
+#define __drv_aliasesMem
+#define __drv_allocatesMem(kind)
+#define __drv_arg(expr,annotes)
+#define __drv_at(expr,annotes)
+#define __drv_callbackType(kind)
+#define __drv_clearDoInit
+#define __drv_completionType(kindlist)
+#define __drv_constant
+#define __drv_defined(x)
+#define __drv_deref(annotes)
+#define __drv_dispatchType_other
#define __drv_dispatchType(x)
-#define __drv_dispatchType_other
+#define __drv_floatRestored
+#define __drv_floatSaved
+#define __drv_floatUsed
+#define __drv_formatString(kind)
+#define __drv_freesMem(kind)
+#define __drv_fun(annotes)
+#define __drv_functionClass
+#define __drv_holdsCancelSpinLock()
+#define __drv_holdsCriticalRegion()
+#define __drv_holdsPriorityRegion()
+#define __drv_in_deref(annotes)
+#define __drv_in(annotes)
+#define __drv_innerAcquiresGlobal(kind,param)
+#define __drv_innerMustHoldGlobal(kind,param)
+#define __drv_innerNeverHoldGlobal(kind,param)
+#define __drv_innerReleasesGlobal(kind,param)
+#define __drv_interlocked
+#define __drv_IoGetDmaAdapter
+#define __drv_isCancelIRQL
+#define __drv_isObjectPointer
+#define __drv_KMDF
+#define __drv_maxFunctionIRQL
+#define __drv_maxIRQL
+#define __drv_minFunctionIRQL
+#define __drv_minIRQL
+#define __drv_Mode_impl(x)
+#define __drv_mustHold(kind)
+#define __drv_mustHoldCancelSpinLock
+#define __drv_mustHoldCriticalRegion
+#define __drv_mustHoldGlobal(kind,param)
+#define __drv_mustHoldPriorityRegion
+#define __drv_NDIS
+#define __drv_neverHold(kind)
+#define __drv_neverHoldCancelSpinLock
+#define __drv_neverHoldCriticalRegion
+#define __drv_neverHoldGlobal(kind,param)
+#define __drv_neverHoldPriorityRegion
+#define __drv_nonConstant
+#define __drv_notInTry
+#define __drv_notPointer
+#define __drv_out_deref(annotes)
+#define __drv_out(annotes)
+#define __drv_preferredFunction(func,why)
+#define __drv_raisesIRQL
+#define __drv_releasesCancelSpinLock
+#define __drv_releasesCriticalRegion
+#define __drv_releasesExclusiveResource(kind)
+#define __drv_releasesExclusiveResourceGlobal(kind,param)
+#define __drv_releasesPriorityRegion
+#define __drv_releasesResource(kind)
+#define __drv_releasesResourceGlobal(kind,param)
+#define __drv_reportError(why)
+#define __drv_requiresIRQL
+#define __drv_restoresIRQL
+#define __drv_restoresIRQLGlobal
+#define __drv_ret(annotes)
+#define __drv_sameIRQL
+#define __drv_savesIRQL
+#define __drv_savesIRQLGlobal
+#define __drv_setsIRQL(irql)
+#define __drv_strictType(typename,mode)
+#define __drv_strictTypeMatch(mode)
+#define __drv_unit(p)
+#define __drv_useCancelIRQL
+#define __drv_valueIs(arglist)
+#define __drv_WDM
+#define __drv_when(cond,annotes)
+#define __internal_kernel_driver
+#define __kernel_code
+#define __kernel_driver
+#define __prefast_operator_new_null
+#define __prefast_operator_new_throws
+#define __user_code
+#define __user_driver
+#define _Dispatch_type_
+#define _IRQL_always_function_max_(irql)
+#define _IRQL_always_function_min_(irql)
+#define _IRQL_is_cancel_
+#define _IRQL_raises_(irql)
+#define _IRQL_requires_(irql)
+#define _IRQL_requires_max_(irql)
+#define _IRQL_requires_min_(irql)
+#define _IRQL_requires_same_
+#define _IRQL_restores_
+#define _IRQL_restores_global_(kind,param)
+#define _IRQL_saves_
+#define _IRQL_saves_global_(kind,param)
+#define _IRQL_uses_cancel_
+#define _Kernel_clear_do_init_(yesNo)
+#define _Kernel_float_restored_
+#define _Kernel_float_saved_
+#define _Kernel_float_used_
+#define _Kernel_IoGetDmaAdapter_
+#define _Kernel_releases_resource_(kind)
+#define _Kernel_requires_resource_held_(kind)
+#define _Kernel_requires_resource_not_held_(kind)
-//
-// FIXME: These annotations are not driver-only and does not belong here
-//
-#define __in
-#define __in_bcount(Size)
-#define __in_ecount(Size)
-
-#define __out
-#define __out_bcount(Size)
-#define __out_bcount_part(Size, Length)
-#define __out_ecount(Size)
-
-#define __inout
-
-#define __deref_out_ecount(Size)
Modified: trunk/reactos/include/psdk/sal.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/sal.h?rev=549…
==============================================================================
--- trunk/reactos/include/psdk/sal.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/sal.h [iso-8859-1] Fri Jan 13 19:01:47 2012
@@ -391,6 +391,10 @@
#define _Struct_size_bytes_(size) _Writable_bytes_(size)
#define _Unchanged_(e) _At_(e, _Post_equal_to_(_Old_(e)) _Const_)
#define _Analysis_noreturn_ _SA_annotes0(SAL_terminates)
+#define _Function_class_(x) _SA_annotes1(SAL_functionClassNew, #x)
+#define _Raises_SEH_exception_ _Group_(_Pre_ _SA_annotes1(SAL_inTry,__yes)
_Analysis_noreturn_)
+#define _Maybe_raises_SEH_exception_ _Pre_ _SA_annotes1(SAL_inTry,__yes)
+#define _Interlocked_operand_ _Pre_ _SA_annotes0(SAL_interlocked)
#define _Field_size_(size) _Notnull_ _Writable_elements_(size)
#define _Field_size_bytes_(size) _Notnull_ _Writable_bytes_(size)
@@ -1185,6 +1189,7 @@
#define _Field_size_part_(size, count)
#define _Field_size_part_opt_(size, count)
#define _Field_z_
+#define _Function_class_(x)
#define _Group_(annos)
#define _In_
#define _In_bound_
@@ -1291,9 +1296,11 @@
#define _Inout_z_cap_x_(size)
#define _Inout_z_count_(size)
#define _Inout_z_count_c_(size)
+#define _Interlocked_operand_
#define _Literal_
#define _Maybenull_
#define _Maybevalid_
+#define _Maybe_raises_SEH_exception
#define _Must_inspect_result_
#define _Notliteral_
#define _Notnull_
@@ -1549,6 +1556,7 @@
#define _Prepost_valid_
#define _Prepost_z_
#define _Printf_format_string_
+#define _Raises_SEH_exception_
#define _Readable_bytes_(size)
#define _Readable_elements_(size)
#define _Reserved_
Modified: trunk/reactos/include/psdk/specstrings.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/specstrings.h…
==============================================================================
--- trunk/reactos/include/psdk/specstrings.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/specstrings.h [iso-8859-1] Fri Jan 13 19:01:47 2012
@@ -24,6 +24,7 @@
#define SPECSTRINGS_H
#include <sal.h>
+#include <driverspecs.h>
#define __field_bcount(size) __notnull __byte_writableTo(size)
#define __field_ecount(size) __notnull __elem_writableTo(size)
@@ -43,5 +44,7 @@
#define __out_awcount(expr,size)
#define __in_awcount(expr,size)
#define __nullnullterminated
-#define __analysis_assume(expr)
+#define __in_data_source(src_sym)
+#define __analysis_noreturn
+#define __kernel_entry