Takes advantage of linux's ID register emulation. The msr instruction is manually assembled to support older compilers and those that disallow reading e.g. SVE ID registers if unsupported by the target, even though they RAZ if unsupported.
This defines a wine-specific SMBIOS table format ontop of the standard additional processor information block to pass ID registers to wineboot. The index of each table within the SMBIOS directly maps to the core it corresponds to and registers are passed using their numerical IDs to match Windows' registry format and avoid needing to map between names and IDs on both ends (the unix side needs to manually encode the msr's anyway).
Question: would it be reasonable to add a wine/smbios.h header? I'm unsure if the duplication here is for a good reason.
--
v2: wineboot: Populate ARM64 ID register registry keys using SMBIOS info.
ntdll: Populate the SMBIOS with ARM64 ID register values.
https://gitlab.winehq.org/wine/wine/-/merge_requests/6225
Fixes a bug where `rundll32.exe advpack.dll,DelNodeRunDLL32 "c:\test",1` is only supposed to delete "test" if the directory is empty.
Also causes the [DelDirs Inf section](https://www.mdgx.com/INF_web/deldirs.htm) to work correctly.
Notes:
- I changed the code so it ignores the result of `SetFileAttributesW` because the user might not have FILE_WRITE_ATTRIBUTES even if they have DELETE rights. This seems to match Windows (XP NTFS).
--
v2: advpack: DelNode support ADN_DEL_IF_EMPTY flag
https://gitlab.winehq.org/wine/wine/-/merge_requests/6347
Patch 1/4 still needs to be merged into 2/4.
The BroadcastSystemMessage() calls seem to have been inadvertently removed in 2/4, and the split isn't quite complete—it still introduces DBT_DEVTYP_HANDLE support in plugplay_send_event(). Ideally separating the new_event() helper would also be a separate commit, so that you're not moving code and changing it at the same time.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/6315#note_79797
On Thu Aug 22 19:02:16 2024 +0000, Vibhav Pant wrote:
> It might be too wordy, but what about `with_notify_registration`? I was
> initially thinking `with_hdevnotify`, but that's not very communicative either.
I think with_hdevnotify is better actually; it requires you to know what a HDEVNOTIFY is but is otherwise clear and unambiguous.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/6315#note_79796
IoGetDevicePropertyData is used to implement the `IOCTL_BTH_GET_DEVICE_INFO` Bluetooth IOCTL to fetch cached information for remote devices, without having to access the device extension pointer (which is arguably racy and more fragile).
--
v9: ntoskrnl/tests: Add test for getting and setting device properties.
https://gitlab.winehq.org/wine/wine/-/merge_requests/6338
Fixes a bug where `rundll32.exe advpack.dll,DelNodeRunDLL32 "c:\test",1` is only supposed to delete "test" if the directory is empty.
Also causes the [DelDirs Inf section](https://www.mdgx.com/INF_web/deldirs.htm) to work correctly.
Notes:
- I changed the code so it ignores the result of `SetFileAttributesW` because the user might not have FILE_WRITE_ATTRIBUTES even if they have DELETE rights. This seems to match Windows (XP NTFS).
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/6347