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

Go to the source code of this file.

Functions

EFI_STATUS VirtioFsFuseOpen (IN OUT VIRTIO_FS *VirtioFs, IN UINT64 NodeId, IN BOOLEAN ReadWrite, OUT UINT64 *FuseHandle)
 

Detailed Description

FUSE_OPEN wrapper for the Virtio Filesystem device.

Copyright (C) 2020, Red Hat, Inc.

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

Definition in file FuseOpen.c.

Function Documentation

◆ VirtioFsFuseOpen()

EFI_STATUS VirtioFsFuseOpen ( IN OUT VIRTIO_FS VirtioFs,
IN UINT64  NodeId,
IN BOOLEAN  ReadWrite,
OUT UINT64 *  FuseHandle 
)

Send a FUSE_OPEN request to the Virtio Filesystem device, for opening a regular file.

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_OPEN request to. On output, the FUSE request counter "VirtioFs->RequestId" will have been incremented.
[in]NodeIdThe inode number of the regular file to open.
[in]ReadWriteIf TRUE, open the regular file in read-write mode. If FALSE, open the regular file in read-only mode.
[out]FuseHandleThe open handle to the regular file, returned by the Virtio Filesystem device.
Return values
EFI_SUCCESSThe regular file has been opened.
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 40 of file FuseOpen.c.