Debian Codegraph @

upstream/debian-trixie/man2/ioctl_fat.2

raw
1 .\" Copyright 2014, Heinrich Schuchardt <[email protected]>
2 .\" Copyright 2024, Alejandro Colomar <[email protected]>
3 .\"
4 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
5 .\"
6 .TH ioctl_fat 2 2024-06-14 "Linux man-pages 6.9.1"
7 .SH NAME
8 ioctl_fat \- manipulating the FAT filesystem
9 .SH LIBRARY
10 Standard C library
11 .RI ( libc ", " \-lc )
12 .SH SYNOPSIS
13 .nf
14 .B #include <sys/ioctl.h>
15 .P
16 .BI "int ioctl(int " fd ", unsigned long " op ", ...);"
17 .fi
18 .SH DESCRIPTION
19 The
20 .BR ioctl (2)
21 system call can be used to read and write metadata of FAT filesystems that
22 are not accessible using other system calls.
23 The following
24 .I op
25 values are available.
26 .SS Reading and setting file attributes
27 .TP
28 .BR FAT_IOCTL_GET_ATTRIBUTES (2const)
29 .TQ
30 .BR FAT_IOCTL_SET_ATTRIBUTES (2const)
31 .SS Reading the volume ID
32 .TP
33 .BR FAT_IOCTL_GET_VOLUME_ID (2const)
34 .SS Reading short filenames of a directory
35 .TP
36 .BR VFAT_IOCTL_READDIR_BOTH (2const)
37 .TQ
38 .BR VFAT_IOCTL_READDIR_SHORT (2const)
39 .SH RETURN VALUE
40 On success,
41 a nonnegative value is returned.
42 On error, \-1 is returned, and
43 .I errno
44 is set to indicate the error.
45 .SH ERRORS
46 .TP
47 .B ENOTTY
48 The file descriptor
49 .I fd
50 does not refer to an object in a FAT filesystem.
51 .SH STANDARDS
52 Linux.
53 .SH SEE ALSO
54 .BR ioctl (2)