Changeset 78563 in vbox for trunk/src/VBox/Additions/WINNT/SharedFolders
- Timestamp:
- May 17, 2019 11:46:23 AM (6 years ago)
- Location:
- trunk/src/VBox/Additions/WINNT/SharedFolders/driver
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/WINNT/SharedFolders/driver/info.cpp
r78553 r78563 1269 1269 uint8_t fTimestampsToCopyAnyway, PFILE_OBJECT pFileObj, PMRX_FCB pFcb) 1270 1270 { 1271 LogFlow(("vbsfNtCopyInfo: hFile=%#RX64 pVBoxFobX=%p\n", pVBoxFobX->hFile, pVBoxFobX)); 1272 uint64_t const nsNow = RTTimeSystemNanoTS(); 1273 1271 1274 /* 1272 1275 * Check if the size changed because RDBSS and the cache manager have … … 1308 1311 } 1309 1312 pVBoxFobX->Info = *pObjInfo; 1313 pVBoxFobX->nsUpToDate = nsNow; 1310 1314 } 1311 1315 … … 1443 1447 * give is "fixes". 1444 1448 * 1449 * The TTL here works around two issues in particular: 1450 * 1451 * 1. We don't want to go to the host three times during a 1452 * FileAllInformation query (RDBSS splits it up). 1453 * 1454 * 2. There are several filter drivers which will query info at the end of the 1455 * IRP_MJ_CREATE processing. On a W10 guest here, FileFinder.sys (belived to 1456 * be related to the prefetcher) first queries FileStandardInformation, then 1457 * WdFilter.sys (Windows Defender) will query FileBasicInformation, 1458 * FileStandardInformation and (not relevant here) FileInternalInformation. 1459 * It would be complete waste of time to requery the data from the host for 1460 * each of the three queries. 1461 * 1462 * The current hardcoded 100us value was choosen by experimentation with FsPerf 1463 * on a decent intel system (6700K). This is however subject to the timer tick 1464 * granularity on systems without KeQueryInterruptTimePrecise (i.e. pre win8). 1465 * 1445 1466 * Note! We verify the buffer size after talking to the host, assuming that there 1446 1467 * won't be a problem and saving an extra switch statement. IIRC the 1447 * NtQueryInformationFile code ver fies the sizes too.1468 * NtQueryInformationFile code verifies the sizes too. 1448 1469 */ 1449 1470 /** @todo r=bird: install a hack so we get FileAllInformation directly up here … … 1462 1483 if ( !(pVBoxFobx->Info.Attr.fMode & RTFS_DOS_DIRECTORY) /** @todo figure out why we don't return up-to-date info for directories! */ 1463 1484 && ( !pVBoxFobx->nsUpToDate 1464 || pVBoxFobx->nsUpToDate - RTTimeSystemNanoTS() <RT_NS_100US /** @todo implement proper TTL */ ) )1485 || RTTimeSystemNanoTS() - pVBoxFobx->nsUpToDate > RT_NS_100US /** @todo implement proper TTL */ ) ) 1465 1486 { 1466 1487 PVBSFNTFCBEXT pVBoxFcbx = VBoxMRxGetFcbExtension(capFcb); -
trunk/src/VBox/Additions/WINNT/SharedFolders/driver/path.cpp
r78553 r78563 222 222 Log(("VBOXSF: vbsfNtCreateWorker: Calling VbglR0SfHostReqCreate(fCreate=%#RX32)...\n", pReq->CreateParms.CreateFlags)); 223 223 int vrc = VbglR0SfHostReqCreate(pNetRootExtension->map.root, pReq); 224 Log(("VBOXSF: vbsfNtCreateWorker: VbglR0SfHostReqCreate returns vrc = %Rrc, Result = 0x%x\n", vrc, pReq->CreateParms.Result)); 224 Log(("VBOXSF: vbsfNtCreateWorker: VbglR0SfHostReqCreate returns vrc = %Rrc, Result = 0x%x, Handle = %#RX64\n", 225 vrc, pReq->CreateParms.Result, pReq->CreateParms.Handle)); 225 226 226 227 if (RT_SUCCESS(vrc)) … … 502 503 * Initialize our file object extension data. 503 504 */ 504 pVBoxFobx->Info = pReq->CreateParms.Info; 505 pVBoxFobx->hFile = pReq->CreateParms.Handle; 506 pVBoxFobx->pSrvCall = RxContext->Create.pSrvCall; 505 pVBoxFobx->Info = pReq->CreateParms.Info; 506 pVBoxFobx->nsUpToDate = RTTimeSystemNanoTS(); 507 pVBoxFobx->hFile = pReq->CreateParms.Handle; 508 pVBoxFobx->pSrvCall = RxContext->Create.pSrvCall; 507 509 508 510 /* bird: Dunno what this really's about. */
Note:
See TracChangeset
for help on using the changeset viewer.