Rebase against 1113f42aa748d9e0a27c4663b9d8de1237f95e73.

This commit is contained in:
Alistair Leslie-Hughes 2022-07-19 13:15:49 +10:00
parent cd8ca4d7d6
commit 7a2920aa2a
7 changed files with 19 additions and 139 deletions

View File

@ -1,4 +1,4 @@
From 505384ad65984c3fc18c1c1a7b1fd39ecd0186f1 Mon Sep 17 00:00:00 2001
From 07694655cf43e87ffc6185a5e7fe8d1bdd8658a4 Mon Sep 17 00:00:00 2001
From: Zebediah Figura <z.figura12@gmail.com>
Date: Wed, 13 Jun 2018 23:32:04 -0500
Subject: [PATCH] kernel32/tests: Add some mutex tests.
@ -8,11 +8,11 @@ Subject: [PATCH] kernel32/tests: Add some mutex tests.
1 file changed, 94 insertions(+)
diff --git a/dlls/kernel32/tests/sync.c b/dlls/kernel32/tests/sync.c
index ea54cb069df..790b7bfe797 100644
index bc85126d9aa..491052d5593 100644
--- a/dlls/kernel32/tests/sync.c
+++ b/dlls/kernel32/tests/sync.c
@@ -177,8 +177,23 @@ static void test_signalandwait(void)
CloseHandle(file);
@@ -227,8 +227,23 @@ static void test_temporary_objects(void)
ok(GetLastError() == ERROR_FILE_NOT_FOUND, "wrong error %lu\n", GetLastError());
}
+static HANDLE mutex, mutex2, mutices[2];
@ -35,7 +35,7 @@ index ea54cb069df..790b7bfe797 100644
DWORD wait_ret;
BOOL ret;
HANDLE hCreated;
@@ -289,6 +304,85 @@ todo_wine_if(getenv("WINEESYNC")) /* XFAIL: due to the above */
@@ -339,6 +354,85 @@ todo_wine_if(getenv("WINEESYNC")) /* XFAIL: due to the above */
CloseHandle(hOpened);
CloseHandle(hCreated);
@ -122,5 +122,5 @@ index ea54cb069df..790b7bfe797 100644
static void test_slist(void)
--
2.28.0
2.35.1

View File

@ -51,7 +51,7 @@ usage()
# Get the upstream commit sha
upstream_commit()
{
echo "dfff9217746e5076aba35513c6d4bc3d271d109c"
echo "1113f42aa748d9e0a27c4663b9d8de1237f95e73"
}
# Show version information
@ -262,9 +262,7 @@ patch_enable_all ()
enable_ws2_32_SIO_IDEAL_SEND_BACKLOG_QUERY="$1"
enable_wscript_support_d_u_switches="$1"
enable_xactengine_initial="$1"
enable_xactengine3_7_Notification="$1"
enable_xactengine3_7_PrepareWave="$1"
enable_xactengine3_7_callbacks="$1"
}
# Enable or disable a specific patchset
@ -811,15 +809,9 @@ patch_enable ()
xactengine-initial)
enable_xactengine_initial="$2"
;;
xactengine3_7-Notification)
enable_xactengine3_7_Notification="$2"
;;
xactengine3_7-PrepareWave)
enable_xactengine3_7_PrepareWave="$2"
;;
xactengine3_7-callbacks)
enable_xactengine3_7_callbacks="$2"
;;
*)
return 1
;;
@ -1167,13 +1159,6 @@ patch_apply()
}
if test "$enable_xactengine3_7_callbacks" -eq 1; then
if test "$enable_xactengine3_7_Notification" -gt 1; then
abort "Patchset xactengine3_7-Notification disabled, but xactengine3_7-callbacks depends on that."
fi
enable_xactengine3_7_Notification=1
fi
if test "$enable_winex11_WM_WINDOWPOSCHANGING" -eq 1; then
if test "$enable_winex11__NET_ACTIVE_WINDOW" -gt 1; then
abort "Patchset winex11-_NET_ACTIVE_WINDOW disabled, but winex11-WM_WINDOWPOSCHANGING depends on that."
@ -3892,19 +3877,6 @@ if test "$enable_xactengine_initial" -eq 1; then
patch_apply xactengine-initial/0003-xactengine3_7-tests-Add-Global-settings-test.patch
fi
# Patchset xactengine3_7-Notification
# |
# | This patchset fixes the following Wine bugs:
# | * [#50546] xactengine3_7: Send Notification after the Wavebank is created.
# |
# | Modified files:
# | * dlls/xactengine3_7/xact_dll.c
# |
if test "$enable_xactengine3_7_Notification" -eq 1; then
patch_apply xactengine3_7-Notification/0001-xactengine3.7-Delay-Notication-for-WAVEBANKPREPARED.patch
patch_apply xactengine3_7-Notification/0002-xactengine3_7-Record-context-for-each-notications.patch
fi
# Patchset xactengine3_7-PrepareWave
# |
# | This patchset fixes the following Wine bugs:
@ -3918,23 +3890,6 @@ if test "$enable_xactengine3_7_PrepareWave" -eq 1; then
patch_apply xactengine3_7-PrepareWave/0003-xactengine3_7-Implement-IXACT3Engine-PrepareInMemory.patch
fi
# Patchset xactengine3_7-callbacks
# |
# | This patchset has the following (direct or indirect) dependencies:
# | * xactengine3_7-Notification
# |
# | This patchset fixes the following Wine bugs:
# | * [#49678] - xactengine: Implement callback notifications.
# |
# | Modified files:
# | * dlls/xactengine3_7/xact_dll.c, libs/faudio/include/FACT.h, libs/faudio/src/FACT.c, libs/faudio/src/FACT_internal.h
# |
if test "$enable_xactengine3_7_callbacks" -eq 1; then
patch_apply xactengine3_7-callbacks/0001-Add-support-for-private-contexts.patch
patch_apply xactengine3_7-callbacks/0002-xactengine3_7-notifications.patch
patch_apply xactengine3_7-callbacks/0004-xactengine3_7-Don-t-use-switch-with-constant-integer.patch
fi
if test "$enable_autoconf" -eq 1; then
if ! update_configure; then
abort "'autoreconf -f' failed."

View File

@ -1,4 +1,4 @@
From 9434e8c7083b21347ce7246c775279323c51c756 Mon Sep 17 00:00:00 2001
From a75e31b9098b8d111ec06a8a3f08470ae8992606 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Thu, 1 Oct 2020 18:34:23 +1000
Subject: [PATCH] xactengine3_7/tests: Add Global settings test
@ -7,8 +7,8 @@ Subject: [PATCH] xactengine3_7/tests: Add Global settings test
dlls/xactengine3_7/tests/Makefile.in | 5 ++-
dlls/xactengine3_7/tests/globals.xgs | Bin 0 -> 440 bytes
dlls/xactengine3_7/tests/rsrc.rc | 22 ++++++++++
dlls/xactengine3_7/tests/xact3.c | 60 +++++++++++++++++++++++++++
4 files changed, 86 insertions(+), 1 deletion(-)
dlls/xactengine3_7/tests/xact3.c | 61 +++++++++++++++++++++++++++
4 files changed, 87 insertions(+), 1 deletion(-)
create mode 100644 dlls/xactengine3_7/tests/globals.xgs
create mode 100644 dlls/xactengine3_7/tests/rsrc.rc
@ -70,11 +70,11 @@ index 00000000000..2c1961c727a
+/* @makedep: globals.xgs*/
+globals.xgs RCDATA "globals.xgs"
diff --git a/dlls/xactengine3_7/tests/xact3.c b/dlls/xactengine3_7/tests/xact3.c
index 623a1c97db8..aadeba735f5 100644
index 5daa18ca81b..7644ec1dfb8 100644
--- a/dlls/xactengine3_7/tests/xact3.c
+++ b/dlls/xactengine3_7/tests/xact3.c
@@ -90,11 +90,71 @@ static void test_interfaces(void)
}
@@ -261,11 +261,72 @@ static void test_notifications(void)
DeleteFileW(filename);
}
+static void test_global_properties(void)
@ -134,6 +134,7 @@ index 623a1c97db8..aadeba735f5 100644
+
+end:
+ IXACT3Engine_Release(engine);
+
+}
+
START_TEST(xact3)
@ -142,9 +143,9 @@ index 623a1c97db8..aadeba735f5 100644
test_interfaces();
+ test_global_properties();
test_notifications();
CoUninitialize();
}
--
2.34.1
2.35.1

View File

@ -1,77 +0,0 @@
From 36d84a848bcffc5e3a2d0ab4c96fe0eaac68bbbc Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Fri, 22 Jan 2021 18:22:41 +1100
Subject: [PATCH 1/2] xactengine3.7: Delay Notication for WAVEBANKPREPARED
---
dlls/xactengine3_7/xact_dll.c | 40 +++++++++++++++++++++++++++++++++++
1 file changed, 40 insertions(+)
diff --git a/dlls/xactengine3_7/xact_dll.c b/dlls/xactengine3_7/xact_dll.c
index 281aecc154b..e3b6e32cd5a 100644
--- a/dlls/xactengine3_7/xact_dll.c
+++ b/dlls/xactengine3_7/xact_dll.c
@@ -883,6 +883,42 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateSoundBank(IXACT3Engine *iface,
return S_OK;
}
+struct thread_data
+{
+ XACT3EngineImpl *engine;
+ XACT_NOTIFICATION note;
+};
+
+static DWORD WINAPI thread_notications(LPVOID data)
+{
+ struct thread_data *tdata = data;
+
+ Sleep(1000);
+
+ FIXME("Callback XACTNOTIFICATIONTYPE_WAVEBANKPREPARED (%p)\n", tdata->engine);
+
+ tdata->engine->notification_callback(&tdata->note);
+
+ CoTaskMemFree(data);
+ return 0;
+}
+
+static void send_wavebank_notification(XACT3EngineImpl *This, IXACT3WaveBank *wavebank)
+{
+ if (This->notification_callback)
+ {
+ HANDLE thread;
+ struct thread_data *tdata = CoTaskMemAlloc(sizeof(struct thread_data));
+
+ tdata->engine = This;
+ tdata->note.type = XACTNOTIFICATIONTYPE_WAVEBANKPREPARED;
+ tdata->note.wave.pWaveBank = wavebank;
+
+ thread = CreateThread(NULL, 0, thread_notications, tdata, 0, NULL);
+ CloseHandle(thread);
+ }
+}
+
static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *iface,
const void* pvBuffer, DWORD dwSize, DWORD dwFlags,
DWORD dwAllocAttributes, IXACT3WaveBank **ppWaveBank)
@@ -915,6 +951,8 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac
wb->fact_wavebank = fwb;
*ppWaveBank = &wb->IXACT3WaveBank_iface;
+ send_wavebank_notification(This, &wb->IXACT3WaveBank_iface);
+
TRACE("Created in-memory WaveBank: %p\n", wb);
return S_OK;
@@ -963,6 +1001,8 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa
wb->fact_wavebank = fwb;
*ppWaveBank = &wb->IXACT3WaveBank_iface;
+ send_wavebank_notification(This, &wb->IXACT3WaveBank_iface);
+
TRACE("Created streaming WaveBank: %p\n", wb);
return S_OK;
--
2.29.2

View File

@ -1,3 +1,3 @@
# The actual fix will involve FAudio and wine changes.
Fixes: [50546] xactengine3_7: Send Notification after the Wavebank is created.
Disabled: True

View File

@ -1,2 +1,3 @@
Fixes: [49678] - xactengine: Implement callback notifications.
Depends: xactengine3_7-Notification
Disabled: True

View File

@ -1 +1 @@
dfff9217746e5076aba35513c6d4bc3d271d109c
1113f42aa748d9e0a27c4663b9d8de1237f95e73