dbgeng: Add IDebugDataSpaces stub.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
9b1b48c514
commit
a47bb5dc83
|
@ -37,6 +37,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(dbgeng);
|
|||
struct debug_client
|
||||
{
|
||||
IDebugClient IDebugClient_iface;
|
||||
IDebugDataSpaces IDebugDataSpaces_iface;
|
||||
LONG refcount;
|
||||
};
|
||||
|
||||
|
@ -45,21 +46,35 @@ static struct debug_client *impl_from_IDebugClient(IDebugClient *iface)
|
|||
return CONTAINING_RECORD(iface, struct debug_client, IDebugClient_iface);
|
||||
}
|
||||
|
||||
static struct debug_client *impl_from_IDebugDataSpaces(IDebugDataSpaces *iface)
|
||||
{
|
||||
return CONTAINING_RECORD(iface, struct debug_client, IDebugDataSpaces_iface);
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugclient_QueryInterface(IDebugClient *iface, REFIID riid, void **obj)
|
||||
{
|
||||
struct debug_client *debug_client = impl_from_IDebugClient(iface);
|
||||
|
||||
TRACE("%p, %s, %p.\n", iface, debugstr_guid(riid), obj);
|
||||
|
||||
if (IsEqualIID(riid, &IID_IDebugClient) ||
|
||||
IsEqualIID(riid, &IID_IUnknown))
|
||||
{
|
||||
*obj = iface;
|
||||
iface->lpVtbl->AddRef(iface);
|
||||
return S_OK;
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IDebugDataSpaces))
|
||||
{
|
||||
*obj = &debug_client->IDebugDataSpaces_iface;
|
||||
}
|
||||
else
|
||||
{
|
||||
WARN("Unsupported interface %s.\n", debugstr_guid(riid));
|
||||
*obj = NULL;
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
WARN("Unsupported interface %s.\n", debugstr_guid(riid));
|
||||
*obj = NULL;
|
||||
return E_NOINTERFACE;
|
||||
IUnknown_AddRef((IUnknown *)*obj);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static ULONG STDMETHODCALLTYPE debugclient_AddRef(IDebugClient *iface)
|
||||
|
@ -467,6 +482,216 @@ static const IDebugClientVtbl debugclientvtbl =
|
|||
debugclient_FlushCallbacks,
|
||||
};
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_QueryInterface(IDebugDataSpaces *iface, REFIID riid, void **obj)
|
||||
{
|
||||
struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface);
|
||||
IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface;
|
||||
return IUnknown_QueryInterface(unk, riid, obj);
|
||||
}
|
||||
|
||||
static ULONG STDMETHODCALLTYPE debugdataspaces_AddRef(IDebugDataSpaces *iface)
|
||||
{
|
||||
struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface);
|
||||
IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface;
|
||||
return IUnknown_AddRef(unk);
|
||||
}
|
||||
|
||||
static ULONG STDMETHODCALLTYPE debugdataspaces_Release(IDebugDataSpaces *iface)
|
||||
{
|
||||
struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface);
|
||||
IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface;
|
||||
return IUnknown_Release(unk);
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadVirtual(IDebugDataSpaces *iface, ULONG64 offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *read_len)
|
||||
{
|
||||
FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteVirtual(IDebugDataSpaces *iface, ULONG64 offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *written)
|
||||
{
|
||||
FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, written);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_SearchVirtual(IDebugDataSpaces *iface, ULONG64 offset, ULONG64 length,
|
||||
void *pattern, ULONG pattern_size, ULONG pattern_granularity, ULONG64 *ret_offset)
|
||||
{
|
||||
FIXME("%p, %s, %s, %p, %u, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), wine_dbgstr_longlong(length),
|
||||
pattern, pattern_size, pattern_granularity, ret_offset);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadVirtualUncached(IDebugDataSpaces *iface, ULONG64 offset,
|
||||
void *buffer, ULONG buffer_size, ULONG *read_len)
|
||||
{
|
||||
FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteVirtualUncached(IDebugDataSpaces *iface, ULONG64 offset,
|
||||
void *buffer, ULONG buffer_size, ULONG *written)
|
||||
{
|
||||
FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, written);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadPointersVirtual(IDebugDataSpaces *iface, ULONG count,
|
||||
ULONG64 offset, ULONG64 *pointers)
|
||||
{
|
||||
FIXME("%p, %u, %s, %p stub.\n", iface, count, wine_dbgstr_longlong(offset), pointers);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WritePointersVirtual(IDebugDataSpaces *iface, ULONG count,
|
||||
ULONG64 offset, ULONG64 *pointers)
|
||||
{
|
||||
FIXME("%p, %u, %s, %p stub.\n", iface, count, wine_dbgstr_longlong(offset), pointers);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadPhysical(IDebugDataSpaces *iface, ULONG64 offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *read_len)
|
||||
{
|
||||
FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WritePhysical(IDebugDataSpaces *iface, ULONG64 offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *written)
|
||||
{
|
||||
FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, written);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadControl(IDebugDataSpaces *iface, ULONG processor, ULONG64 offset,
|
||||
void *buffer, ULONG buffer_size, ULONG *read_len)
|
||||
{
|
||||
FIXME("%p, %u, %s, %p, %u, %p stub.\n", iface, processor, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteControl(IDebugDataSpaces *iface, ULONG processor, ULONG64 offset,
|
||||
void *buffer, ULONG buffer_size, ULONG *written)
|
||||
{
|
||||
FIXME("%p, %u, %s, %p, %u, %p stub.\n", iface, processor, wine_dbgstr_longlong(offset), buffer, buffer_size, written);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadIo(IDebugDataSpaces *iface, ULONG type, ULONG bus_number,
|
||||
ULONG address_space, ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *read_len)
|
||||
{
|
||||
FIXME("%p, %u, %u, %u, %s, %p, %u, %p stub.\n", iface, type, bus_number, address_space, wine_dbgstr_longlong(offset),
|
||||
buffer, buffer_size, read_len);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteIo(IDebugDataSpaces *iface, ULONG type, ULONG bus_number,
|
||||
ULONG address_space, ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *written)
|
||||
{
|
||||
FIXME("%p, %u, %u, %u, %s, %p, %u, %p stub.\n", iface, type, bus_number, address_space, wine_dbgstr_longlong(offset),
|
||||
buffer, buffer_size, written);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadMsr(IDebugDataSpaces *iface, ULONG msr, ULONG64 *value)
|
||||
{
|
||||
FIXME("%p, %u, %p stub.\n", iface, msr, value);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteMsr(IDebugDataSpaces *iface, ULONG msr, ULONG64 value)
|
||||
{
|
||||
FIXME("%p, %u, %s stub.\n", iface, msr, wine_dbgstr_longlong(value));
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadBusData(IDebugDataSpaces *iface, ULONG data_type,
|
||||
ULONG bus_number, ULONG slot_number, ULONG offset, void *buffer, ULONG buffer_size, ULONG *read_len)
|
||||
{
|
||||
FIXME("%p, %u, %u, %u, %u, %p, %u, %p stub.\n", iface, data_type, bus_number, slot_number, offset, buffer,
|
||||
buffer_size, read_len);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteBusData(IDebugDataSpaces *iface, ULONG data_type,
|
||||
ULONG bus_number, ULONG slot_number, ULONG offset, void *buffer, ULONG buffer_size, ULONG *written)
|
||||
{
|
||||
FIXME("%p, %u, %u, %u, %u, %p, %u, %p stub.\n", iface, data_type, bus_number, slot_number, offset, buffer,
|
||||
buffer_size, written);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_CheckLowMemory(IDebugDataSpaces *iface)
|
||||
{
|
||||
FIXME("%p stub.\n", iface);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadDebuggerData(IDebugDataSpaces *iface, ULONG index, void *buffer,
|
||||
ULONG buffer_size, ULONG *data_size)
|
||||
{
|
||||
FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, data_size);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadProcessorSystemData(IDebugDataSpaces *iface, ULONG processor,
|
||||
ULONG index, void *buffer, ULONG buffer_size, ULONG *data_size)
|
||||
{
|
||||
FIXME("%p, %u, %u, %p, %u, %p stub.\n", iface, processor, index, buffer, buffer_size, data_size);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static const IDebugDataSpacesVtbl debugdataspacesvtbl =
|
||||
{
|
||||
debugdataspaces_QueryInterface,
|
||||
debugdataspaces_AddRef,
|
||||
debugdataspaces_Release,
|
||||
debugdataspaces_ReadVirtual,
|
||||
debugdataspaces_WriteVirtual,
|
||||
debugdataspaces_SearchVirtual,
|
||||
debugdataspaces_ReadVirtualUncached,
|
||||
debugdataspaces_WriteVirtualUncached,
|
||||
debugdataspaces_ReadPointersVirtual,
|
||||
debugdataspaces_WritePointersVirtual,
|
||||
debugdataspaces_ReadPhysical,
|
||||
debugdataspaces_WritePhysical,
|
||||
debugdataspaces_ReadControl,
|
||||
debugdataspaces_WriteControl,
|
||||
debugdataspaces_ReadIo,
|
||||
debugdataspaces_WriteIo,
|
||||
debugdataspaces_ReadMsr,
|
||||
debugdataspaces_WriteMsr,
|
||||
debugdataspaces_ReadBusData,
|
||||
debugdataspaces_WriteBusData,
|
||||
debugdataspaces_CheckLowMemory,
|
||||
debugdataspaces_ReadDebuggerData,
|
||||
debugdataspaces_ReadProcessorSystemData,
|
||||
};
|
||||
|
||||
/************************************************************
|
||||
* DebugExtensionInitialize (DBGENG.@)
|
||||
*
|
||||
|
@ -508,6 +733,7 @@ HRESULT WINAPI DebugCreate(REFIID riid, void **obj)
|
|||
return E_OUTOFMEMORY;
|
||||
|
||||
debug_client->IDebugClient_iface.lpVtbl = &debugclientvtbl;
|
||||
debug_client->IDebugDataSpaces_iface.lpVtbl = &debugdataspacesvtbl;
|
||||
debug_client->refcount = 1;
|
||||
|
||||
unk = (IUnknown *)&debug_client->IDebugClient_iface;
|
||||
|
|
|
@ -26,6 +26,7 @@ DEFINE_GUID(IID_IDebugInputCallbacks, 0x9f50e42c, 0xf136, 0x499e, 0x9a, 0x97
|
|||
DEFINE_GUID(IID_IDebugOutputCallbacks, 0x4bf58045, 0xd654, 0x4c40, 0xb0, 0xaf, 0x68, 0x30, 0x90, 0xf3, 0x56, 0xdc);
|
||||
DEFINE_GUID(IID_IDebugEventCallbacks, 0x337be28b, 0x5036, 0x4d72, 0xb6, 0xbf, 0xc4, 0x5f, 0xbb, 0x9f, 0x2e, 0xaa);
|
||||
DEFINE_GUID(IID_IDebugClient, 0x27fe5639, 0x8407, 0x4f47, 0x83, 0x64, 0xee, 0x11, 0x8f, 0xb0, 0x8a, 0xc8);
|
||||
DEFINE_GUID(IID_IDebugDataSpaces, 0x88f7dfab, 0x3ea7, 0x4c3a, 0xae, 0xfb, 0xc4, 0xe8, 0x10, 0x61, 0x73, 0xaa);
|
||||
|
||||
#define INTERFACE IDebugBreakpoint
|
||||
DECLARE_INTERFACE_(IDebugBreakpoint, IUnknown)
|
||||
|
@ -158,6 +159,45 @@ DECLARE_INTERFACE_(IDebugClient, IUnknown)
|
|||
};
|
||||
#undef INTERFACE
|
||||
|
||||
#define INTERFACE IDebugDataSpaces
|
||||
DECLARE_INTERFACE_(IDebugDataSpaces, IUnknown)
|
||||
{
|
||||
/* IUnknown */
|
||||
STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
|
||||
STDMETHOD_(ULONG, AddRef)(THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release)(THIS) PURE;
|
||||
/* IDebugDataSpaces */
|
||||
STDMETHOD(ReadVirtual)(THIS_ ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *read_len) PURE;
|
||||
STDMETHOD(WriteVirtual)(THIS_ ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *written) PURE;
|
||||
STDMETHOD(SearchVirtual)(THIS_ ULONG64 offset, ULONG64 length, void *pattern, ULONG pattern_size,
|
||||
ULONG pattern_granularity, ULONG64 *ret_offset) PURE;
|
||||
STDMETHOD(ReadVirtualUncached)(THIS_ ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *read_len) PURE;
|
||||
STDMETHOD(WriteVirtualUncached)(THIS_ ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *written) PURE;
|
||||
STDMETHOD(ReadPointersVirtual)(THIS_ ULONG count, ULONG64 offset, ULONG64 *pointers) PURE;
|
||||
STDMETHOD(WritePointersVirtual)(THIS_ ULONG count, ULONG64 offset, ULONG64 *pointers) PURE;
|
||||
STDMETHOD(ReadPhysical)(THIS_ ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *read_len) PURE;
|
||||
STDMETHOD(WritePhysical)(THIS_ ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *written) PURE;
|
||||
STDMETHOD(ReadControl)(THIS_ ULONG processor, ULONG64 offset, void *buffer, ULONG buffer_size,
|
||||
ULONG *read_len) PURE;
|
||||
STDMETHOD(WriteControl)(THIS_ ULONG processor, ULONG64 offset, void *buffer, ULONG buffer_size,
|
||||
ULONG *written) PURE;
|
||||
STDMETHOD(ReadIo)(THIS_ ULONG type, ULONG bus_number, ULONG address_space, ULONG64 offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *read_len) PURE;
|
||||
STDMETHOD(WriteIo)(THIS_ ULONG type, ULONG bus_number, ULONG address_space, ULONG64 offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *written) PURE;
|
||||
STDMETHOD(ReadMsr)(THIS_ ULONG msr, ULONG64 *value) PURE;
|
||||
STDMETHOD(WriteMsr)(THIS_ ULONG msr, ULONG64 value) PURE;
|
||||
STDMETHOD(ReadBusData)(THIS_ ULONG data_type, ULONG bus_number, ULONG slot_number, ULONG offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *read_len) PURE;
|
||||
STDMETHOD(WriteBusData)(THIS_ ULONG data_type, ULONG bus_number, ULONG slot_number, ULONG offset, void *buffer,
|
||||
ULONG buffer_size, ULONG *written) PURE;
|
||||
STDMETHOD(CheckLowMemory)(THIS) PURE;
|
||||
STDMETHOD(ReadDebuggerData)(THIS_ ULONG index, void *buffer, ULONG buffer_size, ULONG *data_size) PURE;
|
||||
STDMETHOD(ReadProcessorSystemData)(THIS_ ULONG processor, ULONG index, void *buffer, ULONG buffer_size,
|
||||
ULONG *data_size) PURE;
|
||||
};
|
||||
#undef INTERFACE
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue