fuchsia.fs

PROTOCOLS

Admin

Defined in fuchsia.fs/admin.fidl

Administration functionality for filesystems.

Shutdown

Shuts down the filesystem. Once the filesystem recieves the shutdown request, it will complete any active requests before terminating, but will not respond to new requests. This call blocks until all open connections to the filesystem are terminated and any underlying block devices or other owned channels are released, then it responds to this request and closes this channel.

Request

NameType

Response

NameType

Query

Defined in fuchsia.fs/query.fidl

Query exposes objective filesystem information independent of specific files and directories.

GetInfo

Queries the filesystem.

  • query specifies the fields in FilesystemInfo that the caller is interested in.

Request

NameType
query FilesystemInfoQuery

Response

NameType
result Query_GetInfo_Result

IsNodeInFilesystem

Checks if a node is associated with this filesystem, given some token representing a connection to that node.

Request

NameType
token handle<event>

Response

NameType
is_in_filesystem bool

STRUCTS

Query_GetInfo_Response

Defined in fuchsia.fs/query.fidl

NameTypeDescriptionDefault
info FilesystemInfo No default

ENUMS

FsType

Type: uint32

Defined in fuchsia.fs/query.fidl

The type of the filesystem.

This enum should be flexible, to accommodate future additions.

NameValueDescription
BLOBFS 2657701153
MINFS 1852394785
MEMFS 1047088417

TABLES

FilesystemInfo

Defined in fuchsia.fs/query.fidl

Information about a filesystem.

If a particular field is not applicable or not supported, implementations should leave it absent.

OrdinalNameTypeDescription
1 total_bytes uint64

The number of data bytes which may be stored in the filesystem.

2 used_bytes uint64

The number of data bytes which are in use by the filesystem. Note that this value may change in the mean time.

3 total_nodes uint64

The number of nodes which may be stored in the filesystem.

4 used_nodes uint64

The number of nodes used by the filesystem. Note that this value may change in the mean time.

5 free_shared_pool_bytes uint64

The amount of space which may be allocated from the underlying volume manager. Note that this value may change in the mean time.

6 fs_id handle<event>

A globally unique identifier for this filesystem instance.

7 block_size uint32

The size of a single filesystem block.

8 max_node_name_size uint32

The maximum length of a filesystem name.

9 fs_type FsType

A unique identifier for the type of the underlying filesystem.

10 name string[32]

The name of the filesystem.

11 device_path fuchsia.io2/Path

Path to the device backing this filesystem.

UNIONS

Query_GetInfo_Result

Defined in fuchsia.fs/query.fidl

NameTypeDescription
response Query_GetInfo_Response
err zx/status

BITS

FilesystemInfoQuery

Type: uint64

NameValueDescription
TOTAL_BYTES 1

Requests FilesystemInfoQuery.total_bytes.

USED_BYTES 2

Requests FilesystemInfoQuery.used_bytes.

TOTAL_NODES 4

Requests FilesystemInfoQuery.total_nodes.

USED_NODES 8

Requests FilesystemInfoQuery.used_nodes.

FREE_SHARED_POOL_BYTES 16

Requests FilesystemInfoQuery.free_shared_pool_bytes.

FS_ID 32

Requests FilesystemInfoQuery.fs_id.

BLOCK_SIZE 64

Requests FilesystemInfoQuery.block_size.

MAX_NODE_NAME_SIZE 128

Requests FilesystemInfoQuery.max_node_name_size.

FS_TYPE 256

Requests FilesystemInfoQuery.fs_type.

NAME 512

Requests FilesystemInfoQuery.name.

DEVICE_PATH 1024

Requests FilesystemInfoQuery.device_path.

CONSTANTS

NameValueTypeDescription
MAX_FS_NAME_LENGTH 32 uint64

The maximum length of the name of a filesystem.