File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -33,3 +33,20 @@ Header Name:
3333#error Invalid compiler!
3434
3535#endif
36+
37+ /*
38+ * This attribute should be applied to a function that
39+ * called from pageable code and raises the IRQL at DISPATCH_LEVEL or higher,
40+ * and restores the IRQL before it returns. We must make sure that function is not inlined.
41+ */
42+ #define DECLSPEC_NOINLINE_FROM_PAGED DECLSPEC_NOINLINE
43+
44+ /*
45+ * This attribute should be applied to a function that
46+ * called from non-pageable code at IRQL lower than DISPATCH_LEVEL.
47+ * We should make sure that function is not inlined. Some compilers (GCC)
48+ * can do inlining even if the function is in another section.
49+ * See the discussion https://gcc.gnu.org/bugzilla/show_bug.cgi?id=31362
50+ * for more details.
51+ */
52+ #define DECLSPEC_NOINLINE_FROM_NOT_PAGED DECLSPEC_NOINLINE
You can’t perform that action at this time.
0 commit comments