History log of /external/strace/btrfs.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
d35df493b4e7684c50d2d2fa032ee3a7ac228009 16-Feb-2017 Elliott Hughes <enh@google.com> Upgrade strace to 4.16 from 4.14.

Noteworthy changes in release 4.16 (2017-02-14)

* Improvements
* Implemented syscall return value injection (-e inject=SET:retval= option).
* Implemented signal injection (-e inject=SET:signal= option).
* Implemented decoding of SUID_DUMP_* constants in PR_[GS]ET_DUMPABLE.
* Implemented decoding of all SG_* ioctl commands.
* Implemented decoding of ustat syscall.
* Implemented decoding of BPF_OBJ_PIN, BPF_OBJ_GET, BPF_PROG_ATTACH,
and BPF_PROG_DETACH commands of bpf syscall.
* Enhanced decoding of sg_io_hdr and sg_io_v4 structures.
* Enhanced decoding of get_robust_list, getrandom, io_submit, set_robust_list
syscalls.
* Enhanced decoding of entities of kernel long type on x32 and mips n32 ABIs.
* Updated lists of IP_*, IPV6_*, and LOOP_* constants.
* Updated lists of ioctl commands from Linux 4.10.
* Added decoding of recently added syscalls on avr32, microblaze, ppc,
and ppc64.

* Bug fixes
* Fixed pathmatch of oldselect syscall on 64-bit architectures.
* Fixed decoding of mmap2 syscall on s390 when arguments are not available.
* Fixed decoding of kexec_file_load, mprotect, pkey_mprotect, prctl, preadv*,
and pwritev* syscalls on x32.
* Fixed printing of string arguments of getxattr and setxattr syscalls
when -s option is used to limit the printed string size.
* Fixed decoding of ifconf, ifreq, and loop_info structures on non-native
personalities.
* Fixed decoding of SG_* and LOOP_* ioctl commands.
* Fixed build on mips with musl libc.
* Fixed cross-building of ioctlsort.
* Applied minor formatting fixes to the manual page.

Noteworthy changes in release 4.15 (2016-12-14)

* Changes in behavior
* Time stamps are now printed according to ISO 8601.
* Changed output format of val3 parameter of futex FUTEX_WAKE_OP operation.
* The last argument of mincore, sched_getaffinity, and sched_setaffinity
syscalls is now formatted as an array.

* Improvements
* Implemented syscall fault injection (-e fault=... option).
* Implemented decoding of DM_* ioctl commands.
* Implemented decoding of attr parameter of perf_event_open syscall.
* Implemented decoding of pkey_alloc, pkey_free, and pkey_mprotect syscalls.
* Implemented dumping of mq_timedsend and mq_timedreceive syscalls.
* Implemented decoding of PR_SET_FP_MODE and PR_GET_FP_MODE operations
of prctl syscall.
* Implemented PTRACE_GETREGS API support on m68k.
* Updated lists of ARCH_*, BPF_*, BTRFS_*, FALLOC_*, MS_*, *_MAGIC,
and V4L2_* constants.
* Updated lists of ioctl commands from Linux 4.9.
* Added decoding of recently added syscalls on arc, x32, and xtensa.
* Enhanced manual page.

* Bug fixes
* Fixed corner cases in decoding of exit, exit_group, futimesat, getgroups,
getresuid, init_module, inotify_init1, kcmp, kexec_load, lookup_dcookie,
mq_getsetattr, mq_notify, mq_open, mq_timedreceive, mq_timedsend,
name_to_handle_at, prctl, process_vm_readv, process_vm_writev, setfsuid,
setgroups, setns, unshare, and utimes syscalls.
* Fixed handling of verbose flag in printing of controls array
of struct v4l2_ext_controls.
* Fixed omission of field names in the output of capability, sigaction,
sigevent, statfs, timespec, timeval, and utimbuf structures.
* Fixed printing of unknown syscalls in siginfo structure.
* Fixed decoding of ioctl constants on m68k.
* Fixed cris architecture support.
* Fixed cross build when host compiler does not support the same
set of warning flags as the cross compiler.
* Fixed build on SLE10 and SLE11.

Bug: N/A
Test: manual
Change-Id: I590bf5db1652aa1dfdc0eb16e30fd97c82af2261
/external/strace/btrfs.c
cce5aaef1e44c59063e8b3e99dc3045305a52f20 02-Oct-2016 Dmitry V. Levin <ldv@altlinux.org> Use tprints instead of tprintf in a few more places

* btrfs.c (btrfs_print_qgroup_inherit, btrfs_print_tree_search,
btrfs_ioctl): Replace tprintf with tprints for printing strings without
format specifiers.
* net.c (print_group_req): Likewise.
* scsi.c (scsi_ioctl): Likewise.
* term.c (decode_termios, decode_termio): Likewise.
* userfaultfd.c (uffdio_ioctl): Likewise.
/external/strace/btrfs.c
e7d3d645aeda3a8717f648dfe53c657075291b62 25-Aug-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs: mpersify struct btrfs_ioctl_vol_args_v2

This complements commit v4.11-719-gfb0c609.

* btrfs.c (struct_btrfs_ioctl_vol_args_v2): New type. Mpersify it.
(btrfs_print_qgroup_inherit): Change qgi_addr type to unsigned long.
(btrfs_ioctl): Replace struct btrfs_ioctl_vol_args_v2 with
struct_btrfs_ioctl_vol_args_v2.
/external/strace/btrfs.c
de5b0092a66394c28f62749ca2bf012d121ce128 26-Jul-2016 Dmitry V. Levin <ldv@altlinux.org> Fix one more code pattern that might break gcc strict aliasing rules

* btrfs.c (btrfs_ioctl): Add one more expicit cast to "void *",
to avoid breaking strict-aliasing rules reported by some gcc compilers.
* syscall.c (decode_socket_subcall): Likewise.
* util.c (next_set_bit): Likewise.
* tests/btrfs.c (btrfs_test_send_ioctl): Likewise.
/external/strace/btrfs.c
b759d276d53cbac1f60895c7e674b63f841f6d5d 15-Jul-2016 Dmitry V. Levin <ldv@altlinux.org> Unabuse struct tcb.auxstr

As we've got a proper mechanism that parsers can use for storing private
data between entering and exiting stages, all cases of struct tcb.auxstr
abuse should go.

* btrfs.c (btrfs_ioctl): Use set_tcb_priv_ulong and get_tcb_priv_ulong
instead of abusing tcp->auxstr.
* file_handle.c (SYS_FUNC(name_to_handle_at)): Likewise.
* msghdr.c (SYS_FUNC(recvmsg)): Likewise.
* net.c (decode_sockname, SYS_FUNC(recvfrom)): Likewise.
* v4l2.c (print_v4l2_queryctrl): Likewise.
/external/strace/btrfs.c
d4bdff69fcedb2e54c7fb251a0384a61776fc88b 17-Jun-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs: fix build with fresh linux/btrfs.h

Fix build with fresh <linux/btrfs.h> that provides a slightly different
definition of struct btrfs_ioctl_defrag_range_args.

* btrfs.c (btrfs_ioctl): Cast "len" member of
struct btrfs_ioctl_defrag_range_args to uint64_t.
* tests/btrfs.c (btrfs_print_defrag_range_args): Cast "start" and "len"
members of struct btrfs_ioctl_defrag_range_args to uint64_t.
/external/strace/btrfs.c
fe7a451e5accf78c16ac9e65381d257924b266ed 17-Jun-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs: provide fallback definitions for BTRFS_IOC_QUOTA_RESCAN*

<linux/btrfs.h> was introduced in linux v3.9-rc1 while some
of btrfs ioctls were added later, e.g. BTRFS_IOC_QUOTA_RESCAN
and BTRFS_IOC_QUOTA_RESCAN_STATUS in v3.10-rc2,
or BTRFS_IOC_QUOTA_RESCAN_WAIT in v3.11-rc1.

* btrfs.c [!BTRFS_IOC_QUOTA_RESCAN]
(struct btrfs_ioctl_quota_rescan_args): New structure.
(BTRFS_IOC_QUOTA_RESCAN, BTRFS_IOC_QUOTA_RESCAN_STATUS): New macros.
[!BTRFS_IOC_QUOTA_RESCAN_WAIT] (BTRFS_IOC_QUOTA_RESCAN_WAIT): New macro.
* tests/btrfs.c: Likewise.

Reported-by: Li Er <phoooyb@gmail.com>
/external/strace/btrfs.c
d32d95a87f33117d3717b015d8cc418bcf5d8907 27-May-2016 Jeff Mahoney <jeffm@suse.com> btrfs.c: don't use print_array in btrfs_print_tree_search

* btrfs.c (btrfs_print_tree_search): Don't use print_array. The buffer
represents a series of variable sized records, not an array.
/external/strace/btrfs.c
2060d973824354a3ed2f4dadf8b5326885db9445 27-May-2016 Jeff Mahoney <jeffm@suse.com> btrfs.c: fix print_array usage in btrfs_print_logical_ino_container

* btrfs.c: (btrfs_print_logical_ino_container) Fix the element count
to reflect the number of records rather than the number of items.
/external/strace/btrfs.c
ea516df85e2561f6708838c89dacbb4de86c0791 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: fix build on systems without BTRFS_IOC_FILE_EXTENT_SAME

* btrfs.c (btrfs_ioctl): Skip BTRFS_IOC_FILE_EXTENT_SAME case
if this constant is not defined.
* tests/btrfs.c (btrfs_test_extent_same_ioctl): Skip this part
of the test if BTRFS_IOC_FILE_EXTENT_SAME is not defined.
/external/strace/btrfs.c
6ce6d3be1035384096127542d0f391ec99767698 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: print file descriptors using printfd

* btrfs.c (btrfs_ioctl): Print struct btrfs_ioctl_send_args.send_fd,
struct btrfs_ioctl_vol_args.fd, and struct btrfs_ioctl_vol_args_v2.fd
using printfd.
* tests/btrfs.c (btrfs_print_vol_args_v2, btrfs_test_subvol_ioctls,
btrfs_test_device_ioctls, btrfs_test_clone_ioctls,
btrfs_test_send_ioctl): Update.
/external/strace/btrfs.c
fb0c6095f3d616bee402ab57885758f33163536b 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> Mpersify btrfs.c

* btrfs.c: Mpersify 3 arch-specific structures
and corresponding ioctl numbers.
(btrfs_ioctl): Mpersify.
* defs.h (btrfs_ioctl): Remove.
/external/strace/btrfs.c
d57cc26bf098d2a362a51fb26def39dec0bb4fd4 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: use print_array

* btrfs.c (print_btrfs_data_container_logical_ino,
print_btrfs_data_container_ino_path, print_uint64,
print_btrfs_ioctl_search_header, print_objectid_callback,
print_btrfs_ioctl_space_info): New functions.
(btrfs_print_logical_ino_container, btrfs_print_ino_path_container):
Rewrite printers of struct btrfs_data_container.val array
using print_array.
(btrfs_print_qgroup_inherit): Rewrite printer of
struct btrfs_qgroup_inherit.qgroups array using print_array.
(btrfs_print_tree_search): Rewrite printer of
struct btrfs_ioctl_search_header array using print_array.
(btrfs_ioctl): Rewrite printer of
struct btrfs_ioctl_send_args.clone_sources and
struct btrfs_ioctl_space_args.spaces using print_array.
/external/strace/btrfs.c
82b9e34e7c844c54484f8169c79e737528188b73 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: simplify BTRFS_IOC_GET_FSLABEL parser

* btrfs.c (btrfs_ioctl): Share code of parser of BTRFS_IOC_SET_FSLABEL
with parser of BTRFS_IOC_GET_FSLABEL only on BTRFS_IOC_GET_FSLABEL's
entering.
/external/strace/btrfs.c
d67b2173a12cb9255465850263622606a2bea38a 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: fix BTRFS_IOC_TREE_SEARCH_V2 output

* btrfs.c (btrfs_ioctl): Fix BTRFS_IOC_TREE_SEARCH_V2 output
in case of EOVERFLOW and failed umove.
/external/strace/btrfs.c
6638a5d1324f6c82113884ac974ae41397bed7ed 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: cleanup use of tcp->auxstr

* btrfs.c (btrfs_ioctl): Reset tcp->auxstr only if it is set.
/external/strace/btrfs.c
92b90621cc225813c56221c2546cc4188e718a3a 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: cleanup struct btrfs_ioctl_get_dev_stats.nr_items check

* btrfs.c (btrfs_ioctl): Cleanup check of iterator of
btrfs_ioctl_get_dev_stats.values array.
/external/strace/btrfs.c
0cd7ea055278e6125d7be21efbd9b5e29cd512e0 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: do not use BTRFS_SUBVOL_NAME_MAX

* btrfs.c [BTRFS_SUBVOL_NAME_MAX]: Remove.
(btrfs_ioctl): Use sizeof(struct btrfs_ioctl_vol_args_v2.name)
instead of BTRFS_SUBVOL_NAME_MAX + 1.
/external/strace/btrfs.c
b85d09f316686f984a58631cb72c29a7459a0546 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: mark some function arguments as const

* btrfs.c (btrfs_print_balance_args, btrfs_print_features,
btrfs_print_qgroup_limit, btrfs_print_data_container_header,
btrfs_print_logical_ino_container, btrfs_print_ino_path_container,
btrfs_print_qgroup_inherit): Mark some function arguments as const.
/external/strace/btrfs.c
90ffbc79b01079329bf039b5f3c61f51fbaf8dc9 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: use umove instead of umoven

* btrfs.c: Use umove instead of umoven and umove_or_printaddr
instead of umoven_or_printaddr.
/external/strace/btrfs.c
3ce2dfcebb799dcf3d7e2d2e630c23a81b941d75 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: remove unused variable

* btrfs.c (btrfs_ioctl): Remove "ret" variable.
/external/strace/btrfs.c
95577cf9d342622d78d1a4e09c60ece7eaf61a4d 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: use printxval/printxval64 instead of printxvals

* btrfs.c (btrfs_ioctl): Do not call printxvals directly,
use printxval/printxval64 wrappers that do the right thing.
/external/strace/btrfs.c
2be39ec201873eea39037bbb61b04d33aeaa0a55 24-May-2016 Dmitry V. Levin <ldv@altlinux.org> btrfs.c: fix indentation

* btrfs.c: Fix indentation of preprocessor directives and print formats.
/external/strace/btrfs.c
8cc6962216d302525be2ba4575932061bb4abd15 19-May-2016 Jeff Mahoney <jeffm@suse.com> ioctl: add decoding support for btrfs ioctls

* btrfs.c: New file.
* file_ioctl.c: Likewise.
* Makefile.am (strace_SOURCES): Add them.
* configure.ac (AC_CHECK_HEADERS): Add linux/btrfs.h.
(AC_CHECK_MEMBERS): Add struct btrfs_ioctl_feature_flags.compat_flags,
struct btrfs_ioctl_fs_info_args.nodesize,
struct btrfs_ioctl_defrag_range_args.start,
and struct btrfs_ioctl_search_args_v2.buf_size.
(AC_CHECK_DECLS): Add BTRFS_COMPRESS_* enums.
* defs.h (btrfs_ioctl, file_ioctl): New prototypes.
* ioctl.c (ioctl_decode) [HAVE_LINUX_BTRFS_H]: Use btrfs_ioctl.
* xlat/btrfs_balance_args.in: New file.
* xlat/btrfs_balance_ctl_cmds.in: Likewise.
* xlat/btrfs_balance_flags.in: Likewise.
* xlat/btrfs_balance_state.in: Likewise.
* xlat/btrfs_compress_types.in: Likewise.
* xlat/btrfs_defrag_flags.in: Likewise.
* xlat/btrfs_dev_replace_cmds.in: Likewise.
* xlat/btrfs_dev_replace_results.in: Likewise.
* xlat/btrfs_dev_replace_state.in: Likewise.
* xlat/btrfs_dev_stats_flags.in: Likewise.
* xlat/btrfs_dev_stats_values.in: Likewise.
* xlat/btrfs_features_compat.in: Likewise.
* xlat/btrfs_features_compat_ro.in: Likewise.
* xlat/btrfs_features_incompat.in: Likewise.
* xlat/btrfs_key_types.in: Likewise.
* xlat/btrfs_qgroup_ctl_cmds.in: Likewise.
* xlat/btrfs_qgroup_inherit_flags.in: Likewise.
* xlat/btrfs_qgroup_limit_flags.in: Likewise.
* xlat/btrfs_qgroup_status_flags.in: Likewise.
* xlat/btrfs_scrub_flags.in: Likewise.
* xlat/btrfs_send_flags.in: Likewise.
* xlat/btrfs_snap_flags_v2.in: Likewise.
* xlat/btrfs_space_info_flags.in: Likewise.
* xlat/btrfs_tree_objectids.in: Likewise.
/external/strace/btrfs.c