locks.c revision 78a072e1b56619e3230735ae073668311232ec94
/*++
Copyright (c) 1989 - 1999 Microsoft Corporation
Module Name:
Abstract:
This module implements the mini redirector call down routines pertaining to locks
of file system objects.
--*/
#include "precomp.h"
#pragma hdrstop
#ifdef ALLOC_PRAGMA
#endif
/*++
Routine Description:
This routine handles network requests for filelocks
Arguments:
RxContext - the RDBSS context
Return Value:
RXSTATUS - The return status for the operation
--*/
{
#ifndef VBOX
#endif
int vboxRC;
Log(("VBOXSF: VBoxMRxLocks: Called.\n"));
switch (LowIoContext->Operation)
{
default:
AssertMsgFailed(("VBOXSF: VBoxMRxLocks: Unsupported lock/unlock type %d detected!\n", LowIoContext->Operation));
return STATUS_NOT_IMPLEMENTED;
case LOWIO_OP_UNLOCK_MULTIPLE:
/* @todo Remove multiple locks listed in LowIoContext.ParamsFor.Locks.LockList. */
Log(("VBOXSF: VBoxMRxLocks: Unsupported lock/unlock type %d detected!\n", LowIoContext->Operation));
return STATUS_NOT_IMPLEMENTED;
/* Reading is allowed, writing isn't */
case LOWIO_OP_SHAREDLOCK:
break;
/* Reading and writing not allowed */
case LOWIO_OP_EXCLUSIVELOCK:
break;
case LOWIO_OP_UNLOCK:
break;
}
{
}
else
{
fLock |= SHFL_LOCK_WAIT;
}
/* Do the actual flushing of file buffers */
vboxRC = vboxCallLock(&pDeviceExtension->hgcmClient, &pNetRootExtension->map, pVBoxFobx->hFile, LowIoContext->ParamsFor.Locks.ByteOffset, LowIoContext->ParamsFor.Locks.Length, fLock);
return (Status);
}
NTSTATUS VBoxMRxCompleteBufferingStateChangeRequest (IN OUT PRX_CONTEXT RxContext, IN OUT PMRX_SRV_OPEN SrvOpen, IN PVOID pContext)
/*++
Routine Description:
This routine is called to assert the locks that the wrapper has buffered. currently, it is synchronous!
Arguments:
RxContext - the open instance
SrvOpen - tells which fcb is to be used.
LockEnumerator - the routine to call to get the locks
Return Value:
RXSTATUS - The return status for the operation
--*/
{
Log(("VBOXSF: VBoxMRxCompleteBufferingStateChangeRequest: Called.\n"));
return (Status);
}
/*++
Routine Description:
This routine handles network requests for file flush
Arguments:
RxContext - the RDBSS context
Return Value:
RXSTATUS - The return status for the operation
--*/
{
#ifndef VBOX
#endif
int vboxRC;
Log(("VBOXSF: VBoxMRxFlush: Called.\n"));
/* Do the actual flushing of file buffers */
return (Status);
}