[vbox-dev] [PATCH] open virtual disk file with O_DIRECT
Howard Su
howard0su at gmail.com
Tue Feb 22 02:24:30 PST 2011
I am not sure how big diff this change will bring in. But I think this
is worth trying. I enable this unconditional because i believe the
most write for disk file doesn't need cache in host (guest already
handle it.)
Index: VD.cpp
===================================================================
--- VD.cpp (revision 35998)
+++ VD.cpp (working copy)
@@ -2333,7 +2333,7 @@
pStorage->pfnCompleted = pfnCompleted;
/* Open the file. */
- int rc = RTFileOpen(&pStorage->File, pszLocation, fOpen);
+ int rc = RTFileOpen(&pStorage->File, pszLocation, fOpen |
RTFILE_O_NO_CACHE);
if (RT_SUCCESS(rc))
{
*ppStorage = pStorage;
--
-Howard
More information about the vbox-dev
mailing list