https://git.reactos.org/?p=reactos.git;a=commitdiff;h=0944f808f8f2ef179f562…
commit 0944f808f8f2ef179f5627c10908e30a812ee5cd
Author: Bryan Kirk <Zero3K(a)teknik.io>
AuthorDate: Sun Jan 23 08:57:08 2022 -0500
Commit: Victor Perevertkin <victor.perevertkin(a)reactos.org>
CommitDate: Wed Feb 16 01:31:28 2022 +0300
[DDK] Hack the IDmaChannel::PhysicalAddress ABI
---
sdk/include/ddk/portcls.h | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/sdk/include/ddk/portcls.h b/sdk/include/ddk/portcls.h
index 4a2342fe038..cb6c5939de4 100644
--- a/sdk/include/ddk/portcls.h
+++ b/sdk/include/ddk/portcls.h
@@ -704,6 +704,16 @@ typedef IUnregisterPhysicalConnection
*PUNREGISTERPHYSICALCONNECTION;
IDmaChannel Interface
*/
+/* C++ ABI HACK: IDmaChannel::PhysicalAddress */
+#if defined(__cplusplus) && !defined(_MSC_VER)
+#define DEFINE_ABSTRACT_DMACHANNEL_PhysicalAddress \
+ STDMETHOD_(PHYSICAL_ADDRESS*, PhysicalAddress)( THIS_ PHYSICAL_ADDRESS* pRet ) PURE;
\
+ PHYSICAL_ADDRESS PhysicalAddress() { PHYSICAL_ADDRESS tmp; PhysicalAddress(&tmp);
return tmp; }
+#else
+#define DEFINE_ABSTRACT_DMACHANNEL_PhysicalAddress \
+ STDMETHOD_(PHYSICAL_ADDRESS, PhysicalAddress)( THIS ) PURE
+#endif
+
#define DEFINE_ABSTRACT_DMACHANNEL() \
STDMETHOD_(NTSTATUS, AllocateBuffer)( THIS_ \
IN ULONG BufferSize, \