mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-21 22:47:50 +00:00
vbox: workaround for bug in Windows guest addition
In file src/VBox/Additions/WINNT/SharedFolders/driver/file.c the function static int vbsfTransferCommon(VBSFTRANSFERCTX *pCtx) in the VbglR0CanUsePhysPageList() branch does not correctly evaluate the read or written bytes from the VMM. It ever assumes that whole pages are read/written. Workaround the bug in the Windows guest additions of Vbox until fixed upstream by filling up the read/write buffer completely within the VMM code of Vbox. Fixes #1176
This commit is contained in:
parent
5922617eab
commit
3a8bf754e1
@ -1 +1 @@
|
||||
d2830608e86c55d6124ac016dae652fa6a69ea3e
|
||||
13aca05c49d35f7ce7a2cfd25d2751d9d6de9019
|
||||
|
87
repos/ports/src/virtualbox/sharedfolder_pagelist.patch
Normal file
87
repos/ports/src/virtualbox/sharedfolder_pagelist.patch
Normal file
@ -0,0 +1,87 @@
|
||||
+++ src/app/virtualbox/src/VBox/HostServices/SharedFolders/service.cpp
|
||||
@@ -546,6 +546,14 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
+
|
||||
+
|
||||
+ /* WORKAROUND start */
|
||||
+ uint32_t read = 0;
|
||||
+
|
||||
+ while (paParms[3].u.uint32 && read < paParms[3].u.uint32) {
|
||||
+
|
||||
+
|
||||
/* Execute the function. */
|
||||
if (pStatusLed)
|
||||
{
|
||||
@@ -559,13 +567,25 @@
|
||||
|
||||
if (RT_SUCCESS(rc))
|
||||
{
|
||||
+ read += count;
|
||||
+ offset += count;
|
||||
+ pBuffer += count;
|
||||
+ count = paParms[3].u.uint32 - read;
|
||||
+
|
||||
/* Update parameters.*/
|
||||
- paParms[3].u.uint32 = count;
|
||||
+ //paParms[3].u.uint32 = count;
|
||||
}
|
||||
else
|
||||
{
|
||||
paParms[3].u.uint32 = 0; /* nothing read */
|
||||
}
|
||||
+
|
||||
+
|
||||
+
|
||||
+ } /* WORKAROUND - End */
|
||||
+
|
||||
+
|
||||
+
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -613,6 +633,16 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
+
|
||||
+
|
||||
+
|
||||
+ /* WORKAROUND start */
|
||||
+ uint32_t write = 0;
|
||||
+
|
||||
+ while (paParms[3].u.uint32 && write < paParms[3].u.uint32) {
|
||||
+
|
||||
+
|
||||
+
|
||||
/* Execute the function. */
|
||||
if (pStatusLed)
|
||||
{
|
||||
@@ -626,13 +656,25 @@
|
||||
|
||||
if (RT_SUCCESS(rc))
|
||||
{
|
||||
+ write += count;
|
||||
+ offset += count;
|
||||
+ pBuffer += count;
|
||||
+ count = paParms[3].u.uint32 - write;
|
||||
+
|
||||
/* Update parameters.*/
|
||||
- paParms[3].u.uint32 = count;
|
||||
+ //paParms[3].u.uint32 = count;
|
||||
}
|
||||
else
|
||||
{
|
||||
paParms[3].u.uint32 = 0; /* nothing read */
|
||||
}
|
||||
+
|
||||
+
|
||||
+
|
||||
+ } /* WORKAROUND - End */
|
||||
+
|
||||
+
|
||||
+
|
||||
}
|
||||
}
|
||||
break;
|
Loading…
Reference in New Issue
Block a user