[PATCH v4 0/2] Add decoders for WDIOC_GETSUPPORT and WDIOC_SETOPTIONS

Sahil Siddiq icegambit91 at gmail.com
Sun Aug 25 18:30:00 UTC 2024


Hi,

This patch series incorporates minor logical changes, code
style changes and other miscellaneous changes as suggested
in the response to v3.

I have added the "Reviewed-by" tag in commit #2 even though
there's a minor change in the printf statement on line 102
in tests/ioctl_watchdog.c. To print the firmware version,
%x is now used as the format specifier preceded by "0x" in
place of %u.

Thanks,
Sahil

Changes v3 -> v4:
- Convert series to PATCH series.
- Add "Reviewed-by" tag in commit #2
- src/watchdog_ioctl.c:
  - (headers): Include watchdog_ioctl_flags.h
  - (WDIOC_GETSUPPORT):
    - Place tprint_arg_next() before return.
    - Check umove_or_printaddr() for non-zero return value.
    - Use PRINT_FIELD_X for firmware_version.
    - Code style changes.
- src/xlat/watchdog_ioctl_support_options.in: Rename to
  watchdog_ioctl_flags.in
- tests/ioctl_watchdog-success.c (firmware_version): Use %x instead of %u
  as format specifier.

Sahil Siddiq (2):
  watchdog_ioctl: Add decoding of WDIOC_GETSUPPORT and WDIOC_SETOPTIONS
    ioctls
  tests: Improve tests for watchdog ioctl commands

 NEWS                                  |   2 +
 src/watchdog_ioctl.c                  |  35 ++++++
 src/xlat/watchdog_ioctl_cmds.in       |   1 +
 src/xlat/watchdog_ioctl_flags.in      |  12 ++
 src/xlat/watchdog_ioctl_setoptions.in |   3 +
 tests/.gitignore                      |   2 +
 tests/Makefile.am                     |   2 +
 tests/gen_tests.in                    |   4 +-
 tests/ioctl_watchdog-success-v.c      |   2 +
 tests/ioctl_watchdog-success.c        |   2 +
 tests/ioctl_watchdog.c                | 154 ++++++++++++++++++++++----
 11 files changed, 196 insertions(+), 23 deletions(-)
 create mode 100644 src/xlat/watchdog_ioctl_flags.in
 create mode 100644 src/xlat/watchdog_ioctl_setoptions.in
 create mode 100644 tests/ioctl_watchdog-success-v.c
 create mode 100644 tests/ioctl_watchdog-success.c

-- 
2.46.0



More information about the Strace-devel mailing list