TianoCore EDK2 master
Loading...
Searching...
No Matches
FuseFsync.c File Reference
#include "VirtioFsDxe.h"

Go to the source code of this file.

Functions

EFI_STATUS VirtioFsFuseFsyncFileOrDir (IN OUT VIRTIO_FS *VirtioFs, IN UINT64 NodeId, IN UINT64 FuseHandle, IN BOOLEAN IsDir)
 

Detailed Description

FUSE_FSYNC / FUSE_FSYNCDIR wrapper for the Virtio Filesystem device.

Copyright (C) 2020, Red Hat, Inc.

SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file FuseFsync.c.

Function Documentation

◆ VirtioFsFuseFsyncFileOrDir()

EFI_STATUS VirtioFsFuseFsyncFileOrDir ( IN OUT VIRTIO_FS VirtioFs,
IN UINT64  NodeId,
IN UINT64  FuseHandle,
IN BOOLEAN  IsDir 
)

Synchronize the in-core state of a regular file or a directory with the storage device on the host, by sending the FUSE_FSYNC or FUSE_FSYNCDIR request to the Virtio Filesystem device.

The function may only be called after VirtioFsFuseInitSession() returns successfully and before VirtioFsUninit() is called.

Parameters
[in,out]VirtioFsThe Virtio Filesystem device to send the FUSE_FSYNC / FUSE_FSYNCDIR request to. On output, the FUSE request counter "VirtioFs->RequestId" will have been incremented.
[in]NodeIdThe inode number of the file or directory to sync.
[in]FuseHandleThe open handle to the file or directory to sync.
[in]IsDirTRUE if NodeId and FuseHandle refer to a directory, FALSE if NodeId and FuseHandle refer to a regular file.
Return values
EFI_SUCCESSThe file or directory has been synchronized.
Returns
The "errno" value mapped to an EFI_STATUS code, if the Virtio Filesystem device explicitly reported an error.
Error codes propagated from VirtioFsSgListsValidate(), VirtioFsFuseNewRequest(), VirtioFsSgListsSubmit(), VirtioFsFuseCheckResponse().

Definition at line 42 of file FuseFsync.c.