Move parser of HDIO_* ioctls to a separate file

* hdio.c: New file.
* Makefile.am (strace_SOURCES): Add it.
* block.c: Do not include <linux/hdreg.h>.
(block_ioctl): Move parser of HDIO_GETGEO to hdio.c.
* defs.h (hdio_ioctl): New prototype.
* ioctl.c (ioctl_decode): Call hdio_ioctl for ioctl type 0x03.
5 files changed
tree: 014551f01e5f5bf8db00fe76208fadc7331da8a2
  1. debian/
  2. linux/
  3. m4/
  4. maint/
  5. qemu_multiarch_testing/
  6. test/
  7. tests/
  8. xlat/
  9. .gitignore
  10. .mailmap
  11. .travis.yml
  12. access.c
  13. affinity.c
  14. aio.c
  15. alpha.c
  16. AUTHORS
  17. bjm.c
  18. block.c
  19. bootstrap
  20. bpf.c
  21. btrfs.c
  22. build_static_example.sh
  23. cacheflush.c
  24. capability.c
  25. caps0.h
  26. caps1.h
  27. ChangeLog-CVS
  28. chdir.c
  29. chmod.c
  30. clone.c
  31. configure.ac
  32. copy_file_range.c
  33. COPYING
  34. count.c
  35. CREDITS.in
  36. defs.h
  37. desc.c
  38. dirent.c
  39. dirent64.c
  40. empty.h
  41. epoll.c
  42. errnoent.sh
  43. evdev.c
  44. eventfd.c
  45. execve.c
  46. exit.c
  47. fadvise.c
  48. fallocate.c
  49. fanotify.c
  50. fchownat.c
  51. fcntl.c
  52. fetch_seccomp_fprog.c
  53. fetch_struct_flock.c
  54. fetch_struct_statfs.c
  55. file.c
  56. file_handle.c
  57. file_ioctl.c
  58. flock.c
  59. flock.h
  60. fstatfs.c
  61. fstatfs64.c
  62. futex.c
  63. gcc_compat.h
  64. generate_mpers_am.sh
  65. generate_sen.sh
  66. generate_xlat_in.sh
  67. get_robust_list.c
  68. getcpu.c
  69. getcwd.c
  70. getrandom.c
  71. git-set-file-times
  72. git-version-gen
  73. gitlog-to-changelog
  74. HACKING-scripts
  75. hdio.c
  76. hostname.c
  77. inotify.c
  78. INSTALL
  79. io.c
  80. ioctl.c
  81. ioctlsort.c
  82. ioperm.c
  83. iopl.c
  84. ioprio.c
  85. ipc_defs.h
  86. ipc_msg.c
  87. ipc_msgctl.c
  88. ipc_sem.c
  89. ipc_shm.c
  90. ipc_shmctl.c
  91. kcmp.c
  92. kernel_types.h
  93. kexec.c
  94. keyctl.c
  95. ldt.c
  96. link.c
  97. lookup_dcookie.c
  98. loop.c
  99. lseek.c
  100. make-dist
  101. Makefile.am
  102. mem.c
  103. membarrier.c
  104. memfd_create.c
  105. mknod.c
  106. mount.c
  107. mpers.awk
  108. mpers.sh
  109. mpers_test.sh
  110. mpers_type.h
  111. mq.c
  112. mtd.c
  113. native_defs.h
  114. net.c
  115. NEWS
  116. numa.c
  117. open.c
  118. or1k_atomic.c
  119. pathtrace.c
  120. perf.c
  121. personality.c
  122. poll.c
  123. prctl.c
  124. print_mq_attr.c
  125. print_msgbuf.c
  126. print_sigevent.c
  127. print_statfs.c
  128. print_time.c
  129. print_timex.c
  130. printmode.c
  131. printrusage.c
  132. printsiginfo.c
  133. printsiginfo.h
  134. printstat.h
  135. process.c
  136. process_vm.c
  137. ptp.c
  138. ptrace.h
  139. quota.c
  140. readahead.c
  141. readlink.c
  142. README
  143. README-hacking
  144. README-linux-ptrace
  145. README-mpers
  146. README.md
  147. reboot.c
  148. regs.h
  149. renameat.c
  150. resource.c
  151. rtc.c
  152. sched.c
  153. scsi.c
  154. seccomp.c
  155. seccomp_fprog.h
  156. sendfile.c
  157. sigaltstack.c
  158. sigevent.h
  159. signal.c
  160. signalent.sh
  161. signalfd.c
  162. sigreturn.c
  163. sock.c
  164. socketutils.c
  165. sram_alloc.c
  166. statfs.c
  167. statfs.h
  168. statfs64.c
  169. strace-graph
  170. strace-log-merge
  171. strace.1
  172. strace.c
  173. strace.spec
  174. swapon.c
  175. sync_file_range.c
  176. sync_file_range2.c
  177. syscall.c
  178. syscallent.sh
  179. sysctl.c
  180. sysinfo.c
  181. syslog.c
  182. sysmips.c
  183. term.c
  184. time.c
  185. times.c
  186. travis-ci.sh
  187. truncate.c
  188. uid.c
  189. uid16.c
  190. umask.c
  191. umount.c
  192. uname.c
  193. unwind.c
  194. upeek.c
  195. userfaultfd.c
  196. util.c
  197. utime.c
  198. utimes.c
  199. v4l2.c
  200. vsprintf.c
  201. wait.c
  202. xattr.c
  203. xlat.h
  204. xlate.el
  205. xmalloc.c
README.md

This is strace -- a diagnostic, debugging and instructional userspace utility for Linux. It is used to monitor interactions between processes and the Linux kernel, which include system calls, signal deliveries, and changes of process state. The operation of strace is made possible by the kernel feature known as ptrace.

strace is released under a Berkeley-style license at the request of Paul Kranenburg; see the file COPYING for details.

See the file NEWS for information on what has changed in recent versions.

Please send bug reports and enhancements to the strace mailing list.

Build Status Code Coverage