kvm-guest-drivers-windows icon indicating copy to clipboard operation
kvm-guest-drivers-windows copied to clipboard

Viosock: Remove Coinstaller Stuff from the INF File

Open MartinDrab opened this issue 11 months ago • 10 comments

The driver is installed in the Driver Store (DIRID 13) instead of the System Drivers directory (DIRID 12).

MartinDrab avatar Mar 22 '24 20:03 MartinDrab

Is the protocol not registered?

xuehuihui avatar Mar 25 '24 10:03 xuehuihui

It is not. I think the INFs were not responsible for registering it even before this PR (I did not notice such registrations). I can of course test this (old INFs) on a fresh machine.

MartinDrab avatar Mar 25 '24 10:03 MartinDrab

[VirtioSocket_Device_CoInstaller_AddReg] HKR,,CoInstallers32,0x00010000,"viosocklib.dll,ViosockCoInstaller" ==> The old INFs will register the protocol through the ViosockCoInstaller interface.

xuehuihui avatar Mar 25 '24 14:03 xuehuihui

[VirtioSocket_Device_CoInstaller_AddReg] HKR,,CoInstallers32,0x00010000,"viosocklib.dll,ViosockCoInstaller" ==> The old INFs will register the protocol through the ViosockCoInstaller interface.

Ah, OK, I missed that. I will improve the PR.

MartinDrab avatar Mar 25 '24 14:03 MartinDrab

@MartinDrab

The build failed

C:\EWDK11\Program Files\Microsoft Visual Studio\2019\BuildTools\MSBuild\Microsoft\VC\v160\Microsoft.CppBuild.targets(436,5): error MSB8013: This project doesn't contain the Configuration and Platform combination of Debug|Win32. [C:\workspace\VirtIO-EWDK-11-21H2-SDV\viosock\installer\viosock-installer.vcxproj]

kostyanf14 avatar Jun 04 '24 07:06 kostyanf14

@MartinDrab https://learn.microsoft.com/en-us/windows-hardware/drivers/install/using-an-extension-inf-file did you try to check "Extension INFs"?

YanVugenfirer avatar Jun 10 '24 09:06 YanVugenfirer

@MartinDrab https://learn.microsoft.com/en-us/windows-hardware/drivers/install/using-an-extension-inf-file did you try to check "Extension INFs"?

I came across them several days ago when working on another (unrelated) issue. I did not have time to look at them in more detail and possibly use them, however, I hope to get to it shortly.

MartinDrab avatar Jun 10 '24 10:06 MartinDrab

@MartinDrab We merge https://github.com/virtio-win/kvm-guest-drivers-windows/pull/1087 to switch to the new EWDK. For now, we just disable viosock build for Win11.

kostyanf14 avatar Jun 24 '24 06:06 kostyanf14

@MartinDrab We merge #1087 to switch to the new EWDK. For now, we just disable viosock build for Win11.

OK. I hope to work on this PR shortly and finish it. I apologize for this inconvenience.

MartinDrab avatar Jun 24 '24 07:06 MartinDrab

@MartinDrab We merge #1087 to switch to the new EWDK. For now, we just disable viosock build for Win11.

OK. I hope to work on this PR shortly and finish it. I apologize for this inconvenience.

Not a problem. Disabling the build is not a complicated task. This is more problem for companies that release viosock.

kostyanf14 avatar Jun 24 '24 07:06 kostyanf14

@MartinDrab We merge #1087 to switch to the new EWDK. For now, we just disable viosock build for Win11.

OK. I hope to work on this PR shortly and finish it. I apologize for this inconvenience.

Not a problem. Disabling the build is not a complicated task. This is more problem for companies that release viosock.

Hello,

I hope I overcame issues regarding the co-installer and the socket WSP installation from the INF file. In the end, I decided to separate the WSP installation into a special service since it is possible to install and start it from the INF file. Other possibilities seem to be problematic:

  • WDK complains about the co-installer even when it is used only on old versions of Windows 10,
  • the AddSoftware directive is not supported on old versions of Windows 10.

I hope this should finally pass the tests and build successfully also with new (E)WDKs.

MartinDrab avatar Jul 23 '24 13:07 MartinDrab

@MartinDrab

Thanks for your work. Unfortunately, the build failed again.

Please also revert https://github.com/virtio-win/kvm-guest-drivers-windows/commit/f7646006430f40014373cc747bb75a0d7f2cf1c2 and update buildAll.bat (https://github.com/virtio-win/kvm-guest-drivers-windows/commit/ad1aed4601ba937625263c54720fbf316685a3e5 disabled Win11 for viosock)

if errorlevel 1 goto :fail
call tools\build.bat viosock\sys\viosock.vcxproj "Win10_SDV Win11_SDV" %*
if errorlevel 1 goto :fail
call tools\build.bat viosock\wsk\wsk.vcxproj "Win10_SDV Win11_SDV" %*
if errorlevel 1 goto :fail
call tools\build.bat viosock\viosock-wsk-test\viosock-wsk-test.vcxproj "Win10_SDV Win11_SDV" %*

kostyanf14 avatar Jul 23 '24 13:07 kostyanf14