-
Notifications
You must be signed in to change notification settings - Fork 253
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement D3DKMTEnumAdapters2
and D3DKMTQueryAdapterInfo
(for WDDM_2_7_CAPS
)
#259
Open
liam-middlebrook
wants to merge
67
commits into
ValveSoftware:experimental_9.0
Choose a base branch
from
liam-middlebrook:qai-hws
base: experimental_9.0
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
67 commits
Select commit
Hold shift + click to select a range
508a728
ws2_32/Tests: Add tests for send buffering.
832a61e
ntdll: Avoid short writes on nonblocking sockets.
ce15d36
ntdll: Locally duplicated socket fd for background send.
1eea231
ntdll: Don't cancel background socket sends.
ea84f2f
server: Correct STATUS_NOT_FOUND return from (cancel_async).
ac4be53
fixup! winevulkan: Share keyed mutex data.
fad64fd
winex11.drv: Set X window property to indicate if the presentation ma…
b6eba4d
nsiproxy: Only set the connection count from tcp_conns_enumerate_all …
misterfifths 3638eac
nsiproxy: Only set the endpoint count from udp_endpoint_enumerate_all…
misterfifths db96f88
kernel32/tests: Add a test for TLS links.
fff0fab
ntdll: Reserve space for some TLS directories at once.
ab68793
ntdll: Iterate TEBs only once in alloc_tls_slot().
3d50128
ntdll: Do not use TlsLinks for enumerating TEBs.
e7da5a1
ntdll/tests: Add more tests for process instrumentation callback.
a91e43f
ntdll: Call instrumentation callback from wine_syscall_dispatcher on …
db90ca1
ntdll: Call instrumentation callback for KiUserExceptionDispatcher on…
cabc00e
ntdll: Call instrumentation callback for LdrInitializeThunk on x64.
dbd334b
ntdll: Call instrumentation callback for KiUserModeCallback on x64.
139fd55
ntdll: Support old parameter layout for NtSetInformationProcess( Proc…
95fab23
fixup! ntdll: Support x86_64 syscall emulation.
2382761
Revert "ntdll: Change module search order in LdrFindEntryForAddress()."
6ea3cc3
ntdll: Implement RtlRbInsertNodeEx().
17b61f5
ntdll: Implement RtlRbRemoveNode().
2b697f0
ntdll/tests: Add tests for RTL RB tree.
efadc74
ntdll: Fill LDR_DATA_TABLE_ENTRY.BaseAddressIndexNode.
713554e
ntdll: Use base address tree in get_modref().
5df0fa5
ntdll: Use base address tree in LdrFindEntryForAddress().
a3c850f
ntdll: Implement NtSetInformationProcess( ProcessTlsInformation ).
1bd85e4
ntdll: Use NtSetInformationProcess( ProcessTlsInformation ) in alloc_…
7ebedd3
ntdll: Match memory allocation layout for ThreadLocalStoragePointer.
d037b81
ntdll/tests: Move unwinding tests to a separate file.
julliard c67cc17
ntdll/tests: Add a test for module function table search.
f3cf8d1
ntdll: Maintain module exception directory table.
f612d6f
HACK: wine.inf: Add native,builting override for TDUSC / xinput1_3.
ae11e82
fixup! winevulkan: Support waiting for and signalling d3d12 shared fe…
d444e90
fixup! winex11.drv: Set X window property to indicate if the presenta…
ae0bc6d
winhttp/tests: Add some tests for querying string options with NULL b…
nsivov fb0369b
winhttp: Fix error handling when returning string options.
nsivov 8fc24d2
winhttp: Implement WinHttpQueryOption(WINHTTP_OPTION_URL).
b6eff70
winhttp/tests: Add some more tests for string options in WinHttpQuery…
nsivov a753926
winhttp: Handle exact buffer length match in WinHttpQueryOption().
nsivov 6dfd3c9
winevulkan: Update to VK spec version 1.3.295.
DadSchoorse 38e2c27
winevulkan: Avoid empty struct extension conversions.
DadSchoorse 8b70d56
winevulkan: Update to VK spec version 1.3.296.
DadSchoorse 1e44da3
winevulkan: Update vk.xml to 1.3.296.
ivyl 3254c83
comctl32: Implement EVENT_OBJECT_STATECHANGE for buttons.
madewokherd 61992a5
user32: Handle WM_GETOBJECT in buttons.
madewokherd 2b48135
win32u: Implement EVENT_OBJECT_NAMECHANGE.
madewokherd 0b29c42
comctl32: Handle WM_GETOBJECT in tab control.
madewokherd e753a48
win32u: Correctly fill new foreground window TID in WM_ACTIVATEAPP.
d4022ea
user32: Respond to OBJID_QUERYCLASSNAMEIDX in combo boxes.
madewokherd 2cc5baf
comctl32: Handle OBJID_QUERYCLASSNAMEIDX in trackbars.
madewokherd 4ee0a14
ntdll: Skip dll file search when getting module handle.
be74251
atiadlxx: Bump driver version to 99.
308764a
wine.inf: Enable builtin atiadlxx for FFXVI.
9db402d
ntdll: HACK: Enable WINE_ALERT_SIMULATE_SCHED_QUANTUM option for Mary…
38e2231
Revert "win32u: Correctly fill new foreground window TID in WM_ACTIVA…
cd414fc
win32u: Call set_active_window() helper directly from handle_internal…
e05e0ba
win32u: Correctly fill new foreground window TID in WM_ACTIVATEAPP.
849d4bd
fixup! ntdll: Skip dll file search when getting module handle.
d6e4afd
ntdll: HACK: Force en-US locale for EAC launcher.
68460d3
user32/tests: Add tests for QueryDisplayConfig( QDC_VIRTUAL_MODE_AWAR…
1a1f136
win32u: Support QDC_VIRTUAL_MODE_AWARE in NtUserGetDisplayConfigBuffe…
5416bf6
win32u: Support QDC_VIRTUAL_MODE_AWARE in NtUserQueryDisplayConfig().
f25c0d0
gdi32: Implement D3DKMTEnumAdapters2
liam-middlebrook 23d772f
win32u: Move D3DKMTQueryAdapterInfo into gdi_dc_funcs
liam-middlebrook b239fbc
winex11.drv: Implement D3DKMTQueryAdapterInfo WDDM_2_7_CAPS
liam-middlebrook File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does the
"PCI"
enumerator also include software devices like the Microsoft Basic Display Adapter with the WARP software Direct3D UMD, as well as non-PCI GPUs such as the Host1x-attached Nvidia Tegra 3's GPU in the Microsoft Surface RT?For enumerating all display devices,
CM_Get_Device_Interface_List
forGUID_DISPLAY_DEVICE_ARRIVAL
can be used alternatively (however you needD3DKMTOpenAdapterFromDeviceName
akaNtGdiDdDDIOpenAdapterFromDeviceName
implemented somehow to actually obtain the D3DKMT adapter handle from the device name returned by it — and in upstream Wine, as of now, that function simply doesNtGdiDdDDIOpenAdapterFromLuid
for a zeroed LUID), it does include the software adapter, although I'm not sure how well-implemented cfgmgr32 is in Wine on non-Windows hosts overall.One usage example is available at https://gitlab.freedesktop.org/Triang3l/mesa/-/blob/Terakan/src/amd/terascale/vulkan/winsys/wddm/terakan_physical_device_wddm.c (see
terakan_physical_device_wddm_enumerate
).Note the kind of dependency reversal in that current implementation of
NtGdiDdDDIOpenAdapterFromDeviceName
in Wine also (which is of course fine as for now it's just a stub that opens the first available adapter or something like that).FromDeviceName
has existed since Windows Vista, whileFromLuid
was added in Windows 8, and is itself can be implemented as callingFromDeviceName
and comparing the LUID for each adapter returned byCM_Get_Device_Interface_List
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
According to https://learn.microsoft.com/en-us/windows-hardware/drivers/install/enumerating-installed-device-interface-classes,
SetupDiGetClassDevs
also can be used for the purposes of enumeration, but theEnumerator
argument can beNULL
. And yeah, since you can query the LUID this way (viaDEVPROPKEY_GPU_LUID
) without actually callingD3DKMTOpenAdapterFromDeviceName
, it should be more straightforward than using the Configuration Manager. Is the"PCI"
enumerator needed for anything important in Wine, and what happens if you don't pass it?Edit: The Configuration Manager also has
CM_Get_Device_Interface_Property
for the same purpose, so it doesn't really matter which one of the two is used — and the Setup API also appears to be much older, though CfgMgr appears to have been added in Vista, which is the first release to have WDDM at all.Edit 2: Which Windows version has gotten
DEVPKEY_Gpu_Luid
at all first? If it's actually something as recent as some Windows 10 update rather than Vista, theD3DKMTOpenAdapterFromDeviceName
approach may be more preferable. Though if you can get the device name from the Setup API rather than the Configuration Manager as well, the selection between the two also doesn't matter.