On Sun Apr 20 22:02:46 2025 +0000, Pali Rohár wrote:
WinIO is expecting the carry flag to be set on DPMI failure, otherwise it will segfault on pseudo-random address dereference. SysToolsLib is also expecting the carry flag to be set on the failure. And lspci contains workaround for this "buggy" wine DPMI behavior. The workaround for windows version of lspci was added there by me because of this bug which was causing segfault. Note that I have also checked the Windows 7 behavior and it is also setting the carry flag for physical address mapping request (Windows 7 does not support DPMI physical address mapping functionality). I highly doubt that some application can work when is asking for physical address mapping and wine returns bogus address instead of failure. If application is asking for physical address mapping then application would want to access that mapped address. And accessing the returned bogus address returned by wine will cause segfault of application.
I understand your concern that a broad CF fixes might be required to run more apps.
However, you should try to fix *only* the specific function(s) that yoir application (game), as broad changes tend to cause regressions in all other apps.
The broad fix could pass if there are (conformance) test cases for those functions, but we lack them, so we try to err on the safe side.