History

Merge tag 'docs/v5.10-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media

Pull documentation updates from Mauro Carvalho Chehab: "A series of patches addressing warnings produced by make htmldocs. This includes: - kernel-doc markup fixes - ReST fixes - Updates at the build system in order to support newer versions of the docs build toolchain (Sphinx) After this series, the number of html build warnings should reduce significantly, and building with Sphinx 3.1 or later should now be supported (although it is still recommended to use Sphinx 2.4.4). As agreed with Jon, I should be sending you a late pull request by the end of the merge window addressing remaining issues with docs build, as there are a number of warning fixes that depends on pull requests that should be happening along the merge window. The end goal is to have a clean htmldocs build on Kernel 5.10. PS. It should be noticed that Sphinx 3.0 is not currently supported, as it lacks support for C domain namespaces. Such feature, needed in order to document uAPI system calls with Sphinx 3.x, was added only on Sphinx 3.1" * tag 'docs/v5.10-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (75 commits) PM / devfreq: remove a duplicated kernel-doc markup mm/doc: fix a literal block markup workqueue: fix a kernel-doc warning docs: virt: user_mode_linux_howto_v2.rst: fix a literal block markup Input: sparse-keymap: add a description for @sw rcu/tree: docs: document bkvcache new members at struct kfree_rcu_cpu nl80211: docs: add a description for s1g_cap parameter usb: docs: document altmode register/unregister functions kunit: test.h: fix a bad kernel-doc markup drivers: core: fix kernel-doc markup for dev_err_probe() docs: bio: fix a kerneldoc markup kunit: test.h: solve kernel-doc warnings block: bio: fix a warning at the kernel-doc markups docs: powerpc: syscall64-abi.rst: fix a malformed table drivers: net: hamradio: fix document location net: appletalk: Kconfig: Fix docs location dt-bindings: fix references to files converted to yaml memblock: get rid of a :c:type leftover math64.h: kernel-docs: Convert some markups into normal comments media: uAPI: buffer.rst: remove a left-over documentation ...

Linus Torvalds committed 6 years ago

Commit 54a4c782 parents 93f3d8f 3e2ac97309 files · +1952 −2275Browse files

Unified · Split

309 files
  1. Documentation/admin-guide/pm/cpufreq.rst +5 −6
  2. Documentation/admin-guide/pstore-blk.rst +2 −8
  3. Documentation/block/blk-mq.rst +6 −6
  4. Documentation/block/inline-encryption.rst +4 −4
  5. Documentation/conf.py +62 −3
  6. Documentation/core-api/genericirq.rst +2 −0
  7. Documentation/core-api/kernel-api.rst +0 −6
  8. Documentation/core-api/workqueue.rst +2 −0
  9. Documentation/dev-tools/kgdb.rst +3 −3
  10. Documentation/devicetree/bindings/display/tilcdc/tilcdc.txt +1 −1
  11. Documentation/devicetree/bindings/mailbox/omap-mailbox.txt +1 −1
  12. Documentation/devicetree/bindings/media/i2c/tvp5150.txt +1 −1
  13. Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml +1 −1
  14. Documentation/devicetree/bindings/soc/qcom/qcom,smd-rpm.yaml +1 −1
  15. Documentation/devicetree/bindings/sound/google,cros-ec-codec.yaml +1 −1
  16. Documentation/doc-guide/kernel-doc.rst +8 −0
  17. Documentation/driver-api/basics.rst +4 −15
  18. Documentation/driver-api/device_link.rst +4 −9
  19. Documentation/driver-api/fpga/fpga-bridge.rst +2 −2
  20. Documentation/driver-api/fpga/fpga-mgr.rst +3 −3
  21. Documentation/driver-api/fpga/fpga-programming.rst +1 −1
  22. Documentation/driver-api/fpga/fpga-region.rst +3 −3
  23. Documentation/driver-api/iio/buffers.rst +1 −1
  24. Documentation/driver-api/iio/core.rst +3 −3
  25. Documentation/driver-api/iio/hw-consumer.rst +1 −1
  26. Documentation/driver-api/iio/triggered-buffers.rst +1 −1
  27. Documentation/driver-api/iio/triggers.rst +2 −2
  28. Documentation/driver-api/index.rst +0 −1
  29. Documentation/driver-api/infrastructure.rst +1 −3
  30. Documentation/driver-api/libata.rst +1 −1
  31. Documentation/driver-api/media/cec-core.rst +1 −1
  32. Documentation/driver-api/media/dtv-frontend.rst +2 −2
  33. Documentation/driver-api/media/mc-core.rst +12 −12
  34. Documentation/driver-api/media/v4l2-controls.rst +1 −1
  35. Documentation/driver-api/media/v4l2-dev.rst +4 −4
  36. Documentation/driver-api/media/v4l2-device.rst +3 −3
  37. Documentation/driver-api/media/v4l2-event.rst +5 −5
  38. Documentation/driver-api/media/v4l2-fh.rst +8 −8
  39. Documentation/driver-api/media/v4l2-subdev.rst +1 −1
  40. Documentation/driver-api/mei/mei.rst +1 −1
  41. Documentation/driver-api/pm/cpuidle.rst +30 −35
  42. Documentation/driver-api/pm/devices.rst +9 −17
  43. Documentation/driver-api/regulator.rst +2 −2
  44. Documentation/driver-api/sound.rst +0 −54
  45. Documentation/driver-api/target.rst +0 −12
  46. Documentation/driver-api/usb/URB.rst +1 −1
  47. Documentation/driver-api/usb/gadget.rst +5 −5
  48. Documentation/driver-api/usb/hotplug.rst +1 −1
  49. Documentation/driver-api/usb/typec_bus.rst +7 −1
  50. Documentation/filesystems/fscrypt.rst +36 −38
  51. Documentation/filesystems/fsverity.rst +1 −1
  52. Documentation/gpu/i915.rst +25 −4
  53. Documentation/networking/ieee802154.rst +10 −8
  54. Documentation/powerpc/syscall64-abi.rst +16 −16
  55. Documentation/sound/designs/tracepoints.rst +11 −11
  56. Documentation/sound/kernel-api/alsa-driver-api.rst +1 −0
  57. Documentation/sound/kernel-api/writing-an-alsa-driver.rst +49 −61
  58. Documentation/sphinx/automarkup.py +97 −11
  59. Documentation/sphinx/cdomain.py +92 −1
  60. Documentation/sphinx/kerneldoc.py +14 −1
  61. Documentation/sphinx/parse-headers.pl +1 −1
  62. Documentation/trace/ftrace-uses.rst +6 −6
  63. Documentation/translations/it_IT/kernel-hacking/hacking.rst +1 −1
  64. Documentation/translations/it_IT/kernel-hacking/locking.rst +2 −0
  65. Documentation/translations/zh_CN/arm64/amu.rst +2 −2
  66. Documentation/userspace-api/media/cec/cec-func-close.rst +3 −7
  67. Documentation/userspace-api/media/cec/cec-func-ioctl.rst +4 −7
  68. Documentation/userspace-api/media/cec/cec-func-open.rst +3 −7
  69. Documentation/userspace-api/media/cec/cec-func-poll.rst +5 −9
  70. Documentation/userspace-api/media/cec/cec-ioc-adap-g-caps.rst +5 −5
  71. Documentation/userspace-api/media/cec/cec-ioc-adap-g-conn-info.rst +6 −5
  72. Documentation/userspace-api/media/cec/cec-ioc-adap-g-log-addrs.rst +8 −12
  73. Documentation/userspace-api/media/cec/cec-ioc-adap-g-phys-addr.rst +8 −7
  74. Documentation/userspace-api/media/cec/cec-ioc-dqevent.rst +5 −10
  75. Documentation/userspace-api/media/cec/cec-ioc-g-mode.rst +8 −8
  76. Documentation/userspace-api/media/cec/cec-ioc-receive.rst +8 −10
  77. Documentation/userspace-api/media/dvb/audio-bilingual-channel-select.rst +3 −4
  78. Documentation/userspace-api/media/dvb/audio-channel-select.rst +3 −5
  79. Documentation/userspace-api/media/dvb/audio-clear-buffer.rst +4 −4
  80. Documentation/userspace-api/media/dvb/audio-continue.rst +3 −4
  81. Documentation/userspace-api/media/dvb/audio-fclose.rst +1 −6
  82. Documentation/userspace-api/media/dvb/audio-fopen.rst +1 −6
  83. Documentation/userspace-api/media/dvb/audio-fwrite.rst +1 −6
  84. Documentation/userspace-api/media/dvb/audio-get-capabilities.rst +3 −5
  85. Documentation/userspace-api/media/dvb/audio-get-status.rst +3 −5
  86. Documentation/userspace-api/media/dvb/audio-pause.rst +4 −5
  87. Documentation/userspace-api/media/dvb/audio-play.rst +3 −4
  88. Documentation/userspace-api/media/dvb/audio-select-source.rst +3 −5
  89. Documentation/userspace-api/media/dvb/audio-set-av-sync.rst +3 −5
  90. Documentation/userspace-api/media/dvb/audio-set-bypass-mode.rst +4 −5
  91. Documentation/userspace-api/media/dvb/audio-set-id.rst +4 −5
  92. Documentation/userspace-api/media/dvb/audio-set-mixer.rst +4 −5
  93. Documentation/userspace-api/media/dvb/audio-set-mute.rst +3 −5
  94. Documentation/userspace-api/media/dvb/audio-set-streamtype.rst +3 −7
  95. Documentation/userspace-api/media/dvb/audio-stop.rst +4 −5
  96. Documentation/userspace-api/media/dvb/ca-fclose.rst +2 −5
  97. Documentation/userspace-api/media/dvb/ca-fopen.rst +1 −6
  98. Documentation/userspace-api/media/dvb/ca-get-cap.rst +4 −4
  99. Documentation/userspace-api/media/dvb/ca-get-descr-info.rst +5 −4
  100. Documentation/userspace-api/media/dvb/ca-get-msg.rst +4 −6
  101. Documentation/userspace-api/media/dvb/ca-get-slot-info.rst +4 −5
  102. Documentation/userspace-api/media/dvb/ca-reset.rst +4 −5
  103. Documentation/userspace-api/media/dvb/ca-send-msg.rst +4 −5
  104. Documentation/userspace-api/media/dvb/ca-set-descr.rst +4 −4
  105. Documentation/userspace-api/media/dvb/dmx-add-pid.rst +4 −6
  106. Documentation/userspace-api/media/dvb/dmx-expbuf.rst +4 −7
  107. Documentation/userspace-api/media/dvb/dmx-fclose.rst +3 −6
  108. Documentation/userspace-api/media/dvb/dmx-fopen.rst +1 −4
  109. Documentation/userspace-api/media/dvb/dmx-fread.rst +2 −5
  110. Documentation/userspace-api/media/dvb/dmx-fwrite.rst +2 −4
  111. Documentation/userspace-api/media/dvb/dmx-get-pes-pids.rst +5 −7
  112. Documentation/userspace-api/media/dvb/dmx-get-stc.rst +5 −7
  113. Documentation/userspace-api/media/dvb/dmx-mmap.rst +6 −9
  114. Documentation/userspace-api/media/dvb/dmx-munmap.rst +5 −9
  115. Documentation/userspace-api/media/dvb/dmx-qbuf.rst +8 −9
  116. Documentation/userspace-api/media/dvb/dmx-querybuf.rst +4 −5
  117. Documentation/userspace-api/media/dvb/dmx-remove-pid.rst +4 −6
  118. Documentation/userspace-api/media/dvb/dmx-reqbufs.rst +4 −5
  119. Documentation/userspace-api/media/dvb/dmx-set-buffer-size.rst +4 −6
  120. Documentation/userspace-api/media/dvb/dmx-set-filter.rst +5 −7
  121. Documentation/userspace-api/media/dvb/dmx-set-pes-filter.rst +4 −9
  122. Documentation/userspace-api/media/dvb/dmx-start.rst +4 −7
  123. Documentation/userspace-api/media/dvb/dmx-stop.rst +4 −5
  124. Documentation/userspace-api/media/dvb/fe-diseqc-recv-slave-reply.rst +4 −5
  125. Documentation/userspace-api/media/dvb/fe-diseqc-reset-overload.rst +4 −5
  126. Documentation/userspace-api/media/dvb/fe-diseqc-send-burst.rst +4 −6
  127. Documentation/userspace-api/media/dvb/fe-diseqc-send-master-cmd.rst +4 −5
  128. Documentation/userspace-api/media/dvb/fe-dishnetwork-send-legacy-cmd.rst +4 −6
  129. Documentation/userspace-api/media/dvb/fe-enable-high-lnb-voltage.rst +4 −6
  130. Documentation/userspace-api/media/dvb/fe-get-event.rst +4 −8
  131. Documentation/userspace-api/media/dvb/fe-get-frontend.rst +4 −8
  132. Documentation/userspace-api/media/dvb/fe-get-info.rst +4 −7
  133. Documentation/userspace-api/media/dvb/fe-get-property.rst +7 −8
  134. Documentation/userspace-api/media/dvb/fe-read-ber.rst +4 −5
  135. Documentation/userspace-api/media/dvb/fe-read-signal-strength.rst +4 −5
  136. Documentation/userspace-api/media/dvb/fe-read-snr.rst +4 −5
  137. Documentation/userspace-api/media/dvb/fe-read-status.rst +4 −7
  138. Documentation/userspace-api/media/dvb/fe-read-uncorrected-blocks.rst +4 −5
  139. Documentation/userspace-api/media/dvb/fe-set-frontend-tune-mode.rst +4 −6
  140. Documentation/userspace-api/media/dvb/fe-set-frontend.rst +4 −7
  141. Documentation/userspace-api/media/dvb/fe-set-tone.rst +4 −6
  142. Documentation/userspace-api/media/dvb/fe-set-voltage.rst +4 −6
  143. Documentation/userspace-api/media/dvb/frontend_f_close.rst +2 −6
  144. Documentation/userspace-api/media/dvb/frontend_f_open.rst +2 −8
  145. Documentation/userspace-api/media/dvb/net-add-if.rst +4 −5
  146. Documentation/userspace-api/media/dvb/net-get-if.rst +4 −6
  147. Documentation/userspace-api/media/dvb/net-remove-if.rst +4 −6
  148. Documentation/userspace-api/media/dvb/video-clear-buffer.rst +3 −5
  149. Documentation/userspace-api/media/dvb/video-command.rst +4 −6
  150. Documentation/userspace-api/media/dvb/video-continue.rst +3 −5
  151. Documentation/userspace-api/media/dvb/video-fast-forward.rst +3 −7
  152. Documentation/userspace-api/media/dvb/video-fclose.rst +1 −5
  153. Documentation/userspace-api/media/dvb/video-fopen.rst +1 −5
  154. Documentation/userspace-api/media/dvb/video-freeze.rst +3 −5
  155. Documentation/userspace-api/media/dvb/video-fwrite.rst +1 −5
  156. Documentation/userspace-api/media/dvb/video-get-capabilities.rst +3 −5
  157. Documentation/userspace-api/media/dvb/video-get-event.rst +3 −5
  158. Documentation/userspace-api/media/dvb/video-get-frame-count.rst +3 −5
  159. Documentation/userspace-api/media/dvb/video-get-pts.rst +3 −5
  160. Documentation/userspace-api/media/dvb/video-get-size.rst +3 −5
  161. Documentation/userspace-api/media/dvb/video-get-status.rst +3 −4
  162. Documentation/userspace-api/media/dvb/video-play.rst +3 −5
  163. Documentation/userspace-api/media/dvb/video-select-source.rst +3 −4
  164. Documentation/userspace-api/media/dvb/video-set-blank.rst +3 −5
  165. Documentation/userspace-api/media/dvb/video-set-display-format.rst +3 −5
  166. Documentation/userspace-api/media/dvb/video-set-format.rst +3 −6
  167. Documentation/userspace-api/media/dvb/video-set-streamtype.rst +3 −5
  168. Documentation/userspace-api/media/dvb/video-slowmotion.rst +3 −7
  169. Documentation/userspace-api/media/dvb/video-stillpicture.rst +3 −5
  170. Documentation/userspace-api/media/dvb/video-stop.rst +3 −5
  171. Documentation/userspace-api/media/dvb/video-try-command.rst +3 −5
  172. Documentation/userspace-api/media/mediactl/media-func-close.rst +3 −7
  173. Documentation/userspace-api/media/mediactl/media-func-ioctl.rst +3 −7
  174. Documentation/userspace-api/media/mediactl/media-func-open.rst +3 −7
  175. Documentation/userspace-api/media/mediactl/media-ioc-device-info.rst +4 −9
  176. Documentation/userspace-api/media/mediactl/media-ioc-enum-entities.rst +4 −7
  177. Documentation/userspace-api/media/mediactl/media-ioc-enum-links.rst +4 −9
  178. Documentation/userspace-api/media/mediactl/media-ioc-g-topology.rst +4 −10
  179. Documentation/userspace-api/media/mediactl/media-ioc-request-alloc.rst +5 −6
  180. Documentation/userspace-api/media/mediactl/media-ioc-setup-link.rst +4 −6
  181. Documentation/userspace-api/media/mediactl/media-request-ioc-queue.rst +3 −4
  182. Documentation/userspace-api/media/mediactl/media-request-ioc-reinit.rst +4 −4
  183. Documentation/userspace-api/media/mediactl/request-api.rst +3 −2
  184. Documentation/userspace-api/media/mediactl/request-func-close.rst +2 −6
  185. Documentation/userspace-api/media/mediactl/request-func-ioctl.rst +2 −6
  186. Documentation/userspace-api/media/mediactl/request-func-poll.rst +4 −8
  187. Documentation/userspace-api/media/rc/lirc-get-features.rst +4 −5
  188. Documentation/userspace-api/media/rc/lirc-get-rec-mode.rst +7 −5
  189. Documentation/userspace-api/media/rc/lirc-get-rec-resolution.rst +4 −4
  190. Documentation/userspace-api/media/rc/lirc-get-send-mode.rst +7 −7
  191. Documentation/userspace-api/media/rc/lirc-get-timeout.rst +7 −6
  192. Documentation/userspace-api/media/rc/lirc-read.rst +3 −7
  193. Documentation/userspace-api/media/rc/lirc-set-measure-carrier-mode.rst +4 −4
  194. Documentation/userspace-api/media/rc/lirc-set-rec-carrier-range.rst +4 −2
  195. Documentation/userspace-api/media/rc/lirc-set-rec-carrier.rst +4 −4
  196. Documentation/userspace-api/media/rc/lirc-set-rec-timeout-reports.rst +4 −4
  197. Documentation/userspace-api/media/rc/lirc-set-rec-timeout.rst +7 −6
  198. Documentation/userspace-api/media/rc/lirc-set-send-carrier.rst +4 −4
  199. Documentation/userspace-api/media/rc/lirc-set-send-duty-cycle.rst +4 −4
  200. Documentation/userspace-api/media/rc/lirc-set-transmitter-mask.rst +4 −4
  201. Documentation/userspace-api/media/rc/lirc-set-wideband-receiver.rst +4 −4
  202. Documentation/userspace-api/media/rc/lirc-write.rst +2 −5
  203. Documentation/userspace-api/media/v4l/buffer.rst +3 −25
  204. Documentation/userspace-api/media/v4l/dev-capture.rst +2 −5
  205. Documentation/userspace-api/media/v4l/dev-output.rst +2 −5
  206. Documentation/userspace-api/media/v4l/dev-raw-vbi.rst +6 −13
  207. Documentation/userspace-api/media/v4l/dev-rds.rst +3 −9
  208. Documentation/userspace-api/media/v4l/dev-sliced-vbi.rst +7 −24
  209. Documentation/userspace-api/media/v4l/diff-v4l.rst +6 −33
  210. Documentation/userspace-api/media/v4l/dmabuf.rst +4 −4
  211. Documentation/userspace-api/media/v4l/format.rst +3 −4
  212. Documentation/userspace-api/media/v4l/func-close.rst +2 −6
  213. Documentation/userspace-api/media/v4l/func-ioctl.rst +3 −7
  214. Documentation/userspace-api/media/v4l/func-mmap.rst +7 −11
  215. Documentation/userspace-api/media/v4l/func-munmap.rst +5 −9
  216. Documentation/userspace-api/media/v4l/func-open.rst +5 −9
  217. Documentation/userspace-api/media/v4l/func-poll.rst +18 −22
  218. Documentation/userspace-api/media/v4l/func-read.rst +18 −21
  219. Documentation/userspace-api/media/v4l/func-select.rst +19 −23
  220. Documentation/userspace-api/media/v4l/func-write.rst +5 −8
  221. Documentation/userspace-api/media/v4l/hist-v4l2.rst +4 −66
  222. Documentation/userspace-api/media/v4l/io.rst +3 −3
  223. Documentation/userspace-api/media/v4l/libv4l-introduction.rst +13 −17
  224. Documentation/userspace-api/media/v4l/mmap.rst +13 −13
  225. Documentation/userspace-api/media/v4l/open.rst +6 −9
  226. Documentation/userspace-api/media/v4l/rw.rst +9 −9
  227. Documentation/userspace-api/media/v4l/streaming-par.rst +3 −2
  228. Documentation/userspace-api/media/v4l/userp.rst +6 −5
  229. Documentation/userspace-api/media/v4l/vidioc-create-bufs.rst +4 −7
  230. Documentation/userspace-api/media/v4l/vidioc-cropcap.rst +4 −7
  231. Documentation/userspace-api/media/v4l/vidioc-dbg-g-chip-info.rst +4 −9
  232. Documentation/userspace-api/media/v4l/vidioc-dbg-g-register.rst +7 −11
  233. Documentation/userspace-api/media/v4l/vidioc-decoder-cmd.rst +8 −11
  234. Documentation/userspace-api/media/v4l/vidioc-dqevent.rst +4 −15
  235. Documentation/userspace-api/media/v4l/vidioc-dv-timings-cap.rst +7 −10
  236. Documentation/userspace-api/media/v4l/vidioc-encoder-cmd.rst +11 −14
  237. Documentation/userspace-api/media/v4l/vidioc-enum-dv-timings.rst +7 −9
  238. Documentation/userspace-api/media/v4l/vidioc-enum-fmt.rst +4 −8
  239. Documentation/userspace-api/media/v4l/vidioc-enum-frameintervals.rst +4 −11
  240. Documentation/userspace-api/media/v4l/vidioc-enum-framesizes.rst +4 −12
  241. Documentation/userspace-api/media/v4l/vidioc-enum-freq-bands.rst +4 −8
  242. Documentation/userspace-api/media/v4l/vidioc-enumaudio.rst +4 −6
  243. Documentation/userspace-api/media/v4l/vidioc-enumaudioout.rst +4 −6
  244. Documentation/userspace-api/media/v4l/vidioc-enuminput.rst +4 −10
  245. Documentation/userspace-api/media/v4l/vidioc-enumoutput.rst +4 −9
  246. Documentation/userspace-api/media/v4l/vidioc-enumstd.rst +7 −16
  247. Documentation/userspace-api/media/v4l/vidioc-expbuf.rst +4 −10
  248. Documentation/userspace-api/media/v4l/vidioc-g-audio.rst +7 −11
  249. Documentation/userspace-api/media/v4l/vidioc-g-audioout.rst +7 −9
  250. Documentation/userspace-api/media/v4l/vidioc-g-crop.rst +7 −9
  251. Documentation/userspace-api/media/v4l/vidioc-g-ctrl.rst +7 −9
  252. Documentation/userspace-api/media/v4l/vidioc-g-dv-timings.rst +13 −13
  253. Documentation/userspace-api/media/v4l/vidioc-g-edid.rst +12 −13
  254. Documentation/userspace-api/media/v4l/vidioc-g-enc-index.rst +4 −9
  255. Documentation/userspace-api/media/v4l/vidioc-g-ext-ctrls.rst +8 −13
  256. Documentation/userspace-api/media/v4l/vidioc-g-fbuf.rst +7 −11
  257. Documentation/userspace-api/media/v4l/vidioc-g-fmt.rst +11 −11
  258. Documentation/userspace-api/media/v4l/vidioc-g-frequency.rst +7 −9
  259. Documentation/userspace-api/media/v4l/vidioc-g-input.rst +7 −8
  260. Documentation/userspace-api/media/v4l/vidioc-g-jpegcomp.rst +7 −10
  261. Documentation/userspace-api/media/v4l/vidioc-g-modulator.rst +7 −10
  262. Documentation/userspace-api/media/v4l/vidioc-g-output.rst +7 −8
  263. Documentation/userspace-api/media/v4l/vidioc-g-parm.rst +12 −18
  264. Documentation/userspace-api/media/v4l/vidioc-g-priority.rst +7 −9
  265. Documentation/userspace-api/media/v4l/vidioc-g-selection.rst +6 −9
  266. Documentation/userspace-api/media/v4l/vidioc-g-sliced-vbi-cap.rst +4 −8
  267. Documentation/userspace-api/media/v4l/vidioc-g-std.rst +13 −11
  268. Documentation/userspace-api/media/v4l/vidioc-g-tuner.rst +7 −12
  269. Documentation/userspace-api/media/v4l/vidioc-log-status.rst +4 −6
  270. Documentation/userspace-api/media/v4l/vidioc-overlay.rst +4 −6
  271. Documentation/userspace-api/media/v4l/vidioc-prepare-buf.rst +4 −6
  272. Documentation/userspace-api/media/v4l/vidioc-qbuf.rst +8 −9
  273. Documentation/userspace-api/media/v4l/vidioc-query-dv-timings.rst +7 −8
  274. Documentation/userspace-api/media/v4l/vidioc-querybuf.rst +4 −6
  275. Documentation/userspace-api/media/v4l/vidioc-querycap.rst +6 −10
  276. Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst +8 −14
  277. Documentation/userspace-api/media/v4l/vidioc-querystd.rst +7 −8
  278. Documentation/userspace-api/media/v4l/vidioc-reqbufs.rst +4 −6
  279. Documentation/userspace-api/media/v4l/vidioc-s-hw-freq-seek.rst +4 −7
  280. Documentation/userspace-api/media/v4l/vidioc-streamon.rst +7 −7
  281. Documentation/userspace-api/media/v4l/vidioc-subdev-enum-frame-interval.rst +4 −6
  282. Documentation/userspace-api/media/v4l/vidioc-subdev-enum-frame-size.rst +4 −7
  283. Documentation/userspace-api/media/v4l/vidioc-subdev-enum-mbus-code.rst +4 −6
  284. Documentation/userspace-api/media/v4l/vidioc-subdev-g-crop.rst +7 −9
  285. Documentation/userspace-api/media/v4l/vidioc-subdev-g-fmt.rst +7 −10
  286. Documentation/userspace-api/media/v4l/vidioc-subdev-g-frame-interval.rst +7 −9
  287. Documentation/userspace-api/media/v4l/vidioc-subdev-g-selection.rst +7 −10
  288. Documentation/userspace-api/media/v4l/vidioc-subdev-querycap.rst +4 −5
  289. Documentation/userspace-api/media/v4l/vidioc-subscribe-event.rst +7 −10
  290. Documentation/virt/uml/user_mode_linux_howto_v2.rst +1 −0
  291. Documentation/vm/hmm.rst +1 −1
  292. Documentation/vm/ksm.rst +1 −1
  293. Documentation/vm/memory-model.rst +3 −3
  294. MAINTAINERS +8 −8
  295. block/bio.c +2 −2
  296. drivers/base/core.c +5 −2
  297. drivers/net/appletalk/Kconfig +1 −1
  298. drivers/net/hamradio/scc.c +1 −1
  299. include/kunit/test.h +9 −5
  300. include/linux/devfreq.h +1 −6
  301. include/linux/input/sparse-keymap.h +1 −0
  302. include/linux/math64.h +4 −4
  303. include/linux/usb/typec_altmode.h +16 −0
  304. include/net/cfg80211.h +1 −0
  305. kernel/rcu/tree.c +6 −8
  306. kernel/workqueue.c +3 −0
  307. mm/ksm.c +1 −1
  308. mm/memblock.c +4 −4
  309. scripts/kernel-doc +223 −82
Documentation/admin-guide/pm/cpufreq.rst+5−6
@@ -1,7 +1,6 @@
1.. SPDX-License-Identifier: GPL-2.01.. SPDX-License-Identifier: GPL-2.0
2.. include:: <isonum.txt>2.. include:: <isonum.txt>
3 3
4.. |struct cpufreq_policy| replace:: :c:type:`struct cpufreq_policy <cpufreq_policy>`
5.. |intel_pstate| replace:: :doc:`intel_pstate <intel_pstate>`4.. |intel_pstate| replace:: :doc:`intel_pstate <intel_pstate>`
6 5
7=======================6=======================
@@ -92,16 +91,16 @@ control the P-state of multiple CPUs at the same time and writing to it affects · 84 unmodified lines
92all of those CPUs simultaneously.91all of those CPUs simultaneously.
93 92
94Sets of CPUs sharing hardware P-state control interfaces are represented by93Sets of CPUs sharing hardware P-state control interfaces are represented by
95``CPUFreq`` as |struct cpufreq_policy| objects. For consistency,94``CPUFreq`` as struct cpufreq_policy objects. For consistency,
96|struct cpufreq_policy| is also used when there is only one CPU in the given95struct cpufreq_policy is also used when there is only one CPU in the given
97set.96set.
98 97
99The ``CPUFreq`` core maintains a pointer to a |struct cpufreq_policy| object for98The ``CPUFreq`` core maintains a pointer to a struct cpufreq_policy object for
100every CPU in the system, including CPUs that are currently offline. If multiple99every CPU in the system, including CPUs that are currently offline. If multiple
101CPUs share the same hardware P-state control interface, all of the pointers100CPUs share the same hardware P-state control interface, all of the pointers
102corresponding to them point to the same |struct cpufreq_policy| object.101corresponding to them point to the same struct cpufreq_policy object.
103 102
104``CPUFreq`` uses |struct cpufreq_policy| as its basic data type and the design103``CPUFreq`` uses struct cpufreq_policy as its basic data type and the design
105of its user space interface is based on the policy concept.104of its user space interface is based on the policy concept.
106 105
107 106
Documentation/admin-guide/pstore-blk.rst+2−8
@@ -154,17 +154,11 @@ Configurations for driver · 153 unmodified lines
154Only a block device driver cares about these configurations. A block device154Only a block device driver cares about these configurations. A block device
155driver uses ``register_pstore_blk`` to register to pstore/blk.155driver uses ``register_pstore_blk`` to register to pstore/blk.
156 156
157.. kernel-doc:: fs/pstore/blk.c
158 :identifiers: register_pstore_blk
159
160A non-block device driver uses ``register_pstore_device`` with157A non-block device driver uses ``register_pstore_device`` with
161``struct pstore_device_info`` to register to pstore/blk.158``struct pstore_device_info`` to register to pstore/blk.
162 159
163.. kernel-doc:: fs/pstore/blk.c160.. kernel-doc:: fs/pstore/blk.c
164 :identifiers: register_pstore_device161 :export:
165
166.. kernel-doc:: include/linux/pstore_blk.h
167 :identifiers: pstore_device_info
168 162
169Compression and header163Compression and header
170----------------------164----------------------
@@ -237,7 +231,7 @@ For developer reference, here are all the important structures and APIs: · 66 unmodified lines
237 :internal:231 :internal:
238 232
239.. kernel-doc:: fs/pstore/blk.c233.. kernel-doc:: fs/pstore/blk.c
240 :export:234 :internal:
241 235
242.. kernel-doc:: include/linux/pstore_blk.h236.. kernel-doc:: include/linux/pstore_blk.h
243 :internal:237 :internal:
Documentation/block/blk-mq.rst+6−6
@@ -63,10 +63,10 @@ Software staging queues · 62 unmodified lines
63~~~~~~~~~~~~~~~~~~~~~~~63~~~~~~~~~~~~~~~~~~~~~~~
64 64
65The block IO subsystem adds requests in the software staging queues65The block IO subsystem adds requests in the software staging queues
66(represented by struct :c:type:`blk_mq_ctx`) in case that they weren't sent66(represented by struct blk_mq_ctx) in case that they weren't sent
67directly to the driver. A request is one or more BIOs. They arrived at the67directly to the driver. A request is one or more BIOs. They arrived at the
68block layer through the data structure struct :c:type:`bio`. The block layer68block layer through the data structure struct bio. The block layer
69will then build a new structure from it, the struct :c:type:`request` that will69will then build a new structure from it, the struct request that will
70be used to communicate with the device driver. Each queue has its own lock and70be used to communicate with the device driver. Each queue has its own lock and
71the number of queues is defined by a per-CPU or per-node basis.71the number of queues is defined by a per-CPU or per-node basis.
72 72
@@ -102,7 +102,7 @@ hardware queue will be drained in sequence according to their mapping. · 29 unmodified lines
102Hardware dispatch queues102Hardware dispatch queues
103~~~~~~~~~~~~~~~~~~~~~~~~103~~~~~~~~~~~~~~~~~~~~~~~~
104 104
105The hardware queue (represented by struct :c:type:`blk_mq_hw_ctx`) is a struct105The hardware queue (represented by struct blk_mq_hw_ctx) is a struct
106used by device drivers to map the device submission queues (or device DMA ring106used by device drivers to map the device submission queues (or device DMA ring
107buffer), and are the last step of the block layer submission code before the107buffer), and are the last step of the block layer submission code before the
108low level device driver taking ownership of the request. To run this queue, the108low level device driver taking ownership of the request. To run this queue, the
@@ -110,9 +110,9 @@ block layer removes requests from the associated software queues and tries to · 1 unmodified line
110dispatch to the hardware.110dispatch to the hardware.
111 111
112If it's not possible to send the requests directly to hardware, they will be112If it's not possible to send the requests directly to hardware, they will be
113added to a linked list (:c:type:`hctx->dispatch`) of requests. Then,113added to a linked list (``hctx->dispatch``) of requests. Then,
114next time the block layer runs a queue, it will send the requests laying at the114next time the block layer runs a queue, it will send the requests laying at the
115:c:type:`dispatch` list first, to ensure a fairness dispatch with those115``dispatch`` list first, to ensure a fairness dispatch with those
116requests that were ready to be sent first. The number of hardware queues116requests that were ready to be sent first. The number of hardware queues
117depends on the number of hardware contexts supported by the hardware and its117depends on the number of hardware contexts supported by the hardware and its
118device driver, but it will not be more than the number of cores of the system.118device driver, but it will not be more than the number of cores of the system.
Documentation/block/inline-encryption.rst+4−4
@@ -52,7 +52,7 @@ Constraints and notes · 51 unmodified lines
52Design52Design
53======53======
54 54
55We add a :c:type:`struct bio_crypt_ctx` to :c:type:`struct bio` that can55We add a struct bio_crypt_ctx to struct bio that can
56represent an encryption context, because we need to be able to pass this56represent an encryption context, because we need to be able to pass this
57encryption context from the upper layers (like the fs layer) to the57encryption context from the upper layers (like the fs layer) to the
58device driver to act upon.58device driver to act upon.
@@ -85,7 +85,7 @@ blk-mq changes, other block layer changes and blk-crypto-fallback · 26 unmodified lines
85=================================================================85=================================================================
86 86
87We add a pointer to a ``bi_crypt_context`` and ``keyslot`` to87We add a pointer to a ``bi_crypt_context`` and ``keyslot`` to
88:c:type:`struct request`. These will be referred to as the ``crypto fields``88struct request. These will be referred to as the ``crypto fields``
89for the request. This ``keyslot`` is the keyslot into which the89for the request. This ``keyslot`` is the keyslot into which the
90``bi_crypt_context`` has been programmed in the KSM of the ``request_queue``90``bi_crypt_context`` has been programmed in the KSM of the ``request_queue``
91that this request is being sent to.91that this request is being sent to.
@@ -118,7 +118,7 @@ of the algorithm being used adheres to spec and functions correctly). · 26 unmodified lines
118If a ``request queue``'s inline encryption hardware claimed to support the118If a ``request queue``'s inline encryption hardware claimed to support the
119encryption context specified with a bio, then it will not be handled by the119encryption context specified with a bio, then it will not be handled by the
120``blk-crypto-fallback``. We will eventually reach a point in blk-mq when a120``blk-crypto-fallback``. We will eventually reach a point in blk-mq when a
121:c:type:`struct request` needs to be allocated for that bio. At that point,121struct request needs to be allocated for that bio. At that point,
122blk-mq tries to program the encryption context into the ``request_queue``'s122blk-mq tries to program the encryption context into the ``request_queue``'s
123keyslot_manager, and obtain a keyslot, which it stores in its newly added123keyslot_manager, and obtain a keyslot, which it stores in its newly added
124``keyslot`` field. This keyslot is released when the request is completed.124``keyslot`` field. This keyslot is released when the request is completed.
@@ -188,7 +188,7 @@ keyslots supported by the hardware. · 63 unmodified lines
188The device driver also needs to tell the KSM how to actually manipulate the188The device driver also needs to tell the KSM how to actually manipulate the
189IE hardware in the device to do things like programming the crypto key into189IE hardware in the device to do things like programming the crypto key into
190the IE hardware into a particular keyslot. All this is achieved through the190the IE hardware into a particular keyslot. All this is achieved through the
191:c:type:`struct blk_ksm_ll_ops` field in the KSM that the device driver191struct blk_ksm_ll_ops field in the KSM that the device driver
192must fill up after initing the ``blk_keyslot_manager``.192must fill up after initing the ``blk_keyslot_manager``.
193 193
194The KSM also handles runtime power management for the device when applicable194The KSM also handles runtime power management for the device when applicable
Documentation/conf.py+62−3
@@ -47,9 +47,68 @@ extensions = ['kerneldoc', 'rstFlatTable', 'kernel_include', · 46 unmodified lines
47#47#
48if major >= 3:48if major >= 3:
49 sys.stderr.write('''WARNING: The kernel documentation build process49 sys.stderr.write('''WARNING: The kernel documentation build process
50 does not work correctly with Sphinx v3.0 and above. Expect errors50 support for Sphinx v3.0 and above is brand new. Be prepared for
51 in the generated output.51 possible issues in the generated output.
52 ''')52 ''')
53 if minor > 0 or patch >= 2:
54 # Sphinx c function parser is more pedantic with regards to type
55 # checking. Due to that, having macros at c:function cause problems.
56 # Those needed to be scaped by using c_id_attributes[] array
57 c_id_attributes = [
58 # GCC Compiler types not parsed by Sphinx:
59 "__restrict__",
60
61 # include/linux/compiler_types.h:
62 "__iomem",
63 "__kernel",
64 "noinstr",
65 "notrace",
66 "__percpu",
67 "__rcu",
68 "__user",
69
70 # include/linux/compiler_attributes.h:
71 "__alias",
72 "__aligned",
73 "__aligned_largest",
74 "__always_inline",
75 "__assume_aligned",
76 "__cold",
77 "__attribute_const__",
78 "__copy",
79 "__pure",
80 "__designated_init",
81 "__visible",
82 "__printf",
83 "__scanf",
84 "__gnu_inline",
85 "__malloc",
86 "__mode",
87 "__no_caller_saved_registers",
88 "__noclone",
89 "__nonstring",
90 "__noreturn",
91 "__packed",
92 "__pure",
93 "__section",
94 "__always_unused",
95 "__maybe_unused",
96 "__used",
97 "__weak",
98 "noinline",
99
100 # include/linux/memblock.h:
101 "__init_memblock",
102 "__meminit",
103
104 # include/linux/init.h:
105 "__init",
106 "__ref",
107
108 # include/linux/linkage.h:
109 "asmlinkage",
110 ]
111
53else:112else:
54 extensions.append('cdomain')113 extensions.append('cdomain')
55 114
Documentation/core-api/genericirq.rst+2−0
@@ -419,6 +419,7 @@ functions which are exported. · 418 unmodified lines
419.. kernel-doc:: kernel/irq/manage.c419.. kernel-doc:: kernel/irq/manage.c
420 420
421.. kernel-doc:: kernel/irq/chip.c421.. kernel-doc:: kernel/irq/chip.c
422 :export:
422 423
423Internal Functions Provided424Internal Functions Provided
424===========================425===========================
@@ -431,6 +432,7 @@ functions. · 6 unmodified lines
431.. kernel-doc:: kernel/irq/handle.c432.. kernel-doc:: kernel/irq/handle.c
432 433
433.. kernel-doc:: kernel/irq/chip.c434.. kernel-doc:: kernel/irq/chip.c
435 :internal:
434 436
435Credits437Credits
436=======438=======
Documentation/core-api/kernel-api.rst+0−6
@@ -231,12 +231,6 @@ Refer to the file kernel/module.c for more information. · 230 unmodified lines
231Hardware Interfaces231Hardware Interfaces
232===================232===================
233 233
234Interrupt Handling
235------------------
236
237.. kernel-doc:: kernel/irq/manage.c
238 :export:
239
240DMA Channels234DMA Channels
241------------235------------
242 236
Documentation/core-api/workqueue.rst+2−0
@@ -396,3 +396,5 @@ Kernel Inline Documentations Reference · 395 unmodified lines
396======================================396======================================
397 397
398.. kernel-doc:: include/linux/workqueue.h398.. kernel-doc:: include/linux/workqueue.h
399
400.. kernel-doc:: kernel/workqueue.c
Documentation/dev-tools/kgdb.rst+3−3
@@ -726,7 +726,7 @@ The kernel debugger is organized into a number of components: · 725 unmodified lines
726 - contains an arch-specific trap catcher which invokes726 - contains an arch-specific trap catcher which invokes
727 kgdb_handle_exception() to start kgdb about doing its work727 kgdb_handle_exception() to start kgdb about doing its work
728 728
729 - translation to and from gdb specific packet format to :c:type:`pt_regs`729 - translation to and from gdb specific packet format to struct pt_regs
730 730
731 - Registration and unregistration of architecture specific trap731 - Registration and unregistration of architecture specific trap
732 hooks732 hooks
@@ -846,7 +846,7 @@ invokes a callback in the serial core which in turn uses the callback in · 113 unmodified lines
846the UART driver.846the UART driver.
847 847
848When using kgdboc with a UART, the UART driver must implement two848When using kgdboc with a UART, the UART driver must implement two
849callbacks in the :c:type:`struct uart_ops <uart_ops>`.849callbacks in the struct uart_ops.
850Example from ``drivers/8250.c``::850Example from ``drivers/8250.c``::
851 851
852 852
@@ -875,7 +875,7 @@ kernel when ``CONFIG_KDB_KEYBOARD=y`` is set in the kernel configuration. · 22 unmodified lines
875The core polled keyboard driver for PS/2 type keyboards is in875The core polled keyboard driver for PS/2 type keyboards is in
876``drivers/char/kdb_keyboard.c``. This driver is hooked into the debug core876``drivers/char/kdb_keyboard.c``. This driver is hooked into the debug core
877when kgdboc populates the callback in the array called877when kgdboc populates the callback in the array called
878:c:type:`kdb_poll_funcs[]`. The kdb_get_kbd_char() is the top-level878:c:expr:`kdb_poll_funcs[]`. The kdb_get_kbd_char() is the top-level
879function which polls hardware for single character input.879function which polls hardware for single character input.
880 880
881kgdboc and kms881kgdboc and kms
Documentation/devicetree/bindings/display/tilcdc/tilcdc.txt+1−1
@@ -37,7 +37,7 @@ Optional nodes: · 36 unmodified lines
37 supports a single port with a single endpoint.37 supports a single port with a single endpoint.
38 38
39 - See also Documentation/devicetree/bindings/display/tilcdc/panel.txt and39 - See also Documentation/devicetree/bindings/display/tilcdc/panel.txt and
40 Documentation/devicetree/bindings/display/bridge/ti,tfp410.txt for connecting40 Documentation/devicetree/bindings/display/bridge/ti,tfp410.yaml for connecting
41 tfp410 DVI encoder or lcd panel to lcdc41 tfp410 DVI encoder or lcd panel to lcdc
42 42
43[1] There is an errata about AM335x color wiring. For 16-bit color mode43[1] There is an errata about AM335x color wiring. For 16-bit color mode
Documentation/devicetree/bindings/mailbox/omap-mailbox.txt+1−1
@@ -69,7 +69,7 @@ The following are mandatory properties for the K3 AM65x and J721E SoCs only: · 68 unmodified lines
69 the interrupt routes between the IP and the main GIC69 the interrupt routes between the IP and the main GIC
70 controllers. See the following binding for additional70 controllers. See the following binding for additional
71 details,71 details,
72 Documentation/devicetree/bindings/interrupt-controller/ti,sci-intr.txt72 Documentation/devicetree/bindings/interrupt-controller/ti,sci-intr.yaml
73 73
74Child Nodes:74Child Nodes:
75============75============
Documentation/devicetree/bindings/media/i2c/tvp5150.txt+1−1
@@ -56,7 +56,7 @@ Optional Connector Properties: · 55 unmodified lines
56 instead of using the autodetection mechnism. Please look at56 instead of using the autodetection mechnism. Please look at
57 [1] for more information.57 [1] for more information.
58 58
59[1] Documentation/devicetree/bindings/display/connector/analog-tv-connector.txt.59[1] Documentation/devicetree/bindings/display/connector/analog-tv-connector.yaml.
60 60
61Example - three input sources:61Example - three input sources:
62#include <dt-bindings/display/sdtv-standards.h>62#include <dt-bindings/display/sdtv-standards.h>
Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml+1−1
@@ -14,7 +14,7 @@ description: | · 13 unmodified lines
14 Google's ChromeOS EC PWM is a simple PWM attached to the Embedded Controller14 Google's ChromeOS EC PWM is a simple PWM attached to the Embedded Controller
15 (EC) and controlled via a host-command interface.15 (EC) and controlled via a host-command interface.
16 An EC PWM node should be only found as a sub-node of the EC node (see16 An EC PWM node should be only found as a sub-node of the EC node (see
17 Documentation/devicetree/bindings/mfd/cros-ec.txt).17 Documentation/devicetree/bindings/mfd/google,cros-ec.yaml).
18 18
19properties:19properties:
20 compatible:20 compatible:
Documentation/devicetree/bindings/soc/qcom/qcom,smd-rpm.yaml+1−1
@@ -20,7 +20,7 @@ description: | · 19 unmodified lines
20 present and this subnode may contain children that designate regulator20 present and this subnode may contain children that designate regulator
21 resources.21 resources.
22 22
23 Refer to Documentation/devicetree/bindings/regulator/qcom,smd-rpm-regulator.txt23 Refer to Documentation/devicetree/bindings/regulator/qcom,smd-rpm-regulator.yaml
24 for information on the regulator subnodes that can exist under the24 for information on the regulator subnodes that can exist under the
25 rpm_requests.25 rpm_requests.
26 26
Documentation/devicetree/bindings/sound/google,cros-ec-codec.yaml+1−1
@@ -13,7 +13,7 @@ description: | · 12 unmodified lines
13 Google's ChromeOS EC codec is a digital mic codec provided by the13 Google's ChromeOS EC codec is a digital mic codec provided by the
14 Embedded Controller (EC) and is controlled via a host-command interface.14 Embedded Controller (EC) and is controlled via a host-command interface.
15 An EC codec node should only be found as a sub-node of the EC node (see15 An EC codec node should only be found as a sub-node of the EC node (see
16 Documentation/devicetree/bindings/mfd/cros-ec.txt).16 Documentation/devicetree/bindings/mfd/google,cros-ec.yaml).
17 17
18properties:18properties:
19 compatible:19 compatible:
Documentation/doc-guide/kernel-doc.rst+8−0
@@ -490,6 +490,14 @@ identifiers: *[ function/type ...]* · 489 unmodified lines
490 .. kernel-doc:: lib/idr.c490 .. kernel-doc:: lib/idr.c
491 :identifiers:491 :identifiers:
492 492
493no-identifiers: *[ function/type ...]*
494 Exclude documentation for each *function* and *type* in *source*.
495
496 Example::
497
498 .. kernel-doc:: lib/bitmap.c
499 :no-identifiers: bitmap_parselist
500
493functions: *[ function/type ...]*501functions: *[ function/type ...]*
494 This is an alias of the 'identifiers' directive and deprecated.502 This is an alias of the 'identifiers' directive and deprecated.
495 503
Documentation/driver-api/basics.rst+4−15
@@ -12,6 +12,8 @@ Driver device table · 11 unmodified lines
12 12
13.. kernel-doc:: include/linux/mod_devicetable.h13.. kernel-doc:: include/linux/mod_devicetable.h
14 :internal:14 :internal:
15 :no-identifiers: pci_device_id
16
15 17
16Delaying, scheduling, and timer routines18Delaying, scheduling, and timer routines
17----------------------------------------19----------------------------------------
@@ -55,15 +57,6 @@ High-resolution timers · 37 unmodified lines
55.. kernel-doc:: kernel/time/hrtimer.c57.. kernel-doc:: kernel/time/hrtimer.c
56 :export:58 :export:
57 59
58Workqueues and Kevents
59----------------------
60
61.. kernel-doc:: include/linux/workqueue.h
62 :internal:
63
64.. kernel-doc:: kernel/workqueue.c
65 :export:
66
67Internal Functions60Internal Functions
68------------------61------------------
69 62
@@ -105,19 +98,15 @@ Kernel utility functions · 35 unmodified lines
105 98
106.. kernel-doc:: include/linux/kernel.h99.. kernel-doc:: include/linux/kernel.h
107 :internal:100 :internal:
101 :no-identifiers: kstrtol kstrtoul
108 102
109.. kernel-doc:: kernel/printk/printk.c103.. kernel-doc:: kernel/printk/printk.c
110 :export:104 :export:
105 :no-identifiers: printk
111 106
112.. kernel-doc:: kernel/panic.c107.. kernel-doc:: kernel/panic.c
113 :export:108 :export:
114 109
115.. kernel-doc:: kernel/rcu/tree.c
116 :export:
117
118.. kernel-doc:: kernel/rcu/update.c
119 :export:
120
121.. kernel-doc:: include/linux/overflow.h110.. kernel-doc:: include/linux/overflow.h
122 :internal:111 :internal:
123 112
Documentation/driver-api/device_link.rst+4−9
@@ -1,7 +1,3 @@
1.. |struct dev_pm_domain| replace:: :c:type:`struct dev_pm_domain <dev_pm_domain>`
2.. |struct generic_pm_domain| replace:: :c:type:`struct generic_pm_domain <generic_pm_domain>`
3
4
5.. _device_link:1.. _device_link:
6 2
7============3============
@@ -166,7 +162,7 @@ Examples · 158 unmodified lines
166 is the same as if the MMU was the parent of the master device.162 is the same as if the MMU was the parent of the master device.
167 163
168 The fact that both devices share the same power domain would normally164 The fact that both devices share the same power domain would normally
169 suggest usage of a |struct dev_pm_domain| or |struct generic_pm_domain|,165 suggest usage of a struct dev_pm_domain or struct generic_pm_domain,
170 however these are not independent devices that happen to share a power166 however these are not independent devices that happen to share a power
171 switch, but rather the MMU device serves the busmaster device and is167 switch, but rather the MMU device serves the busmaster device and is
172 useless without it. A device link creates a synthetic hierarchical168 useless without it. A device link creates a synthetic hierarchical
@@ -202,7 +198,7 @@ Examples · 29 unmodified lines
202Alternatives198Alternatives
203============199============
204 200
205* A |struct dev_pm_domain| can be used to override the bus,201* A struct dev_pm_domain can be used to override the bus,
206 class or device type callbacks. It is intended for devices sharing202 class or device type callbacks. It is intended for devices sharing
207 a single on/off switch, however it does not guarantee a specific203 a single on/off switch, however it does not guarantee a specific
208 suspend/resume ordering, this needs to be implemented separately.204 suspend/resume ordering, this needs to be implemented separately.
@@ -211,7 +207,7 @@ Alternatives · 2 unmodified lines
211 suspended. Furthermore it cannot be used to enforce a specific shutdown207 suspended. Furthermore it cannot be used to enforce a specific shutdown
212 ordering or a driver presence dependency.208 ordering or a driver presence dependency.
213 209
214* A |struct generic_pm_domain| is a lot more heavyweight than a210* A struct generic_pm_domain is a lot more heavyweight than a
215 device link and does not allow for shutdown ordering or driver presence211 device link and does not allow for shutdown ordering or driver presence
216 dependencies. It also cannot be used on ACPI systems.212 dependencies. It also cannot be used on ACPI systems.
217 213
@@ -321,5 +317,4 @@ State machine · 103 unmodified lines
321API317API
322===318===
323 319
324.. kernel-doc:: drivers/base/core.c320See device_link_add(), device_link_del() and device_link_remove().
325 :functions: device_link_add device_link_del device_link_remove
Documentation/driver-api/fpga/fpga-bridge.rst+2−2
@@ -4,8 +4,8 @@ FPGA Bridge · 3 unmodified lines
4API to implement a new FPGA bridge4API to implement a new FPGA bridge
5~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~5~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
6 6
7* struct :c:type:`fpga_bridge` — The FPGA Bridge structure7* struct fpga_bridge — The FPGA Bridge structure
8* struct :c:type:`fpga_bridge_ops` — Low level Bridge driver ops8* struct fpga_bridge_ops — Low level Bridge driver ops
9* devm_fpga_bridge_create() — Allocate and init a bridge struct9* devm_fpga_bridge_create() — Allocate and init a bridge struct
10* fpga_bridge_register() — Register a bridge10* fpga_bridge_register() — Register a bridge
11* fpga_bridge_unregister() — Unregister a bridge11* fpga_bridge_unregister() — Unregister a bridge
Documentation/driver-api/fpga/fpga-mgr.rst+3−3
@@ -101,9 +101,9 @@ in state. · 100 unmodified lines
101API for implementing a new FPGA Manager driver101API for implementing a new FPGA Manager driver
102----------------------------------------------102----------------------------------------------
103 103
104* ``fpga_mgr_states`` — Values for :c:member:`fpga_manager->state`.104* ``fpga_mgr_states`` — Values for :c:expr:`fpga_manager->state`.
105* struct :c:type:`fpga_manager` — the FPGA manager struct105* struct fpga_manager — the FPGA manager struct
106* struct :c:type:`fpga_manager_ops` — Low level FPGA manager driver ops106* struct fpga_manager_ops — Low level FPGA manager driver ops
107* devm_fpga_mgr_create() — Allocate and init a manager struct107* devm_fpga_mgr_create() — Allocate and init a manager struct
108* fpga_mgr_register() — Register an FPGA manager108* fpga_mgr_register() — Register an FPGA manager
109* fpga_mgr_unregister() — Unregister an FPGA manager109* fpga_mgr_unregister() — Unregister an FPGA manager
Documentation/driver-api/fpga/fpga-programming.rst+1−1
@@ -15,7 +15,7 @@ the FPGA manager and bridges. It will: · 14 unmodified lines
15 * lock the mutex of the region's FPGA manager15 * lock the mutex of the region's FPGA manager
16 * build a list of FPGA bridges if a method has been specified to do so16 * build a list of FPGA bridges if a method has been specified to do so
17 * disable the bridges17 * disable the bridges
18 * program the FPGA using info passed in :c:member:`fpga_region->info`.18 * program the FPGA using info passed in :c:expr:`fpga_region->info`.
19 * re-enable the bridges19 * re-enable the bridges
20 * release the locks20 * release the locks
21 21
Documentation/driver-api/fpga/fpga-region.rst+3−3
@@ -45,7 +45,7 @@ An example of usage can be seen in the probe function of [#f2]_. · 44 unmodified lines
45API to add a new FPGA region45API to add a new FPGA region
46----------------------------46----------------------------
47 47
48* struct :c:type:`fpga_region` — The FPGA region struct48* struct fpga_region — The FPGA region struct
49* devm_fpga_region_create() — Allocate and init a region struct49* devm_fpga_region_create() — Allocate and init a region struct
50* fpga_region_register() — Register an FPGA region50* fpga_region_register() — Register an FPGA region
51* fpga_region_unregister() — Unregister an FPGA region51* fpga_region_unregister() — Unregister an FPGA region
@@ -61,9 +61,9 @@ during the region's probe function. · 9 unmodified lines
61 61
62The FPGA region will need to specify which bridges to control while programming62The FPGA region will need to specify which bridges to control while programming
63the FPGA. The region driver can build a list of bridges during probe time63the FPGA. The region driver can build a list of bridges during probe time
64(:c:member:`fpga_region->bridge_list`) or it can have a function that creates64(:c:expr:`fpga_region->bridge_list`) or it can have a function that creates
65the list of bridges to program just before programming65the list of bridges to program just before programming
66(:c:member:`fpga_region->get_bridges`). The FPGA bridge framework supplies the66(:c:expr:`fpga_region->get_bridges`). The FPGA bridge framework supplies the
67following APIs to handle building or tearing down that list.67following APIs to handle building or tearing down that list.
68 68
69* fpga_bridge_get_to_list() — Get a ref of an FPGA bridge, add it to a69* fpga_bridge_get_to_list() — Get a ref of an FPGA bridge, add it to a
Documentation/driver-api/iio/buffers.rst+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
2Buffers2Buffers
3=======3=======
4 4
5* struct :c:type:`iio_buffer` — general buffer structure5* struct iio_buffer — general buffer structure
6* :c:func:`iio_validate_scan_mask_onehot` — Validates that exactly one channel6* :c:func:`iio_validate_scan_mask_onehot` — Validates that exactly one channel
7 is selected7 is selected
8* :c:func:`iio_buffer_get` — Grab a reference to the buffer8* :c:func:`iio_buffer_get` — Grab a reference to the buffer
Documentation/driver-api/iio/core.rst+3−3
@@ -10,7 +10,7 @@ applications manipulating sensors. The implementation can be found under · 9 unmodified lines
10Industrial I/O Devices10Industrial I/O Devices
11----------------------11----------------------
12 12
13* struct :c:type:`iio_dev` - industrial I/O device13* struct iio_dev - industrial I/O device
14* iio_device_alloc() - allocate an :c:type:`iio_dev` from a driver14* iio_device_alloc() - allocate an :c:type:`iio_dev` from a driver
15* iio_device_free() - free an :c:type:`iio_dev` from a driver15* iio_device_free() - free an :c:type:`iio_dev` from a driver
16* iio_device_register() - register a device with the IIO subsystem16* iio_device_register() - register a device with the IIO subsystem
@@ -66,7 +66,7 @@ Common attributes are: · 49 unmodified lines
66IIO device channels66IIO device channels
67===================67===================
68 68
69struct :c:type:`iio_chan_spec` - specification of a single channel69struct iio_chan_spec - specification of a single channel
70 70
71An IIO device channel is a representation of a data channel. An IIO device can71An IIO device channel is a representation of a data channel. An IIO device can
72have one or multiple channels. For example:72have one or multiple channels. For example:
@@ -77,7 +77,7 @@ have one or multiple channels. For example: · 4 unmodified lines
77* an accelerometer can have up to 3 channels representing acceleration on X, Y77* an accelerometer can have up to 3 channels representing acceleration on X, Y
78 and Z axes.78 and Z axes.
79 79
80An IIO channel is described by the struct :c:type:`iio_chan_spec`.80An IIO channel is described by the struct iio_chan_spec.
81A thermometer driver for the temperature sensor in the example above would81A thermometer driver for the temperature sensor in the example above would
82have to describe its channel as follows::82have to describe its channel as follows::
83 83
Documentation/driver-api/iio/hw-consumer.rst+1−1
@@ -8,7 +8,7 @@ software buffer for data. The implementation can be found under · 7 unmodified lines
8:file:`drivers/iio/buffer/hw-consumer.c`8:file:`drivers/iio/buffer/hw-consumer.c`
9 9
10 10
11* struct :c:type:`iio_hw_consumer` — Hardware consumer structure11* struct iio_hw_consumer — Hardware consumer structure
12* :c:func:`iio_hw_consumer_alloc` — Allocate IIO hardware consumer12* :c:func:`iio_hw_consumer_alloc` — Allocate IIO hardware consumer
13* :c:func:`iio_hw_consumer_free` — Free IIO hardware consumer13* :c:func:`iio_hw_consumer_free` — Free IIO hardware consumer
14* :c:func:`iio_hw_consumer_enable` — Enable IIO hardware consumer14* :c:func:`iio_hw_consumer_enable` — Enable IIO hardware consumer
Documentation/driver-api/iio/triggered-buffers.rst+1−1
@@ -10,7 +10,7 @@ IIO triggered buffer setup · 9 unmodified lines
10* :c:func:`iio_triggered_buffer_setup` — Setup triggered buffer and pollfunc10* :c:func:`iio_triggered_buffer_setup` — Setup triggered buffer and pollfunc
11* :c:func:`iio_triggered_buffer_cleanup` — Free resources allocated by11* :c:func:`iio_triggered_buffer_cleanup` — Free resources allocated by
12 :c:func:`iio_triggered_buffer_setup`12 :c:func:`iio_triggered_buffer_setup`
13* struct :c:type:`iio_buffer_setup_ops` — buffer setup related callbacks13* struct iio_buffer_setup_ops — buffer setup related callbacks
14 14
15A typical triggered buffer setup looks like this::15A typical triggered buffer setup looks like this::
16 16
Documentation/driver-api/iio/triggers.rst+2−2
@@ -2,7 +2,7 @@ · 1 unmodified line
2Triggers2Triggers
3========3========
4 4
5* struct :c:type:`iio_trigger` — industrial I/O trigger device5* struct iio_trigger — industrial I/O trigger device
6* :c:func:`devm_iio_trigger_alloc` — Resource-managed iio_trigger_alloc6* :c:func:`devm_iio_trigger_alloc` — Resource-managed iio_trigger_alloc
7* :c:func:`devm_iio_trigger_register` — Resource-managed iio_trigger_register7* :c:func:`devm_iio_trigger_register` — Resource-managed iio_trigger_register
8 iio_trigger_unregister8 iio_trigger_unregister
@@ -63,7 +63,7 @@ Let's see a simple example of how to setup a trigger to be used by a driver:: · 54 unmodified lines
63IIO trigger ops63IIO trigger ops
64===============64===============
65 65
66* struct :c:type:`iio_trigger_ops` — operations structure for an iio_trigger.66* struct iio_trigger_ops — operations structure for an iio_trigger.
67 67
68Notice that a trigger has a set of operations attached:68Notice that a trigger has a set of operations attached:
69 69
Documentation/driver-api/index.rst+0−1
@@ -27,7 +27,6 @@ available subsections can be seen below. · 26 unmodified lines
27 component27 component
28 message-based28 message-based
29 infiniband29 infiniband
30 sound
31 frame-buffer30 frame-buffer
32 regulator31 regulator
33 iio/index32 iio/index
Documentation/driver-api/infrastructure.rst+1−3
@@ -6,6 +6,7 @@ The Basic Device Driver-Model Structures · 5 unmodified lines
6 6
7.. kernel-doc:: include/linux/device.h7.. kernel-doc:: include/linux/device.h
8 :internal:8 :internal:
9 :no-identifiers: device_link_state
9 10
10Device Drivers Base11Device Drivers Base
11-------------------12-------------------
@@ -28,9 +29,6 @@ Device Drivers Base · 16 unmodified lines
28.. kernel-doc:: drivers/base/node.c29.. kernel-doc:: drivers/base/node.c
29 :internal:30 :internal:
30 31
31.. kernel-doc:: drivers/base/firmware_loader/main.c
32 :export:
33
34.. kernel-doc:: drivers/base/transport_class.c32.. kernel-doc:: drivers/base/transport_class.c
35 :export:33 :export:
36 34
Documentation/driver-api/libata.rst+1−1
@@ -508,7 +508,7 @@ also complete commands. · 507 unmodified lines
508 508
5092. ATA_QCFLAG_ACTIVE is cleared from qc->flags.5092. ATA_QCFLAG_ACTIVE is cleared from qc->flags.
510 510
5113. :c:func:`qc->complete_fn` callback is invoked. If the return value of the5113. :c:expr:`qc->complete_fn` callback is invoked. If the return value of the
512 callback is not zero. Completion is short circuited and512 callback is not zero. Completion is short circuited and
513 :c:func:`ata_qc_complete` returns.513 :c:func:`ata_qc_complete` returns.
514 514
Documentation/driver-api/media/cec-core.rst+1−1
@@ -98,7 +98,7 @@ Implementing the Low-Level CEC Adapter · 97 unmodified lines
98The following low-level adapter operations have to be implemented in98The following low-level adapter operations have to be implemented in
99your driver:99your driver:
100 100
101.. c:type:: struct cec_adap_ops101.. c:struct:: cec_adap_ops
102 102
103.. code-block:: none103.. code-block:: none
104 104
Documentation/driver-api/media/dtv-frontend.rst+2−2
@@ -125,7 +125,7 @@ responsible for tuning the device. It supports multiple algorithms to · 124 unmodified lines
125detect a channel, as defined at enum :c:func:`dvbfe_algo`.125detect a channel, as defined at enum :c:func:`dvbfe_algo`.
126 126
127The algorithm to be used is obtained via ``.get_frontend_algo``. If the driver127The algorithm to be used is obtained via ``.get_frontend_algo``. If the driver
128doesn't fill its field at struct :c:type:`dvb_frontend_ops`, it will default to128doesn't fill its field at struct dvb_frontend_ops, it will default to
129``DVBFE_ALGO_SW``, meaning that the dvb-core will do a zigzag when tuning,129``DVBFE_ALGO_SW``, meaning that the dvb-core will do a zigzag when tuning,
130e. g. it will try first to use the specified center frequency ``f``,130e. g. it will try first to use the specified center frequency ``f``,
131then, it will do ``f`` + |delta|, ``f`` - |delta|, ``f`` + 2 x |delta|,131then, it will do ``f`` + |delta|, ``f`` - |delta|, ``f`` + 2 x |delta|,
@@ -140,7 +140,7 @@ define a ``.get_frontend_algo`` function that would return ``DVBFE_ALGO_HW``. · 8 unmodified lines
140 a third type (``DVBFE_ALGO_CUSTOM``), in order to allow the driver to140 a third type (``DVBFE_ALGO_CUSTOM``), in order to allow the driver to
141 define its own hardware-assisted algorithm. Very few hardware need to141 define its own hardware-assisted algorithm. Very few hardware need to
142 use it nowadays. Using ``DVBFE_ALGO_CUSTOM`` require to provide other142 use it nowadays. Using ``DVBFE_ALGO_CUSTOM`` require to provide other
143 function callbacks at struct :c:type:`dvb_frontend_ops`.143 function callbacks at struct dvb_frontend_ops.
144 144
145Attaching frontend driver to the bridge driver145Attaching frontend driver to the bridge driver
146^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^146^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Documentation/driver-api/media/mc-core.rst+12−12
@@ -36,7 +36,7 @@ pad to a sink pad. · 35 unmodified lines
36Media device36Media device
37^^^^^^^^^^^^37^^^^^^^^^^^^
38 38
39A media device is represented by a struct :c:type:`media_device`39A media device is represented by a struct media_device
40instance, defined in ``include/media/media-device.h``.40instance, defined in ``include/media/media-device.h``.
41Allocation of the structure is handled by the media device driver, usually by41Allocation of the structure is handled by the media device driver, usually by
42embedding the :c:type:`media_device` instance in a larger driver-specific42embedding the :c:type:`media_device` instance in a larger driver-specific
@@ -49,7 +49,7 @@ and unregistered by calling :c:func:`media_device_unregister()`. · 6 unmodified lines
49Entities49Entities
50^^^^^^^^50^^^^^^^^
51 51
52Entities are represented by a struct :c:type:`media_entity`52Entities are represented by a struct media_entity
53instance, defined in ``include/media/media-entity.h``. The structure is usually53instance, defined in ``include/media/media-entity.h``. The structure is usually
54embedded into a higher-level structure, such as54embedded into a higher-level structure, such as
55:c:type:`v4l2_subdev` or :c:type:`video_device`55:c:type:`v4l2_subdev` or :c:type:`video_device`
@@ -67,10 +67,10 @@ Interfaces · 11 unmodified lines
67^^^^^^^^^^67^^^^^^^^^^
68 68
69Interfaces are represented by a69Interfaces are represented by a
70struct :c:type:`media_interface` instance, defined in70struct media_interface instance, defined in
71``include/media/media-entity.h``. Currently, only one type of interface is71``include/media/media-entity.h``. Currently, only one type of interface is
72defined: a device node. Such interfaces are represented by a72defined: a device node. Such interfaces are represented by a
73struct :c:type:`media_intf_devnode`.73struct media_intf_devnode.
74 74
75Drivers initialize and create device node interfaces by calling75Drivers initialize and create device node interfaces by calling
76:c:func:`media_devnode_create()`76:c:func:`media_devnode_create()`
@@ -79,7 +79,7 @@ and remove them by calling: · 2 unmodified lines
79 79
80Pads80Pads
81^^^^81^^^^
82Pads are represented by a struct :c:type:`media_pad` instance,82Pads are represented by a struct media_pad instance,
83defined in ``include/media/media-entity.h``. Each entity stores its pads in83defined in ``include/media/media-entity.h``. Each entity stores its pads in
84a pads array managed by the entity driver. Drivers usually embed the array in84a pads array managed by the entity driver. Drivers usually embed the array in
85a driver-specific structure.85a driver-specific structure.
@@ -87,8 +87,8 @@ a driver-specific structure. · 1 unmodified line
87Pads are identified by their entity and their 0-based index in the pads87Pads are identified by their entity and their 0-based index in the pads
88array.88array.
89 89
90Both information are stored in the struct :c:type:`media_pad`,90Both information are stored in the struct media_pad,
91making the struct :c:type:`media_pad` pointer the canonical way91making the struct media_pad pointer the canonical way
92to store and pass link references.92to store and pass link references.
93 93
94Pads have flags that describe the pad capabilities and state.94Pads have flags that describe the pad capabilities and state.
@@ -104,7 +104,7 @@ Pads have flags that describe the pad capabilities and state. · 9 unmodified lines
104Links104Links
105^^^^^105^^^^^
106 106
107Links are represented by a struct :c:type:`media_link` instance,107Links are represented by a struct media_link instance,
108defined in ``include/media/media-entity.h``. There are two types of links:108defined in ``include/media/media-entity.h``. There are two types of links:
109 109
110**1. pad to pad links**:110**1. pad to pad links**:
@@ -187,7 +187,7 @@ Use count and power handling · 76 unmodified lines
187 187
188Due to the wide differences between drivers regarding power management188Due to the wide differences between drivers regarding power management
189needs, the media controller does not implement power management. However,189needs, the media controller does not implement power management. However,
190the struct :c:type:`media_entity` includes a ``use_count``190the struct media_entity includes a ``use_count``
191field that media drivers191field that media drivers
192can use to track the number of users of every entity for power management192can use to track the number of users of every entity for power management
193needs.193needs.
@@ -213,11 +213,11 @@ prevent link states from being modified during streaming by calling · 19 unmodified lines
213The function will mark all entities connected to the given entity through213The function will mark all entities connected to the given entity through
214enabled links, either directly or indirectly, as streaming.214enabled links, either directly or indirectly, as streaming.
215 215
216The struct :c:type:`media_pipeline` instance pointed to by216The struct media_pipeline instance pointed to by
217the pipe argument will be stored in every entity in the pipeline.217the pipe argument will be stored in every entity in the pipeline.
218Drivers should embed the struct :c:type:`media_pipeline`218Drivers should embed the struct media_pipeline
219in higher-level pipeline structures and can then access the219in higher-level pipeline structures and can then access the
220pipeline through the struct :c:type:`media_entity`220pipeline through the struct media_entity
221pipe field.221pipe field.
222 222
223Calls to :c:func:`media_pipeline_start()` can be nested.223Calls to :c:func:`media_pipeline_start()` can be nested.
Documentation/driver-api/media/v4l2-controls.rst+1−1
@@ -27,7 +27,7 @@ V4L2 specification with respect to controls in a central place. And to make · 26 unmodified lines
27life as easy as possible for the driver developer.27life as easy as possible for the driver developer.
28 28
29Note that the control framework relies on the presence of a struct29Note that the control framework relies on the presence of a struct
30:c:type:`v4l2_device` for V4L2 drivers and struct :c:type:`v4l2_subdev` for30:c:type:`v4l2_device` for V4L2 drivers and struct v4l2_subdev for
31sub-device drivers.31sub-device drivers.
32 32
33 33
Documentation/driver-api/media/v4l2-dev.rst+4−4
@@ -67,7 +67,7 @@ You should also set these fields of :c:type:`video_device`: · 66 unmodified lines
67 file operation is called this lock will be taken by the core and released67 file operation is called this lock will be taken by the core and released
68 afterwards. See the next section for more details.68 afterwards. See the next section for more details.
69 69
70- :c:type:`video_device`->queue: a pointer to the struct :c:type:`vb2_queue`70- :c:type:`video_device`->queue: a pointer to the struct vb2_queue
71 associated with this device node.71 associated with this device node.
72 If queue is not ``NULL``, and queue->lock is not ``NULL``, then queue->lock72 If queue is not ``NULL``, and queue->lock is not ``NULL``, then queue->lock
73 is used for the queuing ioctls (``VIDIOC_REQBUFS``, ``CREATE_BUFS``,73 is used for the queuing ioctls (``VIDIOC_REQBUFS``, ``CREATE_BUFS``,
@@ -81,7 +81,7 @@ You should also set these fields of :c:type:`video_device`: · 7 unmodified lines
81 81
82- :c:type:`video_device`->prio: keeps track of the priorities. Used to82- :c:type:`video_device`->prio: keeps track of the priorities. Used to
83 implement ``VIDIOC_G_PRIORITY`` and ``VIDIOC_S_PRIORITY``.83 implement ``VIDIOC_G_PRIORITY`` and ``VIDIOC_S_PRIORITY``.
84 If left to ``NULL``, then it will use the struct :c:type:`v4l2_prio_state`84 If left to ``NULL``, then it will use the struct v4l2_prio_state
85 in :c:type:`v4l2_device`. If you want to have a separate priority state per85 in :c:type:`v4l2_device`. If you want to have a separate priority state per
86 (group of) device node(s), then you can point it to your own struct86 (group of) device node(s), then you can point it to your own struct
87 :c:type:`v4l2_prio_state`.87 :c:type:`v4l2_prio_state`.
@@ -95,7 +95,7 @@ You should also set these fields of :c:type:`video_device`: · 7 unmodified lines
95 but it is used by both a raw video PCI device (cx8800) and a MPEG PCI device95 but it is used by both a raw video PCI device (cx8800) and a MPEG PCI device
96 (cx8802). Since the :c:type:`v4l2_device` cannot be associated with two PCI96 (cx8802). Since the :c:type:`v4l2_device` cannot be associated with two PCI
97 devices at the same time it is setup without a parent device. But when the97 devices at the same time it is setup without a parent device. But when the
98 struct :c:type:`video_device` is initialized you **do** know which parent98 struct video_device is initialized you **do** know which parent
99 PCI device to use and so you set ``dev_device`` to the correct PCI device.99 PCI device to use and so you set ``dev_device`` to the correct PCI device.
100 100
101If you use :c:type:`v4l2_ioctl_ops`, then you should set101If you use :c:type:`v4l2_ioctl_ops`, then you should set
@@ -138,7 +138,7 @@ ioctls and locking · 36 unmodified lines
138------------------138------------------
139 139
140The V4L core provides optional locking services. The main service is the140The V4L core provides optional locking services. The main service is the
141lock field in struct :c:type:`video_device`, which is a pointer to a mutex.141lock field in struct video_device, which is a pointer to a mutex.
142If you set this pointer, then that will be used by unlocked_ioctl to142If you set this pointer, then that will be used by unlocked_ioctl to
143serialize all ioctls.143serialize all ioctls.
144 144
Documentation/driver-api/media/v4l2-device.rst+3−3
@@ -3,7 +3,7 @@ · 2 unmodified lines
3V4L2 device instance3V4L2 device instance
4--------------------4--------------------
5 5
6Each device instance is represented by a struct :c:type:`v4l2_device`.6Each device instance is represented by a struct v4l2_device.
7Very simple devices can just allocate this struct, but most of the time you7Very simple devices can just allocate this struct, but most of the time you
8would embed this struct inside a larger struct.8would embed this struct inside a larger struct.
9 9
@@ -18,9 +18,9 @@ dev->driver_data field is ``NULL``, it will be linked to · 8 unmodified lines
18 18
19Drivers that want integration with the media device framework need to set19Drivers that want integration with the media device framework need to set
20dev->driver_data manually to point to the driver-specific device structure20dev->driver_data manually to point to the driver-specific device structure
21that embed the struct :c:type:`v4l2_device` instance. This is achieved by a21that embed the struct v4l2_device instance. This is achieved by a
22``dev_set_drvdata()`` call before registering the V4L2 device instance.22``dev_set_drvdata()`` call before registering the V4L2 device instance.
23They must also set the struct :c:type:`v4l2_device` mdev field to point to a23They must also set the struct v4l2_device mdev field to point to a
24properly initialized and registered :c:type:`media_device` instance.24properly initialized and registered :c:type:`media_device` instance.
25 25
26If :c:type:`v4l2_dev <v4l2_device>`\ ->name is empty then it will be set to a26If :c:type:`v4l2_dev <v4l2_device>`\ ->name is empty then it will be set to a
Documentation/driver-api/media/v4l2-event.rst+5−5
@@ -44,18 +44,18 @@ such objects. · 43 unmodified lines
44 44
45So to summarize:45So to summarize:
46 46
47- struct :c:type:`v4l2_fh` has two lists: one of the ``subscribed`` events,47- struct v4l2_fh has two lists: one of the ``subscribed`` events,
48 and one of the ``available`` events.48 and one of the ``available`` events.
49 49
50- struct :c:type:`v4l2_subscribed_event` has a ringbuffer of raised50- struct v4l2_subscribed_event has a ringbuffer of raised
51 (pending) events of that particular type.51 (pending) events of that particular type.
52 52
53- If struct :c:type:`v4l2_subscribed_event` is associated with a specific53- If struct v4l2_subscribed_event is associated with a specific
54 object, then that object will have an internal list of54 object, then that object will have an internal list of
55 struct :c:type:`v4l2_subscribed_event` so it knows who subscribed an55 struct v4l2_subscribed_event so it knows who subscribed an
56 event to that object.56 event to that object.
57 57
58Furthermore, the internal struct :c:type:`v4l2_subscribed_event` has58Furthermore, the internal struct v4l2_subscribed_event has
59``merge()`` and ``replace()`` callbacks which drivers can set. These59``merge()`` and ``replace()`` callbacks which drivers can set. These
60callbacks are called when a new event is raised and there is no more room.60callbacks are called when a new event is raised and there is no more room.
61 61
Documentation/driver-api/media/v4l2-fh.rst+8−8
@@ -3,11 +3,11 @@ · 2 unmodified lines
3V4L2 File handlers3V4L2 File handlers
4------------------4------------------
5 5
6struct :c:type:`v4l2_fh` provides a way to easily keep file handle specific6struct v4l2_fh provides a way to easily keep file handle specific
7data that is used by the V4L2 framework.7data that is used by the V4L2 framework.
8 8
9.. attention::9.. attention::
10 New drivers must use struct :c:type:`v4l2_fh`10 New drivers must use struct v4l2_fh
11 since it is also used to implement priority handling11 since it is also used to implement priority handling
12 (:ref:`VIDIOC_G_PRIORITY`).12 (:ref:`VIDIOC_G_PRIORITY`).
13 13
@@ -16,11 +16,11 @@ whether a driver uses :c:type:`v4l2_fh` as its ``file->private_data`` pointer · 2 unmodified lines
16by testing the ``V4L2_FL_USES_V4L2_FH`` bit in :c:type:`video_device`->flags.16by testing the ``V4L2_FL_USES_V4L2_FH`` bit in :c:type:`video_device`->flags.
17This bit is set whenever :c:func:`v4l2_fh_init` is called.17This bit is set whenever :c:func:`v4l2_fh_init` is called.
18 18
19struct :c:type:`v4l2_fh` is allocated as a part of the driver's own file handle19struct v4l2_fh is allocated as a part of the driver's own file handle
20structure and ``file->private_data`` is set to it in the driver's ``open()``20structure and ``file->private_data`` is set to it in the driver's ``open()``
21function by the driver.21function by the driver.
22 22
23In many cases the struct :c:type:`v4l2_fh` will be embedded in a larger23In many cases the struct v4l2_fh will be embedded in a larger
24structure. In that case you should call:24structure. In that case you should call:
25 25
26#) :c:func:`v4l2_fh_init` and :c:func:`v4l2_fh_add` in ``open()``26#) :c:func:`v4l2_fh_init` and :c:func:`v4l2_fh_add` in ``open()``
@@ -102,18 +102,18 @@ Below is a short description of the :c:type:`v4l2_fh` functions used: · 75 unmodified lines
102 memory can be freed.102 memory can be freed.
103 103
104 104
105If struct :c:type:`v4l2_fh` is not embedded, then you can use these helper functions:105If struct v4l2_fh is not embedded, then you can use these helper functions:
106 106
107:c:func:`v4l2_fh_open <v4l2_fh_open>`107:c:func:`v4l2_fh_open <v4l2_fh_open>`
108(struct file \*filp)108(struct file \*filp)
109 109
110- This allocates a struct :c:type:`v4l2_fh`, initializes it and adds it to110- This allocates a struct v4l2_fh, initializes it and adds it to
111 the struct :c:type:`video_device` associated with the file struct.111 the struct video_device associated with the file struct.
112 112
113:c:func:`v4l2_fh_release <v4l2_fh_release>`113:c:func:`v4l2_fh_release <v4l2_fh_release>`
114(struct file \*filp)114(struct file \*filp)
115 115
116- This deletes it from the struct :c:type:`video_device` associated with the116- This deletes it from the struct video_device associated with the
117 file struct, uninitialised the :c:type:`v4l2_fh` and frees it.117 file struct, uninitialised the :c:type:`v4l2_fh` and frees it.
118 118
119These two functions can be plugged into the v4l2_file_operation's ``open()``119These two functions can be plugged into the v4l2_file_operation's ``open()``
Documentation/driver-api/media/v4l2-subdev.rst+1−1
@@ -110,7 +110,7 @@ pads: · 109 unmodified lines
110 err = media_entity_pads_init(&sd->entity, npads, pads);110 err = media_entity_pads_init(&sd->entity, npads, pads);
111 111
112The pads array must have been previously initialized. There is no need to112The pads array must have been previously initialized. There is no need to
113manually set the struct :c:type:`media_entity` function and name fields, but the113manually set the struct media_entity function and name fields, but the
114revision field must be initialized if needed.114revision field must be initialized if needed.
115 115
116A reference to the entity will be automatically acquired/released when the116A reference to the entity will be automatically acquired/released when the
Documentation/driver-api/mei/mei.rst+1−1
@@ -38,7 +38,7 @@ Because some of the Intel ME features can change the system · 37 unmodified lines
38configuration, the driver by default allows only a privileged38configuration, the driver by default allows only a privileged
39user to access it.39user to access it.
40 40
41The session is terminated calling :c:func:`close(int fd)`.41The session is terminated calling :c:expr:`close(fd)`.
42 42
43A code snippet for an application communicating with Intel AMTHI client:43A code snippet for an application communicating with Intel AMTHI client:
44 44
Documentation/driver-api/pm/cpuidle.rst+30−35
@@ -1,11 +1,6 @@
1.. SPDX-License-Identifier: GPL-2.01.. SPDX-License-Identifier: GPL-2.0
2.. include:: <isonum.txt>2.. include:: <isonum.txt>
3 3
4.. |struct cpuidle_governor| replace:: :c:type:`struct cpuidle_governor <cpuidle_governor>`
5.. |struct cpuidle_device| replace:: :c:type:`struct cpuidle_device <cpuidle_device>`
6.. |struct cpuidle_driver| replace:: :c:type:`struct cpuidle_driver <cpuidle_driver>`
7.. |struct cpuidle_state| replace:: :c:type:`struct cpuidle_state <cpuidle_state>`
8
9========================4========================
10CPU Idle Time Management5CPU Idle Time Management
11========================6========================
@@ -54,7 +49,7 @@ platform that the Linux kernel can run on. For this reason, data structures · 42 unmodified lines
54operated on by them cannot depend on any hardware architecture or platform49operated on by them cannot depend on any hardware architecture or platform
55design details as well.50design details as well.
56 51
57The governor itself is represented by a |struct cpuidle_governor| object52The governor itself is represented by a struct cpuidle_governor object
58containing four callback pointers, :c:member:`enable`, :c:member:`disable`,53containing four callback pointers, :c:member:`enable`, :c:member:`disable`,
59:c:member:`select`, :c:member:`reflect`, a :c:member:`rating` field described54:c:member:`select`, :c:member:`reflect`, a :c:member:`rating` field described
60below, and a name (string) used for identifying it.55below, and a name (string) used for identifying it.
@@ -83,11 +78,11 @@ callbacks: · 22 unmodified lines
83 int (*enable) (struct cpuidle_driver *drv, struct cpuidle_device *dev);78 int (*enable) (struct cpuidle_driver *drv, struct cpuidle_device *dev);
84 79
85 The role of this callback is to prepare the governor for handling the80 The role of this callback is to prepare the governor for handling the
86 (logical) CPU represented by the |struct cpuidle_device| object pointed81 (logical) CPU represented by the struct cpuidle_device object pointed
87 to by the ``dev`` argument. The |struct cpuidle_driver| object pointed82 to by the ``dev`` argument. The struct cpuidle_driver object pointed
88 to by the ``drv`` argument represents the ``CPUIdle`` driver to be used83 to by the ``drv`` argument represents the ``CPUIdle`` driver to be used
89 with that CPU (among other things, it should contain the list of84 with that CPU (among other things, it should contain the list of
90 |struct cpuidle_state| objects representing idle states that the85 struct cpuidle_state objects representing idle states that the
91 processor holding the given CPU can be asked to enter).86 processor holding the given CPU can be asked to enter).
92 87
93 It may fail, in which case it is expected to return a negative error88 It may fail, in which case it is expected to return a negative error
@@ -102,7 +97,7 @@ callbacks: · 8 unmodified lines
102 void (*disable) (struct cpuidle_driver *drv, struct cpuidle_device *dev);97 void (*disable) (struct cpuidle_driver *drv, struct cpuidle_device *dev);
103 98
104 Called to make the governor stop handling the (logical) CPU represented99 Called to make the governor stop handling the (logical) CPU represented
105 by the |struct cpuidle_device| object pointed to by the ``dev``100 by the struct cpuidle_device object pointed to by the ``dev``
106 argument.101 argument.
107 102
108 It is expected to reverse any changes made by the ``->enable()``103 It is expected to reverse any changes made by the ``->enable()``
@@ -116,12 +111,12 @@ callbacks: · 7 unmodified lines
116 bool *stop_tick);111 bool *stop_tick);
117 112
118 Called to select an idle state for the processor holding the (logical)113 Called to select an idle state for the processor holding the (logical)
119 CPU represented by the |struct cpuidle_device| object pointed to by the114 CPU represented by the struct cpuidle_device object pointed to by the
120 ``dev`` argument.115 ``dev`` argument.
121 116
122 The list of idle states to take into consideration is represented by the117 The list of idle states to take into consideration is represented by the
123 :c:member:`states` array of |struct cpuidle_state| objects held by the118 :c:member:`states` array of struct cpuidle_state objects held by the
124 |struct cpuidle_driver| object pointed to by the ``drv`` argument (which119 struct cpuidle_driver object pointed to by the ``drv`` argument (which
125 represents the ``CPUIdle`` driver to be used with the CPU at hand). The120 represents the ``CPUIdle`` driver to be used with the CPU at hand). The
126 value returned by this callback is interpreted as an index into that121 value returned by this callback is interpreted as an index into that
127 array (unless it is a negative error code).122 array (unless it is a negative error code).
@@ -136,7 +131,7 @@ callbacks: · 8 unmodified lines
136 asking the processor to enter the idle state).131 asking the processor to enter the idle state).
137 132
138 This callback is mandatory (i.e. the :c:member:`select` callback pointer133 This callback is mandatory (i.e. the :c:member:`select` callback pointer
139 in |struct cpuidle_governor| must not be ``NULL`` for the registration134 in struct cpuidle_governor must not be ``NULL`` for the registration
140 of the governor to succeed).135 of the governor to succeed).
141 136
142:c:member:`reflect`137:c:member:`reflect`
@@ -167,21 +162,21 @@ CPU idle time management (``CPUIdle``) drivers provide an interface between the · 24 unmodified lines
167other parts of ``CPUIdle`` and the hardware.162other parts of ``CPUIdle`` and the hardware.
168 163
169First of all, a ``CPUIdle`` driver has to populate the :c:member:`states` array164First of all, a ``CPUIdle`` driver has to populate the :c:member:`states` array
170of |struct cpuidle_state| objects included in the |struct cpuidle_driver| object165of struct cpuidle_state objects included in the struct cpuidle_driver object
171representing it. Going forward this array will represent the list of available166representing it. Going forward this array will represent the list of available
172idle states that the processor hardware can be asked to enter shared by all of167idle states that the processor hardware can be asked to enter shared by all of
173the logical CPUs handled by the given driver.168the logical CPUs handled by the given driver.
174 169
175The entries in the :c:member:`states` array are expected to be sorted by the170The entries in the :c:member:`states` array are expected to be sorted by the
176value of the :c:member:`target_residency` field in |struct cpuidle_state| in171value of the :c:member:`target_residency` field in struct cpuidle_state in
177the ascending order (that is, index 0 should correspond to the idle state with172the ascending order (that is, index 0 should correspond to the idle state with
178the minimum value of :c:member:`target_residency`). [Since the173the minimum value of :c:member:`target_residency`). [Since the
179:c:member:`target_residency` value is expected to reflect the "depth" of the174:c:member:`target_residency` value is expected to reflect the "depth" of the
180idle state represented by the |struct cpuidle_state| object holding it, this175idle state represented by the struct cpuidle_state object holding it, this
181sorting order should be the same as the ascending sorting order by the idle176sorting order should be the same as the ascending sorting order by the idle
182state "depth".]177state "depth".]
183 178
184Three fields in |struct cpuidle_state| are used by the existing ``CPUIdle``179Three fields in struct cpuidle_state are used by the existing ``CPUIdle``
185governors for computations related to idle state selection:180governors for computations related to idle state selection:
186 181
187:c:member:`target_residency`182:c:member:`target_residency`
@@ -203,7 +198,7 @@ governors for computations related to idle state selection: · 15 unmodified lines
203 any idle state at all. [There are other flags used by the ``CPUIdle``198 any idle state at all. [There are other flags used by the ``CPUIdle``
204 core in special situations.]199 core in special situations.]
205 200
206The :c:member:`enter` callback pointer in |struct cpuidle_state|, which must not201The :c:member:`enter` callback pointer in struct cpuidle_state, which must not
207be ``NULL``, points to the routine to execute in order to ask the processor to202be ``NULL``, points to the routine to execute in order to ask the processor to
208enter this particular idle state:203enter this particular idle state:
209 204
@@ -212,14 +207,14 @@ enter this particular idle state: · 2 unmodified lines
212 void (*enter) (struct cpuidle_device *dev, struct cpuidle_driver *drv,207 void (*enter) (struct cpuidle_device *dev, struct cpuidle_driver *drv,
213 int index);208 int index);
214 209
215The first two arguments of it point to the |struct cpuidle_device| object210The first two arguments of it point to the struct cpuidle_device object
216representing the logical CPU running this callback and the211representing the logical CPU running this callback and the
217|struct cpuidle_driver| object representing the driver itself, respectively,212struct cpuidle_driver object representing the driver itself, respectively,
218and the last one is an index of the |struct cpuidle_state| entry in the driver's213and the last one is an index of the struct cpuidle_state entry in the driver's
219:c:member:`states` array representing the idle state to ask the processor to214:c:member:`states` array representing the idle state to ask the processor to
220enter.215enter.
221 216
222The analogous ``->enter_s2idle()`` callback in |struct cpuidle_state| is used217The analogous ``->enter_s2idle()`` callback in struct cpuidle_state is used
223only for implementing the suspend-to-idle system-wide power management feature.218only for implementing the suspend-to-idle system-wide power management feature.
224The difference between in and ``->enter()`` is that it must not re-enable219The difference between in and ``->enter()`` is that it must not re-enable
225interrupts at any point (even temporarily) or attempt to change the states of220interrupts at any point (even temporarily) or attempt to change the states of
@@ -227,48 +222,48 @@ clock event devices, which the ``->enter()`` callback may do sometimes. · 1 unmodified line
227 222
228Once the :c:member:`states` array has been populated, the number of valid223Once the :c:member:`states` array has been populated, the number of valid
229entries in it has to be stored in the :c:member:`state_count` field of the224entries in it has to be stored in the :c:member:`state_count` field of the
230|struct cpuidle_driver| object representing the driver. Moreover, if any225struct cpuidle_driver object representing the driver. Moreover, if any
231entries in the :c:member:`states` array represent "coupled" idle states (that226entries in the :c:member:`states` array represent "coupled" idle states (that
232is, idle states that can only be asked for if multiple related logical CPUs are227is, idle states that can only be asked for if multiple related logical CPUs are
233idle), the :c:member:`safe_state_index` field in |struct cpuidle_driver| needs228idle), the :c:member:`safe_state_index` field in struct cpuidle_driver needs
234to be the index of an idle state that is not "coupled" (that is, one that can be229to be the index of an idle state that is not "coupled" (that is, one that can be
235asked for if only one logical CPU is idle).230asked for if only one logical CPU is idle).
236 231
237In addition to that, if the given ``CPUIdle`` driver is only going to handle a232In addition to that, if the given ``CPUIdle`` driver is only going to handle a
238subset of logical CPUs in the system, the :c:member:`cpumask` field in its233subset of logical CPUs in the system, the :c:member:`cpumask` field in its
239|struct cpuidle_driver| object must point to the set (mask) of CPUs that will be234struct cpuidle_driver object must point to the set (mask) of CPUs that will be
240handled by it.235handled by it.
241 236
242A ``CPUIdle`` driver can only be used after it has been registered. If there237A ``CPUIdle`` driver can only be used after it has been registered. If there
243are no "coupled" idle state entries in the driver's :c:member:`states` array,238are no "coupled" idle state entries in the driver's :c:member:`states` array,
244that can be accomplished by passing the driver's |struct cpuidle_driver| object239that can be accomplished by passing the driver's struct cpuidle_driver object
245to :c:func:`cpuidle_register_driver()`. Otherwise, :c:func:`cpuidle_register()`240to :c:func:`cpuidle_register_driver()`. Otherwise, :c:func:`cpuidle_register()`
246should be used for this purpose.241should be used for this purpose.
247 242
248However, it also is necessary to register |struct cpuidle_device| objects for243However, it also is necessary to register struct cpuidle_device objects for
249all of the logical CPUs to be handled by the given ``CPUIdle`` driver with the244all of the logical CPUs to be handled by the given ``CPUIdle`` driver with the
250help of :c:func:`cpuidle_register_device()` after the driver has been registered245help of :c:func:`cpuidle_register_device()` after the driver has been registered
251and :c:func:`cpuidle_register_driver()`, unlike :c:func:`cpuidle_register()`,246and :c:func:`cpuidle_register_driver()`, unlike :c:func:`cpuidle_register()`,
252does not do that automatically. For this reason, the drivers that use247does not do that automatically. For this reason, the drivers that use
253:c:func:`cpuidle_register_driver()` to register themselves must also take care248:c:func:`cpuidle_register_driver()` to register themselves must also take care
254of registering the |struct cpuidle_device| objects as needed, so it is generally249of registering the struct cpuidle_device objects as needed, so it is generally
255recommended to use :c:func:`cpuidle_register()` for ``CPUIdle`` driver250recommended to use :c:func:`cpuidle_register()` for ``CPUIdle`` driver
256registration in all cases.251registration in all cases.
257 252
258The registration of a |struct cpuidle_device| object causes the ``CPUIdle``253The registration of a struct cpuidle_device object causes the ``CPUIdle``
259``sysfs`` interface to be created and the governor's ``->enable()`` callback to254``sysfs`` interface to be created and the governor's ``->enable()`` callback to
260be invoked for the logical CPU represented by it, so it must take place after255be invoked for the logical CPU represented by it, so it must take place after
261registering the driver that will handle the CPU in question.256registering the driver that will handle the CPU in question.
262 257
263``CPUIdle`` drivers and |struct cpuidle_device| objects can be unregistered258``CPUIdle`` drivers and struct cpuidle_device objects can be unregistered
264when they are not necessary any more which allows some resources associated with259when they are not necessary any more which allows some resources associated with
265them to be released. Due to dependencies between them, all of the260them to be released. Due to dependencies between them, all of the
266|struct cpuidle_device| objects representing CPUs handled by the given261struct cpuidle_device objects representing CPUs handled by the given
267``CPUIdle`` driver must be unregistered, with the help of262``CPUIdle`` driver must be unregistered, with the help of
268:c:func:`cpuidle_unregister_device()`, before calling263:c:func:`cpuidle_unregister_device()`, before calling
269:c:func:`cpuidle_unregister_driver()` to unregister the driver. Alternatively,264:c:func:`cpuidle_unregister_driver()` to unregister the driver. Alternatively,
270:c:func:`cpuidle_unregister()` can be called to unregister a ``CPUIdle`` driver265:c:func:`cpuidle_unregister()` can be called to unregister a ``CPUIdle`` driver
271along with all of the |struct cpuidle_device| objects representing CPUs handled266along with all of the struct cpuidle_device objects representing CPUs handled
272by it.267by it.
273 268
274``CPUIdle`` drivers can respond to runtime system configuration changes that269``CPUIdle`` drivers can respond to runtime system configuration changes that
@@ -277,8 +272,8 @@ happen, for example, when the system's power source is switched from AC to · 2 unmodified lines
277battery or the other way around). Upon a notification of such a change,272battery or the other way around). Upon a notification of such a change,
278a ``CPUIdle`` driver is expected to call :c:func:`cpuidle_pause_and_lock()` to273a ``CPUIdle`` driver is expected to call :c:func:`cpuidle_pause_and_lock()` to
279turn ``CPUIdle`` off temporarily and then :c:func:`cpuidle_disable_device()` for274turn ``CPUIdle`` off temporarily and then :c:func:`cpuidle_disable_device()` for
280all of the |struct cpuidle_device| objects representing CPUs affected by that275all of the struct cpuidle_device objects representing CPUs affected by that
281change. Next, it can update its :c:member:`states` array in accordance with276change. Next, it can update its :c:member:`states` array in accordance with
282the new configuration of the system, call :c:func:`cpuidle_enable_device()` for277the new configuration of the system, call :c:func:`cpuidle_enable_device()` for
283all of the relevant |struct cpuidle_device| objects and invoke278all of the relevant struct cpuidle_device objects and invoke
284:c:func:`cpuidle_resume_and_unlock()` to allow ``CPUIdle`` to be used again.279:c:func:`cpuidle_resume_and_unlock()` to allow ``CPUIdle`` to be used again.
Documentation/driver-api/pm/devices.rst+9−17
@@ -1,14 +1,6 @@
1.. SPDX-License-Identifier: GPL-2.01.. SPDX-License-Identifier: GPL-2.0
2.. include:: <isonum.txt>2.. include:: <isonum.txt>
3 3
4.. |struct dev_pm_ops| replace:: :c:type:`struct dev_pm_ops <dev_pm_ops>`
5.. |struct dev_pm_domain| replace:: :c:type:`struct dev_pm_domain <dev_pm_domain>`
6.. |struct bus_type| replace:: :c:type:`struct bus_type <bus_type>`
7.. |struct device_type| replace:: :c:type:`struct device_type <device_type>`
8.. |struct class| replace:: :c:type:`struct class <class>`
9.. |struct wakeup_source| replace:: :c:type:`struct wakeup_source <wakeup_source>`
10.. |struct device| replace:: :c:type:`struct device <device>`
11
12.. _driverapi_pm_devices:4.. _driverapi_pm_devices:
13 5
14==============================6==============================
@@ -107,7 +99,7 @@ Device Power Management Operations · 92 unmodified lines
107 99
108Device power management operations, at the subsystem level as well as at the100Device power management operations, at the subsystem level as well as at the
109device driver level, are implemented by defining and populating objects of type101device driver level, are implemented by defining and populating objects of type
110|struct dev_pm_ops| defined in :file:`include/linux/pm.h`. The roles of the102struct dev_pm_ops defined in :file:`include/linux/pm.h`. The roles of the
111methods included in it will be explained in what follows. For now, it should be103methods included in it will be explained in what follows. For now, it should be
112sufficient to remember that the last three methods are specific to runtime power104sufficient to remember that the last three methods are specific to runtime power
113management while the remaining ones are used during system-wide power105management while the remaining ones are used during system-wide power
@@ -115,7 +107,7 @@ transitions. · 1 unmodified line
115 107
116There also is a deprecated "old" or "legacy" interface for power management108There also is a deprecated "old" or "legacy" interface for power management
117operations available at least for some subsystems. This approach does not use109operations available at least for some subsystems. This approach does not use
118|struct dev_pm_ops| objects and it is suitable only for implementing system110struct dev_pm_ops objects and it is suitable only for implementing system
119sleep power management methods in a limited way. Therefore it is not described111sleep power management methods in a limited way. Therefore it is not described
120in this document, so please refer directly to the source code for more112in this document, so please refer directly to the source code for more
121information about it.113information about it.
@@ -125,9 +117,9 @@ Subsystem-Level Methods · 3 unmodified lines
125-----------------------117-----------------------
126 118
127The core methods to suspend and resume devices reside in119The core methods to suspend and resume devices reside in
128|struct dev_pm_ops| pointed to by the :c:member:`ops` member of120struct dev_pm_ops pointed to by the :c:member:`ops` member of
129|struct dev_pm_domain|, or by the :c:member:`pm` member of |struct bus_type|,121struct dev_pm_domain, or by the :c:member:`pm` member of struct bus_type,
130|struct device_type| and |struct class|. They are mostly of interest to the122struct device_type and struct class. They are mostly of interest to the
131people writing infrastructure for platforms and buses, like PCI or USB, or123people writing infrastructure for platforms and buses, like PCI or USB, or
132device type and device class drivers. They also are relevant to the writers of124device type and device class drivers. They also are relevant to the writers of
133device drivers whose subsystems (PM domains, device types, device classes and125device drivers whose subsystems (PM domains, device types, device classes and
@@ -156,7 +148,7 @@ The :c:member:`power.can_wakeup` flag just records whether the device (and its · 22 unmodified lines
156driver) can physically support wakeup events. The148driver) can physically support wakeup events. The
157:c:func:`device_set_wakeup_capable()` routine affects this flag. The149:c:func:`device_set_wakeup_capable()` routine affects this flag. The
158:c:member:`power.wakeup` field is a pointer to an object of type150:c:member:`power.wakeup` field is a pointer to an object of type
159|struct wakeup_source| used for controlling whether or not the device should use151struct wakeup_source used for controlling whether or not the device should use
160its system wakeup mechanism and for notifying the PM core of system wakeup152its system wakeup mechanism and for notifying the PM core of system wakeup
161events signaled by the device. This object is only present for wakeup-capable153events signaled by the device. This object is only present for wakeup-capable
162devices (i.e. devices whose :c:member:`can_wakeup` flags are set) and is created154devices (i.e. devices whose :c:member:`can_wakeup` flags are set) and is created
@@ -418,7 +410,7 @@ On many platforms they will gate off one or more clock sources; sometimes they · 255 unmodified lines
418will also switch off power supplies or reduce voltages. [Drivers supporting410will also switch off power supplies or reduce voltages. [Drivers supporting
419runtime PM may already have performed some or all of these steps.]411runtime PM may already have performed some or all of these steps.]
420 412
421If :c:func:`device_may_wakeup(dev)` returns ``true``, the device should be413If :c:func:`device_may_wakeup()` returns ``true``, the device should be
422prepared for generating hardware wakeup signals to trigger a system wakeup event414prepared for generating hardware wakeup signals to trigger a system wakeup event
423when the system is in the sleep state. For example, :c:func:`enable_irq_wake()`415when the system is in the sleep state. For example, :c:func:`enable_irq_wake()`
424might identify GPIO signals hooked up to a switch or other external hardware,416might identify GPIO signals hooked up to a switch or other external hardware,
@@ -713,8 +705,8 @@ nested inside another power domain. The nested domain is referred to as the · 288 unmodified lines
713sub-domain of the parent domain.705sub-domain of the parent domain.
714 706
715Support for power domains is provided through the :c:member:`pm_domain` field of707Support for power domains is provided through the :c:member:`pm_domain` field of
716|struct device|. This field is a pointer to an object of type708struct device. This field is a pointer to an object of type
717|struct dev_pm_domain|, defined in :file:`include/linux/pm.h`, providing a set709struct dev_pm_domain, defined in :file:`include/linux/pm.h`, providing a set
718of power management callbacks analogous to the subsystem-level and device driver710of power management callbacks analogous to the subsystem-level and device driver
719callbacks that are executed for the given device during all power transitions,711callbacks that are executed for the given device during all power transitions,
720instead of the respective subsystem-level callbacks. Specifically, if a712instead of the respective subsystem-level callbacks. Specifically, if a
Documentation/driver-api/regulator.rst+2−2
@@ -116,7 +116,7 @@ core, providing operations structures to the core. A notifier interface · 115 unmodified lines
116allows error conditions to be reported to the core.116allows error conditions to be reported to the core.
117 117
118Registration should be triggered by explicit setup done by the platform,118Registration should be triggered by explicit setup done by the platform,
119supplying a struct :c:type:`regulator_init_data` for the regulator119supplying a struct regulator_init_data for the regulator
120containing constraint and supply information.120containing constraint and supply information.
121 121
122Machine interface122Machine interface
@@ -144,7 +144,7 @@ a given system, for example supporting higher supply voltages than the · 21 unmodified lines
144consumers are rated for.144consumers are rated for.
145 145
146This is done at driver registration time` by providing a146This is done at driver registration time` by providing a
147struct :c:type:`regulation_constraints`.147struct regulation_constraints.
148 148
149The constraints may also specify an initial configuration for the149The constraints may also specify an initial configuration for the
150regulator in the constraints, which is particularly useful for use with150regulator in the constraints, which is particularly useful for use with
Documentation/driver-api/sound.rst+0−54
@@ -1,54 +0,0 @@
1Sound Devices
2=============
3
4.. kernel-doc:: include/sound/core.h
5 :internal:
6
7.. kernel-doc:: sound/sound_core.c
8 :export:
9
10.. kernel-doc:: include/sound/pcm.h
11 :internal:
12
13.. kernel-doc:: sound/core/pcm.c
14 :export:
15
16.. kernel-doc:: sound/core/device.c
17 :export:
18
19.. kernel-doc:: sound/core/info.c
20 :export:
21
22.. kernel-doc:: sound/core/rawmidi.c
23 :export:
24
25.. kernel-doc:: sound/core/sound.c
26 :export:
27
28.. kernel-doc:: sound/core/memory.c
29 :export:
30
31.. kernel-doc:: sound/core/pcm_memory.c
32 :export:
33
34.. kernel-doc:: sound/core/init.c
35 :export:
36
37.. kernel-doc:: sound/core/isadma.c
38 :export:
39
40.. kernel-doc:: sound/core/control.c
41 :export:
42
43.. kernel-doc:: sound/core/pcm_lib.c
44 :export:
45
46.. kernel-doc:: sound/core/hwdep.c
47 :export:
48
49.. kernel-doc:: sound/core/pcm_native.c
50 :export:
51
52.. kernel-doc:: sound/core/memalloc.c
53 :export:
54
Documentation/driver-api/target.rst+0−12
@@ -41,18 +41,6 @@ iSCSI boot information · 40 unmodified lines
41.. kernel-doc:: drivers/scsi/iscsi_boot_sysfs.c41.. kernel-doc:: drivers/scsi/iscsi_boot_sysfs.c
42 :export:42 :export:
43 43
44
45iSCSI transport class
46=====================
47
48The file drivers/scsi/scsi_transport_iscsi.c defines transport
49attributes for the iSCSI class, which sends SCSI packets over TCP/IP
50connections.
51
52.. kernel-doc:: drivers/scsi/scsi_transport_iscsi.c
53 :export:
54
55
56iSCSI TCP interfaces44iSCSI TCP interfaces
57====================45====================
58 46
Documentation/driver-api/usb/URB.rst+1−1
@@ -47,7 +47,7 @@ called USB Request Block, or URB for short. · 46 unmodified lines
47The URB structure47The URB structure
48=================48=================
49 49
50Some of the fields in struct :c:type:`urb` are::50Some of the fields in struct urb are::
51 51
52 struct urb52 struct urb
53 {53 {
Documentation/driver-api/usb/gadget.rst+5−5
@@ -176,9 +176,9 @@ Kernel Mode Gadget API · 175 unmodified lines
176 176
177Gadget drivers declare themselves through a struct177Gadget drivers declare themselves through a struct
178:c:type:`usb_gadget_driver`, which is responsible for most parts of enumeration178:c:type:`usb_gadget_driver`, which is responsible for most parts of enumeration
179for a struct :c:type:`usb_gadget`. The response to a set_configuration usually179for a struct usb_gadget. The response to a set_configuration usually
180involves enabling one or more of the struct :c:type:`usb_ep` objects exposed by180involves enabling one or more of the struct usb_ep objects exposed by
181the gadget, and submitting one or more struct :c:type:`usb_request` buffers to181the gadget, and submitting one or more struct usb_request buffers to
182transfer data. Understand those four data types, and their operations,182transfer data. Understand those four data types, and their operations,
183and you will understand how this API works.183and you will understand how this API works.
184 184
@@ -339,8 +339,8 @@ multi-configuration devices (also more than one function, but not · 154 unmodified lines
339necessarily sharing a given configuration). There is however an optional339necessarily sharing a given configuration). There is however an optional
340framework which makes it easier to reuse and combine functions.340framework which makes it easier to reuse and combine functions.
341 341
342Devices using this framework provide a struct :c:type:`usb_composite_driver`,342Devices using this framework provide a struct usb_composite_driver,
343which in turn provides one or more struct :c:type:`usb_configuration`343which in turn provides one or more struct usb_configuration
344instances. Each such configuration includes at least one struct344instances. Each such configuration includes at least one struct
345:c:type:`usb_function`, which packages a user visible role such as "network345:c:type:`usb_function`, which packages a user visible role such as "network
346link" or "mass storage device". Management functions may also exist,346link" or "mass storage device". Management functions may also exist,
Documentation/driver-api/usb/hotplug.rst+1−1
@@ -122,7 +122,7 @@ and their quirks, might have a MODULE_DEVICE_TABLE like this:: · 121 unmodified lines
122Most USB device drivers should pass these tables to the USB subsystem as122Most USB device drivers should pass these tables to the USB subsystem as
123well as to the module management subsystem. Not all, though: some driver123well as to the module management subsystem. Not all, though: some driver
124frameworks connect using interfaces layered over USB, and so they won't124frameworks connect using interfaces layered over USB, and so they won't
125need such a struct :c:type:`usb_driver`.125need such a struct usb_driver.
126 126
127Drivers that connect directly to the USB subsystem should be declared127Drivers that connect directly to the USB subsystem should be declared
128something like this::128something like this::
Documentation/driver-api/usb/typec_bus.rst+7−1
@@ -91,10 +91,16 @@ their control. · 90 unmodified lines
91Driver API91Driver API
92----------92----------
93 93
94Alternate mode structs
95~~~~~~~~~~~~~~~~~~~~~~
96
97.. kernel-doc:: include/linux/usb/typec_altmode.h
98 :functions: typec_altmode_driver typec_altmode_ops
99
94Alternate mode driver registering/unregistering100Alternate mode driver registering/unregistering
95~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~101~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
96 102
97.. kernel-doc:: drivers/usb/typec/bus.c103.. kernel-doc:: include/linux/usb/typec_altmode.h
98 :functions: typec_altmode_register_driver typec_altmode_unregister_driver104 :functions: typec_altmode_register_driver typec_altmode_unregister_driver
99 105
100Alternate mode driver operations106Alternate mode driver operations
Documentation/filesystems/fscrypt.rst+36−38
@@ -436,9 +436,9 @@ FS_IOC_SET_ENCRYPTION_POLICY · 435 unmodified lines
436 436
437The FS_IOC_SET_ENCRYPTION_POLICY ioctl sets an encryption policy on an437The FS_IOC_SET_ENCRYPTION_POLICY ioctl sets an encryption policy on an
438empty directory or verifies that a directory or regular file already438empty directory or verifies that a directory or regular file already
439has the specified encryption policy. It takes in a pointer to a439has the specified encryption policy. It takes in a pointer to
440:c:type:`struct fscrypt_policy_v1` or a :c:type:`struct440struct fscrypt_policy_v1 or struct fscrypt_policy_v2, defined as
441fscrypt_policy_v2`, defined as follows::441follows::
442 442
443 #define FSCRYPT_POLICY_V1 0443 #define FSCRYPT_POLICY_V1 0
444 #define FSCRYPT_KEY_DESCRIPTOR_SIZE 8444 #define FSCRYPT_KEY_DESCRIPTOR_SIZE 8
@@ -464,11 +464,11 @@ fscrypt_policy_v2`, defined as follows:: · 19 unmodified lines
464 464
465This structure must be initialized as follows:465This structure must be initialized as follows:
466 466
467- ``version`` must be FSCRYPT_POLICY_V1 (0) if the struct is467- ``version`` must be FSCRYPT_POLICY_V1 (0) if
468 :c:type:`fscrypt_policy_v1` or FSCRYPT_POLICY_V2 (2) if the struct468 struct fscrypt_policy_v1 is used or FSCRYPT_POLICY_V2 (2) if
469 is :c:type:`fscrypt_policy_v2`. (Note: we refer to the original469 struct fscrypt_policy_v2 is used. (Note: we refer to the original
470 policy version as "v1", though its version code is really 0.) For470 policy version as "v1", though its version code is really 0.)
471 new encrypted directories, use v2 policies.471 For new encrypted directories, use v2 policies.
472 472
473- ``contents_encryption_mode`` and ``filenames_encryption_mode`` must473- ``contents_encryption_mode`` and ``filenames_encryption_mode`` must
474 be set to constants from ``<linux/fscrypt.h>`` which identify the474 be set to constants from ``<linux/fscrypt.h>`` which identify the
@@ -508,9 +508,9 @@ This structure must be initialized as follows: · 33 unmodified lines
508 replaced with ``master_key_identifier``, which is longer and cannot508 replaced with ``master_key_identifier``, which is longer and cannot
509 be arbitrarily chosen. Instead, the key must first be added using509 be arbitrarily chosen. Instead, the key must first be added using
510 `FS_IOC_ADD_ENCRYPTION_KEY`_. Then, the ``key_spec.u.identifier``510 `FS_IOC_ADD_ENCRYPTION_KEY`_. Then, the ``key_spec.u.identifier``
511 the kernel returned in the :c:type:`struct fscrypt_add_key_arg` must511 the kernel returned in the struct fscrypt_add_key_arg must
512 be used as the ``master_key_identifier`` in the :c:type:`struct512 be used as the ``master_key_identifier`` in
513 fscrypt_policy_v2`.513 struct fscrypt_policy_v2.
514 514
515If the file is not yet encrypted, then FS_IOC_SET_ENCRYPTION_POLICY515If the file is not yet encrypted, then FS_IOC_SET_ENCRYPTION_POLICY
516verifies that the file is an empty directory. If so, the specified516verifies that the file is an empty directory. If so, the specified
@@ -590,7 +590,7 @@ FS_IOC_GET_ENCRYPTION_POLICY_EX · 73 unmodified lines
590The FS_IOC_GET_ENCRYPTION_POLICY_EX ioctl retrieves the encryption590The FS_IOC_GET_ENCRYPTION_POLICY_EX ioctl retrieves the encryption
591policy, if any, for a directory or regular file. No additional591policy, if any, for a directory or regular file. No additional
592permissions are required beyond the ability to open the file. It592permissions are required beyond the ability to open the file. It
593takes in a pointer to a :c:type:`struct fscrypt_get_policy_ex_arg`,593takes in a pointer to struct fscrypt_get_policy_ex_arg,
594defined as follows::594defined as follows::
595 595
596 struct fscrypt_get_policy_ex_arg {596 struct fscrypt_get_policy_ex_arg {
@@ -637,9 +637,8 @@ The FS_IOC_GET_ENCRYPTION_POLICY ioctl can also retrieve the · 40 unmodified lines
637encryption policy, if any, for a directory or regular file. However,637encryption policy, if any, for a directory or regular file. However,
638unlike `FS_IOC_GET_ENCRYPTION_POLICY_EX`_,638unlike `FS_IOC_GET_ENCRYPTION_POLICY_EX`_,
639FS_IOC_GET_ENCRYPTION_POLICY only supports the original policy639FS_IOC_GET_ENCRYPTION_POLICY only supports the original policy
640version. It takes in a pointer directly to a :c:type:`struct640version. It takes in a pointer directly to struct fscrypt_policy_v1
641fscrypt_policy_v1` rather than a :c:type:`struct641rather than struct fscrypt_get_policy_ex_arg.
642fscrypt_get_policy_ex_arg`.
643 642
644The error codes for FS_IOC_GET_ENCRYPTION_POLICY are the same as those643The error codes for FS_IOC_GET_ENCRYPTION_POLICY are the same as those
645for FS_IOC_GET_ENCRYPTION_POLICY_EX, except that644for FS_IOC_GET_ENCRYPTION_POLICY_EX, except that
@@ -680,8 +679,7 @@ the filesystem, making all files on the filesystem which were · 34 unmodified lines
680encrypted using that key appear "unlocked", i.e. in plaintext form.679encrypted using that key appear "unlocked", i.e. in plaintext form.
681It can be executed on any file or directory on the target filesystem,680It can be executed on any file or directory on the target filesystem,
682but using the filesystem's root directory is recommended. It takes in681but using the filesystem's root directory is recommended. It takes in
683a pointer to a :c:type:`struct fscrypt_add_key_arg`, defined as682a pointer to struct fscrypt_add_key_arg, defined as follows::
684follows::
685 683
686 struct fscrypt_add_key_arg {684 struct fscrypt_add_key_arg {
687 struct fscrypt_key_specifier key_spec;685 struct fscrypt_key_specifier key_spec;
@@ -710,17 +708,16 @@ follows:: · 22 unmodified lines
710 __u8 raw[];708 __u8 raw[];
711 };709 };
712 710
713:c:type:`struct fscrypt_add_key_arg` must be zeroed, then initialized711struct fscrypt_add_key_arg must be zeroed, then initialized
714as follows:712as follows:
715 713
716- If the key is being added for use by v1 encryption policies, then714- If the key is being added for use by v1 encryption policies, then
717 ``key_spec.type`` must contain FSCRYPT_KEY_SPEC_TYPE_DESCRIPTOR, and715 ``key_spec.type`` must contain FSCRYPT_KEY_SPEC_TYPE_DESCRIPTOR, and
718 ``key_spec.u.descriptor`` must contain the descriptor of the key716 ``key_spec.u.descriptor`` must contain the descriptor of the key
719 being added, corresponding to the value in the717 being added, corresponding to the value in the
720 ``master_key_descriptor`` field of :c:type:`struct718 ``master_key_descriptor`` field of struct fscrypt_policy_v1.
721 fscrypt_policy_v1`. To add this type of key, the calling process719 To add this type of key, the calling process must have the
722 must have the CAP_SYS_ADMIN capability in the initial user720 CAP_SYS_ADMIN capability in the initial user namespace.
723 namespace.
724 721
725 Alternatively, if the key is being added for use by v2 encryption722 Alternatively, if the key is being added for use by v2 encryption
726 policies, then ``key_spec.type`` must contain723 policies, then ``key_spec.type`` must contain
@@ -737,12 +734,13 @@ as follows: · 10 unmodified lines
737 734
738- ``key_id`` is 0 if the raw key is given directly in the ``raw``735- ``key_id`` is 0 if the raw key is given directly in the ``raw``
739 field. Otherwise ``key_id`` is the ID of a Linux keyring key of736 field. Otherwise ``key_id`` is the ID of a Linux keyring key of
740 type "fscrypt-provisioning" whose payload is a :c:type:`struct737 type "fscrypt-provisioning" whose payload is
741 fscrypt_provisioning_key_payload` whose ``raw`` field contains the738 struct fscrypt_provisioning_key_payload whose ``raw`` field contains
742 raw key and whose ``type`` field matches ``key_spec.type``. Since739 the raw key and whose ``type`` field matches ``key_spec.type``.
743 ``raw`` is variable-length, the total size of this key's payload740 Since ``raw`` is variable-length, the total size of this key's
744 must be ``sizeof(struct fscrypt_provisioning_key_payload)`` plus the741 payload must be ``sizeof(struct fscrypt_provisioning_key_payload)``
745 raw key size. The process must have Search permission on this key.742 plus the raw key size. The process must have Search permission on
743 this key.
746 744
747 Most users should leave this 0 and specify the raw key directly.745 Most users should leave this 0 and specify the raw key directly.
748 The support for specifying a Linux keyring key is intended mainly to746 The support for specifying a Linux keyring key is intended mainly to
@@ -860,8 +858,8 @@ The FS_IOC_REMOVE_ENCRYPTION_KEY ioctl removes a claim to a master · 111 unmodified lines
860encryption key from the filesystem, and possibly removes the key858encryption key from the filesystem, and possibly removes the key
861itself. It can be executed on any file or directory on the target859itself. It can be executed on any file or directory on the target
862filesystem, but using the filesystem's root directory is recommended.860filesystem, but using the filesystem's root directory is recommended.
863It takes in a pointer to a :c:type:`struct fscrypt_remove_key_arg`,861It takes in a pointer to struct fscrypt_remove_key_arg, defined
864defined as follows::862as follows::
865 863
866 struct fscrypt_remove_key_arg {864 struct fscrypt_remove_key_arg {
867 struct fscrypt_key_specifier key_spec;865 struct fscrypt_key_specifier key_spec;
@@ -956,8 +954,8 @@ FS_IOC_GET_ENCRYPTION_KEY_STATUS · 88 unmodified lines
956The FS_IOC_GET_ENCRYPTION_KEY_STATUS ioctl retrieves the status of a954The FS_IOC_GET_ENCRYPTION_KEY_STATUS ioctl retrieves the status of a
957master encryption key. It can be executed on any file or directory on955master encryption key. It can be executed on any file or directory on
958the target filesystem, but using the filesystem's root directory is956the target filesystem, but using the filesystem's root directory is
959recommended. It takes in a pointer to a :c:type:`struct957recommended. It takes in a pointer to
960fscrypt_get_key_status_arg`, defined as follows::958struct fscrypt_get_key_status_arg, defined as follows::
961 959
962 struct fscrypt_get_key_status_arg {960 struct fscrypt_get_key_status_arg {
963 /* input */961 /* input */
@@ -1148,10 +1146,10 @@ Implementation details · 184 unmodified lines
1148Encryption context1146Encryption context
1149------------------1147------------------
1150 1148
1151An encryption policy is represented on-disk by a :c:type:`struct1149An encryption policy is represented on-disk by
1152fscrypt_context_v1` or a :c:type:`struct fscrypt_context_v2`. It is1150struct fscrypt_context_v1 or struct fscrypt_context_v2. It is up to
1153up to individual filesystems to decide where to store it, but normally1151individual filesystems to decide where to store it, but normally it
1154it would be stored in a hidden extended attribute. It should *not* be1152would be stored in a hidden extended attribute. It should *not* be
1155exposed by the xattr-related system calls such as getxattr() and1153exposed by the xattr-related system calls such as getxattr() and
1156setxattr() because of the special semantics of the encryption xattr.1154setxattr() because of the special semantics of the encryption xattr.
1157(In particular, there would be much confusion if an encryption policy1155(In particular, there would be much confusion if an encryption policy
@@ -1249,8 +1247,8 @@ a strong "hash" of the ciphertext filename, along with the optional · 91 unmodified lines
1249filesystem-specific hash(es) needed for directory lookups. This1247filesystem-specific hash(es) needed for directory lookups. This
1250allows the filesystem to still, with a high degree of confidence, map1248allows the filesystem to still, with a high degree of confidence, map
1251the filename given in ->lookup() back to a particular directory entry1249the filename given in ->lookup() back to a particular directory entry
1252that was previously listed by readdir(). See :c:type:`struct1250that was previously listed by readdir(). See
1253fscrypt_nokey_name` in the source for more details.1251struct fscrypt_nokey_name in the source for more details.
1254 1252
1255Note that the precise way that filenames are presented to userspace1253Note that the precise way that filenames are presented to userspace
1256without the key is subject to change in the future. It is only meant1254without the key is subject to change in the future. It is only meant
Documentation/filesystems/fsverity.rst+1−1
@@ -84,7 +84,7 @@ FS_IOC_ENABLE_VERITY · 83 unmodified lines
84--------------------84--------------------
85 85
86The FS_IOC_ENABLE_VERITY ioctl enables fs-verity on a file. It takes86The FS_IOC_ENABLE_VERITY ioctl enables fs-verity on a file. It takes
87in a pointer to a :c:type:`struct fsverity_enable_arg`, defined as87in a pointer to a struct fsverity_enable_arg, defined as
88follows::88follows::
89 89
90 struct fsverity_enable_arg {90 struct fsverity_enable_arg {
Documentation/gpu/i915.rst+25−4
@@ -636,15 +636,36 @@ i915 Perf Observation Architecture Stream · 635 unmodified lines
636.. kernel-doc:: drivers/gpu/drm/i915/i915_perf.c636.. kernel-doc:: drivers/gpu/drm/i915/i915_perf.c
637 :functions: i915_oa_poll_wait637 :functions: i915_oa_poll_wait
638 638
639All i915 Perf Internals639Other i915 Perf Internals
640-----------------------640-------------------------
641 641
642This section simply includes all currently documented i915 perf internals, in642This section simply includes all other currently documented i915 perf internals,
643no particular order, but may include some more minor utilities or platform643in no particular order, but may include some more minor utilities or platform
644specific details than found in the more high-level sections.644specific details than found in the more high-level sections.
645 645
646.. kernel-doc:: drivers/gpu/drm/i915/i915_perf.c646.. kernel-doc:: drivers/gpu/drm/i915/i915_perf.c
647 :internal:647 :internal:
648 :no-identifiers:
649 i915_perf_init
650 i915_perf_fini
651 i915_perf_register
652 i915_perf_unregister
653 i915_perf_open_ioctl
654 i915_perf_release
655 i915_perf_add_config_ioctl
656 i915_perf_remove_config_ioctl
657 read_properties_unlocked
658 i915_perf_open_ioctl_locked
659 i915_perf_destroy_locked
660 i915_perf_read i915_perf_ioctl
661 i915_perf_enable_locked
662 i915_perf_disable_locked
663 i915_perf_poll i915_perf_poll_locked
664 i915_oa_stream_init i915_oa_read
665 i915_oa_stream_enable
666 i915_oa_stream_disable
667 i915_oa_wait_unlocked
668 i915_oa_poll_wait
648 669
649Style670Style
650=====671=====
Documentation/networking/ieee802154.rst+10−8
@@ -26,7 +26,9 @@ The stack is composed of three main parts: · 25 unmodified lines
26Socket API26Socket API
27==========27==========
28 28
29.. c:function:: int sd = socket(PF_IEEE802154, SOCK_DGRAM, 0);29::
30
31 int sd = socket(PF_IEEE802154, SOCK_DGRAM, 0);
30 32
31The address family, socket addresses etc. are defined in the33The address family, socket addresses etc. are defined in the
32include/net/af_ieee802154.h header or in the special header34include/net/af_ieee802154.h header or in the special header
@@ -131,12 +133,12 @@ Register PHY in the system. · 98 unmodified lines
131 133
132Freeing registered PHY.134Freeing registered PHY.
133 135
134.. c:function:: void ieee802154_rx_irqsafe(struct ieee802154_hw *hw, struct sk_buff *skb, u8 lqi):136.. c:function:: void ieee802154_rx_irqsafe(struct ieee802154_hw *hw, struct sk_buff *skb, u8 lqi)
135 137
136Telling 802.15.4 module there is a new received frame in the skb with138Telling 802.15.4 module there is a new received frame in the skb with
137the RF Link Quality Indicator (LQI) from the hardware device.139the RF Link Quality Indicator (LQI) from the hardware device.
138 140
139.. c:function:: void ieee802154_xmit_complete(struct ieee802154_hw *hw, struct sk_buff *skb, bool ifs_handling):141.. c:function:: void ieee802154_xmit_complete(struct ieee802154_hw *hw, struct sk_buff *skb, bool ifs_handling)
140 142
141Telling 802.15.4 module the frame in the skb is or going to be143Telling 802.15.4 module the frame in the skb is or going to be
142transmitted through the hardware device144transmitted through the hardware device
@@ -155,25 +157,25 @@ operations structure at least:: · 12 unmodified lines
155 ...157 ...
156 };158 };
157 159
158.. c:function:: int start(struct ieee802154_hw *hw):160.. c:function:: int start(struct ieee802154_hw *hw)
159 161
160Handler that 802.15.4 module calls for the hardware device initialization.162Handler that 802.15.4 module calls for the hardware device initialization.
161 163
162.. c:function:: void stop(struct ieee802154_hw *hw):164.. c:function:: void stop(struct ieee802154_hw *hw)
163 165
164Handler that 802.15.4 module calls for the hardware device cleanup.166Handler that 802.15.4 module calls for the hardware device cleanup.
165 167
166.. c:function:: int xmit_async(struct ieee802154_hw *hw, struct sk_buff *skb):168.. c:function:: int xmit_async(struct ieee802154_hw *hw, struct sk_buff *skb)
167 169
168Handler that 802.15.4 module calls for each frame in the skb going to be170Handler that 802.15.4 module calls for each frame in the skb going to be
169transmitted through the hardware device.171transmitted through the hardware device.
170 172
171.. c:function:: int ed(struct ieee802154_hw *hw, u8 *level):173.. c:function:: int ed(struct ieee802154_hw *hw, u8 *level)
172 174
173Handler that 802.15.4 module calls for Energy Detection from the hardware175Handler that 802.15.4 module calls for Energy Detection from the hardware
174device.176device.
175 177
176.. c:function:: int set_channel(struct ieee802154_hw *hw, u8 page, u8 channel):178.. c:function:: int set_channel(struct ieee802154_hw *hw, u8 page, u8 channel)
177 179
178Set radio for listening on specific channel of the hardware device.180Set radio for listening on specific channel of the hardware device.
179 181
Documentation/powerpc/syscall64-abi.rst+16−16
@@ -49,22 +49,22 @@ Register preservation rules · 48 unmodified lines
49Register preservation rules match the ELF ABI calling sequence with the49Register preservation rules match the ELF ABI calling sequence with the
50following differences:50following differences:
51 51
52--- For the sc instruction, differences with the ELF ABI ---52+------------------------------------------------------------------------+
53=========== ============= ========================================53| For the sc instruction, differences with the ELF ABI |
54r0 Volatile (System call number.)54+--------------+--------------+------------------------------------------+
55r3 Volatile (Parameter 1, and return value.)55| r0 | Volatile | (System call number.) |
56r4-r8 Volatile (Parameters 2-6.)56| rr3 | Volatile | (Parameter 1, and return value.) |
57cr0 Volatile (cr0.SO is the return error condition.)57| rr4-r8 | Volatile | (Parameters 2-6.) |
58cr1, cr5-7 Nonvolatile58| rcr0 | Volatile | (cr0.SO is the return error condition.) |
59lr Nonvolatile59| rcr1, cr5-7 | Nonvolatile | |
60=========== ============= ========================================60| rlr | Nonvolatile | |
61 61+--------------+--------------+------------------------------------------+
62--- For the scv 0 instruction, differences with the ELF ABI ---62| For the scv 0 instruction, differences with the ELF ABI |
63=========== ============= ========================================63+--------------+--------------+------------------------------------------+
64r0 Volatile (System call number.)64| r0 | Volatile | (System call number.) |
65r3 Volatile (Parameter 1, and return value.)65| r3 | Volatile | (Parameter 1, and return value.) |
66r4-r8 Volatile (Parameters 2-6.)66| r4-r8 | Volatile | (Parameters 2-6.) |
67=========== ============= ========================================67+--------------+--------------+------------------------------------------+
68 68
69All floating point and vector data registers as well as control and status69All floating point and vector data registers as well as control and status
70registers are nonvolatile.70registers are nonvolatile.
Documentation/sound/designs/tracepoints.rst+11−11
@@ -34,20 +34,20 @@ substream. In this procedure, PCM hardware parameters are decided by · 33 unmodified lines
34interaction between applications and ALSA PCM core. Once decided, runtime of34interaction between applications and ALSA PCM core. Once decided, runtime of
35the PCM substream keeps the parameters.35the PCM substream keeps the parameters.
36 36
37The parameters are described in :c:type:`struct snd_pcm_hw_params`. This37The parameters are described in struct snd_pcm_hw_params. This
38structure includes several types of parameters. Applications set preferable38structure includes several types of parameters. Applications set preferable
39value to these parameters, then execute ioctl(2) with SNDRV_PCM_IOCTL_HW_REFINE39value to these parameters, then execute ioctl(2) with SNDRV_PCM_IOCTL_HW_REFINE
40or SNDRV_PCM_IOCTL_HW_PARAMS. The former is used just for refining available40or SNDRV_PCM_IOCTL_HW_PARAMS. The former is used just for refining available
41set of parameters. The latter is used for an actual decision of the parameters.41set of parameters. The latter is used for an actual decision of the parameters.
42 42
43The :c:type:`struct snd_pcm_hw_params` structure has below members:43The struct snd_pcm_hw_params structure has below members:
44 44
45``flags``45``flags``
46 Configurable. ALSA PCM core and some drivers handle this flag to select46 Configurable. ALSA PCM core and some drivers handle this flag to select
47 convenient parameters or change their behaviour.47 convenient parameters or change their behaviour.
48``masks``48``masks``
49 Configurable. This type of parameter is described in49 Configurable. This type of parameter is described in
50 :c:type:`struct snd_mask` and represent mask values. As of PCM protocol50 struct snd_mask and represent mask values. As of PCM protocol
51 v2.0.13, three types are defined.51 v2.0.13, three types are defined.
52 52
53 - SNDRV_PCM_HW_PARAM_ACCESS53 - SNDRV_PCM_HW_PARAM_ACCESS
@@ -55,7 +55,7 @@ The :c:type:`struct snd_pcm_hw_params` structure has below members: · 1 unmodified line
55 - SNDRV_PCM_HW_PARAM_SUBFORMAT55 - SNDRV_PCM_HW_PARAM_SUBFORMAT
56``intervals``56``intervals``
57 Configurable. This type of parameter is described in57 Configurable. This type of parameter is described in
58 :c:type:`struct snd_interval` and represent values with a range. As of58 struct snd_interval and represent values with a range. As of
59 PCM protocol v2.0.13, twelve types are defined.59 PCM protocol v2.0.13, twelve types are defined.
60 60
61 - SNDRV_PCM_HW_PARAM_SAMPLE_BITS61 - SNDRV_PCM_HW_PARAM_SAMPLE_BITS
@@ -78,7 +78,7 @@ The :c:type:`struct snd_pcm_hw_params` structure has below members: · 16 unmodified lines
78 are going to be changed.78 are going to be changed.
79``cmask``79``cmask``
80 Read-only. After returning from ioctl(2), buffer in user space for80 Read-only. After returning from ioctl(2), buffer in user space for
81 :c:type:`struct snd_pcm_hw_params` includes result of each operation.81 struct snd_pcm_hw_params includes result of each operation.
82 This mask represents which mask/interval parameter is actually changed.82 This mask represents which mask/interval parameter is actually changed.
83``info``83``info``
84 Read-only. This represents hardware/driver capabilities as bit flags84 Read-only. This represents hardware/driver capabilities as bit flags
@@ -110,10 +110,10 @@ The :c:type:`struct snd_pcm_hw_params` structure has below members: · 25 unmodified lines
110 value to this parameter but some drivers intentionally set zero with110 value to this parameter but some drivers intentionally set zero with
111 a care of hardware design or data transmission protocol.111 a care of hardware design or data transmission protocol.
112 112
113ALSA PCM core handles buffer of :c:type:`struct snd_pcm_hw_params` when113ALSA PCM core handles buffer of struct snd_pcm_hw_params when
114applications execute ioctl(2) with SNDRV_PCM_HW_REFINE or SNDRV_PCM_HW_PARAMS.114applications execute ioctl(2) with SNDRV_PCM_HW_REFINE or SNDRV_PCM_HW_PARAMS.
115Parameters in the buffer are changed according to115Parameters in the buffer are changed according to
116:c:type:`struct snd_pcm_hardware` and rules of constraints in the runtime. The116struct snd_pcm_hardware and rules of constraints in the runtime. The
117structure describes capabilities of handled hardware. The rules describes117structure describes capabilities of handled hardware. The rules describes
118dependencies on which a parameter is decided according to several parameters.118dependencies on which a parameter is decided according to several parameters.
119A rule has a callback function, and drivers can register arbitrary functions119A rule has a callback function, and drivers can register arbitrary functions
@@ -121,17 +121,17 @@ to compute the target parameter. ALSA PCM core registers some rules to the · 1 unmodified line
121runtime as a default.121runtime as a default.
122 122
123Each driver can join in the interaction as long as it prepared for two stuffs123Each driver can join in the interaction as long as it prepared for two stuffs
124in a callback of :c:type:`struct snd_pcm_ops.open`.124in a callback of struct snd_pcm_ops.open.
125 125
1261. In the callback, drivers are expected to change a member of1261. In the callback, drivers are expected to change a member of
127 :c:type:`struct snd_pcm_hardware` type in the runtime, according to127 struct snd_pcm_hardware type in the runtime, according to
128 capacities of corresponding hardware.128 capacities of corresponding hardware.
1292. In the same callback, drivers are also expected to register additional rules1292. In the same callback, drivers are also expected to register additional rules
130 of constraints into the runtime when several parameters have dependencies130 of constraints into the runtime when several parameters have dependencies
131 due to hardware design.131 due to hardware design.
132 132
133The driver can refers to result of the interaction in a callback of133The driver can refers to result of the interaction in a callback of
134:c:type:`struct snd_pcm_ops.hw_params`, however it should not change the134struct snd_pcm_ops.hw_params, however it should not change the
135content.135content.
136 136
137Tracepoints in this category are designed to trace changes of the137Tracepoints in this category are designed to trace changes of the
@@ -163,7 +163,7 @@ fields are different according to type of the parameter. For parameters of mask · 25 unmodified lines
163type, the fields represent hexadecimal dump of content of the parameter. For163type, the fields represent hexadecimal dump of content of the parameter. For
164parameters of interval type, the fields represent values of each member of164parameters of interval type, the fields represent values of each member of
165``empty``, ``integer``, ``openmin``, ``min``, ``max``, ``openmax`` in165``empty``, ``integer``, ``openmin``, ``min``, ``max``, ``openmax`` in
166:c:type:`struct snd_interval` in this order.166struct snd_interval in this order.
167 167
168Tracepoints in drivers168Tracepoints in drivers
169======================169======================
Documentation/sound/kernel-api/alsa-driver-api.rst+1−0
@@ -132,3 +132,4 @@ ISA DMA Helpers · 131 unmodified lines
132Other Helper Macros132Other Helper Macros
133-------------------133-------------------
134.. kernel-doc:: include/sound/core.h134.. kernel-doc:: include/sound/core.h
135.. kernel-doc:: sound/sound_core.c
Documentation/sound/kernel-api/writing-an-alsa-driver.rst+49−61
@@ -194,7 +194,7 @@ The minimum flow for PCI soundcards is as follows: · 193 unmodified lines
194 194
195- create ``remove`` callback.195- create ``remove`` callback.
196 196
197- create a :c:type:`struct pci_driver <pci_driver>` structure197- create a struct pci_driver structure
198 containing the three pointers above.198 containing the three pointers above.
199 199
200- create an ``init`` function just calling the200- create an ``init`` function just calling the
@@ -487,7 +487,7 @@ The destructor, remove callback, simply releases the card instance. Then · 286 unmodified lines
487the ALSA middle layer will release all the attached components487the ALSA middle layer will release all the attached components
488automatically.488automatically.
489 489
490It would be typically just :c:func:`calling snd_card_free()`:490It would be typically just calling :c:func:`snd_card_free()`:
491 491
492::492::
493 493
@@ -560,16 +560,15 @@ return the card instance. The extra_size argument is used to allocate · 66 unmodified lines
560card->private_data for the chip-specific data. Note that these data are560card->private_data for the chip-specific data. Note that these data are
561allocated by :c:func:`snd_card_new()`.561allocated by :c:func:`snd_card_new()`.
562 562
563The first argument, the pointer of struct :c:type:`struct device563The first argument, the pointer of struct device, specifies the parent
564<device>`, specifies the parent device. For PCI devices, typically564device. For PCI devices, typically ``&pci->`` is passed there.
565``&pci->`` is passed there.
566 565
567Components566Components
568----------567----------
569 568
570After the card is created, you can attach the components (devices) to569After the card is created, you can attach the components (devices) to
571the card instance. In an ALSA driver, a component is represented as a570the card instance. In an ALSA driver, a component is represented as a
572:c:type:`struct snd_device <snd_device>` object. A component571struct snd_device object. A component
573can be a PCM instance, a control interface, a raw MIDI interface, etc.572can be a PCM instance, a control interface, a raw MIDI interface, etc.
574Each such instance has one component entry.573Each such instance has one component entry.
575 574
@@ -628,7 +627,7 @@ argument of :c:func:`snd_card_new()`, i.e. · 52 unmodified lines
628 err = snd_card_new(&pci->dev, index[dev], id[dev], THIS_MODULE,627 err = snd_card_new(&pci->dev, index[dev], id[dev], THIS_MODULE,
629 sizeof(struct mychip), &card);628 sizeof(struct mychip), &card);
630 629
631:c:type:`struct mychip <mychip>` is the type of the chip record.630struct mychip is the type of the chip record.
632 631
633In return, the allocated record can be accessed as632In return, the allocated record can be accessed as
634 633
@@ -890,7 +889,7 @@ functions. These resources must be released in the destructor · 255 unmodified lines
890function (see below).889function (see below).
891 890
892Now assume that the PCI device has an I/O port with 8 bytes and an891Now assume that the PCI device has an I/O port with 8 bytes and an
893interrupt. Then :c:type:`struct mychip <mychip>` will have the892interrupt. Then struct mychip will have the
894following fields:893following fields:
895 894
896::895::
@@ -1094,7 +1093,7 @@ PCI Entries · 197 unmodified lines
1094-----------1093-----------
1095 1094
1096So far, so good. Let's finish the missing PCI stuff. At first, we need a1095So far, so good. Let's finish the missing PCI stuff. At first, we need a
1097:c:type:`struct pci_device_id <pci_device_id>` table for1096struct pci_device_id table for
1098this chipset. It's a table of PCI vendor/device ID number, and some1097this chipset. It's a table of PCI vendor/device ID number, and some
1099masks.1098masks.
1100 1099
@@ -1110,19 +1109,17 @@ For example, · 9 unmodified lines
1110 };1109 };
1111 MODULE_DEVICE_TABLE(pci, snd_mychip_ids);1110 MODULE_DEVICE_TABLE(pci, snd_mychip_ids);
1112 1111
1113The first and second fields of the :c:type:`struct pci_device_id1112The first and second fields of the struct pci_device_id are the vendor
1114<pci_device_id>` structure are the vendor and device IDs. If you1113and device IDs. If you have no reason to filter the matching devices, you can
1115have no reason to filter the matching devices, you can leave the1114leave the remaining fields as above. The last field of the
1116remaining fields as above. The last field of the :c:type:`struct1115struct pci_device_id contains private data for this entry. You can specify
1117pci_device_id <pci_device_id>` struct contains private data1116any value here, for example, to define specific operations for supported
1118for this entry. You can specify any value here, for example, to define1117device IDs. Such an example is found in the intel8x0 driver.
1119specific operations for supported device IDs. Such an example is found
1120in the intel8x0 driver.
1121 1118
1122The last entry of this list is the terminator. You must specify this1119The last entry of this list is the terminator. You must specify this
1123all-zero entry.1120all-zero entry.
1124 1121
1125Then, prepare the :c:type:`struct pci_driver <pci_driver>`1122Then, prepare the struct pci_driver
1126record:1123record:
1127 1124
1128::1125::
@@ -1439,8 +1436,8 @@ corresponding argument. · 310 unmodified lines
1439If a chip supports multiple playbacks or captures, you can specify more1436If a chip supports multiple playbacks or captures, you can specify more
1440numbers, but they must be handled properly in open/close, etc.1437numbers, but they must be handled properly in open/close, etc.
1441callbacks. When you need to know which substream you are referring to,1438callbacks. When you need to know which substream you are referring to,
1442then it can be obtained from :c:type:`struct snd_pcm_substream1439then it can be obtained from struct snd_pcm_substream data passed to each
1443<snd_pcm_substream>` data passed to each callback as follows:1440callback as follows:
1444 1441
1445::1442::
1446 1443
@@ -1639,10 +1636,9 @@ In the sections below, important records are explained. · 192 unmodified lines
1639Hardware Description1636Hardware Description
1640~~~~~~~~~~~~~~~~~~~~1637~~~~~~~~~~~~~~~~~~~~
1641 1638
1642The hardware descriptor (:c:type:`struct snd_pcm_hardware1639The hardware descriptor (struct snd_pcm_hardware) contains the definitions of
1643<snd_pcm_hardware>`) contains the definitions of the fundamental1640the fundamental hardware configuration. Above all, you'll need to define this
1644hardware configuration. Above all, you'll need to define this in the1641in the `PCM open callback`_. Note that the runtime instance holds the copy of
1645`PCM open callback`_. Note that the runtime instance holds the copy of
1646the descriptor, not the pointer to the existing descriptor. That is,1642the descriptor, not the pointer to the existing descriptor. That is,
1647in the open callback, you can modify the copied descriptor1643in the open callback, you can modify the copied descriptor
1648(``runtime->hw``) as you need. For example, if the maximum number of1644(``runtime->hw``) as you need. For example, if the maximum number of
@@ -1800,14 +1796,13 @@ Running Status · 151 unmodified lines
1800~~~~~~~~~~~~~~1796~~~~~~~~~~~~~~
1801 1797
1802The running status can be referred via ``runtime->status``. This is1798The running status can be referred via ``runtime->status``. This is
1803the pointer to the :c:type:`struct snd_pcm_mmap_status1799the pointer to the struct snd_pcm_mmap_status record.
1804<snd_pcm_mmap_status>` record. For example, you can get the current1800For example, you can get the current
1805DMA hardware pointer via ``runtime->status->hw_ptr``.1801DMA hardware pointer via ``runtime->status->hw_ptr``.
1806 1802
1807The DMA application pointer can be referred via ``runtime->control``,1803The DMA application pointer can be referred via ``runtime->control``,
1808which points to the :c:type:`struct snd_pcm_mmap_control1804which points to the struct snd_pcm_mmap_control record.
1809<snd_pcm_mmap_control>` record. However, accessing directly to1805However, accessing directly to this value is not recommended.
1810this value is not recommended.
1811 1806
1812Private Data1807Private Data
1813~~~~~~~~~~~~1808~~~~~~~~~~~~
@@ -1843,8 +1838,8 @@ error number such as ``-EINVAL``. To choose an appropriate error · 29 unmodified lines
1843number, it is advised to check what value other parts of the kernel1838number, it is advised to check what value other parts of the kernel
1844return when the same kind of request fails.1839return when the same kind of request fails.
1845 1840
1846The callback function takes at least the argument with :c:type:`struct1841The callback function takes at least the argument with
1847snd_pcm_substream <snd_pcm_substream>` pointer. To retrieve the chip1842struct snd_pcm_substream pointer. To retrieve the chip
1848record from the given substream instance, you can use the following1843record from the given substream instance, you can use the following
1849macro.1844macro.
1850 1845
@@ -2313,10 +2308,10 @@ non-atomic contexts. For example, the function · 462 unmodified lines
2313:c:func:`snd_pcm_period_elapsed()` is called typically from the2308:c:func:`snd_pcm_period_elapsed()` is called typically from the
2314interrupt handler. But, if you set up the driver to use a threaded2309interrupt handler. But, if you set up the driver to use a threaded
2315interrupt handler, this call can be in non-atomic context, too. In such2310interrupt handler, this call can be in non-atomic context, too. In such
2316a case, you can set ``nonatomic`` filed of :c:type:`struct snd_pcm2311a case, you can set ``nonatomic`` filed of struct snd_pcm object
2317<snd_pcm>` object after creating it. When this flag is set, mutex2312after creating it. When this flag is set, mutex and rwsem are used internally
2318and rwsem are used internally in the PCM core instead of spin and2313in the PCM core instead of spin and rwlocks, so that you can call all PCM
2319rwlocks, so that you can call all PCM functions safely in a non-atomic2314functions safely in a non-atomic
2320context.2315context.
2321 2316
2322Constraints2317Constraints
@@ -2357,8 +2352,7 @@ There are many different constraints. Look at ``sound/pcm.h`` for a · 34 unmodified lines
2357complete list. You can even define your own constraint rules. For2352complete list. You can even define your own constraint rules. For
2358example, let's suppose my_chip can manage a substream of 1 channel if2353example, let's suppose my_chip can manage a substream of 1 channel if
2359and only if the format is ``S16_LE``, otherwise it supports any format2354and only if the format is ``S16_LE``, otherwise it supports any format
2360specified in the :c:type:`struct snd_pcm_hardware2355specified in struct snd_pcm_hardware> (or in any other
2361<snd_pcm_hardware>` structure (or in any other
2362constraint_list). You can build a rule like this:2356constraint_list). You can build a rule like this:
2363 2357
2364::2358::
@@ -2467,7 +2461,7 @@ Definition of Controls · 102 unmodified lines
2467 2461
2468To create a new control, you need to define the following three2462To create a new control, you need to define the following three
2469callbacks: ``info``, ``get`` and ``put``. Then, define a2463callbacks: ``info``, ``get`` and ``put``. Then, define a
2470:c:type:`struct snd_kcontrol_new <snd_kcontrol_new>` record, such as:2464struct snd_kcontrol_new record, such as:
2471 2465
2472::2466::
2473 2467
@@ -2602,8 +2596,8 @@ info callback · 128 unmodified lines
2602~~~~~~~~~~~~~2596~~~~~~~~~~~~~
2603 2597
2604The ``info`` callback is used to get detailed information on this2598The ``info`` callback is used to get detailed information on this
2605control. This must store the values of the given :c:type:`struct2599control. This must store the values of the given
2606snd_ctl_elem_info <snd_ctl_elem_info>` object. For example,2600struct snd_ctl_elem_info object. For example,
2607for a boolean control with a single element:2601for a boolean control with a single element:
2608 2602
2609::2603::
@@ -2774,13 +2768,11 @@ In the simplest way, you can do like this: · 164 unmodified lines
2774 if (err < 0)2768 if (err < 0)
2775 return err;2769 return err;
2776 2770
2777where ``my_control`` is the :c:type:`struct snd_kcontrol_new2771where ``my_control`` is the struct snd_kcontrol_new object defined above,
2778<snd_kcontrol_new>` object defined above, and chip is the object2772and chip is the object pointer to be passed to kcontrol->private_data which
2779pointer to be passed to kcontrol->private_data which can be referred2773can be referred to in callbacks.
2780to in callbacks.
2781 2774
2782:c:func:`snd_ctl_new1()` allocates a new :c:type:`struct2775:c:func:`snd_ctl_new1()` allocates a new struct snd_kcontrol instance, and
2783snd_kcontrol <snd_kcontrol>` instance, and
2784:c:func:`snd_ctl_add()` assigns the given control component to the2776:c:func:`snd_ctl_add()` assigns the given control component to the
2785card.2777card.
2786 2778
@@ -2797,10 +2789,9 @@ can call :c:func:`snd_ctl_notify()`. For example, · 10 unmodified lines
2797This function takes the card pointer, the event-mask, and the control id2789This function takes the card pointer, the event-mask, and the control id
2798pointer for the notification. The event-mask specifies the types of2790pointer for the notification. The event-mask specifies the types of
2799notification, for example, in the above example, the change of control2791notification, for example, in the above example, the change of control
2800values is notified. The id pointer is the pointer of :c:type:`struct2792values is notified. The id pointer is the pointer of struct snd_ctl_elem_id
2801snd_ctl_elem_id <snd_ctl_elem_id>` to be notified. You can2793to be notified. You can find some examples in ``es1938.c`` or ``es1968.c``
2802find some examples in ``es1938.c`` or ``es1968.c`` for hardware volume2794for hardware volume interrupts.
2803interrupts.
2804 2795
2805Metadata2796Metadata
2806--------2797--------
@@ -2915,9 +2906,8 @@ with an ``ac97_bus_ops_t`` record with callback functions. · 108 unmodified lines
2915 2906
2916The bus record is shared among all belonging ac97 instances.2907The bus record is shared among all belonging ac97 instances.
2917 2908
2918And then call :c:func:`snd_ac97_mixer()` with an :c:type:`struct2909And then call :c:func:`snd_ac97_mixer()` with an struct snd_ac97_template
2919snd_ac97_template <snd_ac97_template>` record together with2910record together with the bus pointer created above.
2920the bus pointer created above.
2921 2911
2922::2912::
2923 2913
@@ -3118,11 +3108,10 @@ devices on the card, set ``MPU401_INFO_IRQ_HOOK`` (see · 194 unmodified lines
3118 3108
3119Usually, the port address corresponds to the command port and port + 13109Usually, the port address corresponds to the command port and port + 1
3120corresponds to the data port. If not, you may change the ``cport``3110corresponds to the data port. If not, you may change the ``cport``
3121field of :c:type:`struct snd_mpu401 <snd_mpu401>` manually afterward.3111field of struct snd_mpu401 manually afterward.
3122However, :c:type:`struct snd_mpu401 <snd_mpu401>` pointer is3112However, struct snd_mpu401 pointer is
3123not returned explicitly by :c:func:`snd_mpu401_uart_new()`. You3113not returned explicitly by :c:func:`snd_mpu401_uart_new()`. You
3124need to cast ``rmidi->private_data`` to :c:type:`struct snd_mpu4013114need to cast ``rmidi->private_data`` to struct snd_mpu401 explicitly,
3125<snd_mpu401>` explicitly,
3126 3115
3127::3116::
3128 3117
@@ -3326,8 +3315,7 @@ data and removes them from the buffer at once: · 197 unmodified lines
3326 }3315 }
3327 3316
3328If you know beforehand how many bytes you can accept, you can use a3317If you know beforehand how many bytes you can accept, you can use a
3329buffer size greater than one with the3318buffer size greater than one with the ``snd_rawmidi_transmit*()`` functions.
3330:c:func:`snd_rawmidi_transmit\*()` functions.
3331 3319
3332The ``trigger`` callback must not sleep. If the hardware FIFO is full3320The ``trigger`` callback must not sleep. If the hardware FIFO is full
3333before the substream buffer has been emptied, you have to continue3321before the substream buffer has been emptied, you have to continue
@@ -3772,7 +3760,7 @@ For creating the SG-buffer handler, call · 438 unmodified lines
3772:c:func:`snd_pcm_set_managed_buffer_all()` with3760:c:func:`snd_pcm_set_managed_buffer_all()` with
3773``SNDRV_DMA_TYPE_DEV_SG`` in the PCM constructor like other PCI3761``SNDRV_DMA_TYPE_DEV_SG`` in the PCM constructor like other PCI
3774pre-allocator. You need to pass ``&pci->dev``, where pci is3762pre-allocator. You need to pass ``&pci->dev``, where pci is
3775the :c:type:`struct pci_dev <pci_dev>` pointer of the chip as3763the struct pci_dev pointer of the chip as
3776well.3764well.
3777 3765
3778::3766::
@@ -3927,7 +3915,7 @@ the maximum size of the proc file access. · 148 unmodified lines
3927 3915
3928The read/write callbacks of raw mode are more direct than the text mode.3916The read/write callbacks of raw mode are more direct than the text mode.
3929You need to use a low-level I/O functions such as3917You need to use a low-level I/O functions such as
3930:c:func:`copy_from/to_user()` to transfer the data.3918:c:func:`copy_from_user()` and :c:func:`copy_to_user()` to transfer the data.
3931 3919
3932::3920::
3933 3921
Documentation/sphinx/automarkup.py+97−11
@@ -22,13 +22,34 @@ from itertools import chain · 21 unmodified lines
22# :c:func: block (i.e. ":c:func:`mmap()`s" flakes out), so the last22# :c:func: block (i.e. ":c:func:`mmap()`s" flakes out), so the last
23# bit tries to restrict matches to things that won't create trouble.23# bit tries to restrict matches to things that won't create trouble.
24#24#
25RE_function = re.compile(r'(([\w_][\w\d_]+)\(\))')25RE_function = re.compile(r'\b(([a-zA-Z_]\w+)\(\))', flags=re.ASCII)
26RE_type = re.compile(r'(struct|union|enum|typedef)\s+([\w_][\w\d_]+)')26
27#
28# Sphinx 2 uses the same :c:type role for struct, union, enum and typedef
29#
30RE_generic_type = re.compile(r'\b(struct|union|enum|typedef)\s+([a-zA-Z_]\w+)',
31 flags=re.ASCII)
32
33#
34# Sphinx 3 uses a different C role for each one of struct, union, enum and
35# typedef
36#
37RE_struct = re.compile(r'\b(struct)\s+([a-zA-Z_]\w+)', flags=re.ASCII)
38RE_union = re.compile(r'\b(union)\s+([a-zA-Z_]\w+)', flags=re.ASCII)
39RE_enum = re.compile(r'\b(enum)\s+([a-zA-Z_]\w+)', flags=re.ASCII)
40RE_typedef = re.compile(r'\b(typedef)\s+([a-zA-Z_]\w+)', flags=re.ASCII)
41
27#42#
28# Detects a reference to a documentation page of the form Documentation/... with43# Detects a reference to a documentation page of the form Documentation/... with
29# an optional extension44# an optional extension
30#45#
31RE_doc = re.compile(r'Documentation(/[\w\-_/]+)(\.\w+)*')46RE_doc = re.compile(r'\bDocumentation(/[\w\-_/]+)(\.\w+)*')
47
48#
49# Reserved C words that we should skip when cross-referencing
50#
51Skipnames = [ 'for', 'if', 'register', 'sizeof', 'struct', 'unsigned' ]
52
32 53
33#54#
34# Many places in the docs refer to common system calls. It is55# Many places in the docs refer to common system calls. It is
@@ -48,9 +69,22 @@ def markup_refs(docname, app, node): · 13 unmodified lines
48 #69 #
49 # Associate each regex with the function that will markup its matches70 # Associate each regex with the function that will markup its matches
50 #71 #
51 markup_func = {RE_type: markup_c_ref,72 markup_func_sphinx2 = {RE_doc: markup_doc_ref,
52 RE_function: markup_c_ref,73 RE_function: markup_c_ref,
53 RE_doc: markup_doc_ref}74 RE_generic_type: markup_c_ref}
75
76 markup_func_sphinx3 = {RE_doc: markup_doc_ref,
77 RE_function: markup_func_ref_sphinx3,
78 RE_struct: markup_c_ref,
79 RE_union: markup_c_ref,
80 RE_enum: markup_c_ref,
81 RE_typedef: markup_c_ref}
82
83 if sphinx.version_info[0] >= 3:
84 markup_func = markup_func_sphinx3
85 else:
86 markup_func = markup_func_sphinx2
87
54 match_iterators = [regex.finditer(t) for regex in markup_func]88 match_iterators = [regex.finditer(t) for regex in markup_func]
55 #89 #
56 # Sort all references by the starting position in text90 # Sort all references by the starting position in text
@@ -75,12 +109,63 @@ def markup_refs(docname, app, node): · 18 unmodified lines
75 return repl109 return repl
76 110
77#111#
78# Try to replace a C reference (function() or struct/union/enum/typedef112# In sphinx3 we can cross-reference to C macro and function, each one with its
79# type_name) with an appropriate cross reference.113# own C role, but both match the same regex, so we try both.
80#114#
115def markup_func_ref_sphinx3(docname, app, match):
116 class_str = ['c-func', 'c-macro']
117 reftype_str = ['function', 'macro']
118
119 cdom = app.env.domains['c']
120 #
121 # Go through the dance of getting an xref out of the C domain
122 #
123 target = match.group(2)
124 target_text = nodes.Text(match.group(0))
125 xref = None
126 if not (target in Skipfuncs or target in Skipnames):
127 for class_s, reftype_s in zip(class_str, reftype_str):
128 lit_text = nodes.literal(classes=['xref', 'c', class_s])
129 lit_text += target_text
130 pxref = addnodes.pending_xref('', refdomain = 'c',
131 reftype = reftype_s,
132 reftarget = target, modname = None,
133 classname = None)
134 #
135 # XXX The Latex builder will throw NoUri exceptions here,
136 # work around that by ignoring them.
137 #
138 try:
139 xref = cdom.resolve_xref(app.env, docname, app.builder,
140 reftype_s, target, pxref,
141 lit_text)
142 except NoUri:
143 xref = None
144
145 if xref:
146 return xref
147
148 return target_text
149
81def markup_c_ref(docname, app, match):150def markup_c_ref(docname, app, match):
82 class_str = {RE_function: 'c-func', RE_type: 'c-type'}151 class_str = {# Sphinx 2 only
83 reftype_str = {RE_function: 'function', RE_type: 'type'}152 RE_function: 'c-func',
153 RE_generic_type: 'c-type',
154 # Sphinx 3+ only
155 RE_struct: 'c-struct',
156 RE_union: 'c-union',
157 RE_enum: 'c-enum',
158 RE_typedef: 'c-type',
159 }
160 reftype_str = {# Sphinx 2 only
161 RE_function: 'function',
162 RE_generic_type: 'type',
163 # Sphinx 3+ only
164 RE_struct: 'struct',
165 RE_union: 'union',
166 RE_enum: 'enum',
167 RE_typedef: 'type',
168 }
84 169
85 cdom = app.env.domains['c']170 cdom = app.env.domains['c']
86 #171 #
@@ -89,7 +174,8 @@ def markup_c_ref(docname, app, match): · 2 unmodified lines
89 target = match.group(2)174 target = match.group(2)
90 target_text = nodes.Text(match.group(0))175 target_text = nodes.Text(match.group(0))
91 xref = None176 xref = None
92 if not (match.re == RE_function and target in Skipfuncs):177 if not ((match.re == RE_function and target in Skipfuncs)
178 or (target in Skipnames)):
93 lit_text = nodes.literal(classes=['xref', 'c', class_str[match.re]])179 lit_text = nodes.literal(classes=['xref', 'c', class_str[match.re]])
94 lit_text += target_text180 lit_text += target_text
95 pxref = addnodes.pending_xref('', refdomain = 'c',181 pxref = addnodes.pending_xref('', refdomain = 'c',
Documentation/sphinx/cdomain.py+92−1
@@ -40,14 +40,94 @@ from sphinx import addnodes · 39 unmodified lines
40from sphinx.domains.c import c_funcptr_sig_re, c_sig_re40from sphinx.domains.c import c_funcptr_sig_re, c_sig_re
41from sphinx.domains.c import CObject as Base_CObject41from sphinx.domains.c import CObject as Base_CObject
42from sphinx.domains.c import CDomain as Base_CDomain42from sphinx.domains.c import CDomain as Base_CDomain
43from itertools import chain
44import re
43 45
44__version__ = '1.0'46__version__ = '1.1'
45 47
46# Get Sphinx version48# Get Sphinx version
47major, minor, patch = sphinx.version_info[:3]49major, minor, patch = sphinx.version_info[:3]
48 50
51# Namespace to be prepended to the full name
52namespace = None
53
54#
55# Handle trivial newer c domain tags that are part of Sphinx 3.1 c domain tags
56# - Store the namespace if ".. c:namespace::" tag is found
57#
58RE_namespace = re.compile(r'^\s*..\s*c:namespace::\s*(\S+)\s*$')
59
60def markup_namespace(match):
61 global namespace
62
63 namespace = match.group(1)
64
65 return ""
66
67#
68# Handle c:macro for function-style declaration
69#
70RE_macro = re.compile(r'^\s*..\s*c:macro::\s*(\S+)\s+(\S.*)\s*$')
71def markup_macro(match):
72 return ".. c:function:: " + match.group(1) + ' ' + match.group(2)
73
74#
75# Handle newer c domain tags that are evaluated as .. c:type: for
76# backward-compatibility with Sphinx < 3.0
77#
78RE_ctype = re.compile(r'^\s*..\s*c:(struct|union|enum|enumerator|alias)::\s*(.*)$')
79
80def markup_ctype(match):
81 return ".. c:type:: " + match.group(2)
82
83#
84# Handle newer c domain tags that are evaluated as :c:type: for
85# backward-compatibility with Sphinx < 3.0
86#
87RE_ctype_refs = re.compile(r':c:(var|struct|union|enum|enumerator)::`([^\`]+)`')
88def markup_ctype_refs(match):
89 return ":c:type:`" + match.group(2) + '`'
90
91#
92# Simply convert :c:expr: and :c:texpr: into a literal block.
93#
94RE_expr = re.compile(r':c:(expr|texpr):`([^\`]+)`')
95def markup_c_expr(match):
96 return '\ ``' + match.group(2) + '``\ '
97
98#
99# Parse Sphinx 3.x C markups, replacing them by backward-compatible ones
100#
101def c_markups(app, docname, source):
102 result = ""
103 markup_func = {
104 RE_namespace: markup_namespace,
105 RE_expr: markup_c_expr,
106 RE_macro: markup_macro,
107 RE_ctype: markup_ctype,
108 RE_ctype_refs: markup_ctype_refs,
109 }
110
111 lines = iter(source[0].splitlines(True))
112 for n in lines:
113 match_iterators = [regex.finditer(n) for regex in markup_func]
114 matches = sorted(chain(*match_iterators), key=lambda m: m.start())
115 for m in matches:
116 n = n[:m.start()] + markup_func[m.re](m) + n[m.end():]
117
118 result = result + n
119
120 source[0] = result
121
122#
123# Now implements support for the cdomain namespacing logic
124#
125
49def setup(app):126def setup(app):
50 127
128 # Handle easy Sphinx 3.1+ simple new tags: :c:expr and .. c:namespace::
129 app.connect('source-read', c_markups)
130
51 if (major == 1 and minor < 8):131 if (major == 1 and minor < 8):
52 app.override_domain(CDomain)132 app.override_domain(CDomain)
53 else:133 else:
@@ -75,6 +155,8 @@ class CObject(Base_CObject): · 21 unmodified lines
75 function-like macro, the name of the macro is returned. Otherwise155 function-like macro, the name of the macro is returned. Otherwise
76 ``False`` is returned. """156 ``False`` is returned. """
77 157
158 global namespace
159
78 if not self.objtype == 'function':160 if not self.objtype == 'function':
79 return False161 return False
80 162
@@ -107,11 +189,16 @@ class CObject(Base_CObject): · 26 unmodified lines
107 param += nodes.emphasis(argname, argname)189 param += nodes.emphasis(argname, argname)
108 paramlist += param190 paramlist += param
109 191
192 if namespace:
193 fullname = namespace + "." + fullname
194
110 return fullname195 return fullname
111 196
112 def handle_signature(self, sig, signode):197 def handle_signature(self, sig, signode):
113 """Transform a C signature into RST nodes."""198 """Transform a C signature into RST nodes."""
114 199
200 global namespace
201
115 fullname = self.handle_func_like_macro(sig, signode)202 fullname = self.handle_func_like_macro(sig, signode)
116 if not fullname:203 if not fullname:
117 fullname = super(CObject, self).handle_signature(sig, signode)204 fullname = super(CObject, self).handle_signature(sig, signode)
@@ -122,6 +209,10 @@ class CObject(Base_CObject): · 4 unmodified lines
122 else:209 else:
123 # FIXME: handle :name: value of other declaration types?210 # FIXME: handle :name: value of other declaration types?
124 pass211 pass
212 else:
213 if namespace:
214 fullname = namespace + "." + fullname
215
125 return fullname216 return fullname
126 217
127 def add_target_and_index(self, name, sig, signode):218 def add_target_and_index(self, name, sig, signode):
Documentation/sphinx/kerneldoc.py+14−1
@@ -62,6 +62,7 @@ class KernelDocDirective(Directive): · 61 unmodified lines
62 'export': directives.unchanged,62 'export': directives.unchanged,
63 'internal': directives.unchanged,63 'internal': directives.unchanged,
64 'identifiers': directives.unchanged,64 'identifiers': directives.unchanged,
65 'no-identifiers': directives.unchanged,
65 'functions': directives.unchanged,66 'functions': directives.unchanged,
66 }67 }
67 has_content = False68 has_content = False
@@ -70,6 +71,11 @@ class KernelDocDirective(Directive): · 2 unmodified lines
70 env = self.state.document.settings.env71 env = self.state.document.settings.env
71 cmd = [env.config.kerneldoc_bin, '-rst', '-enable-lineno']72 cmd = [env.config.kerneldoc_bin, '-rst', '-enable-lineno']
72 73
74 # Pass the version string to kernel-doc, as it needs to use a different
75 # dialect, depending what the C domain supports for each specific
76 # Sphinx versions
77 cmd += ['-sphinx-version', sphinx.__version__]
78
73 filename = env.config.kerneldoc_srctree + '/' + self.arguments[0]79 filename = env.config.kerneldoc_srctree + '/' + self.arguments[0]
74 export_file_patterns = []80 export_file_patterns = []
75 81
@@ -99,6 +105,12 @@ class KernelDocDirective(Directive): · 23 unmodified lines
99 else:105 else:
100 cmd += ['-no-doc-sections']106 cmd += ['-no-doc-sections']
101 107
108 if 'no-identifiers' in self.options:
109 no_identifiers = self.options.get('no-identifiers').split()
110 if no_identifiers:
111 for i in no_identifiers:
112 cmd += ['-nosymbol', i]
113
102 for pattern in export_file_patterns:114 for pattern in export_file_patterns:
103 for f in glob.glob(env.config.kerneldoc_srctree + '/' + pattern):115 for f in glob.glob(env.config.kerneldoc_srctree + '/' + pattern):
104 env.note_dependency(os.path.abspath(f))116 env.note_dependency(os.path.abspath(f))
@@ -136,7 +148,8 @@ class KernelDocDirective(Directive): · 31 unmodified lines
136 lineoffset = int(match.group(1)) - 1148 lineoffset = int(match.group(1)) - 1
137 # we must eat our comments since the upset the markup149 # we must eat our comments since the upset the markup
138 else:150 else:
139 result.append(line, filename, lineoffset)151 doc = env.srcdir + "/" + env.docname + ":" + str(self.lineno)
152 result.append(line, doc + ": " + filename, lineoffset)
140 lineoffset += 1153 lineoffset += 1
141 154
142 node = nodes.section()155 node = nodes.section()
Documentation/sphinx/parse-headers.pl+1−1
@@ -110,7 +110,7 @@ while (<IN>) { · 109 unmodified lines
110 ) {110 ) {
111 my $s = $1;111 my $s = $1;
112 112
113 $structs{$s} = "struct :c:type:`$s`\\ ";113 $structs{$s} = "struct $s\\ ";
114 next;114 next;
115 }115 }
116}116}
Documentation/trace/ftrace-uses.rst+6−6
@@ -55,17 +55,17 @@ an ftrace_ops with ftrace: · 54 unmodified lines
55 55
56Both .flags and .private are optional. Only .func is required.56Both .flags and .private are optional. Only .func is required.
57 57
58To enable tracing call:58To enable tracing call::
59 59
60.. c:function:: register_ftrace_function(&ops);60 register_ftrace_function(&ops);
61 61
62To disable tracing call:62To disable tracing call::
63 63
64.. c:function:: unregister_ftrace_function(&ops);64 unregister_ftrace_function(&ops);
65 65
66The above is defined by including the header:66The above is defined by including the header::
67 67
68.. c:function:: #include <linux/ftrace.h>68 #include <linux/ftrace.h>
69 69
70The registered callback will start being called some time after the70The registered callback will start being called some time after the
71register_ftrace_function() is called and before it returns. The exact time71register_ftrace_function() is called and before it returns. The exact time
Documentation/translations/it_IT/kernel-hacking/hacking.rst+1−1
@@ -402,7 +402,7 @@ il valore convertito. Tutte le varianti supportano anche il processo inverso: · 401 unmodified lines
402:c:func:`be32_to_cpu()`, eccetera.402:c:func:`be32_to_cpu()`, eccetera.
403 403
404Queste funzioni hanno principalmente due varianti: la variante per404Queste funzioni hanno principalmente due varianti: la variante per
405puntatori, come :c:func:`cpu_to_be32p(), che prende un puntatore405puntatori, come :c:func:`cpu_to_be32p()`, che prende un puntatore
406ad un tipo, e ritorna il valore convertito. L'altra variante per406ad un tipo, e ritorna il valore convertito. L'altra variante per
407la famiglia di conversioni "in-situ", come :c:func:`cpu_to_be32s()`,407la famiglia di conversioni "in-situ", come :c:func:`cpu_to_be32s()`,
408che convertono il valore puntato da un puntatore, e ritornano void.408che convertono il valore puntato da un puntatore, e ritornano void.
Documentation/translations/it_IT/kernel-hacking/locking.rst+2−0
@@ -1,5 +1,7 @@
1.. include:: ../disclaimer-ita.rst1.. include:: ../disclaimer-ita.rst
2 2
3.. c:namespace:: it_IT
4
3:Original: :ref:`Documentation/kernel-hacking/locking.rst <kernel_hacking_lock>`5:Original: :ref:`Documentation/kernel-hacking/locking.rst <kernel_hacking_lock>`
4:Translator: Federico Vaga <federico.vaga@vaga.pv.it>6:Translator: Federico Vaga <federico.vaga@vaga.pv.it>
5 7
Documentation/translations/zh_CN/arm64/amu.rst+2−2
@@ -4,9 +4,9 @@ · 3 unmodified lines
4 4
5Translator: Bailu Lin <bailu.lin@vivo.com>5Translator: Bailu Lin <bailu.lin@vivo.com>
6 6
7=================================7==================================
8AArch64 Linux 中扩展的活动监控单元8AArch64 Linux 中扩展的活动监控单元
9=================================9==================================
10 10
11作者: Ionela Voinescu <ionela.voinescu@arm.com>11作者: Ionela Voinescu <ionela.voinescu@arm.com>
12 12
Documentation/userspace-api/media/cec/cec-func-close.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _cec-func-close:4.. _cec-func-close:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12cec-close - Close a cec device13cec-close - Close a cec device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,16 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: int close( int fd )22.. c:function:: int close( int fd )
24 :name: cec-close
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :c:func:`open() <cec-open>`.28 File descriptor returned by :c:func:`open()`.
31
32 29
33Description30Description
34===========31===========
@@ -36,11 +33,10 @@ Description · 1 unmodified line
36Closes the cec device. Resources associated with the file descriptor are33Closes the cec device. Resources associated with the file descriptor are
37freed. The device configuration remain unchanged.34freed. The device configuration remain unchanged.
38 35
39
40Return Value36Return Value
41============37============
42 38
43:c:func:`close() <cec-close>` returns 0 on success. On error, -1 is returned, and39:c:func:`close()` returns 0 on success. On error, -1 is returned, and
44``errno`` is set appropriately. Possible error codes are:40``errno`` is set appropriately. Possible error codes are:
45 41
46``EBADF``42``EBADF``
Documentation/userspace-api/media/cec/cec-func-ioctl.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _cec-func-ioctl:4.. _cec-func-ioctl:
4 5
@@ -18,15 +19,13 @@ Synopsis · 13 unmodified lines
18 19
19 #include <sys/ioctl.h>20 #include <sys/ioctl.h>
20 21
21 22``int ioctl(int fd, int request, void *argp)``
22.. c:function:: int ioctl( int fd, int request, void *argp )
23 :name: cec-ioctl
24 23
25Arguments24Arguments
26=========25=========
27 26
28``fd``27``fd``
29 File descriptor returned by :c:func:`open() <cec-open>`.28 File descriptor returned by :c:func:`open()`.
30 29
31``request``30``request``
32 CEC ioctl request code as defined in the cec.h header file, for31 CEC ioctl request code as defined in the cec.h header file, for
@@ -35,11 +34,10 @@ Arguments · 2 unmodified lines
35``argp``34``argp``
36 Pointer to a request-specific structure.35 Pointer to a request-specific structure.
37 36
38
39Description37Description
40===========38===========
41 39
42The :c:func:`ioctl() <cec-ioctl>` function manipulates cec device parameters. The40The :c:func:`ioctl()` function manipulates cec device parameters. The
43argument ``fd`` must be an open file descriptor.41argument ``fd`` must be an open file descriptor.
44 42
45The ioctl ``request`` code specifies the cec function to be called. It43The ioctl ``request`` code specifies the cec function to be called. It
@@ -51,7 +49,6 @@ their parameters are located in the cec.h header file. All cec ioctl · 5 unmodified lines
51requests, their respective function and parameters are specified in49requests, their respective function and parameters are specified in
52:ref:`cec-user-func`.50:ref:`cec-user-func`.
53 51
54
55Return Value52Return Value
56============53============
57 54
Documentation/userspace-api/media/cec/cec-func-open.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _cec-func-open:4.. _cec-func-open:
4 5
@@ -18,10 +19,7 @@ Synopsis · 13 unmodified lines
18 19
19 #include <fcntl.h>20 #include <fcntl.h>
20 21
21
22.. c:function:: int open( const char *device_name, int flags )22.. c:function:: int open( const char *device_name, int flags )
23 :name: cec-open
24
25 23
26Arguments24Arguments
27=========25=========
@@ -42,11 +40,10 @@ Arguments · 14 unmodified lines
42 40
43 Other flags have no effect.41 Other flags have no effect.
44 42
45
46Description43Description
47===========44===========
48 45
49To open a cec device applications call :c:func:`open() <cec-open>` with the46To open a cec device applications call :c:func:`open()` with the
50desired device name. The function has no side effects; the device47desired device name. The function has no side effects; the device
51configuration remain unchanged.48configuration remain unchanged.
52 49
@@ -54,11 +51,10 @@ When the device is opened in read-only mode, attempts to modify its · 1 unmodified line
54configuration will result in an error, and ``errno`` will be set to51configuration will result in an error, and ``errno`` will be set to
55EBADF.52EBADF.
56 53
57
58Return Value54Return Value
59============55============
60 56
61:c:func:`open() <cec-open>` returns the new file descriptor on success. On error,57:c:func:`open()` returns the new file descriptor on success. On error,
62-1 is returned, and ``errno`` is set appropriately. Possible error codes58-1 is returned, and ``errno`` is set appropriately. Possible error codes
63include:59include:
64 60
Documentation/userspace-api/media/cec/cec-func-poll.rst+5−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _cec-func-poll:4.. _cec-func-poll:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12cec-poll - Wait for some event on a file descriptor13cec-poll - Wait for some event on a file descriptor
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <sys/poll.h>20 #include <sys/poll.h>
21 21
22
23.. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )22.. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )
24 :name: cec-poll
25 23
26Arguments24Arguments
27=========25=========
@@ -35,14 +33,13 @@ Arguments · 7 unmodified lines
35``timeout``33``timeout``
36 Timeout to wait for events34 Timeout to wait for events
37 35
38
39Description36Description
40===========37===========
41 38
42With the :c:func:`poll() <cec-poll>` function applications can wait for CEC39With the :c:func:`poll()` function applications can wait for CEC
43events.40events.
44 41
45On success :c:func:`poll() <cec-poll>` returns the number of file descriptors42On success :c:func:`poll()` returns the number of file descriptors
46that have been selected (that is, file descriptors for which the43that have been selected (that is, file descriptors for which the
47``revents`` field of the respective struct :c:type:`pollfd`44``revents`` field of the respective struct :c:type:`pollfd`
48is non-zero). CEC devices set the ``POLLIN`` and ``POLLRDNORM`` flags in45is non-zero). CEC devices set the ``POLLIN`` and ``POLLRDNORM`` flags in
@@ -53,13 +50,12 @@ then the ``POLLPRI`` flag is set. When the function times out it returns · 4 unmodified lines
53a value of zero, on failure it returns -1 and the ``errno`` variable is50a value of zero, on failure it returns -1 and the ``errno`` variable is
54set appropriately.51set appropriately.
55 52
56For more details see the :c:func:`poll() <cec-poll>` manual page.53For more details see the :c:func:`poll()` manual page.
57
58 54
59Return Value55Return Value
60============56============
61 57
62On success, :c:func:`poll() <cec-poll>` returns the number structures which have58On success, :c:func:`poll()` returns the number structures which have
63non-zero ``revents`` fields, or zero if the call timed out. On error -159non-zero ``revents`` fields, or zero if the call timed out. On error -1
64is returned, and the ``errno`` variable is set appropriately:60is returned, and the ``errno`` variable is set appropriately:
65 61
Documentation/userspace-api/media/cec/cec-ioc-adap-g-caps.rst+5−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _CEC_ADAP_G_CAPS:4.. _CEC_ADAP_G_CAPS:
4 5
@@ -14,18 +15,18 @@ CEC_ADAP_G_CAPS - Query device capabilities · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, CEC_ADAP_G_CAPS, struct cec_caps *argp )18.. c:macro:: CEC_ADAP_G_CAPS
18 :name: CEC_ADAP_G_CAPS19
20``int ioctl(int fd, CEC_ADAP_G_CAPS, struct cec_caps *argp)``
19 21
20Arguments22Arguments
21=========23=========
22 24
23``fd``25``fd``
24 File descriptor returned by :c:func:`open() <cec-open>`.26 File descriptor returned by :c:func:`open()`.
25 27
26``argp``28``argp``
27 29
28
29Description30Description
30===========31===========
31 32
@@ -62,7 +63,6 @@ returns the information to the application. The ioctl never fails. · 30 unmodified lines
62 - CEC Framework API version, formatted with the ``KERNEL_VERSION()``63 - CEC Framework API version, formatted with the ``KERNEL_VERSION()``
63 macro.64 macro.
64 65
65
66.. tabularcolumns:: |p{4.4cm}|p{2.5cm}|p{10.6cm}|66.. tabularcolumns:: |p{4.4cm}|p{2.5cm}|p{10.6cm}|
67 67
68.. _cec-capabilities:68.. _cec-capabilities:
Documentation/userspace-api/media/cec/cec-ioc-adap-g-conn-info.rst+6−5
@@ -2,6 +2,8 @@ · 1 unmodified line
2..2..
3.. Copyright 2019 Google LLC3.. Copyright 2019 Google LLC
4..4..
5.. c:namespace:: CEC
6
5.. _CEC_ADAP_G_CONNECTOR_INFO:7.. _CEC_ADAP_G_CONNECTOR_INFO:
6 8
7*******************************9*******************************
@@ -16,18 +18,18 @@ CEC_ADAP_G_CONNECTOR_INFO - Query HDMI connector information · 8 unmodified lines
16Synopsis18Synopsis
17========19========
18 20
19.. c:function:: int ioctl( int fd, CEC_ADAP_G_CONNECTOR_INFO, struct cec_connector_info *argp )21.. c:macro:: CEC_ADAP_G_CONNECTOR_INFO
20 :name: CEC_ADAP_G_CONNECTOR_INFO22
23``int ioctl(int fd, CEC_ADAP_G_CONNECTOR_INFO, struct cec_connector_info *argp)``
21 24
22Arguments25Arguments
23=========26=========
24 27
25``fd``28``fd``
26 File descriptor returned by :c:func:`open() <cec-open>`.29 File descriptor returned by :c:func:`open()`.
27 30
28``argp``31``argp``
29 32
30
31Description33Description
32===========34===========
33 35
@@ -57,7 +59,6 @@ is only available if the ``CEC_CAP_CONNECTOR_INFO`` capability is set. · 23 unmodified lines
57 * - }59 * - }
58 -60 -
59 61
60
61.. tabularcolumns:: |p{4.4cm}|p{2.5cm}|p{10.6cm}|62.. tabularcolumns:: |p{4.4cm}|p{2.5cm}|p{10.6cm}|
62 63
63.. _connector-type:64.. _connector-type:
Documentation/userspace-api/media/cec/cec-ioc-adap-g-log-addrs.rst+8−12
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _CEC_ADAP_LOG_ADDRS:4.. _CEC_ADAP_LOG_ADDRS:
4.. _CEC_ADAP_G_LOG_ADDRS:5.. _CEC_ADAP_G_LOG_ADDRS:
@@ -13,21 +14,22 @@ Name · 8 unmodified lines
13 14
14CEC_ADAP_G_LOG_ADDRS, CEC_ADAP_S_LOG_ADDRS - Get or set the logical addresses15CEC_ADAP_G_LOG_ADDRS, CEC_ADAP_S_LOG_ADDRS - Get or set the logical addresses
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl( int fd, CEC_ADAP_G_LOG_ADDRS, struct cec_log_addrs *argp )20.. c:macro:: CEC_ADAP_G_LOG_ADDRS
21 :name: CEC_ADAP_G_LOG_ADDRS21
22``int ioctl(int fd, CEC_ADAP_G_LOG_ADDRS, struct cec_log_addrs *argp)``
23
24.. c:macro:: CEC_ADAP_S_LOG_ADDRS
22 25
23.. c:function:: int ioctl( int fd, CEC_ADAP_S_LOG_ADDRS, struct cec_log_addrs *argp )26``int ioctl(int fd, CEC_ADAP_S_LOG_ADDRS, struct cec_log_addrs *argp)``
24 :name: CEC_ADAP_S_LOG_ADDRS
25 27
26Arguments28Arguments
27=========29=========
28 30
29``fd``31``fd``
30 File descriptor returned by :c:func:`open() <cec-open>`.32 File descriptor returned by :c:func:`open()`.
31 33
32``argp``34``argp``
33 Pointer to struct :c:type:`cec_log_addrs`.35 Pointer to struct :c:type:`cec_log_addrs`.
@@ -148,7 +150,6 @@ logical address types are already defined will return with error ``EBUSY``. · 114 unmodified lines
148 give the CEC framework more information about the device type, even150 give the CEC framework more information about the device type, even
149 though the framework won't use it directly in the CEC message.151 though the framework won't use it directly in the CEC message.
150 152
151
152.. tabularcolumns:: |p{7.8cm}|p{1.0cm}|p{8.7cm}|153.. tabularcolumns:: |p{7.8cm}|p{1.0cm}|p{8.7cm}|
153 154
154.. _cec-log-addrs-flags:155.. _cec-log-addrs-flags:
@@ -185,7 +186,6 @@ logical address types are already defined will return with error ``EBUSY``. · 30 unmodified lines
185 186
186 All other messages are ignored.187 All other messages are ignored.
187 188
188
189.. tabularcolumns:: |p{7.8cm}|p{1.0cm}|p{8.7cm}|189.. tabularcolumns:: |p{7.8cm}|p{1.0cm}|p{8.7cm}|
190 190
191.. _cec-versions:191.. _cec-versions:
@@ -211,7 +211,6 @@ logical address types are already defined will return with error ``EBUSY``. · 19 unmodified lines
211 - 6211 - 6
212 - CEC version according to the HDMI 2.0 standard.212 - CEC version according to the HDMI 2.0 standard.
213 213
214
215.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|214.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
216 215
217.. _cec-prim-dev-types:216.. _cec-prim-dev-types:
@@ -257,7 +256,6 @@ logical address types are already defined will return with error ``EBUSY``. · 39 unmodified lines
257 - 7256 - 7
258 - Use for a video processor device.257 - Use for a video processor device.
259 258
260
261.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|259.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
262 260
263.. _cec-log-addr-types:261.. _cec-log-addr-types:
@@ -306,7 +304,6 @@ logical address types are already defined will return with error ``EBUSY``. · 42 unmodified lines
306 Control).304 Control).
307 305
308 306
309
310.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|307.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
311 308
312.. _cec-all-dev-types-flags:309.. _cec-all-dev-types-flags:
@@ -348,7 +345,6 @@ logical address types are already defined will return with error ``EBUSY``. · 35 unmodified lines
348 - This supports the CEC Switch or Video Processing type.345 - This supports the CEC Switch or Video Processing type.
349 346
350 347
351
352Return Value348Return Value
353============349============
354 350
Documentation/userspace-api/media/cec/cec-ioc-adap-g-phys-addr.rst+8−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _CEC_ADAP_PHYS_ADDR:4.. _CEC_ADAP_PHYS_ADDR:
4.. _CEC_ADAP_G_PHYS_ADDR:5.. _CEC_ADAP_G_PHYS_ADDR:
@@ -13,21 +14,22 @@ Name · 8 unmodified lines
13 14
14CEC_ADAP_G_PHYS_ADDR, CEC_ADAP_S_PHYS_ADDR - Get or set the physical address15CEC_ADAP_G_PHYS_ADDR, CEC_ADAP_S_PHYS_ADDR - Get or set the physical address
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl( int fd, CEC_ADAP_G_PHYS_ADDR, __u16 *argp )20.. c:macro:: CEC_ADAP_G_PHYS_ADDR
21 :name: CEC_ADAP_G_PHYS_ADDR21
22``int ioctl(int fd, CEC_ADAP_G_PHYS_ADDR, __u16 *argp)``
22 23
23.. c:function:: int ioctl( int fd, CEC_ADAP_S_PHYS_ADDR, __u16 *argp )24.. c:macro:: CEC_ADAP_S_PHYS_ADDR
24 :name: CEC_ADAP_S_PHYS_ADDR25
26``int ioctl(int fd, CEC_ADAP_S_PHYS_ADDR, __u16 *argp)``
25 27
26Arguments28Arguments
27=========29=========
28 30
29``fd``31``fd``
30 File descriptor returned by :c:func:`open() <cec-open>`.32 File descriptor returned by :c:func:`open()`.
31 33
32``argp``34``argp``
33 Pointer to the CEC address.35 Pointer to the CEC address.
@@ -71,7 +73,6 @@ For example, the EDID for each HDMI input of the TV will have a · 37 unmodified lines
71different physical address of the form a.0.0.0 that the sources will73different physical address of the form a.0.0.0 that the sources will
72read out and use as their physical address.74read out and use as their physical address.
73 75
74
75Return Value76Return Value
76============77============
77 78
Documentation/userspace-api/media/cec/cec-ioc-dqevent.rst+5−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _CEC_DQEVENT:4.. _CEC_DQEVENT:
4 5
@@ -11,22 +12,21 @@ Name · 6 unmodified lines
11 12
12CEC_DQEVENT - Dequeue a CEC event13CEC_DQEVENT - Dequeue a CEC event
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, CEC_DQEVENT, struct cec_event *argp )18.. c:macro:: CEC_DQEVENT
19 :name: CEC_DQEVENT19
20``int ioctl(int fd, CEC_DQEVENT, struct cec_event *argp)``
20 21
21Arguments22Arguments
22=========23=========
23 24
24``fd``25``fd``
25 File descriptor returned by :c:func:`open() <cec-open>`.26 File descriptor returned by :c:func:`open()`.
26 27
27``argp``28``argp``
28 29
29
30Description30Description
31===========31===========
32 32
@@ -72,7 +72,6 @@ it is guaranteed that the state did change in between the two events. · 39 unmodified lines
72 the HDMI driver is still configuring the device or because the HDMI72 the HDMI driver is still configuring the device or because the HDMI
73 device was unbound.73 device was unbound.
74 74
75
76.. c:type:: cec_event_lost_msgs75.. c:type:: cec_event_lost_msgs
77 76
78.. tabularcolumns:: |p{1.0cm}|p{2.0cm}|p{14.5cm}|77.. tabularcolumns:: |p{1.0cm}|p{2.0cm}|p{14.5cm}|
@@ -94,7 +93,6 @@ it is guaranteed that the state did change in between the two events. · 15 unmodified lines
94 replied to within a second according to the CEC specification,93 replied to within a second according to the CEC specification,
95 this is more than enough.94 this is more than enough.
96 95
97
98.. tabularcolumns:: |p{1.0cm}|p{4.4cm}|p{2.5cm}|p{9.6cm}|96.. tabularcolumns:: |p{1.0cm}|p{4.4cm}|p{2.5cm}|p{9.6cm}|
99 97
100.. c:type:: cec_event98.. c:type:: cec_event
@@ -130,7 +128,6 @@ it is guaranteed that the state did change in between the two events. · 29 unmodified lines
130 * - }128 * - }
131 -129 -
132 130
133
134.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|131.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
135 132
136.. _cec-events:133.. _cec-events:
@@ -204,7 +201,6 @@ it is guaranteed that the state did change in between the two events. · 67 unmodified lines
204 if the 5V is high, then an initial event will be generated for that201 if the 5V is high, then an initial event will be generated for that
205 filehandle.202 filehandle.
206 203
207
208.. tabularcolumns:: |p{6.0cm}|p{0.6cm}|p{10.9cm}|204.. tabularcolumns:: |p{6.0cm}|p{0.6cm}|p{10.9cm}|
209 205
210.. _cec-event-flags:206.. _cec-event-flags:
@@ -230,7 +226,6 @@ it is guaranteed that the state did change in between the two events. · 19 unmodified lines
230 This is an indication that the application cannot keep up.226 This is an indication that the application cannot keep up.
231 227
232 228
233
234Return Value229Return Value
235============230============
236 231
Documentation/userspace-api/media/cec/cec-ioc-g-mode.rst+8−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _CEC_MODE:4.. _CEC_MODE:
4.. _CEC_G_MODE:5.. _CEC_G_MODE:
@@ -13,17 +14,19 @@ CEC_G_MODE, CEC_S_MODE - Get or set exclusive use of the CEC adapter · 8 unmodified lines
13Synopsis14Synopsis
14========15========
15 16
16.. c:function:: int ioctl( int fd, CEC_G_MODE, __u32 *argp )17.. c:macro:: CEC_G_MODE
17 :name: CEC_G_MODE
18 18
19.. c:function:: int ioctl( int fd, CEC_S_MODE, __u32 *argp )19``int ioctl(int fd, CEC_G_MODE, __u32 *argp)``
20 :name: CEC_S_MODE20
21.. c:macro:: CEC_S_MODE
22
23``int ioctl(int fd, CEC_S_MODE, __u32 *argp)``
21 24
22Arguments25Arguments
23=========26=========
24 27
25``fd``28``fd``
26 File descriptor returned by :c:func:`open() <cec-open>`.29 File descriptor returned by :c:func:`open()`.
27 30
28``argp``31``argp``
29 Pointer to CEC mode.32 Pointer to CEC mode.
@@ -101,7 +104,6 @@ Available initiator modes are: · 71 unmodified lines
101 then an attempt to become one will return the ``EBUSY`` error code104 then an attempt to become one will return the ``EBUSY`` error code
102 error.105 error.
103 106
104
105Available follower modes are:107Available follower modes are:
106 108
107.. tabularcolumns:: |p{6.6cm}|p{0.9cm}|p{10.0cm}|109.. tabularcolumns:: |p{6.6cm}|p{0.9cm}|p{10.0cm}|
@@ -193,7 +195,6 @@ Available follower modes are: · 85 unmodified lines
193 the process has the ``CAP_NET_ADMIN`` capability. If that is not195 the process has the ``CAP_NET_ADMIN`` capability. If that is not
194 set, then the ``EPERM`` error code is returned.196 set, then the ``EPERM`` error code is returned.
195 197
196
197Core message processing details:198Core message processing details:
198 199
199.. tabularcolumns:: |p{6.6cm}|p{10.9cm}|200.. tabularcolumns:: |p{6.6cm}|p{10.9cm}|
@@ -272,7 +273,6 @@ Core message processing details: · 72 unmodified lines
272 and then just pass the message on to the follower(s).273 and then just pass the message on to the follower(s).
273 274
274 275
275
276Return Value276Return Value
277============277============
278 278
Documentation/userspace-api/media/cec/cec-ioc-receive.rst+8−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: CEC
2 3
3.. _CEC_TRANSMIT:4.. _CEC_TRANSMIT:
4.. _CEC_RECEIVE:5.. _CEC_RECEIVE:
@@ -12,21 +13,22 @@ Name · 7 unmodified lines
12 13
13CEC_RECEIVE, CEC_TRANSMIT - Receive or transmit a CEC message14CEC_RECEIVE, CEC_TRANSMIT - Receive or transmit a CEC message
14 15
15
16Synopsis16Synopsis
17========17========
18 18
19.. c:function:: int ioctl( int fd, CEC_RECEIVE, struct cec_msg \*argp )19.. c:macro:: CEC_RECEIVE
20 :name: CEC_RECEIVE20
21``int ioctl(int fd, CEC_RECEIVE, struct cec_msg *argp)``
21 22
22.. c:function:: int ioctl( int fd, CEC_TRANSMIT, struct cec_msg \*argp )23.. c:macro:: CEC_TRANSMIT
23 :name: CEC_TRANSMIT24
25``int ioctl(int fd, CEC_TRANSMIT, struct cec_msg *argp)``
24 26
25Arguments27Arguments
26=========28=========
27 29
28``fd``30``fd``
29 File descriptor returned by :c:func:`open() <cec-open>`.31 File descriptor returned by :c:func:`open()`.
30 32
31``argp``33``argp``
32 Pointer to struct cec_msg.34 Pointer to struct cec_msg.
@@ -194,7 +196,6 @@ View On' messages from initiator 0xf ('Unregistered') to destination 0 ('TV'). · 161 unmodified lines
194 supports this, otherwise it is always 0. This counter is only196 supports this, otherwise it is always 0. This counter is only
195 valid if the :ref:`CEC_TX_STATUS_ERROR <CEC-TX-STATUS-ERROR>` status bit is set.197 valid if the :ref:`CEC_TX_STATUS_ERROR <CEC-TX-STATUS-ERROR>` status bit is set.
196 198
197
198.. tabularcolumns:: |p{6.2cm}|p{1.0cm}|p{10.3cm}|199.. tabularcolumns:: |p{6.2cm}|p{1.0cm}|p{10.3cm}|
199 200
200.. _cec-msg-flags:201.. _cec-msg-flags:
@@ -228,7 +229,6 @@ View On' messages from initiator 0xf ('Unregistered') to destination 0 ('TV'). · 27 unmodified lines
228 capability. If that is not set, then the ``EPERM`` error code is229 capability. If that is not set, then the ``EPERM`` error code is
229 returned.230 returned.
230 231
231
232.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|232.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
233 233
234.. _cec-tx-status:234.. _cec-tx-status:
@@ -298,7 +298,6 @@ View On' messages from initiator 0xf ('Unregistered') to destination 0 ('TV'). · 63 unmodified lines
298 - The transmit timed out. This should not normally happen and this298 - The transmit timed out. This should not normally happen and this
299 indicates a driver problem.299 indicates a driver problem.
300 300
301
302.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|301.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
303 302
304.. _cec-rx-status:303.. _cec-rx-status:
@@ -335,7 +334,6 @@ View On' messages from initiator 0xf ('Unregistered') to destination 0 ('TV'). · 30 unmodified lines
335 reply was interrupted.334 reply was interrupted.
336 335
337 336
338
339Return Value337Return Value
340============338============
341 339
Documentation/userspace-api/media/dvb/audio-bilingual-channel-select.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_BILINGUAL_CHANNEL_SELECT:4.. _AUDIO_BILINGUAL_CHANNEL_SELECT:
4 5
@@ -16,9 +17,9 @@ AUDIO_BILINGUAL_CHANNEL_SELECT · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_BILINGUAL_CHANNEL_SELECT, struct *audio_channel_select)20.. c:macro:: AUDIO_BILINGUAL_CHANNEL_SELECT
20 :name: AUDIO_BILINGUAL_CHANNEL_SELECT
21 21
22``int ioctl(int fd, AUDIO_BILINGUAL_CHANNEL_SELECT, struct audio_channel_select *select)``
22 23
23Arguments24Arguments
24---------25---------
@@ -39,7 +40,6 @@ Arguments · 14 unmodified lines
39 40
40 - Select the output format of the audio (mono left/right, stereo).41 - Select the output format of the audio (mono left/right, stereo).
41 42
42
43Description43Description
44-----------44-----------
45 45
@@ -50,7 +50,6 @@ for MPEG decoders controlled through V4L2. · 4 unmodified lines
50This ioctl call asks the Audio Device to select the requested channel50This ioctl call asks the Audio Device to select the requested channel
51for bilingual streams if possible.51for bilingual streams if possible.
52 52
53
54Return Value53Return Value
55------------54------------
56 55
Documentation/userspace-api/media/dvb/audio-channel-select.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_CHANNEL_SELECT:4.. _AUDIO_CHANNEL_SELECT:
4 5
@@ -16,9 +17,9 @@ AUDIO_CHANNEL_SELECT · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_CHANNEL_SELECT, struct *audio_channel_select)20.. c:macro:: AUDIO_CHANNEL_SELECT
20 :name: AUDIO_CHANNEL_SELECT
21 21
22``int ioctl(int fd, AUDIO_CHANNEL_SELECT, struct audio_channel_select *select)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Arguments · 6 unmodified lines
40 40
41 - Select the output format of the audio (mono left/right, stereo).41 - Select the output format of the audio (mono left/right, stereo).
42 42
43
44Description43Description
45-----------44-----------
46 45
@@ -50,7 +49,6 @@ V4L2 ``V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK`` control instead. · 3 unmodified lines
50This ioctl call asks the Audio Device to select the requested channel if49This ioctl call asks the Audio Device to select the requested channel if
51possible.50possible.
52 51
53
54Return Value52Return Value
55------------53------------
56 54
Documentation/userspace-api/media/dvb/audio-clear-buffer.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_CLEAR_BUFFER:4.. _AUDIO_CLEAR_BUFFER:
4 5
@@ -16,8 +17,9 @@ AUDIO_CLEAR_BUFFER · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_CLEAR_BUFFER)20.. c:macro:: AUDIO_CLEAR_BUFFER
20 :name: AUDIO_CLEAR_BUFFER21
22``int ioctl(int fd, AUDIO_CLEAR_BUFFER)``
21 23
22Arguments24Arguments
23---------25---------
@@ -26,7 +28,6 @@ Arguments · 2 unmodified lines
26 :header-rows: 028 :header-rows: 0
27 :stub-columns: 029 :stub-columns: 0
28 30
29
30 - .. row 131 - .. row 1
31 32
32 - int fd33 - int fd
@@ -39,7 +40,6 @@ Description · 6 unmodified lines
39This ioctl call asks the Audio Device to clear all software and hardware40This ioctl call asks the Audio Device to clear all software and hardware
40buffers of the audio decoder device.41buffers of the audio decoder device.
41 42
42
43Return Value43Return Value
44------------44------------
45 45
Documentation/userspace-api/media/dvb/audio-continue.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_CONTINUE:4.. _AUDIO_CONTINUE:
4 5
@@ -16,9 +17,9 @@ AUDIO_CONTINUE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_CONTINUE)20.. c:macro:: AUDIO_CONTINUE
20 :name: AUDIO_CONTINUE
21 21
22``int ioctl(int fd, AUDIO_CONTINUE)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Description · 6 unmodified lines
40This ioctl restarts the decoding and playing process previously paused40This ioctl restarts the decoding and playing process previously paused
41with AUDIO_PAUSE command.41with AUDIO_PAUSE command.
42 42
43
44Return Value43Return Value
45------------44------------
46 45
Documentation/userspace-api/media/dvb/audio-fclose.rst+1−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _audio_fclose:4.. _audio_fclose:
4 5
@@ -17,8 +18,6 @@ Synopsis · 12 unmodified lines
17--------18--------
18 19
19.. c:function:: int close(int fd)20.. c:function:: int close(int fd)
20 :name: dvb-audio-close
21
22 21
23Arguments22Arguments
24---------23---------
@@ -27,20 +26,17 @@ Arguments · 2 unmodified lines
27 :header-rows: 026 :header-rows: 0
28 :stub-columns: 027 :stub-columns: 0
29 28
30
31 - .. row 129 - .. row 1
32 30
33 - int fd31 - int fd
34 32
35 - File descriptor returned by a previous call to open().33 - File descriptor returned by a previous call to open().
36 34
37
38Description35Description
39-----------36-----------
40 37
41This system call closes a previously opened audio device.38This system call closes a previously opened audio device.
42 39
43
44Return Value40Return Value
45------------41------------
46 42
@@ -48,7 +44,6 @@ Return Value · 1 unmodified line
48 :header-rows: 044 :header-rows: 0
49 :stub-columns: 045 :stub-columns: 0
50 46
51
52 - .. row 147 - .. row 1
53 48
54 - ``EBADF``49 - ``EBADF``
Documentation/userspace-api/media/dvb/audio-fopen.rst+1−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _audio_fopen:4.. _audio_fopen:
4 5
@@ -17,8 +18,6 @@ Synopsis · 12 unmodified lines
17--------18--------
18 19
19.. c:function:: int open(const char *deviceName, int flags)20.. c:function:: int open(const char *deviceName, int flags)
20 :name: dvb-audio-open
21
22 21
23Arguments22Arguments
24---------23---------
@@ -27,7 +26,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 026 :header-rows: 0
28 :stub-columns: 027 :stub-columns: 0
29 28
30
31 - .. row 129 - .. row 1
32 30
33 - const char \*deviceName31 - const char \*deviceName
@@ -60,7 +58,6 @@ Arguments · 26 unmodified lines
60 -58 -
61 - (blocking mode is the default)59 - (blocking mode is the default)
62 60
63
64Description61Description
65-----------62-----------
66 63
@@ -78,7 +75,6 @@ fail, and an error code will be returned. If the Audio Device is opened · 11 unmodified lines
78in O_RDONLY mode, the only ioctl call that can be used is75in O_RDONLY mode, the only ioctl call that can be used is
79AUDIO_GET_STATUS. All other call will return with an error code.76AUDIO_GET_STATUS. All other call will return with an error code.
80 77
81
82Return Value78Return Value
83------------79------------
84 80
@@ -88,7 +84,6 @@ Return Value · 3 unmodified lines
88 :header-rows: 084 :header-rows: 0
89 :stub-columns: 085 :stub-columns: 0
90 86
91
92 - .. row 187 - .. row 1
93 88
94 - ``ENODEV``89 - ``ENODEV``
Documentation/userspace-api/media/dvb/audio-fwrite.rst+1−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _audio_fwrite:4.. _audio_fwrite:
4 5
@@ -17,8 +18,6 @@ Synopsis · 12 unmodified lines
17--------18--------
18 19
19.. c:function:: size_t write(int fd, const void *buf, size_t count)20.. c:function:: size_t write(int fd, const void *buf, size_t count)
20 :name: dvb-audio-write
21
22 21
23Arguments22Arguments
24---------23---------
@@ -27,7 +26,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 026 :header-rows: 0
28 :stub-columns: 027 :stub-columns: 0
29 28
30
31 - .. row 129 - .. row 1
32 30
33 - int fd31 - int fd
@@ -46,7 +44,6 @@ Arguments · 12 unmodified lines
46 44
47 - Size of buf.45 - Size of buf.
48 46
49
50Description47Description
51-----------48-----------
52 49
@@ -56,7 +53,6 @@ PES format. If O_NONBLOCK is not specified the function will block · 3 unmodified lines
56until buffer space is available. The amount of data to be transferred is53until buffer space is available. The amount of data to be transferred is
57implied by count.54implied by count.
58 55
59
60Return Value56Return Value
61------------57------------
62 58
@@ -64,7 +60,6 @@ Return Value · 1 unmodified line
64 :header-rows: 060 :header-rows: 0
65 :stub-columns: 061 :stub-columns: 0
66 62
67
68 - .. row 163 - .. row 1
69 64
70 - ``EPERM``65 - ``EPERM``
Documentation/userspace-api/media/dvb/audio-get-capabilities.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_GET_CAPABILITIES:4.. _AUDIO_GET_CAPABILITIES:
4 5
@@ -16,9 +17,9 @@ AUDIO_GET_CAPABILITIES · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_GET_CAPABILITIES, unsigned int *cap)20.. c:macro:: AUDIO_GET_CAPABILITIES
20 :name: AUDIO_GET_CAPABILITIES
21 21
22``int ioctl(int fd, AUDIO_GET_CAPABILITIES, unsigned int *cap)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -40,14 +40,12 @@ Arguments · 6 unmodified lines
40 40
41 - Returns a bit array of supported sound formats.41 - Returns a bit array of supported sound formats.
42 42
43
44Description43Description
45-----------44-----------
46 45
47This ioctl call asks the Audio Device to tell us about the decoding46This ioctl call asks the Audio Device to tell us about the decoding
48capabilities of the audio hardware.47capabilities of the audio hardware.
49 48
50
51Return Value49Return Value
52------------50------------
53 51
Documentation/userspace-api/media/dvb/audio-get-status.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_GET_STATUS:4.. _AUDIO_GET_STATUS:
4 5
@@ -16,9 +17,9 @@ AUDIO_GET_STATUS · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_GET_STATUS, struct audio_status *status)20.. c:macro:: AUDIO_GET_STATUS
20 :name: AUDIO_GET_STATUS
21 21
22``int ioctl(int fd, AUDIO_GET_STATUS, struct audio_status *status)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -40,14 +40,12 @@ Arguments · 6 unmodified lines
40 40
41 - Returns the current state of Audio Device.41 - Returns the current state of Audio Device.
42 42
43
44Description43Description
45-----------44-----------
46 45
47This ioctl call asks the Audio Device to return the current state of the46This ioctl call asks the Audio Device to return the current state of the
48Audio Device.47Audio Device.
49 48
50
51Return Value49Return Value
52------------50------------
53 51
Documentation/userspace-api/media/dvb/audio-pause.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_PAUSE:4.. _AUDIO_PAUSE:
4 5
@@ -16,8 +17,9 @@ AUDIO_PAUSE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_PAUSE)20.. c:macro:: AUDIO_PAUSE
20 :name: AUDIO_PAUSE21
22``int ioctl(int fd, AUDIO_PAUSE)``
21 23
22Arguments24Arguments
23---------25---------
@@ -26,14 +28,12 @@ Arguments · 2 unmodified lines
26 :header-rows: 028 :header-rows: 0
27 :stub-columns: 029 :stub-columns: 0
28 30
29
30 - .. row 131 - .. row 1
31 32
32 - int fd33 - int fd
33 34
34 - File descriptor returned by a previous call to open().35 - File descriptor returned by a previous call to open().
35 36
36
37Description37Description
38-----------38-----------
39 39
@@ -41,7 +41,6 @@ This ioctl call suspends the audio stream being played. Decoding and · 1 unmodified line
41playing are paused. It is then possible to restart again decoding and41playing are paused. It is then possible to restart again decoding and
42playing process of the audio stream using AUDIO_CONTINUE command.42playing process of the audio stream using AUDIO_CONTINUE command.
43 43
44
45Return Value44Return Value
46------------45------------
47 46
Documentation/userspace-api/media/dvb/audio-play.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_PLAY:4.. _AUDIO_PLAY:
4 5
@@ -16,9 +17,9 @@ AUDIO_PLAY · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_PLAY)20.. c:macro:: AUDIO_PLAY
20 :name: AUDIO_PLAY
21 21
22``int ioctl(int fd, AUDIO_PLAY)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Description · 6 unmodified lines
40This ioctl call asks the Audio Device to start playing an audio stream40This ioctl call asks the Audio Device to start playing an audio stream
41from the selected source.41from the selected source.
42 42
43
44Return Value43Return Value
45------------44------------
46 45
Documentation/userspace-api/media/dvb/audio-select-source.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SELECT_SOURCE:4.. _AUDIO_SELECT_SOURCE:
4 5
@@ -16,9 +17,9 @@ AUDIO_SELECT_SOURCE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_SELECT_SOURCE, struct audio_stream_source *source)20.. c:macro:: AUDIO_SELECT_SOURCE
20 :name: AUDIO_SELECT_SOURCE
21 21
22``int ioctl(int fd, AUDIO_SELECT_SOURCE, struct audio_stream_source *source)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Arguments · 6 unmodified lines
40 40
41 - Indicates the source that shall be used for the Audio stream.41 - Indicates the source that shall be used for the Audio stream.
42 42
43
44Description43Description
45-----------44-----------
46 45
@@ -49,7 +48,6 @@ the input data. The possible sources are demux or memory. If · 2 unmodified lines
49AUDIO_SOURCE_MEMORY is selected, the data is fed to the Audio Device48AUDIO_SOURCE_MEMORY is selected, the data is fed to the Audio Device
50through the write command.49through the write command.
51 50
52
53Return Value51Return Value
54------------52------------
55 53
Documentation/userspace-api/media/dvb/audio-set-av-sync.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SET_AV_SYNC:4.. _AUDIO_SET_AV_SYNC:
4 5
@@ -16,9 +17,9 @@ AUDIO_SET_AV_SYNC · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_SET_AV_SYNC, boolean state)20.. c:macro:: AUDIO_SET_AV_SYNC
20 :name: AUDIO_SET_AV_SYNC
21 21
22``int ioctl(int fd, AUDIO_SET_AV_SYNC, boolean state)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -44,14 +44,12 @@ Arguments · 10 unmodified lines
44 44
45 FALSE: AV-sync OFF45 FALSE: AV-sync OFF
46 46
47
48Description47Description
49-----------48-----------
50 49
51This ioctl call asks the Audio Device to turn ON or OFF A/V50This ioctl call asks the Audio Device to turn ON or OFF A/V
52synchronization.51synchronization.
53 52
54
55Return Value53Return Value
56------------54------------
57 55
Documentation/userspace-api/media/dvb/audio-set-bypass-mode.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SET_BYPASS_MODE:4.. _AUDIO_SET_BYPASS_MODE:
4 5
@@ -16,8 +17,9 @@ AUDIO_SET_BYPASS_MODE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_SET_BYPASS_MODE, boolean mode)20.. c:macro:: AUDIO_SET_BYPASS_MODE
20 :name: AUDIO_SET_BYPASS_MODE21
22``int ioctl(int fd, AUDIO_SET_BYPASS_MODE, boolean mode)``
21 23
22Arguments24Arguments
23---------25---------
@@ -26,7 +28,6 @@ Arguments · 2 unmodified lines
26 :header-rows: 028 :header-rows: 0
27 :stub-columns: 029 :stub-columns: 0
28 30
29
30 -31 -
31 32
32 - int fd33 - int fd
@@ -44,7 +45,6 @@ Arguments · 11 unmodified lines
44 45
45 FALSE: Bypass is enabled46 FALSE: Bypass is enabled
46 47
47
48Description48Description
49-----------49-----------
50 50
@@ -54,7 +54,6 @@ that can’t be handled by the Digital TV system shall be decoded. Dolby · 3 unmodified lines
54DigitalTM streams are automatically forwarded by the Digital TV subsystem if54DigitalTM streams are automatically forwarded by the Digital TV subsystem if
55the hardware can handle it.55the hardware can handle it.
56 56
57
58Return Value57Return Value
59------------58------------
60 59
Documentation/userspace-api/media/dvb/audio-set-id.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SET_ID:4.. _AUDIO_SET_ID:
4 5
@@ -16,8 +17,9 @@ AUDIO_SET_ID · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_SET_ID, int id)20.. c:macro:: AUDIO_SET_ID
20 :name: AUDIO_SET_ID21
22``int ioctl(int fd, AUDIO_SET_ID, int id)``
21 23
22Arguments24Arguments
23---------25---------
@@ -26,7 +28,6 @@ Arguments · 2 unmodified lines
26 :header-rows: 028 :header-rows: 0
27 :stub-columns: 029 :stub-columns: 0
28 30
29
30 -31 -
31 32
32 - int fd33 - int fd
@@ -39,7 +40,6 @@ Arguments · 6 unmodified lines
39 40
40 - audio sub-stream id41 - audio sub-stream id
41 42
42
43Description43Description
44-----------44-----------
45 45
@@ -51,7 +51,6 @@ other stream types. If the stream type is set the id just specifies the · 5 unmodified lines
51substream id of the audio stream and only the first 5 bits are51substream id of the audio stream and only the first 5 bits are
52recognized.52recognized.
53 53
54
55Return Value54Return Value
56------------55------------
57 56
Documentation/userspace-api/media/dvb/audio-set-mixer.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SET_MIXER:4.. _AUDIO_SET_MIXER:
4 5
@@ -16,8 +17,9 @@ AUDIO_SET_MIXER · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_SET_MIXER, struct audio_mixer *mix)20.. c:macro:: AUDIO_SET_MIXER
20 :name: AUDIO_SET_MIXER21
22``int ioctl(int fd, AUDIO_SET_MIXER, struct audio_mixer *mix)``
21 23
22Arguments24Arguments
23---------25---------
@@ -26,7 +28,6 @@ Arguments · 2 unmodified lines
26 :header-rows: 028 :header-rows: 0
27 :stub-columns: 029 :stub-columns: 0
28 30
29
30 -31 -
31 32
32 - int fd33 - int fd
@@ -39,13 +40,11 @@ Arguments · 6 unmodified lines
39 40
40 - mixer settings.41 - mixer settings.
41 42
42
43Description43Description
44-----------44-----------
45 45
46This ioctl lets you adjust the mixer settings of the audio decoder.46This ioctl lets you adjust the mixer settings of the audio decoder.
47 47
48
49Return Value48Return Value
50------------49------------
51 50
Documentation/userspace-api/media/dvb/audio-set-mute.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SET_MUTE:4.. _AUDIO_SET_MUTE:
4 5
@@ -16,9 +17,9 @@ AUDIO_SET_MUTE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_SET_MUTE, boolean state)20.. c:macro:: AUDIO_SET_MUTE
20 :name: AUDIO_SET_MUTE
21 21
22``int ioctl(int fd, AUDIO_SET_MUTE, boolean state)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -44,7 +44,6 @@ Arguments · 10 unmodified lines
44 44
45 FALSE: Audio Un-mute45 FALSE: Audio Un-mute
46 46
47
48Description47Description
49-----------48-----------
50 49
@@ -55,7 +54,6 @@ V4L2 :ref:`VIDIOC_DECODER_CMD` with the · 4 unmodified lines
55This ioctl call asks the audio device to mute the stream that is54This ioctl call asks the audio device to mute the stream that is
56currently being played.55currently being played.
57 56
58
59Return Value57Return Value
60------------58------------
61 59
Documentation/userspace-api/media/dvb/audio-set-streamtype.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_SET_STREAMTYPE:4.. _AUDIO_SET_STREAMTYPE:
4 5
@@ -16,9 +17,9 @@ AUDIO_SET_STREAMTYPE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, AUDIO_SET_STREAMTYPE, int type)20.. c:macro:: AUDIO_SET_STREAMTYPE
20 :name: AUDIO_SET_STREAMTYPE
21 21
22``int ioctl(fd, AUDIO_SET_STREAMTYPE, int type)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 -31 -
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Arguments · 6 unmodified lines
40 40
41 - stream type41 - stream type
42 42
43
44Description43Description
45-----------44-----------
46 45
@@ -48,7 +47,6 @@ This ioctl tells the driver which kind of audio stream to expect. This · 1 unmodified line
48is useful if the stream offers several audio sub-streams like LPCM and47is useful if the stream offers several audio sub-streams like LPCM and
49AC3.48AC3.
50 49
51
52Return Value50Return Value
53------------51------------
54 52
@@ -57,12 +55,10 @@ appropriately. The generic error codes are described at the · 2 unmodified lines
57:ref:`Generic Error Codes <gen-errors>` chapter.55:ref:`Generic Error Codes <gen-errors>` chapter.
58 56
59 57
60
61.. flat-table::58.. flat-table::
62 :header-rows: 059 :header-rows: 0
63 :stub-columns: 060 :stub-columns: 0
64 61
65
66 - .. row 162 - .. row 1
67 63
68 - ``EINVAL``64 - ``EINVAL``
Documentation/userspace-api/media/dvb/audio-stop.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.audio
2 3
3.. _AUDIO_STOP:4.. _AUDIO_STOP:
4 5
@@ -16,8 +17,9 @@ AUDIO_STOP · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, AUDIO_STOP)20.. c:macro:: AUDIO_STOP
20 :name: AUDIO_STOP21
22``int ioctl(int fd, AUDIO_STOP)``
21 23
22Arguments24Arguments
23---------25---------
@@ -26,21 +28,18 @@ Arguments · 2 unmodified lines
26 :header-rows: 028 :header-rows: 0
27 :stub-columns: 029 :stub-columns: 0
28 30
29
30 - .. row 131 - .. row 1
31 32
32 - int fd33 - int fd
33 34
34 - File descriptor returned by a previous call to open().35 - File descriptor returned by a previous call to open().
35 36
36
37Description37Description
38-----------38-----------
39 39
40This ioctl call asks the Audio Device to stop playing the current40This ioctl call asks the Audio Device to stop playing the current
41stream.41stream.
42 42
43
44Return Value43Return Value
45------------44------------
46 45
Documentation/userspace-api/media/dvb/ca-fclose.rst+2−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _ca_fclose:4.. _ca_fclose:
4 5
@@ -11,26 +12,22 @@ Name · 6 unmodified lines
11 12
12Digital TV CA close()13Digital TV CA close()
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int close(int fd)18.. c:function:: int close(int fd)
19 :name: dvb-ca-close
20
21 19
22Arguments20Arguments
23---------21---------
24 22
25``fd``23``fd``
26 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.24 File descriptor returned by a previous call to :c:func:`open()`.
27 25
28Description26Description
29-----------27-----------
30 28
31This system call closes a previously opened CA device.29This system call closes a previously opened CA device.
32 30
33
34Return Value31Return Value
35------------32------------
36 33
Documentation/userspace-api/media/dvb/ca-fopen.rst+1−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _ca_fopen:4.. _ca_fopen:
4 5
@@ -11,13 +12,10 @@ Name · 6 unmodified lines
11 12
12Digital TV CA open()13Digital TV CA open()
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int open(const char *name, int flags)18.. c:function:: int open(const char *name, int flags)
19 :name: dvb-ca-open
20
21 19
22Arguments20Arguments
23---------21---------
@@ -45,7 +43,6 @@ Arguments · 21 unmodified lines
45 - open in non-blocking mode43 - open in non-blocking mode
46 (blocking mode is the default)44 (blocking mode is the default)
47 45
48
49Description46Description
50-----------47-----------
51 48
@@ -63,11 +60,9 @@ Only one user can open the CA Device in ``O_RDWR`` mode. All other · 11 unmodified lines
63attempts to open the device in this mode will fail, and an error code60attempts to open the device in this mode will fail, and an error code
64will be returned.61will be returned.
65 62
66
67Return Value63Return Value
68------------64------------
69 65
70
71On success 0 is returned.66On success 0 is returned.
72 67
73On error -1 is returned, and the ``errno`` variable is set68On error -1 is returned, and the ``errno`` variable is set
Documentation/userspace-api/media/dvb/ca-get-cap.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_GET_CAP:4.. _CA_GET_CAP:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12CA_GET_CAP13CA_GET_CAP
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_GET_CAP, struct ca_caps *caps)18.. c:macro:: CA_GET_CAP
19 :name: CA_GET_CAP
20 19
20``int ioctl(fd, CA_GET_CAP, struct ca_caps *caps)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
27 27
28``caps``28``caps``
29 Pointer to struct :c:type:`ca_caps`.29 Pointer to struct :c:type:`ca_caps`.
Documentation/userspace-api/media/dvb/ca-get-descr-info.rst+5−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_GET_DESCR_INFO:4.. _CA_GET_DESCR_INFO:
4 5
@@ -11,18 +12,18 @@ Name · 6 unmodified lines
11 12
12CA_GET_DESCR_INFO13CA_GET_DESCR_INFO
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_GET_DESCR_INFO, struct ca_descr_info *desc)18.. c:macro:: CA_GET_DESCR_INFO
19 :name: CA_GET_DESCR_INFO19
20``int ioctl(fd, CA_GET_DESCR_INFO, struct ca_descr_info *desc)``
20 21
21Arguments22Arguments
22---------23---------
23 24
24``fd``25``fd``
25 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
26 27
27``desc``28``desc``
28 Pointer to struct :c:type:`ca_descr_info`.29 Pointer to struct :c:type:`ca_descr_info`.
Documentation/userspace-api/media/dvb/ca-get-msg.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_GET_MSG:4.. _CA_GET_MSG:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12CA_GET_MSG13CA_GET_MSG
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_GET_MSG, struct ca_msg *msg)18.. c:macro:: CA_GET_MSG
19 :name: CA_GET_MSG
20 19
20``int ioctl(fd, CA_GET_MSG, struct ca_msg *msg)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
27 27
28``msg``28``msg``
29 Pointer to struct :c:type:`ca_msg`.29 Pointer to struct :c:type:`ca_msg`.
@@ -38,11 +38,9 @@ Receives a message via a CI CA module. · 8 unmodified lines
38 Please notice that, on most drivers, this is done by reading from38 Please notice that, on most drivers, this is done by reading from
39 the /dev/adapter?/ca? device node.39 the /dev/adapter?/ca? device node.
40 40
41
42Return Value41Return Value
43------------42------------
44 43
45
46On success 0 is returned.44On success 0 is returned.
47 45
48On error -1 is returned, and the ``errno`` variable is set46On error -1 is returned, and the ``errno`` variable is set
Documentation/userspace-api/media/dvb/ca-get-slot-info.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_GET_SLOT_INFO:4.. _CA_GET_SLOT_INFO:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12CA_GET_SLOT_INFO13CA_GET_SLOT_INFO
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_GET_SLOT_INFO, struct ca_slot_info *info)18.. c:macro:: CA_GET_SLOT_INFO
19 :name: CA_GET_SLOT_INFO
20 19
20``int ioctl(fd, CA_GET_SLOT_INFO, struct ca_slot_info *info)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
27 27
28``info``28``info``
29 Pointer to struct :c:type:`ca_slot_info`.29 Pointer to struct :c:type:`ca_slot_info`.
@@ -34,7 +34,6 @@ Description · 4 unmodified lines
34Returns information about a CA slot identified by34Returns information about a CA slot identified by
35:c:type:`ca_slot_info`.slot_num.35:c:type:`ca_slot_info`.slot_num.
36 36
37
38Return Value37Return Value
39------------38------------
40 39
Documentation/userspace-api/media/dvb/ca-reset.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_RESET:4.. _CA_RESET:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12CA_RESET13CA_RESET
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_RESET)18.. c:macro:: CA_RESET
19 :name: CA_RESET
20 19
20``int ioctl(fd, CA_RESET)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
27 27
28Description28Description
29-----------29-----------
@@ -31,7 +31,6 @@ Description · 1 unmodified line
31Puts the Conditional Access hardware on its initial state. It should31Puts the Conditional Access hardware on its initial state. It should
32be called before start using the CA hardware.32be called before start using the CA hardware.
33 33
34
35Return Value34Return Value
36------------35------------
37 36
Documentation/userspace-api/media/dvb/ca-send-msg.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_SEND_MSG:4.. _CA_SEND_MSG:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12CA_SEND_MSG13CA_SEND_MSG
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_SEND_MSG, struct ca_msg *msg)18.. c:macro:: CA_SEND_MSG
19 :name: CA_SEND_MSG
20 19
20``int ioctl(fd, CA_SEND_MSG, struct ca_msg *msg)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
27 27
28``msg``28``msg``
29 Pointer to struct :c:type:`ca_msg`.29 Pointer to struct :c:type:`ca_msg`.
30 30
31
32Description31Description
33-----------32-----------
34 33
Documentation/userspace-api/media/dvb/ca-set-descr.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.ca
2 3
3.. _CA_SET_DESCR:4.. _CA_SET_DESCR:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12CA_SET_DESCR13CA_SET_DESCR
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, CA_SET_DESCR, struct ca_descr *desc)18.. c:macro:: CA_SET_DESCR
19 :name: CA_SET_DESCR
20 19
20``int ioctl(fd, CA_SET_DESCR, struct ca_descr *desc)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.26 File descriptor returned by a previous call to :c:func:`open()`.
27 27
28``msg``28``msg``
29 Pointer to struct :c:type:`ca_descr`.29 Pointer to struct :c:type:`ca_descr`.
Documentation/userspace-api/media/dvb/dmx-add-pid.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_ADD_PID:4.. _DMX_ADD_PID:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12DMX_ADD_PID13DMX_ADD_PID
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, DMX_ADD_PID, __u16 *pid)18.. c:macro:: DMX_ADD_PID
19 :name: DMX_ADD_PID
20 19
20``int ioctl(fd, DMX_ADD_PID, __u16 *pid)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``pid``28``pid``
29 PID number to be filtered.29 PID number to be filtered.
30 30
31
32Description31Description
33-----------32-----------
34 33
@@ -36,7 +35,6 @@ This ioctl call allows to add multiple PIDs to a transport stream filter · 1 unmodified line
36previously set up with :ref:`DMX_SET_PES_FILTER` and output equal to35previously set up with :ref:`DMX_SET_PES_FILTER` and output equal to
37:c:type:`DMX_OUT_TSDEMUX_TAP <dmx_output>`.36:c:type:`DMX_OUT_TSDEMUX_TAP <dmx_output>`.
38 37
39
40Return Value38Return Value
41------------39------------
42 40
Documentation/userspace-api/media/dvb/dmx-expbuf.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_EXPBUF:4.. _DMX_EXPBUF:
4 5
@@ -13,24 +14,22 @@ DMX_EXPBUF - Export a buffer as a DMABUF file descriptor. · 8 unmodified lines
13 14
14.. warning:: this API is still experimental15.. warning:: this API is still experimental
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl( int fd, DMX_EXPBUF, struct dmx_exportbuffer *argp )20.. c:macro:: DMX_EXPBUF
21 :name: DMX_EXPBUF
22 21
22``int ioctl(int fd, DMX_EXPBUF, struct dmx_exportbuffer *argp)``
23 23
24Arguments24Arguments
25=========25=========
26 26
27``fd``27``fd``
28 File descriptor returned by :ref:`open() <dmx_fopen>`.28 File descriptor returned by :c:func:`open()`.
29 29
30``argp``30``argp``
31 Pointer to struct :c:type:`dmx_exportbuffer`.31 Pointer to struct :c:type:`dmx_exportbuffer`.
32 32
33
34Description33Description
35===========34===========
36 35
@@ -54,11 +53,9 @@ driver, on success. This is a DMABUF file descriptor. The application may · 17 unmodified lines
54pass it to other DMABUF-aware devices. It is recommended to close a DMABUF53pass it to other DMABUF-aware devices. It is recommended to close a DMABUF
55file when it is no longer used to allow the associated memory to be reclaimed.54file when it is no longer used to allow the associated memory to be reclaimed.
56 55
57
58Examples56Examples
59========57========
60 58
61
62.. code-block:: c59.. code-block:: c
63 60
64 int buffer_export(int v4lfd, enum dmx_buf_type bt, int index, int *dmafd)61 int buffer_export(int v4lfd, enum dmx_buf_type bt, int index, int *dmafd)
Documentation/userspace-api/media/dvb/dmx-fclose.rst+3−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _dmx_fclose:4.. _dmx_fclose:
4 5
@@ -11,27 +12,23 @@ Name · 6 unmodified lines
11 12
12Digital TV demux close()13Digital TV demux close()
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int close(int fd)18.. c:function:: int close(int fd)
19 :name: dvb-dmx-close
20
21 19
22Arguments20Arguments
23---------21---------
24 22
25``fd``23``fd``
26 File descriptor returned by a previous call to24 File descriptor returned by a previous call to
27 :c:func:`open() <dvb-dmx-open>`.25 :c:func:`open()`.
28 26
29Description27Description
30-----------28-----------
31 29
32This system call deactivates and deallocates a filter that was30This system call deactivates and deallocates a filter that was
33previously allocated via the :c:func:`open() <dvb-dmx-open>` call.31previously allocated via the :c:func:`open()` call.
34
35 32
36Return Value33Return Value
37------------34------------
Documentation/userspace-api/media/dvb/dmx-fopen.rst+1−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _dmx_fopen:4.. _dmx_fopen:
4 5
@@ -11,12 +12,10 @@ Name · 6 unmodified lines
11 12
12Digital TV demux open()13Digital TV demux open()
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int open(const char *deviceName, int flags)18.. c:function:: int open(const char *deviceName, int flags)
19 :name: dvb-dmx-open
20 19
21Arguments20Arguments
22---------21---------
@@ -47,7 +46,6 @@ Arguments · 24 unmodified lines
47 - open in non-blocking mode46 - open in non-blocking mode
48 (blocking mode is the default)47 (blocking mode is the default)
49 48
50
51Description49Description
52-----------50-----------
53 51
@@ -68,7 +66,6 @@ affect the semantics of the ``open()`` call itself. A device opened · 14 unmodified lines
68in blocking mode can later be put into non-blocking mode (and vice versa)66in blocking mode can later be put into non-blocking mode (and vice versa)
69using the ``F_SETFL`` command of the fcntl system call.67using the ``F_SETFL`` command of the fcntl system call.
70 68
71
72Return Value69Return Value
73------------70------------
74 71
Documentation/userspace-api/media/dvb/dmx-fread.rst+2−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _dmx_fread:4.. _dmx_fread:
4 5
@@ -11,18 +12,16 @@ Name · 6 unmodified lines
11 12
12Digital TV demux read()13Digital TV demux read()
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: size_t read(int fd, void *buf, size_t count)18.. c:function:: size_t read(int fd, void *buf, size_t count)
19 :name: dvb-dmx-read
20 19
21Arguments20Arguments
22---------21---------
23 22
24``fd``23``fd``
25 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.24 File descriptor returned by a previous call to :c:func:`open()`.
26 25
27 ``buf``26 ``buf``
28 Buffer to be filled27 Buffer to be filled
@@ -44,7 +43,6 @@ to be transferred is implied by count. · 15 unmodified lines
44 :c:type:`DMX_CHECK_CRC <dmx_sct_filter_params>` flag set,43 :c:type:`DMX_CHECK_CRC <dmx_sct_filter_params>` flag set,
45 data that fails on CRC check will be silently ignored.44 data that fails on CRC check will be silently ignored.
46 45
47
48Return Value46Return Value
49------------47------------
50 48
@@ -75,6 +73,5 @@ appropriately. · 24 unmodified lines
75 - The driver failed to write to the callers buffer due to an73 - The driver failed to write to the callers buffer due to an
76 invalid \*buf pointer.74 invalid \*buf pointer.
77 75
78
79The generic error codes are described at the76The generic error codes are described at the
80:ref:`Generic Error Codes <gen-errors>` chapter.77:ref:`Generic Error Codes <gen-errors>` chapter.
Documentation/userspace-api/media/dvb/dmx-fwrite.rst+2−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _dmx_fwrite:4.. _dmx_fwrite:
4 5
@@ -11,18 +12,16 @@ Name · 6 unmodified lines
11 12
12Digital TV demux write()13Digital TV demux write()
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: ssize_t write(int fd, const void *buf, size_t count)18.. c:function:: ssize_t write(int fd, const void *buf, size_t count)
19 :name: dvb-dmx-write
20 19
21Arguments20Arguments
22---------21---------
23 22
24``fd``23``fd``
25 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.24 File descriptor returned by a previous call to :c:func:`open()`.
26 25
27``buf``26``buf``
28 Buffer with data to be written27 Buffer with data to be written
@@ -40,7 +39,6 @@ digitally recorded Transport Stream. Matching filters have to be defined · 11 unmodified lines
40in the corresponding physical demux device, ``/dev/dvb/adapter?/demux?``.39in the corresponding physical demux device, ``/dev/dvb/adapter?/demux?``.
41The amount of data to be transferred is implied by count.40The amount of data to be transferred is implied by count.
42 41
43
44Return Value42Return Value
45------------43------------
46 44
Documentation/userspace-api/media/dvb/dmx-get-pes-pids.rst+5−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_GET_PES_PIDS:4.. _DMX_GET_PES_PIDS:
4 5
@@ -11,23 +12,22 @@ Name · 6 unmodified lines
11 12
12DMX_GET_PES_PIDS13DMX_GET_PES_PIDS
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, DMX_GET_PES_PIDS, __u16 pids[5])18.. c:macro:: DMX_GET_PES_PIDS
19 :name: DMX_GET_PES_PIDS19
20``int ioctl(fd, DMX_GET_PES_PIDS, __u16 pids[5])``
20 21
21Arguments22Arguments
22---------23---------
23 24
24``fd``25``fd``
25 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
26 27
27``pids``28``pids``
28 Array used to store 5 Program IDs.29 Array used to store 5 Program IDs.
29 30
30
31Description31Description
32-----------32-----------
33 33
@@ -45,13 +45,11 @@ pids[DMX_PES_SUBTITLE] 3 first subtitle PID · 11 unmodified lines
45pids[DMX_PES_PCR] 4 first Program Clock Reference PID45pids[DMX_PES_PCR] 4 first Program Clock Reference PID
46======================= ======== =======================================46======================= ======== =======================================
47 47
48
49.. note::48.. note::
50 49
51 A value equal to 0xffff means that the PID was not filled by the50 A value equal to 0xffff means that the PID was not filled by the
52 Kernel.51 Kernel.
53 52
54
55Return Value53Return Value
56------------54------------
57 55
Documentation/userspace-api/media/dvb/dmx-get-stc.rst+5−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_GET_STC:4.. _DMX_GET_STC:
4 5
@@ -11,23 +12,22 @@ Name · 6 unmodified lines
11 12
12DMX_GET_STC13DMX_GET_STC
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl( int fd, DMX_GET_STC, struct dmx_stc *stc)18.. c:macro:: DMX_GET_STC
19 :name: DMX_GET_STC19
20``int ioctl(int fd, DMX_GET_STC, struct dmx_stc *stc)``
20 21
21Arguments22Arguments
22---------23---------
23 24
24``fd``25``fd``
25 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
26 27
27``stc``28``stc``
28 Pointer to :c:type:`dmx_stc` where the stc data is to be stored.29 Pointer to :c:type:`dmx_stc` where the stc data is to be stored.
29 30
30
31Description31Description
32-----------32-----------
33 33
@@ -39,7 +39,6 @@ The result is returned in form of a ratio with a 64 bit numerator · 5 unmodified lines
39and a 32 bit denominator, so the real 90kHz STC value is39and a 32 bit denominator, so the real 90kHz STC value is
40``stc->stc / stc->base``.40``stc->stc / stc->base``.
41 41
42
43Return Value42Return Value
44------------43------------
45 44
@@ -61,6 +60,5 @@ appropriately. · 15 unmodified lines
61 60
62 - Invalid stc number.61 - Invalid stc number.
63 62
64
65The generic error codes are described at the63The generic error codes are described at the
66:ref:`Generic Error Codes <gen-errors>` chapter.64:ref:`Generic Error Codes <gen-errors>` chapter.
Documentation/userspace-api/media/dvb/dmx-mmap.rst+6−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _dmx-mmap:4.. _dmx-mmap:
4 5
@@ -21,9 +22,7 @@ Synopsis · 16 unmodified lines
21 #include <unistd.h>22 #include <unistd.h>
22 #include <sys/mman.h>23 #include <sys/mman.h>
23 24
24
25.. c:function:: void *mmap( void *start, size_t length, int prot, int flags, int fd, off_t offset )25.. c:function:: void *mmap( void *start, size_t length, int prot, int flags, int fd, off_t offset )
26 :name: dmx-mmap
27 26
28Arguments27Arguments
29=========28=========
@@ -54,7 +53,7 @@ Arguments · 24 unmodified lines
54 53
55 ``MAP_FIXED`` requests that the driver selects no other address than54 ``MAP_FIXED`` requests that the driver selects no other address than
56 the one specified. If the specified address cannot be used,55 the one specified. If the specified address cannot be used,
57 :ref:`mmap() <dmx-mmap>` will fail. If ``MAP_FIXED`` is specified,56 :c:func:`mmap()` will fail. If ``MAP_FIXED`` is specified,
58 ``start`` must be a multiple of the pagesize. Use of this option is57 ``start`` must be a multiple of the pagesize. Use of this option is
59 discouraged.58 discouraged.
60 59
@@ -69,17 +68,16 @@ Arguments · 8 unmodified lines
69 flags.68 flags.
70 69
71``fd``70``fd``
72 File descriptor returned by :ref:`open() <dmx_fopen>`.71 File descriptor returned by :c:func:`open()`.
73 72
74``offset``73``offset``
75 Offset of the buffer in device memory, as returned by74 Offset of the buffer in device memory, as returned by
76 :ref:`DMX_QUERYBUF` ioctl.75 :ref:`DMX_QUERYBUF` ioctl.
77 76
78
79Description77Description
80===========78===========
81 79
82The :ref:`mmap() <dmx-mmap>` function asks to map ``length`` bytes starting at80The :c:func:`mmap()` function asks to map ``length`` bytes starting at
83``offset`` in the memory of the device specified by ``fd`` into the81``offset`` in the memory of the device specified by ``fd`` into the
84application address space, preferably at address ``start``. This latter82application address space, preferably at address ``start``. This latter
85address is a hint only, and is usually specified as 0.83address is a hint only, and is usually specified as 0.
@@ -88,13 +86,12 @@ Suitable length and offset parameters are queried with the · 2 unmodified lines
88:ref:`DMX_QUERYBUF` ioctl. Buffers must be allocated with the86:ref:`DMX_QUERYBUF` ioctl. Buffers must be allocated with the
89:ref:`DMX_REQBUFS` ioctl before they can be queried.87:ref:`DMX_REQBUFS` ioctl before they can be queried.
90 88
91To unmap buffers the :ref:`munmap() <dmx-munmap>` function is used.89To unmap buffers the :c:func:`munmap()` function is used.
92
93 90
94Return Value91Return Value
95============92============
96 93
97On success :ref:`mmap() <dmx-mmap>` returns a pointer to the mapped buffer. On94On success :c:func:`mmap()` returns a pointer to the mapped buffer. On
98error ``MAP_FAILED`` (-1) is returned, and the ``errno`` variable is set95error ``MAP_FAILED`` (-1) is returned, and the ``errno`` variable is set
99appropriately. Possible error codes are:96appropriately. Possible error codes are:
100 97
Documentation/userspace-api/media/dvb/dmx-munmap.rst+5−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _dmx-munmap:4.. _dmx-munmap:
4 5
@@ -13,7 +14,6 @@ dmx-munmap - Unmap device memory · 8 unmodified lines
13 14
14.. warning:: This API is still experimental.15.. warning:: This API is still experimental.
15 16
16
17Synopsis17Synopsis
18========18========
19 19
@@ -22,33 +22,29 @@ Synopsis · 2 unmodified lines
22 #include <unistd.h>22 #include <unistd.h>
23 #include <sys/mman.h>23 #include <sys/mman.h>
24 24
25
26.. c:function:: int munmap( void *start, size_t length )25.. c:function:: int munmap( void *start, size_t length )
27 :name: dmx-munmap
28 26
29Arguments27Arguments
30=========28=========
31 29
32``start``30``start``
33 Address of the mapped buffer as returned by the31 Address of the mapped buffer as returned by the
34 :ref:`mmap() <dmx-mmap>` function.32 :c:func:`mmap()` function.
35 33
36``length``34``length``
37 Length of the mapped buffer. This must be the same value as given to35 Length of the mapped buffer. This must be the same value as given to
38 :ref:`mmap() <dmx-mmap>`.36 :c:func:`mmap()`.
39
40 37
41Description38Description
42===========39===========
43 40
44Unmaps a previously with the :ref:`mmap() <dmx-mmap>` function mapped41Unmaps a previously with the :c:func:`mmap()` function mapped
45buffer and frees it, if possible.42buffer and frees it, if possible.
46 43
47
48Return Value44Return Value
49============45============
50 46
51On success :ref:`munmap() <dmx-munmap>` returns 0, on failure -1 and the47On success :c:func:`munmap()` returns 0, on failure -1 and the
52``errno`` variable is set appropriately:48``errno`` variable is set appropriately:
53 49
54EINVAL50EINVAL
Documentation/userspace-api/media/dvb/dmx-qbuf.rst+8−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_QBUF:4.. _DMX_QBUF:
4 5
@@ -13,27 +14,26 @@ DMX_QBUF - DMX_DQBUF - Exchange a buffer with the driver · 8 unmodified lines
13 14
14.. warning:: this API is still experimental15.. warning:: this API is still experimental
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl( int fd, DMX_QBUF, struct dmx_buffer *argp )20.. c:macro:: DMX_QBUF
21 :name: DMX_QBUF21
22``int ioctl(int fd, DMX_QBUF, struct dmx_buffer *argp)``
22 23
23.. c:function:: int ioctl( int fd, DMX_DQBUF, struct dmx_buffer *argp )24.. c:macro:: DMX_DQBUF
24 :name: DMX_DQBUF
25 25
26``int ioctl(int fd, DMX_DQBUF, struct dmx_buffer *argp)``
26 27
27Arguments28Arguments
28=========29=========
29 30
30``fd``31``fd``
31 File descriptor returned by :ref:`open() <dmx_fopen>`.32 File descriptor returned by :c:func:`open()`.
32 33
33``argp``34``argp``
34 Pointer to struct :c:type:`dmx_buffer`.35 Pointer to struct :c:type:`dmx_buffer`.
35 36
36
37Description37Description
38===========38===========
39 39
@@ -60,13 +60,12 @@ the driver fills the remaining fields or returns an error code. · 20 unmodified lines
60 60
61By default ``DMX_DQBUF`` blocks when no buffer is in the outgoing61By default ``DMX_DQBUF`` blocks when no buffer is in the outgoing
62queue. When the ``O_NONBLOCK`` flag was given to the62queue. When the ``O_NONBLOCK`` flag was given to the
63:ref:`open() <dmx_fopen>` function, ``DMX_DQBUF`` returns63:c:func:`open()` function, ``DMX_DQBUF`` returns
64immediately with an ``EAGAIN`` error code when no buffer is available.64immediately with an ``EAGAIN`` error code when no buffer is available.
65 65
66The struct :c:type:`dmx_buffer` structure is specified in66The struct :c:type:`dmx_buffer` structure is specified in
67:ref:`buffer`.67:ref:`buffer`.
68 68
69
70Return Value69Return Value
71============70============
72 71
Documentation/userspace-api/media/dvb/dmx-querybuf.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_QUERYBUF:4.. _DMX_QUERYBUF:
4 5
@@ -13,24 +14,22 @@ DMX_QUERYBUF - Query the status of a buffer · 8 unmodified lines
13 14
14.. warning:: this API is still experimental15.. warning:: this API is still experimental
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl( int fd, DMX_QUERYBUF, struct dvb_buffer *argp )20.. c:macro:: DMX_QUERYBUF
21 :name: DMX_QUERYBUF
22 21
22``int ioctl(int fd, DMX_QUERYBUF, struct dvb_buffer *argp)``
23 23
24Arguments24Arguments
25=========25=========
26 26
27``fd``27``fd``
28 File descriptor returned by :ref:`open() <dmx_fopen>`.28 File descriptor returned by :c:func:`open()`.
29 29
30``argp``30``argp``
31 Pointer to struct :c:type:`dvb_buffer`.31 Pointer to struct :c:type:`dvb_buffer`.
32 32
33
34Description33Description
35===========34===========
36 35
Documentation/userspace-api/media/dvb/dmx-remove-pid.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_REMOVE_PID:4.. _DMX_REMOVE_PID:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12DMX_REMOVE_PID13DMX_REMOVE_PID
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl(fd, DMX_REMOVE_PID, __u16 *pid)18.. c:macro:: DMX_REMOVE_PID
19 :name: DMX_REMOVE_PID
20 19
20``int ioctl(fd, DMX_REMOVE_PID, __u16 *pid)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``pid``28``pid``
29 PID of the PES filter to be removed.29 PID of the PES filter to be removed.
30 30
31
32Description31Description
33-----------32-----------
34 33
@@ -37,7 +36,6 @@ transport stream filter, e. g. a filter previously set up with output · 2 unmodified lines
37equal to :c:type:`DMX_OUT_TSDEMUX_TAP <dmx_output>`, created via either36equal to :c:type:`DMX_OUT_TSDEMUX_TAP <dmx_output>`, created via either
38:ref:`DMX_SET_PES_FILTER` or :ref:`DMX_ADD_PID`.37:ref:`DMX_SET_PES_FILTER` or :ref:`DMX_ADD_PID`.
39 38
40
41Return Value39Return Value
42------------40------------
43 41
Documentation/userspace-api/media/dvb/dmx-reqbufs.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_REQBUFS:4.. _DMX_REQBUFS:
4 5
@@ -13,19 +14,18 @@ DMX_REQBUFS - Initiate Memory Mapping and/or DMA buffer I/O · 8 unmodified lines
13 14
14.. warning:: this API is still experimental15.. warning:: this API is still experimental
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl( int fd, DMX_REQBUFS, struct dmx_requestbuffers *argp )20.. c:macro:: DMX_REQBUFS
21 :name: DMX_REQBUFS
22 21
22``int ioctl(int fd, DMX_REQBUFS, struct dmx_requestbuffers *argp)``
23 23
24Arguments24Arguments
25=========25=========
26 26
27``fd``27``fd``
28 File descriptor returned by :ref:`open() <dmx_fopen>`.28 File descriptor returned by :c:func:`open()`.
29 29
30``argp``30``argp``
31 Pointer to struct :c:type:`dmx_requestbuffers`.31 Pointer to struct :c:type:`dmx_requestbuffers`.
@@ -64,7 +64,6 @@ buffers, however this cannot succeed when any buffers are still mapped. · 32 unmodified lines
64A ``count`` value of zero frees all buffers, after aborting or finishing64A ``count`` value of zero frees all buffers, after aborting or finishing
65any DMA in progress.65any DMA in progress.
66 66
67
68Return Value67Return Value
69============68============
70 69
Documentation/userspace-api/media/dvb/dmx-set-buffer-size.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_SET_BUFFER_SIZE:4.. _DMX_SET_BUFFER_SIZE:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12DMX_SET_BUFFER_SIZE13DMX_SET_BUFFER_SIZE
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl( int fd, DMX_SET_BUFFER_SIZE, unsigned long size)18.. c:macro:: DMX_SET_BUFFER_SIZE
19 :name: DMX_SET_BUFFER_SIZE
20 19
20``int ioctl(int fd, DMX_SET_BUFFER_SIZE, unsigned long size)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``size``28``size``
29 Unsigned long size29 Unsigned long size
@@ -36,11 +36,9 @@ filtered data. The default size is two maximum sized sections, i.e. if · 6 unmodified lines
36this function is not called a buffer size of ``2 * 4096`` bytes will be36this function is not called a buffer size of ``2 * 4096`` bytes will be
37used.37used.
38 38
39
40Return Value39Return Value
41------------40------------
42 41
43
44On success 0 is returned.42On success 0 is returned.
45 43
46On error -1 is returned, and the ``errno`` variable is set44On error -1 is returned, and the ``errno`` variable is set
Documentation/userspace-api/media/dvb/dmx-set-filter.rst+5−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_SET_FILTER:4.. _DMX_SET_FILTER:
4 5
@@ -11,24 +12,23 @@ Name · 6 unmodified lines
11 12
12DMX_SET_FILTER13DMX_SET_FILTER
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl( int fd, DMX_SET_FILTER, struct dmx_sct_filter_params *params)18.. c:macro:: DMX_SET_FILTER
19 :name: DMX_SET_FILTER19
20``int ioctl(int fd, DMX_SET_FILTER, struct dmx_sct_filter_params *params)``
20 21
21Arguments22Arguments
22---------23---------
23 24
24``fd``25``fd``
25 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
26 27
27``params``28``params``
28 29
29 Pointer to structure containing filter parameters.30 Pointer to structure containing filter parameters.
30 31
31
32Description32Description
33-----------33-----------
34 34
@@ -43,11 +43,9 @@ operation should be started immediately (without waiting for a · 8 unmodified lines
43:ref:`DMX_START` ioctl call). If a filter was previously set-up, this43:ref:`DMX_START` ioctl call). If a filter was previously set-up, this
44filter will be canceled, and the receive buffer will be flushed.44filter will be canceled, and the receive buffer will be flushed.
45 45
46
47Return Value46Return Value
48------------47------------
49 48
50
51On success 0 is returned.49On success 0 is returned.
52 50
53On error -1 is returned, and the ``errno`` variable is set51On error -1 is returned, and the ``errno`` variable is set
Documentation/userspace-api/media/dvb/dmx-set-pes-filter.rst+4−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_SET_PES_FILTER:4.. _DMX_SET_PES_FILTER:
4 5
@@ -11,25 +12,22 @@ Name · 6 unmodified lines
11 12
12DMX_SET_PES_FILTER13DMX_SET_PES_FILTER
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl( int fd, DMX_SET_PES_FILTER, struct dmx_pes_filter_params *params)18.. c:macro:: DMX_SET_PES_FILTER
19 :name: DMX_SET_PES_FILTER
20 19
20``int ioctl(int fd, DMX_SET_PES_FILTER, struct dmx_pes_filter_params *params)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25
26``fd``25``fd``
27 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
28 27
29``params``28``params``
30 Pointer to structure containing filter parameters.29 Pointer to structure containing filter parameters.
31 30
32
33Description31Description
34-----------32-----------
35 33
@@ -38,7 +36,6 @@ provided. By a PES filter is meant a filter that is based just on the · 2 unmodified lines
38packet identifier (PID), i.e. no PES header or payload filtering36packet identifier (PID), i.e. no PES header or payload filtering
39capability is supported.37capability is supported.
40 38
41
42Return Value39Return Value
43------------40------------
44 41
@@ -54,7 +51,6 @@ appropriately. · 9 unmodified lines
54 :stub-columns: 051 :stub-columns: 0
55 :widths: 1 1652 :widths: 1 16
56 53
57
58 - .. row 154 - .. row 1
59 55
60 - ``EBUSY``56 - ``EBUSY``
@@ -64,6 +60,5 @@ appropriately. · 3 unmodified lines
64 Make sure that these filters are stopped before starting this60 Make sure that these filters are stopped before starting this
65 filter.61 filter.
66 62
67
68The generic error codes are described at the63The generic error codes are described at the
69:ref:`Generic Error Codes <gen-errors>` chapter.64:ref:`Generic Error Codes <gen-errors>` chapter.
Documentation/userspace-api/media/dvb/dmx-start.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_START:4.. _DMX_START:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12DMX_START13DMX_START
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl( int fd, DMX_START)18.. c:macro:: DMX_START
19 :name: DMX_START
20 19
20``int ioctl(int fd, DMX_START)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28Description28Description
29-----------29-----------
@@ -31,7 +31,6 @@ Description · 1 unmodified line
31This ioctl call is used to start the actual filtering operation defined31This ioctl call is used to start the actual filtering operation defined
32via the ioctl calls :ref:`DMX_SET_FILTER` or :ref:`DMX_SET_PES_FILTER`.32via the ioctl calls :ref:`DMX_SET_FILTER` or :ref:`DMX_SET_PES_FILTER`.
33 33
34
35Return Value34Return Value
36------------35------------
37 36
@@ -46,7 +45,6 @@ appropriately. · 8 unmodified lines
46 :header-rows: 045 :header-rows: 0
47 :stub-columns: 046 :stub-columns: 0
48 47
49
50 - .. row 148 - .. row 1
51 49
52 - ``EINVAL``50 - ``EINVAL``
@@ -63,6 +61,5 @@ appropriately. · 10 unmodified lines
63 Make sure that these filters are stopped before starting this61 Make sure that these filters are stopped before starting this
64 filter.62 filter.
65 63
66
67The generic error codes are described at the64The generic error codes are described at the
68:ref:`Generic Error Codes <gen-errors>` chapter.65:ref:`Generic Error Codes <gen-errors>` chapter.
Documentation/userspace-api/media/dvb/dmx-stop.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.dmx
2 3
3.. _DMX_STOP:4.. _DMX_STOP:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12DMX_STOP13DMX_STOP
13 14
14
15Synopsis15Synopsis
16--------16--------
17 17
18.. c:function:: int ioctl( int fd, DMX_STOP)18.. c:macro:: DMX_STOP
19 :name: DMX_STOP
20 19
20``int ioctl(int fd, DMX_STOP)``
21 21
22Arguments22Arguments
23---------23---------
24 24
25``fd``25``fd``
26 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28Description28Description
29-----------29-----------
@@ -32,7 +32,6 @@ This ioctl call is used to stop the actual filtering operation defined · 2 unmodified lines
32via the ioctl calls :ref:`DMX_SET_FILTER` or :ref:`DMX_SET_PES_FILTER` and32via the ioctl calls :ref:`DMX_SET_FILTER` or :ref:`DMX_SET_PES_FILTER` and
33started via the :ref:`DMX_START` command.33started via the :ref:`DMX_START` command.
34 34
35
36Return Value35Return Value
37------------36------------
38 37
Documentation/userspace-api/media/dvb/fe-diseqc-recv-slave-reply.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_DISEQC_RECV_SLAVE_REPLY:4.. _FE_DISEQC_RECV_SLAVE_REPLY:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12FE_DISEQC_RECV_SLAVE_REPLY - Receives reply from a DiSEqC 2.0 command13FE_DISEQC_RECV_SLAVE_REPLY - Receives reply from a DiSEqC 2.0 command
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_DISEQC_RECV_SLAVE_REPLY, struct dvb_diseqc_slave_reply *argp )18.. c:macro:: FE_DISEQC_RECV_SLAVE_REPLY
19 :name: FE_DISEQC_RECV_SLAVE_REPLY
20 19
20``int ioctl(int fd, FE_DISEQC_RECV_SLAVE_REPLY, struct dvb_diseqc_slave_reply *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 pointer to struct :c:type:`dvb_diseqc_slave_reply`.29 pointer to struct :c:type:`dvb_diseqc_slave_reply`.
30 30
31
32Description31Description
33===========32===========
34 33
Documentation/userspace-api/media/dvb/fe-diseqc-reset-overload.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_DISEQC_RESET_OVERLOAD:4.. _FE_DISEQC_RESET_OVERLOAD:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12FE_DISEQC_RESET_OVERLOAD - Restores the power to the antenna subsystem, if it was powered off due - to power overload.13FE_DISEQC_RESET_OVERLOAD - Restores the power to the antenna subsystem, if it was powered off due - to power overload.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_DISEQC_RESET_OVERLOAD, NULL )18.. c:macro:: FE_DISEQC_RESET_OVERLOAD
19 :name: FE_DISEQC_RESET_OVERLOAD
20 19
20``int ioctl(int fd, FE_DISEQC_RESET_OVERLOAD, NULL)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28Description28Description
29===========29===========
@@ -33,7 +33,6 @@ this ioctl call restores the power to the bus. The call requires · 3 unmodified lines
33read/write access to the device. This call has no effect if the device33read/write access to the device. This call has no effect if the device
34is manually powered off. Not all Digital TV adapters support this ioctl.34is manually powered off. Not all Digital TV adapters support this ioctl.
35 35
36
37Return Value36Return Value
38============37============
39 38
Documentation/userspace-api/media/dvb/fe-diseqc-send-burst.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_DISEQC_SEND_BURST:4.. _FE_DISEQC_SEND_BURST:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12FE_DISEQC_SEND_BURST - Sends a 22KHz tone burst for 2x1 mini DiSEqC satellite selection.13FE_DISEQC_SEND_BURST - Sends a 22KHz tone burst for 2x1 mini DiSEqC satellite selection.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_DISEQC_SEND_BURST, enum fe_sec_mini_cmd tone )18.. c:macro:: FE_DISEQC_SEND_BURST
19 :name: FE_DISEQC_SEND_BURST
20 19
20``int ioctl(int fd, FE_DISEQC_SEND_BURST, enum fe_sec_mini_cmd tone)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``tone``28``tone``
29 An integer enumered value described at :c:type:`fe_sec_mini_cmd`.29 An integer enumered value described at :c:type:`fe_sec_mini_cmd`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -39,7 +38,6 @@ read/write permissions. · 4 unmodified lines
39It provides support for what's specified at38It provides support for what's specified at
40`Digital Satellite Equipment Control (DiSEqC) - Simple "ToneBurst" Detection Circuit specification. <http://www.eutelsat.com/files/contributed/satellites/pdf/Diseqc/associated%20docs/simple_tone_burst_detec.pdf>`__39`Digital Satellite Equipment Control (DiSEqC) - Simple "ToneBurst" Detection Circuit specification. <http://www.eutelsat.com/files/contributed/satellites/pdf/Diseqc/associated%20docs/simple_tone_burst_detec.pdf>`__
41 40
42
43Return Value41Return Value
44============42============
45 43
Documentation/userspace-api/media/dvb/fe-diseqc-send-master-cmd.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_DISEQC_SEND_MASTER_CMD:4.. _FE_DISEQC_SEND_MASTER_CMD:
4 5
@@ -11,25 +12,23 @@ Name · 6 unmodified lines
11 12
12FE_DISEQC_SEND_MASTER_CMD - Sends a DiSEqC command13FE_DISEQC_SEND_MASTER_CMD - Sends a DiSEqC command
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_DISEQC_SEND_MASTER_CMD, struct dvb_diseqc_master_cmd *argp )18.. c:macro:: FE_DISEQC_SEND_MASTER_CMD
19 :name: FE_DISEQC_SEND_MASTER_CMD
20 19
20``int ioctl(int fd, FE_DISEQC_SEND_MASTER_CMD, struct dvb_diseqc_master_cmd *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 pointer to struct29 pointer to struct
30 :c:type:`dvb_diseqc_master_cmd`30 :c:type:`dvb_diseqc_master_cmd`
31 31
32
33Description32Description
34===========33===========
35 34
Documentation/userspace-api/media/dvb/fe-dishnetwork-send-legacy-cmd.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_DISHNETWORK_SEND_LEGACY_CMD:4.. _FE_DISHNETWORK_SEND_LEGACY_CMD:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12FE_DISHNETWORK_SEND_LEGACY_CMD13FE_DISHNETWORK_SEND_LEGACY_CMD
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl(int fd, FE_DISHNETWORK_SEND_LEGACY_CMD, unsigned long cmd)18.. c:macro:: FE_DISHNETWORK_SEND_LEGACY_CMD
19 :name: FE_DISHNETWORK_SEND_LEGACY_CMD
20 19
20``int ioctl(int fd, FE_DISHNETWORK_SEND_LEGACY_CMD, unsigned long cmd)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :c:func:`open() <dvb-fe-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``cmd``28``cmd``
29 Sends the specified raw cmd to the dish via DISEqC.29 Sends the specified raw cmd to the dish via DISEqC.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -42,7 +41,6 @@ frontend, for Dish Network legacy switches. · 7 unmodified lines
42As support for this ioctl were added in 2004, this means that such41As support for this ioctl were added in 2004, this means that such
43dishes were already legacy in 2004.42dishes were already legacy in 2004.
44 43
45
46Return Value44Return Value
47============45============
48 46
Documentation/userspace-api/media/dvb/fe-enable-high-lnb-voltage.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_ENABLE_HIGH_LNB_VOLTAGE:4.. _FE_ENABLE_HIGH_LNB_VOLTAGE:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12FE_ENABLE_HIGH_LNB_VOLTAGE - Select output DC level between normal LNBf voltages or higher LNBf - voltages.13FE_ENABLE_HIGH_LNB_VOLTAGE - Select output DC level between normal LNBf voltages or higher LNBf - voltages.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_ENABLE_HIGH_LNB_VOLTAGE, unsigned int high )18.. c:macro:: FE_ENABLE_HIGH_LNB_VOLTAGE
19 :name: FE_ENABLE_HIGH_LNB_VOLTAGE
20 19
20``int ioctl(int fd, FE_ENABLE_HIGH_LNB_VOLTAGE, unsigned int high)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``high``28``high``
29 Valid flags:29 Valid flags:
@@ -33,7 +33,6 @@ Arguments · 3 unmodified lines
33 - >0 - enables slightly higher voltages instead of 13/18V, in order33 - >0 - enables slightly higher voltages instead of 13/18V, in order
34 to compensate for long antenna cables.34 to compensate for long antenna cables.
35 35
36
37Description36Description
38===========37===========
39 38
@@ -41,7 +40,6 @@ Select output DC level between normal LNBf voltages or higher LNBf · 1 unmodified line
41voltages between 0 (normal) or a value grater than 0 for higher40voltages between 0 (normal) or a value grater than 0 for higher
42voltages.41voltages.
43 42
44
45Return Value43Return Value
46============44============
47 45
Documentation/userspace-api/media/dvb/fe-get-event.rst+4−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_GET_EVENT:4.. _FE_GET_EVENT:
4 5
@@ -13,24 +14,22 @@ FE_GET_EVENT · 8 unmodified lines
13 14
14.. attention:: This ioctl is deprecated.15.. attention:: This ioctl is deprecated.
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl(int fd, FE_GET_EVENT, struct dvb_frontend_event *ev)20.. c:macro:: FE_GET_EVENT
21 :name: FE_GET_EVENT
22 21
22``int ioctl(int fd, FE_GET_EVENT, struct dvb_frontend_event *ev)``
23 23
24Arguments24Arguments
25=========25=========
26 26
27``fd``27``fd``
28 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
29 29
30``ev``30``ev``
31 Points to the location where the event, if any, is to be stored.31 Points to the location where the event, if any, is to be stored.
32 32
33
34Description33Description
35===========34===========
36 35
@@ -40,7 +39,6 @@ or non-blocking mode. In the latter case, the call fails immediately · 3 unmodified lines
40with errno set to ``EWOULDBLOCK``. In the former case, the call blocks until39with errno set to ``EWOULDBLOCK``. In the former case, the call blocks until
41an event becomes available.40an event becomes available.
42 41
43
44Return Value42Return Value
45============43============
46 44
@@ -49,12 +47,10 @@ On success 0 is returned. · 2 unmodified lines
49On error -1 is returned, and the ``errno`` variable is set47On error -1 is returned, and the ``errno`` variable is set
50appropriately.48appropriately.
51 49
52
53.. flat-table::50.. flat-table::
54 :header-rows: 051 :header-rows: 0
55 :stub-columns: 052 :stub-columns: 0
56 53
57
58 - .. row 154 - .. row 1
59 55
60 - ``EWOULDBLOCK``56 - ``EWOULDBLOCK``
Documentation/userspace-api/media/dvb/fe-get-frontend.rst+4−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_GET_FRONTEND:4.. _FE_GET_FRONTEND:
4 5
@@ -13,32 +14,28 @@ FE_GET_FRONTEND · 8 unmodified lines
13 14
14.. attention:: This ioctl is deprecated.15.. attention:: This ioctl is deprecated.
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl(int fd, FE_GET_FRONTEND, struct dvb_frontend_parameters *p)20.. c:macro:: FE_GET_FRONTEND
21 :name: FE_GET_FRONTEND
22 21
22``int ioctl(int fd, FE_GET_FRONTEND, struct dvb_frontend_parameters *p)``
23 23
24Arguments24Arguments
25=========25=========
26 26
27``fd``27``fd``
28 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
29
30 29
31``p``30``p``
32 Points to parameters for tuning operation.31 Points to parameters for tuning operation.
33 32
34
35Description33Description
36===========34===========
37 35
38This ioctl call queries the currently effective frontend parameters. For36This ioctl call queries the currently effective frontend parameters. For
39this command, read-only access to the device is sufficient.37this command, read-only access to the device is sufficient.
40 38
41
42Return Value39Return Value
43============40============
44 41
@@ -51,7 +48,6 @@ appropriately. · 6 unmodified lines
51 :header-rows: 048 :header-rows: 0
52 :stub-columns: 049 :stub-columns: 0
53 50
54
55 - .. row 151 - .. row 1
56 52
57 - ``EINVAL``53 - ``EINVAL``
Documentation/userspace-api/media/dvb/fe-get-info.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_GET_INFO:4.. _FE_GET_INFO:
4 5
@@ -12,24 +13,22 @@ Name · 7 unmodified lines
12FE_GET_INFO - Query Digital TV frontend capabilities and returns information13FE_GET_INFO - Query Digital TV frontend capabilities and returns information
13about the - front-end. This call only requires read-only access to the device.14about the - front-end. This call only requires read-only access to the device.
14 15
15
16Synopsis16Synopsis
17========17========
18 18
19.. c:function:: int ioctl( int fd, FE_GET_INFO, struct dvb_frontend_info *argp )19.. c:macro:: FE_GET_INFO
20 :name: FE_GET_INFO
21 20
21``int ioctl(int fd, FE_GET_INFO, struct dvb_frontend_info *argp)``
22 22
23Arguments23Arguments
24=========24=========
25 25
26``fd``26``fd``
27 File descriptor returned by :ref:`open() <frontend_f_open>`.27 File descriptor returned by :c:func:`open()`.
28 28
29``argp``29``argp``
30 pointer to struct :c:type:`dvb_frontend_info`30 pointer to struct :c:type:`dvb_frontend_info`
31 31
32
33Description32Description
34===========33===========
35 34
@@ -40,7 +39,6 @@ takes a pointer to dvb_frontend_info which is filled by the driver. · 4 unmodified lines
40When the driver is not compatible with this specification the ioctl39When the driver is not compatible with this specification the ioctl
41returns an error.40returns an error.
42 41
43
44frontend capabilities42frontend capabilities
45=====================43=====================
46 44
@@ -49,7 +47,6 @@ supported only on some specific frontend types. · 2 unmodified lines
49 47
50The frontend capabilities are described at :c:type:`fe_caps`.48The frontend capabilities are described at :c:type:`fe_caps`.
51 49
52
53Return Value50Return Value
54============51============
55 52
Documentation/userspace-api/media/dvb/fe-get-property.rst+7−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_GET_PROPERTY:4.. _FE_GET_PROPERTY:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12FE_SET_PROPERTY - FE_GET_PROPERTY - FE_SET_PROPERTY sets one or more frontend properties. - FE_GET_PROPERTY returns one or more frontend properties.13FE_SET_PROPERTY - FE_GET_PROPERTY - FE_SET_PROPERTY sets one or more frontend properties. - FE_GET_PROPERTY returns one or more frontend properties.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_GET_PROPERTY, struct dtv_properties *argp )18.. c:macro:: FE_GET_PROPERTY
19 :name: FE_GET_PROPERTY19
20``int ioctl(int fd, FE_GET_PROPERTY, struct dtv_properties *argp)``
20 21
21.. c:function:: int ioctl( int fd, FE_SET_PROPERTY, struct dtv_properties *argp )22.. c:macro:: FE_SET_PROPERTY
22 :name: FE_SET_PROPERTY
23 23
24``int ioctl(int fd, FE_SET_PROPERTY, struct dtv_properties *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <frontend_f_open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`dtv_properties`.33 Pointer to struct :c:type:`dtv_properties`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -63,7 +63,6 @@ depends on the delivery system and on the device: · 25 unmodified lines
63 63
64 - This call only requires read-only access to the device.64 - This call only requires read-only access to the device.
65 65
66
67Return Value66Return Value
68============67============
69 68
Documentation/userspace-api/media/dvb/fe-read-ber.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_READ_BER:4.. _FE_READ_BER:
4 5
@@ -16,20 +17,19 @@ FE_READ_BER · 11 unmodified lines
16Synopsis17Synopsis
17========18========
18 19
19.. c:function:: int ioctl(int fd, FE_READ_BER, uint32_t *ber)20.. c:macro:: FE_READ_BER
20 :name: FE_READ_BER
21 21
22``int ioctl(int fd, FE_READ_BER, uint32_t *ber)``
22 23
23Arguments24Arguments
24=========25=========
25 26
26``fd``27``fd``
27 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
28 29
29``ber``30``ber``
30 The bit error rate is stored into \*ber.31 The bit error rate is stored into \*ber.
31 32
32
33Description33Description
34===========34===========
35 35
@@ -37,7 +37,6 @@ This ioctl call returns the bit error rate for the signal currently · 1 unmodified line
37received/demodulated by the front-end. For this command, read-only37received/demodulated by the front-end. For this command, read-only
38access to the device is sufficient.38access to the device is sufficient.
39 39
40
41Return Value40Return Value
42============41============
43 42
Documentation/userspace-api/media/dvb/fe-read-signal-strength.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_READ_SIGNAL_STRENGTH:4.. _FE_READ_SIGNAL_STRENGTH:
4 5
@@ -16,20 +17,19 @@ FE_READ_SIGNAL_STRENGTH · 11 unmodified lines
16Synopsis17Synopsis
17========18========
18 19
19.. c:function:: int ioctl( int fd, FE_READ_SIGNAL_STRENGTH, uint16_t *strength)20.. c:macro:: FE_READ_SIGNAL_STRENGTH
20 :name: FE_READ_SIGNAL_STRENGTH
21 21
22``int ioctl(int fd, FE_READ_SIGNAL_STRENGTH, uint16_t *strength)``
22 23
23Arguments24Arguments
24=========25=========
25 26
26``fd``27``fd``
27 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
28 29
29``strength``30``strength``
30 The signal strength value is stored into \*strength.31 The signal strength value is stored into \*strength.
31 32
32
33Description33Description
34===========34===========
35 35
@@ -37,7 +37,6 @@ This ioctl call returns the signal strength value for the signal · 1 unmodified line
37currently received by the front-end. For this command, read-only access37currently received by the front-end. For this command, read-only access
38to the device is sufficient.38to the device is sufficient.
39 39
40
41Return Value40Return Value
42============41============
43 42
Documentation/userspace-api/media/dvb/fe-read-snr.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_READ_SNR:4.. _FE_READ_SNR:
4 5
@@ -16,20 +17,19 @@ FE_READ_SNR · 11 unmodified lines
16Synopsis17Synopsis
17========18========
18 19
19.. c:function:: int ioctl(int fd, FE_READ_SNR, int16_t *snr)20.. c:macro:: FE_READ_SNR
20 :name: FE_READ_SNR
21 21
22``int ioctl(int fd, FE_READ_SNR, int16_t *snr)``
22 23
23Arguments24Arguments
24=========25=========
25 26
26``fd``27``fd``
27 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
28 29
29``snr``30``snr``
30 The signal-to-noise ratio is stored into \*snr.31 The signal-to-noise ratio is stored into \*snr.
31 32
32
33Description33Description
34===========34===========
35 35
@@ -37,7 +37,6 @@ This ioctl call returns the signal-to-noise ratio for the signal · 1 unmodified line
37currently received by the front-end. For this command, read-only access37currently received by the front-end. For this command, read-only access
38to the device is sufficient.38to the device is sufficient.
39 39
40
41Return Value40Return Value
42============41============
43 42
Documentation/userspace-api/media/dvb/fe-read-status.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_READ_STATUS:4.. _FE_READ_STATUS:
4 5
@@ -11,25 +12,23 @@ Name · 6 unmodified lines
11 12
12FE_READ_STATUS - Returns status information about the front-end. This call only requires - read-only access to the device13FE_READ_STATUS - Returns status information about the front-end. This call only requires - read-only access to the device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_READ_STATUS, unsigned int *status )18.. c:macro:: FE_READ_STATUS
19 :name: FE_READ_STATUS
20 19
20``int ioctl(int fd, FE_READ_STATUS, unsigned int *status)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``status``28``status``
29 pointer to a bitmask integer filled with the values defined by enum29 pointer to a bitmask integer filled with the values defined by enum
30 :c:type:`fe_status`.30 :c:type:`fe_status`.
31 31
32
33Description32Description
34===========33===========
35 34
@@ -44,7 +43,6 @@ written. · 8 unmodified lines
44 varies according with the architecture. This needs to be fixed in the43 varies according with the architecture. This needs to be fixed in the
45 future.44 future.
46 45
47
48int fe_status46int fe_status
49=============47=============
50 48
@@ -52,7 +50,6 @@ The fe_status parameter is used to indicate the current state and/or · 1 unmodified line
52state changes of the frontend hardware. It is produced using the enum50state changes of the frontend hardware. It is produced using the enum
53:c:type:`fe_status` values on a bitmask51:c:type:`fe_status` values on a bitmask
54 52
55
56Return Value53Return Value
57============54============
58 55
Documentation/userspace-api/media/dvb/fe-read-uncorrected-blocks.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_READ_UNCORRECTED_BLOCKS:4.. _FE_READ_UNCORRECTED_BLOCKS:
4 5
@@ -16,20 +17,19 @@ FE_READ_UNCORRECTED_BLOCKS · 11 unmodified lines
16Synopsis17Synopsis
17========18========
18 19
19.. c:function:: int ioctl( int fd, FE_READ_UNCORRECTED_BLOCKS, uint32_t *ublocks)20.. c:macro:: FE_READ_UNCORRECTED_BLOCKS
20 :name: FE_READ_UNCORRECTED_BLOCKS
21 21
22``int ioctl(int fd, FE_READ_UNCORRECTED_BLOCKS, uint32_t *ublocks)``
22 23
23Arguments24Arguments
24=========25=========
25 26
26``fd``27``fd``
27 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
28 29
29``ublocks``30``ublocks``
30 The total number of uncorrected blocks seen by the driver so far.31 The total number of uncorrected blocks seen by the driver so far.
31 32
32
33Description33Description
34===========34===========
35 35
@@ -39,7 +39,6 @@ increment in block count during a specific time interval should be · 3 unmodified lines
39calculated. For this command, read-only access to the device is39calculated. For this command, read-only access to the device is
40sufficient.40sufficient.
41 41
42
43Return Value42Return Value
44============43============
45 44
Documentation/userspace-api/media/dvb/fe-set-frontend-tune-mode.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_SET_FRONTEND_TUNE_MODE:4.. _FE_SET_FRONTEND_TUNE_MODE:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12FE_SET_FRONTEND_TUNE_MODE - Allow setting tuner mode flags to the frontend.13FE_SET_FRONTEND_TUNE_MODE - Allow setting tuner mode flags to the frontend.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_SET_FRONTEND_TUNE_MODE, unsigned int flags )18.. c:macro:: FE_SET_FRONTEND_TUNE_MODE
19 :name: FE_SET_FRONTEND_TUNE_MODE
20 19
20``int ioctl(int fd, FE_SET_FRONTEND_TUNE_MODE, unsigned int flags)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``flags``28``flags``
29 Valid flags:29 Valid flags:
@@ -37,14 +37,12 @@ Arguments · 7 unmodified lines
37 is closed, this flag will be automatically turned off when the37 is closed, this flag will be automatically turned off when the
38 device is reopened read-write.38 device is reopened read-write.
39 39
40
41Description40Description
42===========41===========
43 42
44Allow setting tuner mode flags to the frontend, between 0 (normal) or43Allow setting tuner mode flags to the frontend, between 0 (normal) or
45``FE_TUNE_MODE_ONESHOT`` mode44``FE_TUNE_MODE_ONESHOT`` mode
46 45
47
48Return Value46Return Value
49============47============
50 48
Documentation/userspace-api/media/dvb/fe-set-frontend.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_SET_FRONTEND:4.. _FE_SET_FRONTEND:
4 5
@@ -13,24 +14,22 @@ Name · 8 unmodified lines
13 14
14FE_SET_FRONTEND15FE_SET_FRONTEND
15 16
16
17Synopsis17Synopsis
18========18========
19 19
20.. c:function:: int ioctl(int fd, FE_SET_FRONTEND, struct dvb_frontend_parameters *p)20.. c:macro:: FE_SET_FRONTEND
21 :name: FE_SET_FRONTEND
22 21
22``int ioctl(int fd, FE_SET_FRONTEND, struct dvb_frontend_parameters *p)``
23 23
24Arguments24Arguments
25=========25=========
26 26
27``fd``27``fd``
28 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
29 29
30``p``30``p``
31 Points to parameters for tuning operation.31 Points to parameters for tuning operation.
32 32
33
34Description33Description
35===========34===========
36 35
@@ -44,7 +43,6 @@ operation is initiated before the previous one was completed, the · 7 unmodified lines
44previous operation will be aborted in favor of the new one. This command43previous operation will be aborted in favor of the new one. This command
45requires read/write access to the device.44requires read/write access to the device.
46 45
47
48Return Value46Return Value
49============47============
50 48
@@ -66,6 +64,5 @@ appropriately. · 15 unmodified lines
66 64
67 - Maximum supported symbol rate reached.65 - Maximum supported symbol rate reached.
68 66
69
70Generic error codes are described at the67Generic error codes are described at the
71:ref:`Generic Error Codes <gen-errors>` chapter.68:ref:`Generic Error Codes <gen-errors>` chapter.
Documentation/userspace-api/media/dvb/fe-set-tone.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_SET_TONE:4.. _FE_SET_TONE:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12FE_SET_TONE - Sets/resets the generation of the continuous 22kHz tone.13FE_SET_TONE - Sets/resets the generation of the continuous 22kHz tone.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_SET_TONE, enum fe_sec_tone_mode tone )18.. c:macro:: FE_SET_TONE
19 :name: FE_SET_TONE
20 19
20``int ioctl(int fd, FE_SET_TONE, enum fe_sec_tone_mode tone)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``tone``28``tone``
29 an integer enumered value described at :c:type:`fe_sec_tone_mode`29 an integer enumered value described at :c:type:`fe_sec_tone_mode`
30 30
31
32Description31Description
33===========32===========
34 33
@@ -45,7 +44,6 @@ this is done using the DiSEqC ioctls. · 10 unmodified lines
45 capability of selecting the band. So, it is recommended that applications44 capability of selecting the band. So, it is recommended that applications
46 would change to SEC_TONE_OFF when the device is not used.45 would change to SEC_TONE_OFF when the device is not used.
47 46
48
49Return Value47Return Value
50============48============
51 49
Documentation/userspace-api/media/dvb/fe-set-voltage.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _FE_SET_VOLTAGE:4.. _FE_SET_VOLTAGE:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12FE_SET_VOLTAGE - Allow setting the DC level sent to the antenna subsystem.13FE_SET_VOLTAGE - Allow setting the DC level sent to the antenna subsystem.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, FE_SET_VOLTAGE, enum fe_sec_voltage voltage )18.. c:macro:: FE_SET_VOLTAGE
19 :name: FE_SET_VOLTAGE
20 19
20``int ioctl(int fd, FE_SET_VOLTAGE, enum fe_sec_voltage voltage)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``voltage``28``voltage``
29 an integer enumered value described at :c:type:`fe_sec_voltage`29 an integer enumered value described at :c:type:`fe_sec_voltage`
30 30
31
32Description31Description
33===========32===========
34 33
@@ -49,7 +48,6 @@ power up the LNBf. · 14 unmodified lines
49 the voltage to SEC_VOLTAGE_OFF while the device is not is used is48 the voltage to SEC_VOLTAGE_OFF while the device is not is used is
50 recommended.49 recommended.
51 50
52
53Return Value51Return Value
54============52============
55 53
Documentation/userspace-api/media/dvb/frontend_f_close.rst+2−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _frontend_f_close:4.. _frontend_f_close:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12fe-close - Close a frontend device13fe-close - Close a frontend device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,16 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: int close( int fd )22.. c:function:: int close( int fd )
24 :name: dvb-fe-close
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :c:func:`open() <dvb-fe-open>`.28 File descriptor returned by :c:func:`open()`.
31
32 29
33Description30Description
34===========31===========
@@ -37,7 +34,6 @@ This system call closes a previously opened front-end device. After · 2 unmodified lines
37closing a front-end device, its corresponding hardware might be powered34closing a front-end device, its corresponding hardware might be powered
38down automatically.35down automatically.
39 36
40
41Return Value37Return Value
42============38============
43 39
Documentation/userspace-api/media/dvb/frontend_f_open.rst+2−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.fe
2 3
3.. _frontend_f_open:4.. _frontend_f_open:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12fe-open - Open a frontend device13fe-open - Open a frontend device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <fcntl.h>20 #include <fcntl.h>
21 21
22
23.. c:function:: int open( const char *device_name, int flags )22.. c:function:: int open( const char *device_name, int flags )
24 :name: dvb-fe-open
25 23
26Arguments24Arguments
27=========25=========
@@ -44,7 +42,6 @@ Arguments · 16 unmodified lines
44 42
45 Other flags have no effect.43 Other flags have no effect.
46 44
47
48Description45Description
49===========46===========
50 47
@@ -70,16 +67,14 @@ the specified mode. This implies that the corresponding hardware is · 19 unmodified lines
70powered up, and that other front-ends may have been powered down to make67powered up, and that other front-ends may have been powered down to make
71that possible.68that possible.
72 69
73
74Return Value70Return Value
75============71============
76 72
77On success :ref:`open() <frontend_f_open>` returns the new file descriptor.73On success :c:func:`open()` returns the new file descriptor.
78On error, -1 is returned, and the ``errno`` variable is set appropriately.74On error, -1 is returned, and the ``errno`` variable is set appropriately.
79 75
80Possible error codes are:76Possible error codes are:
81 77
82
83On success 0 is returned, and :c:type:`ca_slot_info` is filled.78On success 0 is returned, and :c:type:`ca_slot_info` is filled.
84 79
85On error -1 is returned, and the ``errno`` variable is set80On error -1 is returned, and the ``errno`` variable is set
@@ -105,6 +100,5 @@ appropriately. · 19 unmodified lines
105 - The limit on the total number of files open on the system has been100 - The limit on the total number of files open on the system has been
106 reached.101 reached.
107 102
108
109The generic error codes are described at the103The generic error codes are described at the
110:ref:`Generic Error Codes <gen-errors>` chapter.104:ref:`Generic Error Codes <gen-errors>` chapter.
Documentation/userspace-api/media/dvb/net-add-if.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.net
2 3
3.. _NET_ADD_IF:4.. _NET_ADD_IF:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12NET_ADD_IF - Creates a new network interface for a given Packet ID.13NET_ADD_IF - Creates a new network interface for a given Packet ID.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, NET_ADD_IF, struct dvb_net_if *net_if )18.. c:macro:: NET_ADD_IF
19 :name: NET_ADD_IF
20 19
20``int ioctl(int fd, NET_ADD_IF, struct dvb_net_if *net_if)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``net_if``28``net_if``
29 pointer to struct :c:type:`dvb_net_if`29 pointer to struct :c:type:`dvb_net_if`
30 30
31
32Description31Description
33===========32===========
34 33
Documentation/userspace-api/media/dvb/net-get-if.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.net
2 3
3.. _NET_GET_IF:4.. _NET_GET_IF:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12NET_GET_IF - Read the configuration data of an interface created via - :ref:`NET_ADD_IF <net>`.13NET_GET_IF - Read the configuration data of an interface created via - :ref:`NET_ADD_IF <net>`.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, NET_GET_IF, struct dvb_net_if *net_if )18.. c:macro:: NET_GET_IF
19 :name: NET_GET_IF
20 19
20``int ioctl(int fd, NET_GET_IF, struct dvb_net_if *net_if)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``net_if``28``net_if``
29 pointer to struct :c:type:`dvb_net_if`29 pointer to struct :c:type:`dvb_net_if`
30 30
31
32Description31Description
33===========32===========
34 33
@@ -39,7 +38,6 @@ encapsulation type used on such interface. If the interface was not · 4 unmodified lines
39created yet with :ref:`NET_ADD_IF <net>`, it will return -1 and fill38created yet with :ref:`NET_ADD_IF <net>`, it will return -1 and fill
40the ``errno`` with ``EINVAL`` error code.39the ``errno`` with ``EINVAL`` error code.
41 40
42
43Return Value41Return Value
44============42============
45 43
Documentation/userspace-api/media/dvb/net-remove-if.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.net
2 3
3.. _NET_REMOVE_IF:4.. _NET_REMOVE_IF:
4 5
@@ -11,31 +12,28 @@ Name · 6 unmodified lines
11 12
12NET_REMOVE_IF - Removes a network interface.13NET_REMOVE_IF - Removes a network interface.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, NET_REMOVE_IF, int ifnum )18.. c:macro:: NET_REMOVE_IF
19 :name: NET_REMOVE_IF
20 19
20``int ioctl(int fd, NET_REMOVE_IF, int ifnum)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``net_if``28``net_if``
29 number of the interface to be removed29 number of the interface to be removed
30 30
31
32Description31Description
33===========32===========
34 33
35The NET_REMOVE_IF ioctl deletes an interface previously created via34The NET_REMOVE_IF ioctl deletes an interface previously created via
36:ref:`NET_ADD_IF <net>`.35:ref:`NET_ADD_IF <net>`.
37 36
38
39Return Value37Return Value
40============38============
41 39
Documentation/userspace-api/media/dvb/video-clear-buffer.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_CLEAR_BUFFER:4.. _VIDEO_CLEAR_BUFFER:
4 5
@@ -16,9 +17,9 @@ VIDEO_CLEAR_BUFFER · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_CLEAR_BUFFER)20.. c:macro:: VIDEO_CLEAR_BUFFER
20 :name: VIDEO_CLEAR_BUFFER
21 21
22``int ioctl(fd, VIDEO_CLEAR_BUFFER)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -40,14 +40,12 @@ Arguments · 6 unmodified lines
40 40
41 - Equals VIDEO_CLEAR_BUFFER for this command.41 - Equals VIDEO_CLEAR_BUFFER for this command.
42 42
43
44Description43Description
45-----------44-----------
46 45
47This ioctl call clears all video buffers in the driver and in the46This ioctl call clears all video buffers in the driver and in the
48decoder hardware.47decoder hardware.
49 48
50
51Return Value49Return Value
52------------50------------
53 51
Documentation/userspace-api/media/dvb/video-command.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_COMMAND:4.. _VIDEO_COMMAND:
4 5
@@ -16,9 +17,9 @@ VIDEO_COMMAND · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, VIDEO_COMMAND, struct video_command *cmd)20.. c:macro:: VIDEO_COMMAND
20 :name: VIDEO_COMMAND
21 21
22``int ioctl(int fd, VIDEO_COMMAND, struct video_command *cmd)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Commands the decoder.47 - Commands the decoder.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -59,7 +58,7 @@ subset of the ``v4l2_decoder_cmd`` struct, so refer to the · 6 unmodified lines
59:ref:`VIDIOC_DECODER_CMD` documentation for58:ref:`VIDIOC_DECODER_CMD` documentation for
60more information.59more information.
61 60
62.. c:type:: struct video_command61.. c:type:: video_command
63 62
64.. code-block:: c63.. code-block:: c
65 64
@@ -89,7 +88,6 @@ more information. · 23 unmodified lines
89 };88 };
90 };89 };
91 90
92
93Return Value91Return Value
94------------92------------
95 93
Documentation/userspace-api/media/dvb/video-continue.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_CONTINUE:4.. _VIDEO_CONTINUE:
4 5
@@ -16,9 +17,9 @@ VIDEO_CONTINUE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_CONTINUE)20.. c:macro:: VIDEO_CONTINUE
20 :name: VIDEO_CONTINUE
21 21
22``int ioctl(fd, VIDEO_CONTINUE)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Arguments · 6 unmodified lines
40 40
41 - Equals VIDEO_CONTINUE for this command.41 - Equals VIDEO_CONTINUE for this command.
42 42
43
44Description43Description
45-----------44-----------
46 45
@@ -50,7 +49,6 @@ V4L2 :ref:`VIDIOC_DECODER_CMD` instead. · 3 unmodified lines
50This ioctl call restarts decoding and playing processes of the video49This ioctl call restarts decoding and playing processes of the video
51stream which was played before a call to VIDEO_FREEZE was made.50stream which was played before a call to VIDEO_FREEZE was made.
52 51
53
54Return Value52Return Value
55------------53------------
56 54
Documentation/userspace-api/media/dvb/video-fast-forward.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_FAST_FORWARD:4.. _VIDEO_FAST_FORWARD:
4 5
@@ -16,9 +17,9 @@ VIDEO_FAST_FORWARD · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_FAST_FORWARD, int nFrames)20.. c:macro:: VIDEO_FAST_FORWARD
20 :name: VIDEO_FAST_FORWARD
21 21
22``int ioctl(fd, VIDEO_FAST_FORWARD, int nFrames)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - The number of frames to skip.47 - The number of frames to skip.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -54,7 +53,6 @@ This ioctl call asks the Video Device to skip decoding of N number of · 1 unmodified line
54I-frames. This call can only be used if VIDEO_SOURCE_MEMORY is53I-frames. This call can only be used if VIDEO_SOURCE_MEMORY is
55selected.54selected.
56 55
57
58Return Value56Return Value
59------------57------------
60 58
@@ -63,12 +61,10 @@ appropriately. The generic error codes are described at the · 2 unmodified lines
63:ref:`Generic Error Codes <gen-errors>` chapter.61:ref:`Generic Error Codes <gen-errors>` chapter.
64 62
65 63
66
67.. flat-table::64.. flat-table::
68 :header-rows: 065 :header-rows: 0
69 :stub-columns: 066 :stub-columns: 0
70 67
71
72 - .. row 168 - .. row 1
73 69
74 - ``EPERM``70 - ``EPERM``
Documentation/userspace-api/media/dvb/video-fclose.rst+1−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _video_fclose:4.. _video_fclose:
4 5
@@ -18,7 +19,6 @@ Synopsis · 13 unmodified lines
18 19
19.. c:function:: int close(int fd)20.. c:function:: int close(int fd)
20 21
21
22Arguments22Arguments
23---------23---------
24 24
@@ -26,20 +26,17 @@ Arguments · 1 unmodified line
26 :header-rows: 026 :header-rows: 0
27 :stub-columns: 027 :stub-columns: 0
28 28
29
30 - .. row 129 - .. row 1
31 30
32 - int fd31 - int fd
33 32
34 - File descriptor returned by a previous call to open().33 - File descriptor returned by a previous call to open().
35 34
36
37Description35Description
38-----------36-----------
39 37
40This system call closes a previously opened video device.38This system call closes a previously opened video device.
41 39
42
43Return Value40Return Value
44------------41------------
45 42
@@ -47,7 +44,6 @@ Return Value · 1 unmodified line
47 :header-rows: 044 :header-rows: 0
48 :stub-columns: 045 :stub-columns: 0
49 46
50
51 - .. row 147 - .. row 1
52 48
53 - ``EBADF``49 - ``EBADF``
Documentation/userspace-api/media/dvb/video-fopen.rst+1−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _video_fopen:4.. _video_fopen:
4 5
@@ -18,7 +19,6 @@ Synopsis · 13 unmodified lines
18 19
19.. c:function:: int open(const char *deviceName, int flags)20.. c:function:: int open(const char *deviceName, int flags)
20 21
21
22Arguments22Arguments
23---------23---------
24 24
@@ -26,7 +26,6 @@ Arguments · 1 unmodified line
26 :header-rows: 026 :header-rows: 0
27 :stub-columns: 027 :stub-columns: 0
28 28
29
30 - .. row 129 - .. row 1
31 30
32 - const char \*deviceName31 - const char \*deviceName
@@ -59,7 +58,6 @@ Arguments · 26 unmodified lines
59 -58 -
60 - (blocking mode is the default)59 - (blocking mode is the default)
61 60
62
63Description61Description
64-----------62-----------
65 63
@@ -79,7 +77,6 @@ returned. If the Video Device is opened in O_RDONLY mode, the only · 13 unmodified lines
79ioctl call that can be used is VIDEO_GET_STATUS. All other call will77ioctl call that can be used is VIDEO_GET_STATUS. All other call will
80return an error code.78return an error code.
81 79
82
83Return Value80Return Value
84------------81------------
85 82
@@ -89,7 +86,6 @@ Return Value · 3 unmodified lines
89 :header-rows: 086 :header-rows: 0
90 :stub-columns: 087 :stub-columns: 0
91 88
92
93 - .. row 189 - .. row 1
94 90
95 - ``ENODEV``91 - ``ENODEV``
Documentation/userspace-api/media/dvb/video-freeze.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_FREEZE:4.. _VIDEO_FREEZE:
4 5
@@ -16,9 +17,9 @@ VIDEO_FREEZE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_FREEZE)20.. c:macro:: VIDEO_FREEZE
20 :name: VIDEO_FREEZE
21 21
22``int ioctl(fd, VIDEO_FREEZE)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Arguments · 6 unmodified lines
40 40
41 - Equals VIDEO_FREEZE for this command.41 - Equals VIDEO_FREEZE for this command.
42 42
43
44Description43Description
45-----------44-----------
46 45
@@ -54,7 +53,6 @@ If VIDEO_SOURCE_MEMORY is selected in the ioctl call · 7 unmodified lines
54VIDEO_SELECT_SOURCE, the Digital TV subsystem will not decode any more data53VIDEO_SELECT_SOURCE, the Digital TV subsystem will not decode any more data
55until the ioctl call VIDEO_CONTINUE or VIDEO_PLAY is performed.54until the ioctl call VIDEO_CONTINUE or VIDEO_PLAY is performed.
56 55
57
58Return Value56Return Value
59------------57------------
60 58
Documentation/userspace-api/media/dvb/video-fwrite.rst+1−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _video_fwrite:4.. _video_fwrite:
4 5
@@ -18,7 +19,6 @@ Synopsis · 13 unmodified lines
18 19
19.. c:function:: size_t write(int fd, const void *buf, size_t count)20.. c:function:: size_t write(int fd, const void *buf, size_t count)
20 21
21
22Arguments22Arguments
23---------23---------
24 24
@@ -26,7 +26,6 @@ Arguments · 1 unmodified line
26 :header-rows: 026 :header-rows: 0
27 :stub-columns: 027 :stub-columns: 0
28 28
29
30 - .. row 129 - .. row 1
31 30
32 - int fd31 - int fd
@@ -45,7 +44,6 @@ Arguments · 12 unmodified lines
45 44
46 - Size of buf.45 - Size of buf.
47 46
48
49Description47Description
50-----------48-----------
51 49
@@ -55,7 +53,6 @@ PES format, unless the capability allows other formats. If O_NONBLOCK · 3 unmodified lines
55is not specified the function will block until buffer space is53is not specified the function will block until buffer space is
56available. The amount of data to be transferred is implied by count.54available. The amount of data to be transferred is implied by count.
57 55
58
59Return Value56Return Value
60------------57------------
61 58
@@ -63,7 +60,6 @@ Return Value · 1 unmodified line
63 :header-rows: 060 :header-rows: 0
64 :stub-columns: 061 :stub-columns: 0
65 62
66
67 - .. row 163 - .. row 1
68 64
69 - ``EPERM``65 - ``EPERM``
Documentation/userspace-api/media/dvb/video-get-capabilities.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_GET_CAPABILITIES:4.. _VIDEO_GET_CAPABILITIES:
4 5
@@ -16,9 +17,9 @@ VIDEO_GET_CAPABILITIES · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_GET_CAPABILITIES, unsigned int *cap)20.. c:macro:: VIDEO_GET_CAPABILITIES
20 :name: VIDEO_GET_CAPABILITIES
21 21
22``int ioctl(fd, VIDEO_GET_CAPABILITIES, unsigned int *cap)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Pointer to a location where to store the capability information.47 - Pointer to a location where to store the capability information.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -54,7 +53,6 @@ This ioctl call asks the video device about its decoding capabilities. · 1 unmodified line
54On success it returns and integer which has bits set according to the53On success it returns and integer which has bits set according to the
55defines in section ??.54defines in section ??.
56 55
57
58Return Value56Return Value
59------------57------------
60 58
Documentation/userspace-api/media/dvb/video-get-event.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_GET_EVENT:4.. _VIDEO_GET_EVENT:
4 5
@@ -16,9 +17,9 @@ VIDEO_GET_EVENT · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_GET_EVENT, struct video_event *ev)20.. c:macro:: VIDEO_GET_EVENT
20 :name: VIDEO_GET_EVENT
21 21
22``int ioctl(fd, VIDEO_GET_EVENT, struct video_event *ev)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Points to the location where the event, if any, is to be stored.47 - Points to the location where the event, if any, is to be stored.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -93,7 +92,6 @@ appropriately. The generic error codes are described at the · 40 unmodified lines
93 :header-rows: 092 :header-rows: 0
94 :stub-columns: 093 :stub-columns: 0
95 94
96
97 - .. row 195 - .. row 1
98 96
99 - ``EWOULDBLOCK``97 - ``EWOULDBLOCK``
Documentation/userspace-api/media/dvb/video-get-frame-count.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_GET_FRAME_COUNT:4.. _VIDEO_GET_FRAME_COUNT:
4 5
@@ -16,9 +17,9 @@ VIDEO_GET_FRAME_COUNT · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, VIDEO_GET_FRAME_COUNT, __u64 *pts)20.. c:macro:: VIDEO_GET_FRAME_COUNT
20 :name: VIDEO_GET_FRAME_COUNT
21 21
22``int ioctl(int fd, VIDEO_GET_FRAME_COUNT, __u64 *pts)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -47,7 +47,6 @@ Arguments · 13 unmodified lines
47 - Returns the number of frames displayed since the decoder was47 - Returns the number of frames displayed since the decoder was
48 started.48 started.
49 49
50
51Description50Description
52-----------51-----------
53 52
@@ -58,7 +57,6 @@ control. · 4 unmodified lines
58This ioctl call asks the Video Device to return the number of displayed57This ioctl call asks the Video Device to return the number of displayed
59frames since the decoder was started.58frames since the decoder was started.
60 59
61
62Return Value60Return Value
63------------61------------
64 62
Documentation/userspace-api/media/dvb/video-get-pts.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_GET_PTS:4.. _VIDEO_GET_PTS:
4 5
@@ -16,9 +17,9 @@ VIDEO_GET_PTS · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, VIDEO_GET_PTS, __u64 *pts)20.. c:macro:: VIDEO_GET_PTS
20 :name: VIDEO_GET_PTS
21 21
22``int ioctl(int fd, VIDEO_GET_PTS, __u64 *pts)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -51,7 +51,6 @@ Arguments · 17 unmodified lines
51 but may also be a value close to it like the PTS of the last51 but may also be a value close to it like the PTS of the last
52 decoded frame or the last PTS extracted by the PES parser.52 decoded frame or the last PTS extracted by the PES parser.
53 53
54
55Description54Description
56-----------55-----------
57 56
@@ -62,7 +61,6 @@ control. · 4 unmodified lines
62This ioctl call asks the Video Device to return the current PTS61This ioctl call asks the Video Device to return the current PTS
63timestamp.62timestamp.
64 63
65
66Return Value64Return Value
67------------65------------
68 66
Documentation/userspace-api/media/dvb/video-get-size.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_GET_SIZE:4.. _VIDEO_GET_SIZE:
4 5
@@ -16,9 +17,9 @@ VIDEO_GET_SIZE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, VIDEO_GET_SIZE, video_size_t *size)20.. c:macro:: VIDEO_GET_SIZE
20 :name: VIDEO_GET_SIZE
21 21
22``int ioctl(int fd, VIDEO_GET_SIZE, video_size_t *size)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Returns the size and aspect ratio.47 - Returns the size and aspect ratio.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -62,7 +61,6 @@ This ioctl returns the size and aspect ratio. · 9 unmodified lines
62 video_format_t aspect_ratio;61 video_format_t aspect_ratio;
63 } video_size_t;62 } video_size_t;
64 63
65
66Return Value64Return Value
67------------65------------
68 66
Documentation/userspace-api/media/dvb/video-get-status.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_GET_STATUS:4.. _VIDEO_GET_STATUS:
4 5
@@ -16,9 +17,9 @@ VIDEO_GET_STATUS · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_GET_STATUS, struct video_status *status)20.. c:macro:: VIDEO_GET_STATUS
20 :name: VIDEO_GET_STATUS
21 21
22``int ioctl(fd, VIDEO_GET_STATUS, struct video_status *status)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Returns the current status of the Video Device.47 - Returns the current status of the Video Device.
48 48
49
50Description49Description
51-----------50-----------
52 51
Documentation/userspace-api/media/dvb/video-play.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_PLAY:4.. _VIDEO_PLAY:
4 5
@@ -16,9 +17,9 @@ VIDEO_PLAY · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_PLAY)20.. c:macro:: VIDEO_PLAY
20 :name: VIDEO_PLAY
21 21
22``int ioctl(fd, VIDEO_PLAY)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -40,7 +40,6 @@ Arguments · 6 unmodified lines
40 40
41 - Equals VIDEO_PLAY for this command.41 - Equals VIDEO_PLAY for this command.
42 42
43
44Description43Description
45-----------44-----------
46 45
@@ -50,7 +49,6 @@ V4L2 :ref:`VIDIOC_DECODER_CMD` instead. · 3 unmodified lines
50This ioctl call asks the Video Device to start playing a video stream49This ioctl call asks the Video Device to start playing a video stream
51from the selected source.50from the selected source.
52 51
53
54Return Value52Return Value
55------------53------------
56 54
Documentation/userspace-api/media/dvb/video-select-source.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_SELECT_SOURCE:4.. _VIDEO_SELECT_SOURCE:
4 5
@@ -16,9 +17,9 @@ VIDEO_SELECT_SOURCE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_SELECT_SOURCE, video_stream_source_t source)20.. c:macro:: VIDEO_SELECT_SOURCE
20 :name: VIDEO_SELECT_SOURCE
21 21
22``int ioctl(fd, VIDEO_SELECT_SOURCE, video_stream_source_t source)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Indicates which source shall be used for the Video stream.47 - Indicates which source shall be used for the Video stream.
48 48
49
50Description49Description
51-----------50-----------
52 51
Documentation/userspace-api/media/dvb/video-set-blank.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_SET_BLANK:4.. _VIDEO_SET_BLANK:
4 5
@@ -16,9 +17,9 @@ VIDEO_SET_BLANK · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_SET_BLANK, boolean mode)20.. c:macro:: VIDEO_SET_BLANK
20 :name: VIDEO_SET_BLANK
21 21
22``int ioctl(fd, VIDEO_SET_BLANK, boolean mode)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -51,13 +51,11 @@ Arguments · 17 unmodified lines
51 -51 -
52 - FALSE: Show last decoded frame.52 - FALSE: Show last decoded frame.
53 53
54
55Description54Description
56-----------55-----------
57 56
58This ioctl call asks the Video Device to blank out the picture.57This ioctl call asks the Video Device to blank out the picture.
59 58
60
61Return Value59Return Value
62------------60------------
63 61
Documentation/userspace-api/media/dvb/video-set-display-format.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_SET_DISPLAY_FORMAT:4.. _VIDEO_SET_DISPLAY_FORMAT:
4 5
@@ -16,9 +17,9 @@ VIDEO_SET_DISPLAY_FORMAT · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_SET_DISPLAY_FORMAT)20.. c:macro:: VIDEO_SET_DISPLAY_FORMAT
20 :name: VIDEO_SET_DISPLAY_FORMAT
21 21
22``int ioctl(fd, VIDEO_SET_DISPLAY_FORMAT)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,14 +46,12 @@ Arguments · 12 unmodified lines
46 46
47 - Selects the video format to be used.47 - Selects the video format to be used.
48 48
49
50Description49Description
51-----------50-----------
52 51
53This ioctl call asks the Video Device to select the video format to be52This ioctl call asks the Video Device to select the video format to be
54applied by the MPEG chip on the video.53applied by the MPEG chip on the video.
55 54
56
57Return Value55Return Value
58------------56------------
59 57
Documentation/userspace-api/media/dvb/video-set-format.rst+3−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_SET_FORMAT:4.. _VIDEO_SET_FORMAT:
4 5
@@ -16,9 +17,9 @@ VIDEO_SET_FORMAT · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_SET_FORMAT, video_format_t format)20.. c:macro:: VIDEO_SET_FORMAT
20 :name: VIDEO_SET_FORMAT
21 21
22``int ioctl(fd, VIDEO_SET_FORMAT, video_format_t format)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - video format of TV as defined in section ??.47 - video format of TV as defined in section ??.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -72,12 +71,10 @@ appropriately. The generic error codes are described at the · 19 unmodified lines
72:ref:`Generic Error Codes <gen-errors>` chapter.71:ref:`Generic Error Codes <gen-errors>` chapter.
73 72
74 73
75
76.. flat-table::74.. flat-table::
77 :header-rows: 075 :header-rows: 0
78 :stub-columns: 076 :stub-columns: 0
79 77
80
81 - .. row 178 - .. row 1
82 79
83 - ``EINVAL``80 - ``EINVAL``
Documentation/userspace-api/media/dvb/video-set-streamtype.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_SET_STREAMTYPE:4.. _VIDEO_SET_STREAMTYPE:
4 5
@@ -16,9 +17,9 @@ VIDEO_SET_STREAMTYPE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_SET_STREAMTYPE, int type)20.. c:macro:: VIDEO_SET_STREAMTYPE
20 :name: VIDEO_SET_STREAMTYPE
21 21
22``int ioctl(fd, VIDEO_SET_STREAMTYPE, int type)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - stream type47 - stream type
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -54,7 +53,6 @@ This ioctl tells the driver which kind of stream to expect being written · 1 unmodified line
54to it. If this call is not used the default of video PES is used. Some53to it. If this call is not used the default of video PES is used. Some
55drivers might not support this call and always expect PES.54drivers might not support this call and always expect PES.
56 55
57
58Return Value56Return Value
59------------57------------
60 58
Documentation/userspace-api/media/dvb/video-slowmotion.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_SLOWMOTION:4.. _VIDEO_SLOWMOTION:
4 5
@@ -16,9 +17,9 @@ VIDEO_SLOWMOTION · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_SLOWMOTION, int nFrames)20.. c:macro:: VIDEO_SLOWMOTION
20 :name: VIDEO_SLOWMOTION
21 21
22``int ioctl(fd, VIDEO_SLOWMOTION, int nFrames)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - The number of times to repeat each frame.47 - The number of times to repeat each frame.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -54,7 +53,6 @@ This ioctl call asks the video device to repeat decoding frames N number · 1 unmodified line
54of times. This call can only be used if VIDEO_SOURCE_MEMORY is53of times. This call can only be used if VIDEO_SOURCE_MEMORY is
55selected.54selected.
56 55
57
58Return Value56Return Value
59------------57------------
60 58
@@ -63,12 +61,10 @@ appropriately. The generic error codes are described at the · 2 unmodified lines
63:ref:`Generic Error Codes <gen-errors>` chapter.61:ref:`Generic Error Codes <gen-errors>` chapter.
64 62
65 63
66
67.. flat-table::64.. flat-table::
68 :header-rows: 065 :header-rows: 0
69 :stub-columns: 066 :stub-columns: 0
70 67
71
72 - .. row 168 - .. row 1
73 69
74 - ``EPERM``70 - ``EPERM``
Documentation/userspace-api/media/dvb/video-stillpicture.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_STILLPICTURE:4.. _VIDEO_STILLPICTURE:
4 5
@@ -16,9 +17,9 @@ VIDEO_STILLPICTURE · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_STILLPICTURE, struct video_still_picture *sp)20.. c:macro:: VIDEO_STILLPICTURE
20 :name: VIDEO_STILLPICTURE
21 21
22``int ioctl(fd, VIDEO_STILLPICTURE, struct video_still_picture *sp)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Pointer to a location where an I-frame and size is stored.47 - Pointer to a location where an I-frame and size is stored.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -54,7 +53,6 @@ This ioctl call asks the Video Device to display a still picture · 1 unmodified line
54(I-frame). The input data shall contain an I-frame. If the pointer is53(I-frame). The input data shall contain an I-frame. If the pointer is
55NULL, then the current displayed still picture is blanked.54NULL, then the current displayed still picture is blanked.
56 55
57
58Return Value56Return Value
59------------57------------
60 58
Documentation/userspace-api/media/dvb/video-stop.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_STOP:4.. _VIDEO_STOP:
4 5
@@ -16,9 +17,9 @@ VIDEO_STOP · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(fd, VIDEO_STOP, boolean mode)20.. c:macro:: VIDEO_STOP
20 :name: VIDEO_STOP
21 21
22``int ioctl(fd, VIDEO_STOP, boolean mode)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -56,7 +56,6 @@ Arguments · 22 unmodified lines
56 -56 -
57 - FALSE: Show last decoded frame.57 - FALSE: Show last decoded frame.
58 58
59
60Description59Description
61-----------60-----------
62 61
@@ -67,7 +66,6 @@ This ioctl call asks the Video Device to stop playing the current · 4 unmodified lines
67stream. Depending on the input parameter, the screen can be blanked out66stream. Depending on the input parameter, the screen can be blanked out
68or displaying the last decoded frame.67or displaying the last decoded frame.
69 68
70
71Return Value69Return Value
72------------70------------
73 71
Documentation/userspace-api/media/dvb/video-try-command.rst+3−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: DTV.video
2 3
3.. _VIDEO_TRY_COMMAND:4.. _VIDEO_TRY_COMMAND:
4 5
@@ -16,9 +17,9 @@ VIDEO_TRY_COMMAND · 11 unmodified lines
16Synopsis17Synopsis
17--------18--------
18 19
19.. c:function:: int ioctl(int fd, VIDEO_TRY_COMMAND, struct video_command *cmd)20.. c:macro:: VIDEO_TRY_COMMAND
20 :name: VIDEO_TRY_COMMAND
21 21
22``int ioctl(int fd, VIDEO_TRY_COMMAND, struct video_command *cmd)``
22 23
23Arguments24Arguments
24---------25---------
@@ -27,7 +28,6 @@ Arguments · 2 unmodified lines
27 :header-rows: 028 :header-rows: 0
28 :stub-columns: 029 :stub-columns: 0
29 30
30
31 - .. row 131 - .. row 1
32 32
33 - int fd33 - int fd
@@ -46,7 +46,6 @@ Arguments · 12 unmodified lines
46 46
47 - Try a decoder command.47 - Try a decoder command.
48 48
49
50Description49Description
51-----------50-----------
52 51
@@ -59,7 +58,6 @@ subset of the ``v4l2_decoder_cmd`` struct, so refer to the · 6 unmodified lines
59:ref:`VIDIOC_TRY_DECODER_CMD <VIDIOC_DECODER_CMD>` documentation58:ref:`VIDIOC_TRY_DECODER_CMD <VIDIOC_DECODER_CMD>` documentation
60for more information.59for more information.
61 60
62
63Return Value61Return Value
64------------62------------
65 63
Documentation/userspace-api/media/mediactl/media-func-close.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media-func-close:4.. _media-func-close:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12media-close - Close a media device13media-close - Close a media device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,16 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: int close( int fd )22.. c:function:: int close( int fd )
24 :name: mc-close
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :c:func:`open() <mc-open>`.28 File descriptor returned by :c:func:`open()`.
31
32 29
33Description30Description
34===========31===========
@@ -36,11 +33,10 @@ Description · 1 unmodified line
36Closes the media device. Resources associated with the file descriptor33Closes the media device. Resources associated with the file descriptor
37are freed. The device configuration remain unchanged.34are freed. The device configuration remain unchanged.
38 35
39
40Return Value36Return Value
41============37============
42 38
43:ref:`close() <media-func-close>` returns 0 on success. On error, -1 is returned, and39:c:func:`close()` returns 0 on success. On error, -1 is returned, and
44``errno`` is set appropriately. Possible error codes are:40``errno`` is set appropriately. Possible error codes are:
45 41
46EBADF42EBADF
Documentation/userspace-api/media/mediactl/media-func-ioctl.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media-func-ioctl:4.. _media-func-ioctl:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12media-ioctl - Control a media device13media-ioctl - Control a media device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,15 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <sys/ioctl.h>20 #include <sys/ioctl.h>
21 21
22 22``int ioctl(int fd, int request, void *argp)``
23.. c:function:: int ioctl( int fd, int request, void *argp )
24 :name: mc-ioctl
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :c:func:`open() <mc-open>`.28 File descriptor returned by :c:func:`open()`.
31 29
32``request``30``request``
33 Media ioctl request code as defined in the media.h header file, for31 Media ioctl request code as defined in the media.h header file, for
@@ -36,7 +34,6 @@ Arguments · 2 unmodified lines
36``argp``34``argp``
37 Pointer to a request-specific structure.35 Pointer to a request-specific structure.
38 36
39
40Description37Description
41===========38===========
42 39
@@ -52,7 +49,6 @@ their parameters are located in the media.h header file. All media ioctl · 9 unmodified lines
52requests, their respective function and parameters are specified in49requests, their respective function and parameters are specified in
53:ref:`media-user-func`.50:ref:`media-user-func`.
54 51
55
56Return Value52Return Value
57============53============
58 54
Documentation/userspace-api/media/mediactl/media-func-open.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media-func-open:4.. _media-func-open:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12media-open - Open a media device13media-open - Open a media device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <fcntl.h>20 #include <fcntl.h>
21 21
22
23.. c:function:: int open( const char *device_name, int flags )22.. c:function:: int open( const char *device_name, int flags )
24 :name: mc-open
25 23
26Arguments24Arguments
27=========25=========
@@ -33,11 +31,10 @@ Arguments · 5 unmodified lines
33 Open flags. Access mode must be either ``O_RDONLY`` or ``O_RDWR``.31 Open flags. Access mode must be either ``O_RDONLY`` or ``O_RDWR``.
34 Other flags have no effect.32 Other flags have no effect.
35 33
36
37Description34Description
38===========35===========
39 36
40To open a media device applications call :ref:`open() <media-func-open>` with the37To open a media device applications call :c:func:`open()` with the
41desired device name. The function has no side effects; the device38desired device name. The function has no side effects; the device
42configuration remain unchanged.39configuration remain unchanged.
43 40
@@ -45,11 +42,10 @@ When the device is opened in read-only mode, attempts to modify its · 1 unmodified line
45configuration will result in an error, and ``errno`` will be set to42configuration will result in an error, and ``errno`` will be set to
46EBADF.43EBADF.
47 44
48
49Return Value45Return Value
50============46============
51 47
52:ref:`open() <func-open>` returns the new file descriptor on success. On error,48:c:func:`open()` returns the new file descriptor on success. On error,
53-1 is returned, and ``errno`` is set appropriately. Possible error codes49-1 is returned, and ``errno`` is set appropriately. Possible error codes
54are:50are:
55 51
Documentation/userspace-api/media/mediactl/media-ioc-device-info.rst+4−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_ioc_device_info:4.. _media_ioc_device_info:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12MEDIA_IOC_DEVICE_INFO - Query device information13MEDIA_IOC_DEVICE_INFO - Query device information
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, MEDIA_IOC_DEVICE_INFO, struct media_device_info *argp )18.. c:macro:: MEDIA_IOC_DEVICE_INFO
19 :name: MEDIA_IOC_DEVICE_INFO
20 19
20``int ioctl(int fd, MEDIA_IOC_DEVICE_INFO, struct media_device_info *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <media-func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`media_device_info`.29 Pointer to struct :c:type:`media_device_info`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -38,7 +37,6 @@ a struct :c:type:`media_device_info`. The driver · 3 unmodified lines
38fills the structure and returns the information to the application. The37fills the structure and returns the information to the application. The
39ioctl never fails.38ioctl never fails.
40 39
41
42.. c:type:: media_device_info40.. c:type:: media_device_info
43 41
44.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|42.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -48,7 +46,6 @@ ioctl never fails. · 3 unmodified lines
48 :stub-columns: 046 :stub-columns: 0
49 :widths: 1 1 247 :widths: 1 1 2
50 48
51
52 * - char49 * - char
53 - ``driver``\ [16]50 - ``driver``\ [16]
54 - Name of the driver implementing the media API as a NUL-terminated51 - Name of the driver implementing the media API as a NUL-terminated
@@ -94,7 +91,6 @@ ioctl never fails. · 39 unmodified lines
94 - Reserved for future extensions. Drivers and applications must set91 - Reserved for future extensions. Drivers and applications must set
95 this array to zero.92 this array to zero.
96 93
97
98The ``serial`` and ``bus_info`` fields can be used to distinguish94The ``serial`` and ``bus_info`` fields can be used to distinguish
99between multiple instances of otherwise identical hardware. The serial95between multiple instances of otherwise identical hardware. The serial
100number takes precedence when provided and can be assumed to be unique.96number takes precedence when provided and can be assumed to be unique.
@@ -102,7 +98,6 @@ If the serial number is an empty string, the ``bus_info`` field can be · 1 unmodified line
102used instead. The ``bus_info`` field is guaranteed to be unique, but can98used instead. The ``bus_info`` field is guaranteed to be unique, but can
103vary across reboots or device unplug/replug.99vary across reboots or device unplug/replug.
104 100
105
106Return Value101Return Value
107============102============
108 103
Documentation/userspace-api/media/mediactl/media-ioc-enum-entities.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_ioc_enum_entities:4.. _media_ioc_enum_entities:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12MEDIA_IOC_ENUM_ENTITIES - Enumerate entities and their properties13MEDIA_IOC_ENUM_ENTITIES - Enumerate entities and their properties
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, MEDIA_IOC_ENUM_ENTITIES, struct media_entity_desc *argp )18.. c:macro:: MEDIA_IOC_ENUM_ENTITIES
19 :name: MEDIA_IOC_ENUM_ENTITIES
20 19
20``int ioctl(int fd, MEDIA_IOC_ENUM_ENTITIES, struct media_entity_desc *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <media-func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`media_entity_desc`.29 Pointer to struct :c:type:`media_entity_desc`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -49,7 +48,6 @@ Entity IDs can be non-contiguous. Applications must *not* try to · 14 unmodified lines
49enumerate entities by calling MEDIA_IOC_ENUM_ENTITIES with increasing48enumerate entities by calling MEDIA_IOC_ENUM_ENTITIES with increasing
50id's until they get an error.49id's until they get an error.
51 50
52
53.. c:type:: media_entity_desc51.. c:type:: media_entity_desc
54 52
55.. tabularcolumns:: |p{1.5cm}|p{1.7cm}|p{1.6cm}|p{1.5cm}|p{11.2cm}|53.. tabularcolumns:: |p{1.5cm}|p{1.7cm}|p{1.6cm}|p{1.5cm}|p{11.2cm}|
@@ -136,7 +134,6 @@ id's until they get an error. · 80 unmodified lines
136 * - }134 * - }
137 -135 -
138 136
139
140Return Value137Return Value
141============138============
142 139
Documentation/userspace-api/media/mediactl/media-ioc-enum-links.rst+4−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_ioc_enum_links:4.. _media_ioc_enum_links:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12MEDIA_IOC_ENUM_LINKS - Enumerate all pads and links for a given entity13MEDIA_IOC_ENUM_LINKS - Enumerate all pads and links for a given entity
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, MEDIA_IOC_ENUM_LINKS, struct media_links_enum *argp )18.. c:macro:: MEDIA_IOC_ENUM_LINKS
19 :name: MEDIA_IOC_ENUM_LINKS
20 19
20``int ioctl(int fd, MEDIA_IOC_ENUM_LINKS, struct media_links_enum *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <media-func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`media_links_enum`.29 Pointer to struct :c:type:`media_links_enum`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -53,7 +52,6 @@ outbound links can be retrieved with :ref:`MEDIA_IOC_ENUM_ENTITIES`. · 18 unmodified lines
53Only forward links that originate at one of the entity's source pads are52Only forward links that originate at one of the entity's source pads are
54returned during the enumeration process.53returned during the enumeration process.
55 54
56
57.. c:type:: media_links_enum55.. c:type:: media_links_enum
58 56
59.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|57.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -82,7 +80,6 @@ returned during the enumeration process. · 22 unmodified lines
82 - Reserved for future extensions. Drivers and applications must set80 - Reserved for future extensions. Drivers and applications must set
83 the array to zero.81 the array to zero.
84 82
85
86.. c:type:: media_pad_desc83.. c:type:: media_pad_desc
87 84
88.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|85.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -110,7 +107,6 @@ returned during the enumeration process. · 21 unmodified lines
110 the array to zero.107 the array to zero.
111 108
112 109
113
114.. c:type:: media_link_desc110.. c:type:: media_link_desc
115 111
116.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|112.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -137,7 +133,6 @@ returned during the enumeration process. · 20 unmodified lines
137 - Reserved for future extensions. Drivers and applications must set133 - Reserved for future extensions. Drivers and applications must set
138 the array to zero.134 the array to zero.
139 135
140
141Return Value136Return Value
142============137============
143 138
Documentation/userspace-api/media/mediactl/media-ioc-g-topology.rst+4−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_ioc_g_topology:4.. _media_ioc_g_topology:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12MEDIA_IOC_G_TOPOLOGY - Enumerate the graph topology and graph element properties13MEDIA_IOC_G_TOPOLOGY - Enumerate the graph topology and graph element properties
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, MEDIA_IOC_G_TOPOLOGY, struct media_v2_topology *argp )18.. c:macro:: MEDIA_IOC_G_TOPOLOGY
19 :name: MEDIA_IOC_G_TOPOLOGY
20 19
20``int ioctl(int fd, MEDIA_IOC_G_TOPOLOGY, struct media_v2_topology *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <media-func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`media_v2_topology`.29 Pointer to struct :c:type:`media_v2_topology`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -120,7 +119,6 @@ desired arrays with the media graph elements. · 85 unmodified lines
120 converted to a 64-bits integer. It can be zero. if zero, the ioctl119 converted to a 64-bits integer. It can be zero. if zero, the ioctl
121 won't store the links. It will just update ``num_links``120 won't store the links. It will just update ``num_links``
122 121
123
124.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|122.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|
125 123
126.. c:type:: media_v2_entity124.. c:type:: media_v2_entity
@@ -158,7 +156,6 @@ desired arrays with the media graph elements. · 31 unmodified lines
158 - Reserved for future extensions. Drivers and applications must set156 - Reserved for future extensions. Drivers and applications must set
159 this array to zero.157 this array to zero.
160 158
161
162.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|159.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|
163 160
164.. c:type:: media_v2_interface161.. c:type:: media_v2_interface
@@ -192,7 +189,6 @@ desired arrays with the media graph elements. · 27 unmodified lines
192 - Used only for device node interfaces. See189 - Used only for device node interfaces. See
193 :c:type:`media_v2_intf_devnode` for details.190 :c:type:`media_v2_intf_devnode` for details.
194 191
195
196.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|192.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|
197 193
198.. c:type:: media_v2_intf_devnode194.. c:type:: media_v2_intf_devnode
@@ -245,7 +241,6 @@ desired arrays with the media graph elements. · 46 unmodified lines
245 - Reserved for future extensions. Drivers and applications must set241 - Reserved for future extensions. Drivers and applications must set
246 this array to zero.242 this array to zero.
247 243
248
249.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|244.. tabularcolumns:: |p{1.6cm}|p{3.2cm}|p{12.7cm}|
250 245
251.. c:type:: media_v2_link246.. c:type:: media_v2_link
@@ -282,7 +277,6 @@ desired arrays with the media graph elements. · 30 unmodified lines
282 - Reserved for future extensions. Drivers and applications must set277 - Reserved for future extensions. Drivers and applications must set
283 this array to zero.278 this array to zero.
284 279
285
286Return Value280Return Value
287============281============
288 282
Documentation/userspace-api/media/mediactl/media-ioc-request-alloc.rst+5−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_ioc_request_alloc:4.. _media_ioc_request_alloc:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12MEDIA_IOC_REQUEST_ALLOC - Allocate a request13MEDIA_IOC_REQUEST_ALLOC - Allocate a request
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, MEDIA_IOC_REQUEST_ALLOC, int *argp )18.. c:macro:: MEDIA_IOC_REQUEST_ALLOC
19 :name: MEDIA_IOC_REQUEST_ALLOC
20 19
20``int ioctl(int fd, MEDIA_IOC_REQUEST_ALLOC, int *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <media-func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to an integer.29 Pointer to an integer.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -51,7 +50,7 @@ Finally, the file descriptor can be :ref:`polled <request-func-poll>` to wait · 16 unmodified lines
51for the request to complete.50for the request to complete.
52 51
53The request will remain allocated until all the file descriptors associated52The request will remain allocated until all the file descriptors associated
54with it are closed by :ref:`close() <request-func-close>` and the driver no53with it are closed by :c:func:`close()` and the driver no
55longer uses the request internally. See also54longer uses the request internally. See also
56:ref:`here <media-request-life-time>` for more information.55:ref:`here <media-request-life-time>` for more information.
57 56
Documentation/userspace-api/media/mediactl/media-ioc-setup-link.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_ioc_setup_link:4.. _media_ioc_setup_link:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12MEDIA_IOC_SETUP_LINK - Modify the properties of a link13MEDIA_IOC_SETUP_LINK - Modify the properties of a link
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, MEDIA_IOC_SETUP_LINK, struct media_link_desc *argp )18.. c:macro:: MEDIA_IOC_SETUP_LINK
19 :name: MEDIA_IOC_SETUP_LINK
20 19
20``int ioctl(int fd, MEDIA_IOC_SETUP_LINK, struct media_link_desc *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <media-func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`media_link_desc`.29 Pointer to struct :c:type:`media_link_desc`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -53,7 +52,6 @@ non-dynamic link will return an ``EBUSY`` error code. · 18 unmodified lines
53If the specified link can't be found the driver returns with an ``EINVAL``52If the specified link can't be found the driver returns with an ``EINVAL``
54error code.53error code.
55 54
56
57Return Value55Return Value
58============56============
59 57
Documentation/userspace-api/media/mediactl/media-request-ioc-queue.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_request_ioc_queue:4.. _media_request_ioc_queue:
4 5
@@ -11,13 +12,12 @@ Name · 6 unmodified lines
11 12
12MEDIA_REQUEST_IOC_QUEUE - Queue a request13MEDIA_REQUEST_IOC_QUEUE - Queue a request
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int request_fd, MEDIA_REQUEST_IOC_QUEUE )18.. c:macro:: MEDIA_REQUEST_IOC_QUEUE
19 :name: MEDIA_REQUEST_IOC_QUEUE
20 19
20``int ioctl(int request_fd, MEDIA_REQUEST_IOC_QUEUE)``
21 21
22Arguments22Arguments
23=========23=========
@@ -25,7 +25,6 @@ Arguments · 1 unmodified line
25``request_fd``25``request_fd``
26 File descriptor returned by :ref:`MEDIA_IOC_REQUEST_ALLOC`.26 File descriptor returned by :ref:`MEDIA_IOC_REQUEST_ALLOC`.
27 27
28
29Description28Description
30===========29===========
31 30
Documentation/userspace-api/media/mediactl/media-request-ioc-reinit.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media_request_ioc_reinit:4.. _media_request_ioc_reinit:
4 5
@@ -11,13 +12,12 @@ Name · 6 unmodified lines
11 12
12MEDIA_REQUEST_IOC_REINIT - Re-initialize a request13MEDIA_REQUEST_IOC_REINIT - Re-initialize a request
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int request_fd, MEDIA_REQUEST_IOC_REINIT )18.. c:macro:: MEDIA_REQUEST_IOC_REINIT
19 :name: MEDIA_REQUEST_IOC_REINIT
20 19
20``int ioctl(int request_fd, MEDIA_REQUEST_IOC_REINIT)``
21 21
22Arguments22Arguments
23=========23=========
@@ -33,7 +33,7 @@ this request ioctl can be used to re-initialize a previously allocated · 9 unmodified lines
33request.33request.
34 34
35Re-initializing a request will clear any existing data from the request.35Re-initializing a request will clear any existing data from the request.
36This avoids having to :ref:`close() <request-func-close>` a completed36This avoids having to :c:func:`close()` a completed
37request and allocate a new request. Instead the completed request can just37request and allocate a new request. Instead the completed request can just
38be re-initialized and it is ready to be used again.38be re-initialized and it is ready to be used again.
39 39
Documentation/userspace-api/media/mediactl/request-api.rst+3−2
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _media-request-api:4.. _media-request-api:
4 5
@@ -93,7 +94,7 @@ regardless of whether a request is in use or not. · 88 unmodified lines
93 Setting the same control through a request and also directly can lead to94 Setting the same control through a request and also directly can lead to
94 undefined behavior!95 undefined behavior!
95 96
96User-space can :ref:`poll() <request-func-poll>` a request file descriptor in97User-space can :c:func:`poll()` a request file descriptor in
97order to wait until the request completes. A request is considered complete98order to wait until the request completes. A request is considered complete
98once all its associated buffers are available for dequeuing and all the99once all its associated buffers are available for dequeuing and all the
99associated controls have been updated with the values at the time of completion.100associated controls have been updated with the values at the time of completion.
@@ -115,7 +116,7 @@ Recycling and Destruction · 15 unmodified lines
115-------------------------116-------------------------
116 117
117Finally, a completed request can either be discarded or be reused. Calling118Finally, a completed request can either be discarded or be reused. Calling
118:ref:`close() <request-func-close>` on a request file descriptor will make119:c:func:`close()` on a request file descriptor will make
119that file descriptor unusable and the request will be freed once it is no120that file descriptor unusable and the request will be freed once it is no
120longer in use by the kernel. That is, if the request is queued and then the121longer in use by the kernel. That is, if the request is queued and then the
121file descriptor is closed, then it won't be freed until the driver completed122file descriptor is closed, then it won't be freed until the driver completed
Documentation/userspace-api/media/mediactl/request-func-close.rst+2−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC.request
2 3
3.. _request-func-close:4.. _request-func-close:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12request-close - Close a request file descriptor13request-close - Close a request file descriptor
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: int close( int fd )22.. c:function:: int close( int fd )
24 :name: req-close
25 23
26Arguments24Arguments
27=========25=========
@@ -29,7 +27,6 @@ Arguments · 1 unmodified line
29``fd``27``fd``
30 File descriptor returned by :ref:`MEDIA_IOC_REQUEST_ALLOC`.28 File descriptor returned by :ref:`MEDIA_IOC_REQUEST_ALLOC`.
31 29
32
33Description30Description
34===========31===========
35 32
@@ -38,11 +35,10 @@ are freed once all file descriptors associated with the request are closed · 2 unmodified lines
38and the driver has completed the request.35and the driver has completed the request.
39See :ref:`here <media-request-life-time>` for more information.36See :ref:`here <media-request-life-time>` for more information.
40 37
41
42Return Value38Return Value
43============39============
44 40
45:ref:`close() <request-func-close>` returns 0 on success. On error, -1 is41:c:func:`close()` returns 0 on success. On error, -1 is
46returned, and ``errno`` is set appropriately. Possible error codes are:42returned, and ``errno`` is set appropriately. Possible error codes are:
47 43
48EBADF44EBADF
Documentation/userspace-api/media/mediactl/request-func-ioctl.rst+2−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _request-func-ioctl:4.. _request-func-ioctl:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12request-ioctl - Control a request file descriptor13request-ioctl - Control a request file descriptor
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <sys/ioctl.h>20 #include <sys/ioctl.h>
21 21
22 22``int ioctl(int fd, int cmd, void *argp)``
23.. c:function:: int ioctl( int fd, int cmd, void *argp )
24 :name: req-ioctl
25 23
26Arguments24Arguments
27=========25=========
@@ -36,7 +34,6 @@ Arguments · 8 unmodified lines
36``argp``34``argp``
37 Pointer to a request-specific structure.35 Pointer to a request-specific structure.
38 36
39
40Description37Description
41===========38===========
42 39
@@ -52,7 +49,6 @@ their parameters are located in the media.h header file. All request ioctl · 9 unmodified lines
52commands, their respective function and parameters are specified in49commands, their respective function and parameters are specified in
53:ref:`media-user-func`.50:ref:`media-user-func`.
54 51
55
56Return Value52Return Value
57============53============
58 54
Documentation/userspace-api/media/mediactl/request-func-poll.rst+4−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: MC
2 3
3.. _request-func-poll:4.. _request-func-poll:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12request-poll - Wait for some event on a file descriptor13request-poll - Wait for some event on a file descriptor
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <sys/poll.h>20 #include <sys/poll.h>
21 21
22
23.. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )22.. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )
24 :name: request-poll
25 23
26Arguments24Arguments
27=========25=========
@@ -35,14 +33,13 @@ Arguments · 7 unmodified lines
35``timeout``33``timeout``
36 Timeout to wait for events34 Timeout to wait for events
37 35
38
39Description36Description
40===========37===========
41 38
42With the :c:func:`poll() <request-func-poll>` function applications can wait39With the :c:func:`poll()` function applications can wait
43for a request to complete.40for a request to complete.
44 41
45On success :c:func:`poll() <request-func-poll>` returns the number of file42On success :c:func:`poll()` returns the number of file
46descriptors that have been selected (that is, file descriptors for which the43descriptors that have been selected (that is, file descriptors for which the
47``revents`` field of the respective struct :c:type:`pollfd`44``revents`` field of the respective struct :c:type:`pollfd`
48is non-zero). Request file descriptor set the ``POLLPRI`` flag in ``revents``45is non-zero). Request file descriptor set the ``POLLPRI`` flag in ``revents``
@@ -53,11 +50,10 @@ set appropriately. · 4 unmodified lines
53Attempting to poll for a request that is not yet queued will50Attempting to poll for a request that is not yet queued will
54set the ``POLLERR`` flag in ``revents``.51set the ``POLLERR`` flag in ``revents``.
55 52
56
57Return Value53Return Value
58============54============
59 55
60On success, :c:func:`poll() <request-func-poll>` returns the number of56On success, :c:func:`poll()` returns the number of
61structures which have non-zero ``revents`` fields, or zero if the call57structures which have non-zero ``revents`` fields, or zero if the call
62timed out. On error -1 is returned, and the ``errno`` variable is set58timed out. On error -1 is returned, and the ``errno`` variable is set
63appropriately:59appropriately:
Documentation/userspace-api/media/rc/lirc-get-features.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_get_features:4.. _lirc_get_features:
4 5
@@ -14,8 +15,9 @@ LIRC_GET_FEATURES - Get the underlying hardware device's features · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, LIRC_GET_FEATURES, __u32 *features)18.. c:macro:: LIRC_GET_FEATURES
18 :name: LIRC_GET_FEATURES19
20``int ioctl(int fd, LIRC_GET_FEATURES, __u32 *features)``
19 21
20Arguments22Arguments
21=========23=========
@@ -26,11 +28,9 @@ Arguments · 4 unmodified lines
26``features``28``features``
27 Bitmask with the LIRC features.29 Bitmask with the LIRC features.
28 30
29
30Description31Description
31===========32===========
32 33
33
34Get the underlying hardware device's features. If a driver does not34Get the underlying hardware device's features. If a driver does not
35announce support of certain features, calling of the corresponding ioctls35announce support of certain features, calling of the corresponding ioctls
36is undefined.36is undefined.
@@ -184,7 +184,6 @@ LIRC features · 147 unmodified lines
184 184
185 Unused. Kept just to avoid breaking uAPI.185 Unused. Kept just to avoid breaking uAPI.
186 186
187
188Return Value187Return Value
189============188============
190 189
Documentation/userspace-api/media/rc/lirc-get-rec-mode.rst+7−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_get_rec_mode:4.. _lirc_get_rec_mode:
4.. _lirc_set_rec_mode:5.. _lirc_set_rec_mode:
@@ -15,11 +16,13 @@ LIRC_GET_REC_MODE/LIRC_SET_REC_MODE - Get/set current receive mode. · 10 unmodified lines
15Synopsis16Synopsis
16========17========
17 18
18.. c:function:: int ioctl( int fd, LIRC_GET_REC_MODE, __u32 *mode)19.. c:macro:: LIRC_GET_REC_MODE
19 :name: LIRC_GET_REC_MODE
20 20
21.. c:function:: int ioctl( int fd, LIRC_SET_REC_MODE, __u32 *mode)21``int ioctl(int fd, LIRC_GET_REC_MODE, __u32 *mode)``
22 :name: LIRC_SET_REC_MODE22
23.. c:macro:: LIRC_SET_REC_MODE
24
25``int ioctl(int fd, LIRC_SET_REC_MODE, __u32 *mode)``
23 26
24Arguments27Arguments
25=========28=========
@@ -47,7 +50,6 @@ Return Value · 21 unmodified lines
47 :header-rows: 050 :header-rows: 0
48 :stub-columns: 051 :stub-columns: 0
49 52
50
51 - .. row 153 - .. row 1
52 54
53 - ``ENODEV``55 - ``ENODEV``
Documentation/userspace-api/media/rc/lirc-get-rec-resolution.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_get_rec_resolution:4.. _lirc_get_rec_resolution:
4 5
@@ -14,8 +15,9 @@ LIRC_GET_REC_RESOLUTION - Obtain the value of receive resolution, in microsecond · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, LIRC_GET_REC_RESOLUTION, __u32 *microseconds)18.. c:macro:: LIRC_GET_REC_RESOLUTION
18 :name: LIRC_GET_REC_RESOLUTION19
20``int ioctl(int fd, LIRC_GET_REC_RESOLUTION, __u32 *microseconds)``
19 21
20Arguments22Arguments
21=========23=========
@@ -26,7 +28,6 @@ Arguments · 4 unmodified lines
26``microseconds``28``microseconds``
27 Resolution, in microseconds.29 Resolution, in microseconds.
28 30
29
30Description31Description
31===========32===========
32 33
@@ -38,7 +39,6 @@ This ioctl returns the integer value with such resolution, with can be · 5 unmodified lines
38used by userspace applications like lircd to automatically adjust the39used by userspace applications like lircd to automatically adjust the
39tolerance value.40tolerance value.
40 41
41
42Return Value42Return Value
43============43============
44 44
Documentation/userspace-api/media/rc/lirc-get-send-mode.rst+7−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_get_send_mode:4.. _lirc_get_send_mode:
4.. _lirc_set_send_mode:5.. _lirc_set_send_mode:
@@ -15,11 +16,13 @@ LIRC_GET_SEND_MODE/LIRC_SET_SEND_MODE - Get/set current transmit mode. · 10 unmodified lines
15Synopsis16Synopsis
16========17========
17 18
18.. c:function:: int ioctl( int fd, LIRC_GET_SEND_MODE, __u32 *mode )19.. c:macro:: LIRC_GET_SEND_MODE
19 :name: LIRC_GET_SEND_MODE
20 20
21.. c:function:: int ioctl( int fd, LIRC_SET_SEND_MODE, __u32 *mode )21``int ioctl(int fd, LIRC_GET_SEND_MODE, __u32 *mode)``
22 :name: LIRC_SET_SEND_MODE22
23.. c:macro:: LIRC_SET_SEND_MODE
24
25``int ioctl(int fd, LIRC_SET_SEND_MODE, __u32 *mode)``
23 26
24Arguments27Arguments
25=========28=========
@@ -30,7 +33,6 @@ Arguments · 4 unmodified lines
30``mode``33``mode``
31 The mode used for transmitting.34 The mode used for transmitting.
32 35
33
34Description36Description
35===========37===========
36 38
@@ -44,14 +46,12 @@ modes the driver supports. · 7 unmodified lines
44Return Value46Return Value
45============47============
46 48
47
48.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|49.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
49 50
50.. flat-table::51.. flat-table::
51 :header-rows: 052 :header-rows: 0
52 :stub-columns: 053 :stub-columns: 0
53 54
54
55 - .. row 155 - .. row 1
56 56
57 - ``ENODEV``57 - ``ENODEV``
Documentation/userspace-api/media/rc/lirc-get-timeout.rst+7−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_get_min_timeout:4.. _lirc_get_min_timeout:
4.. _lirc_get_max_timeout:5.. _lirc_get_max_timeout:
@@ -16,11 +17,13 @@ range for IR receive. · 11 unmodified lines
16Synopsis17Synopsis
17========18========
18 19
19.. c:function:: int ioctl( int fd, LIRC_GET_MIN_TIMEOUT, __u32 *timeout)20.. c:macro:: LIRC_GET_MIN_TIMEOUT
20 :name: LIRC_GET_MIN_TIMEOUT
21 21
22.. c:function:: int ioctl( int fd, LIRC_GET_MAX_TIMEOUT, __u32 *timeout)22``int ioctl(int fd, LIRC_GET_MIN_TIMEOUT, __u32 *timeout)``
23 :name: LIRC_GET_MAX_TIMEOUT23
24.. c:macro:: LIRC_GET_MAX_TIMEOUT
25
26``int ioctl(int fd, LIRC_GET_MAX_TIMEOUT, __u32 *timeout)``
24 27
25Arguments28Arguments
26=========29=========
@@ -31,7 +34,6 @@ Arguments · 4 unmodified lines
31``timeout``34``timeout``
32 Timeout, in microseconds.35 Timeout, in microseconds.
33 36
34
35Description37Description
36===========38===========
37 39
@@ -47,7 +49,6 @@ that can be set. · 9 unmodified lines
47 both ioctls will return the same value even though the timeout49 both ioctls will return the same value even though the timeout
48 cannot be changed via :ref:`LIRC_SET_REC_TIMEOUT`.50 cannot be changed via :ref:`LIRC_SET_REC_TIMEOUT`.
49 51
50
51Return Value52Return Value
52============53============
53 54
Documentation/userspace-api/media/rc/lirc-read.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc-read:4.. _lirc-read:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12lirc-read - Read from a LIRC device13lirc-read - Read from a LIRC device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,10 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: ssize_t read( int fd, void *buf, size_t count )22.. c:function:: ssize_t read( int fd, void *buf, size_t count )
24 :name: lirc-read
25
26 23
27Arguments24Arguments
28=========25=========
@@ -39,9 +36,9 @@ Arguments · 10 unmodified lines
39Description36Description
40===========37===========
41 38
42:ref:`read() <lirc-read>` attempts to read up to ``count`` bytes from file39:c:func:`read()` attempts to read up to ``count`` bytes from file
43descriptor ``fd`` into the buffer starting at ``buf``. If ``count`` is zero,40descriptor ``fd`` into the buffer starting at ``buf``. If ``count`` is zero,
44:ref:`read() <lirc-read>` returns zero and has no other results. If ``count``41:c:func:`read()` returns zero and has no other results. If ``count``
45is greater than ``SSIZE_MAX``, the result is unspecified.42is greater than ``SSIZE_MAX``, the result is unspecified.
46 43
47The exact format of the data depends on what :ref:`lirc_modes` a driver44The exact format of the data depends on what :ref:`lirc_modes` a driver
@@ -59,7 +56,6 @@ by hardware decoders. The :c:type:`rc_proto` member is set to the · 11 unmodified lines
59used for transmission, and ``scancode`` to the decoded scancode,56used for transmission, and ``scancode`` to the decoded scancode,
60and the ``keycode`` set to the keycode or ``KEY_RESERVED``.57and the ``keycode`` set to the keycode or ``KEY_RESERVED``.
61 58
62
63Return Value59Return Value
64============60============
65 61
Documentation/userspace-api/media/rc/lirc-set-measure-carrier-mode.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_measure_carrier_mode:4.. _lirc_set_measure_carrier_mode:
4 5
@@ -14,8 +15,9 @@ LIRC_SET_MEASURE_CARRIER_MODE - enable or disable measure mode · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, LIRC_SET_MEASURE_CARRIER_MODE, __u32 *enable )18.. c:macro:: LIRC_SET_MEASURE_CARRIER_MODE
18 :name: LIRC_SET_MEASURE_CARRIER_MODE19
20``int ioctl(int fd, LIRC_SET_MEASURE_CARRIER_MODE, __u32 *enable)``
19 21
20Arguments22Arguments
21=========23=========
@@ -27,7 +29,6 @@ Arguments · 5 unmodified lines
27 enable = 1 means enable measure mode, enable = 0 means disable measure29 enable = 1 means enable measure mode, enable = 0 means disable measure
28 mode.30 mode.
29 31
30
31Description32Description
32===========33===========
33 34
@@ -37,7 +38,6 @@ Enable or disable measure mode. If enabled, from the next key · 3 unmodified lines
37press on, the driver will send ``LIRC_MODE2_FREQUENCY`` packets. By38press on, the driver will send ``LIRC_MODE2_FREQUENCY`` packets. By
38default this should be turned off.39default this should be turned off.
39 40
40
41Return Value41Return Value
42============42============
43 43
Documentation/userspace-api/media/rc/lirc-set-rec-carrier-range.rst+4−2
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_rec_carrier_range:4.. _lirc_set_rec_carrier_range:
4 5
@@ -15,8 +16,9 @@ IR receive. · 10 unmodified lines
15Synopsis16Synopsis
16========17========
17 18
18.. c:function:: int ioctl( int fd, LIRC_SET_REC_CARRIER_RANGE, __u32 *frequency )19.. c:macro:: LIRC_SET_REC_CARRIER_RANGE
19 :name: LIRC_SET_REC_CARRIER_RANGE20
21``int ioctl(int fd, LIRC_SET_REC_CARRIER_RANGE, __u32 *frequency)``
20 22
21Arguments23Arguments
22=========24=========
Documentation/userspace-api/media/rc/lirc-set-rec-carrier.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_rec_carrier:4.. _lirc_set_rec_carrier:
4 5
@@ -11,12 +12,12 @@ Name · 6 unmodified lines
11 12
12LIRC_SET_REC_CARRIER - Set carrier used to modulate IR receive.13LIRC_SET_REC_CARRIER - Set carrier used to modulate IR receive.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, LIRC_SET_REC_CARRIER, __u32 *frequency )18.. c:macro:: LIRC_SET_REC_CARRIER
19 :name: LIRC_SET_REC_CARRIER19
20``int ioctl(int fd, LIRC_SET_REC_CARRIER, __u32 *frequency)``
20 21
21Arguments22Arguments
22=========23=========
@@ -37,7 +38,6 @@ Set receive carrier used to modulate IR PWM pulses and spaces. · 14 unmodified lines
37 If called together with :ref:`LIRC_SET_REC_CARRIER_RANGE`, this ioctl38 If called together with :ref:`LIRC_SET_REC_CARRIER_RANGE`, this ioctl
38 sets the upper bound frequency that will be recognized by the device.39 sets the upper bound frequency that will be recognized by the device.
39 40
40
41Return Value41Return Value
42============42============
43 43
Documentation/userspace-api/media/rc/lirc-set-rec-timeout-reports.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_rec_timeout_reports:4.. _lirc_set_rec_timeout_reports:
4 5
@@ -14,8 +15,9 @@ LIRC_SET_REC_TIMEOUT_REPORTS - enable or disable timeout reports for IR receive · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, LIRC_SET_REC_TIMEOUT_REPORTS, __u32 *enable )18.. c:macro:: LIRC_SET_REC_TIMEOUT_REPORTS
18 :name: LIRC_SET_REC_TIMEOUT_REPORTS19
20``int ioctl(int fd, LIRC_SET_REC_TIMEOUT_REPORTS, __u32 *enable)``
19 21
20Arguments22Arguments
21=========23=========
@@ -27,7 +29,6 @@ Arguments · 5 unmodified lines
27 enable = 1 means enable timeout report, enable = 0 means disable timeout29 enable = 1 means enable timeout report, enable = 0 means disable timeout
28 reports.30 reports.
29 31
30
31Description32Description
32===========33===========
33 34
@@ -40,7 +41,6 @@ should be turned off. · 6 unmodified lines
40 41
41 This ioctl is only valid for :ref:`LIRC_MODE_MODE2 <lirc-mode-mode2>`.42 This ioctl is only valid for :ref:`LIRC_MODE_MODE2 <lirc-mode-mode2>`.
42 43
43
44Return Value44Return Value
45============45============
46 46
Documentation/userspace-api/media/rc/lirc-set-rec-timeout.rst+7−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_rec_timeout:4.. _lirc_set_rec_timeout:
4.. _lirc_get_rec_timeout:5.. _lirc_get_rec_timeout:
@@ -15,11 +16,13 @@ LIRC_GET_REC_TIMEOUT/LIRC_SET_REC_TIMEOUT - Get/set the integer value for IR ina · 10 unmodified lines
15Synopsis16Synopsis
16========17========
17 18
18.. c:function:: int ioctl( int fd, LIRC_GET_REC_TIMEOUT, __u32 *timeout )19.. c:macro:: LIRC_GET_REC_TIMEOUT
19 :name: LIRC_GET_REC_TIMEOUT
20 20
21.. c:function:: int ioctl( int fd, LIRC_SET_REC_TIMEOUT, __u32 *timeout )21``int ioctl(int fd, LIRC_GET_REC_TIMEOUT, __u32 *timeout)``
22 :name: LIRC_SET_REC_TIMEOUT22
23.. c:macro:: LIRC_SET_REC_TIMEOUT
24
25``int ioctl(int fd, LIRC_SET_REC_TIMEOUT, __u32 *timeout)``
23 26
24Arguments27Arguments
25=========28=========
@@ -30,7 +33,6 @@ Arguments · 4 unmodified lines
30``timeout``33``timeout``
31 Timeout, in microseconds.34 Timeout, in microseconds.
32 35
33
34Description36Description
35===========37===========
36 38
@@ -45,7 +47,6 @@ given value should be set. · 8 unmodified lines
45 47
46 The range of supported timeout is given by :ref:`LIRC_GET_MIN_TIMEOUT`.48 The range of supported timeout is given by :ref:`LIRC_GET_MIN_TIMEOUT`.
47 49
48
49Return Value50Return Value
50============51============
51 52
Documentation/userspace-api/media/rc/lirc-set-send-carrier.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_send_carrier:4.. _lirc_set_send_carrier:
4 5
@@ -11,12 +12,12 @@ Name · 6 unmodified lines
11 12
12LIRC_SET_SEND_CARRIER - Set send carrier used to modulate IR TX.13LIRC_SET_SEND_CARRIER - Set send carrier used to modulate IR TX.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, LIRC_SET_SEND_CARRIER, __u32 *frequency )18.. c:macro:: LIRC_SET_SEND_CARRIER
19 :name: LIRC_SET_SEND_CARRIER19
20``int ioctl(int fd, LIRC_SET_SEND_CARRIER, __u32 *frequency)``
20 21
21Arguments22Arguments
22=========23=========
@@ -32,7 +33,6 @@ Description · 9 unmodified lines
32 33
33Set send carrier used to modulate IR PWM pulses and spaces.34Set send carrier used to modulate IR PWM pulses and spaces.
34 35
35
36Return Value36Return Value
37============37============
38 38
Documentation/userspace-api/media/rc/lirc-set-send-duty-cycle.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_send_duty_cycle:4.. _lirc_set_send_duty_cycle:
4 5
@@ -15,8 +16,9 @@ IR transmit. · 10 unmodified lines
15Synopsis16Synopsis
16========17========
17 18
18.. c:function:: int ioctl( int fd, LIRC_SET_SEND_DUTY_CYCLE, __u32 *duty_cycle)19.. c:macro:: LIRC_SET_SEND_DUTY_CYCLE
19 :name: LIRC_SET_SEND_DUTY_CYCLE20
21``int ioctl(int fd, LIRC_SET_SEND_DUTY_CYCLE, __u32 *duty_cycle)``
20 22
21Arguments23Arguments
22=========24=========
@@ -28,7 +30,6 @@ Arguments · 5 unmodified lines
28 Duty cicle, describing the pulse width in percent (from 1 to 99) of30 Duty cicle, describing the pulse width in percent (from 1 to 99) of
29 the total cycle. Values 0 and 100 are reserved.31 the total cycle. Values 0 and 100 are reserved.
30 32
31
32Description33Description
33===========34===========
34 35
@@ -38,7 +39,6 @@ Currently, no special meaning is defined for 0 or 100, but this · 3 unmodified lines
38could be used to switch off carrier generation in the future, so39could be used to switch off carrier generation in the future, so
39these values should be reserved.40these values should be reserved.
40 41
41
42Return Value42Return Value
43============43============
44 44
Documentation/userspace-api/media/rc/lirc-set-transmitter-mask.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_transmitter_mask:4.. _lirc_set_transmitter_mask:
4 5
@@ -14,8 +15,9 @@ LIRC_SET_TRANSMITTER_MASK - Enables send codes on a given set of transmitters · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, LIRC_SET_TRANSMITTER_MASK, __u32 *mask )18.. c:macro:: LIRC_SET_TRANSMITTER_MASK
18 :name: LIRC_SET_TRANSMITTER_MASK19
20``int ioctl(int fd, LIRC_SET_TRANSMITTER_MASK, __u32 *mask)``
19 21
20Arguments22Arguments
21=========23=========
@@ -26,7 +28,6 @@ Arguments · 4 unmodified lines
26``mask``28``mask``
27 Mask with channels to enable tx. Channel 0 is the least significant bit.29 Mask with channels to enable tx. Channel 0 is the least significant bit.
28 30
29
30Description31Description
31===========32===========
32 33
@@ -42,7 +43,6 @@ When an invalid bit mask is given, i.e. a bit is set, even though the device · 9 unmodified lines
42does not have so many transitters, then this ioctl returns the number of43does not have so many transitters, then this ioctl returns the number of
43available transitters and does nothing otherwise.44available transitters and does nothing otherwise.
44 45
45
46Return Value46Return Value
47============47============
48 48
Documentation/userspace-api/media/rc/lirc-set-wideband-receiver.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc_set_wideband_receiver:4.. _lirc_set_wideband_receiver:
4 5
@@ -14,8 +15,9 @@ LIRC_SET_WIDEBAND_RECEIVER - enable wide band receiver. · 9 unmodified lines
14Synopsis15Synopsis
15========16========
16 17
17.. c:function:: int ioctl( int fd, LIRC_SET_WIDEBAND_RECEIVER, __u32 *enable )18.. c:macro:: LIRC_SET_WIDEBAND_RECEIVER
18 :name: LIRC_SET_WIDEBAND_RECEIVER19
20``int ioctl(int fd, LIRC_SET_WIDEBAND_RECEIVER, __u32 *enable)``
19 21
20Arguments22Arguments
21=========23=========
@@ -27,7 +29,6 @@ Arguments · 5 unmodified lines
27 enable = 1 means enable wideband receiver, enable = 0 means disable29 enable = 1 means enable wideband receiver, enable = 0 means disable
28 wideband receiver.30 wideband receiver.
29 31
30
31Description32Description
32===========33===========
33 34
@@ -47,7 +48,6 @@ reduced range of reception. · 13 unmodified lines
47 carrier reports. Trying to disable wide band receiver while carrier48 carrier reports. Trying to disable wide band receiver while carrier
48 reports are active will do nothing.49 reports are active will do nothing.
49 50
50
51Return Value51Return Value
52============52============
53 53
Documentation/userspace-api/media/rc/lirc-write.rst+2−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
2 3
3.. _lirc-write:4.. _lirc-write:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12lirc-write - Write to a LIRC device13lirc-write - Write to a LIRC device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: ssize_t write( int fd, void *buf, size_t count )22.. c:function:: ssize_t write( int fd, void *buf, size_t count )
24 :name: lirc-write
25 23
26Arguments24Arguments
27=========25=========
@@ -38,7 +36,7 @@ Arguments · 10 unmodified lines
38Description36Description
39===========37===========
40 38
41:ref:`write() <lirc-write>` writes up to ``count`` bytes to the device39:c:func:`write()` writes up to ``count`` bytes to the device
42referenced by the file descriptor ``fd`` from the buffer starting at40referenced by the file descriptor ``fd`` from the buffer starting at
43``buf``.41``buf``.
44 42
@@ -64,7 +62,6 @@ for the protocol or the scancode is not valid for the specified protocol, · 19 unmodified lines
64``EINVAL`` is returned. The write function blocks until the scancode62``EINVAL`` is returned. The write function blocks until the scancode
65is transmitted by the hardware.63is transmitted by the hardware.
66 64
67
68Return Value65Return Value
69============66============
70 67
Documentation/userspace-api/media/v4l/buffer.rst+3−25
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _buffer:4.. _buffer:
4 5
@@ -33,7 +34,6 @@ mem-to-mem devices is an exception to the rule: the timestamp source · 28 unmodified lines
33flags are copied from the OUTPUT video buffer to the CAPTURE video34flags are copied from the OUTPUT video buffer to the CAPTURE video
34buffer.35buffer.
35 36
36
37Interactions between formats, controls and buffers37Interactions between formats, controls and buffers
38==================================================38==================================================
39 39
@@ -152,7 +152,6 @@ based on the queried sizes (for instance by allocating a set of buffers large · 112 unmodified lines
152enough for all the desired formats and controls, or by allocating separate set152enough for all the desired formats and controls, or by allocating separate set
153of appropriately sized buffers for each use case).153of appropriately sized buffers for each use case).
154 154
155
156.. c:type:: v4l2_buffer155.. c:type:: v4l2_buffer
157 156
158struct v4l2_buffer157struct v4l2_buffer
@@ -257,7 +256,7 @@ struct v4l2_buffer · 98 unmodified lines
257 ``V4L2_MEMORY_MMAP`` this is the offset of the buffer from the256 ``V4L2_MEMORY_MMAP`` this is the offset of the buffer from the
258 start of the device memory. The value is returned by the driver257 start of the device memory. The value is returned by the driver
259 and apart of serving as parameter to the258 and apart of serving as parameter to the
260 :ref:`mmap() <func-mmap>` function not useful for applications.259 :c:func:`mmap()` function not useful for applications.
261 See :ref:`mmap` for details260 See :ref:`mmap` for details
262 * - unsigned long261 * - unsigned long
263 - ``userptr``262 - ``userptr``
@@ -310,7 +309,6 @@ struct v4l2_buffer · 46 unmodified lines
310 given, then ``EINVAL`` will be returned.309 given, then ``EINVAL`` will be returned.
311 310
312 311
313
314.. c:type:: v4l2_plane312.. c:type:: v4l2_plane
315 313
316struct v4l2_plane314struct v4l2_plane
@@ -350,7 +348,7 @@ struct v4l2_plane · 33 unmodified lines
350 - ``mem_offset``348 - ``mem_offset``
351 - When the memory type in the containing struct349 - When the memory type in the containing struct
352 :c:type:`v4l2_buffer` is ``V4L2_MEMORY_MMAP``, this350 :c:type:`v4l2_buffer` is ``V4L2_MEMORY_MMAP``, this
353 is the value that should be passed to :ref:`mmap() <func-mmap>`,351 is the value that should be passed to :c:func:`mmap()`,
354 similar to the ``offset`` field in struct352 similar to the ``offset`` field in struct
355 :c:type:`v4l2_buffer`.353 :c:type:`v4l2_buffer`.
356 * - unsigned long354 * - unsigned long
@@ -384,7 +382,6 @@ struct v4l2_plane · 27 unmodified lines
384 applications.382 applications.
385 383
386 384
387
388.. c:type:: v4l2_buf_type385.. c:type:: v4l2_buf_type
389 386
390enum v4l2_buf_type387enum v4l2_buf_type
@@ -448,7 +445,6 @@ enum v4l2_buf_type · 57 unmodified lines
448 - Buffer for metadata output, see :ref:`metadata`.445 - Buffer for metadata output, see :ref:`metadata`.
449 446
450 447
451
452.. _buffer-flags:448.. _buffer-flags:
453 449
454Buffer Flags450Buffer Flags
@@ -682,20 +678,6 @@ Buffer Flags · 227 unmodified lines
682 678
683.. _memory-flags:679.. _memory-flags:
684 680
685Memory Consistency Flags
686========================
687
688.. tabularcolumns:: |p{7.0cm}|p{2.2cm}|p{8.3cm}|
689
690.. cssclass:: longtable
691
692.. flat-table::
693 :header-rows: 0
694 :stub-columns: 0
695 :widths: 3 1 4
696
697.. c:type:: v4l2_memory
698
699enum v4l2_memory681enum v4l2_memory
700================682================
701 683
@@ -720,7 +702,6 @@ enum v4l2_memory · 18 unmodified lines
720 - The buffer is used for :ref:`DMA shared buffer <dmabuf>` I/O.702 - The buffer is used for :ref:`DMA shared buffer <dmabuf>` I/O.
721 703
722 704
723
724Timecodes705Timecodes
725=========706=========
726 707
@@ -729,7 +710,6 @@ The :c:type:`v4l2_buffer_timecode` structure is designed to hold a · 2 unmodified lines
729(struct :c:type:`timeval` timestamps are stored in the struct710(struct :c:type:`timeval` timestamps are stored in the struct
730:c:type:`v4l2_buffer` ``timestamp`` field.)711:c:type:`v4l2_buffer` ``timestamp`` field.)
731 712
732
733.. c:type:: v4l2_timecode713.. c:type:: v4l2_timecode
734 714
735struct v4l2_timecode715struct v4l2_timecode
@@ -766,7 +746,6 @@ struct v4l2_timecode · 30 unmodified lines
766 - The "user group" bits from the timecode.746 - The "user group" bits from the timecode.
767 747
768 748
769
770.. _timecode-type:749.. _timecode-type:
771 750
772Timecode Types751Timecode Types
@@ -796,7 +775,6 @@ Timecode Types · 23 unmodified lines
796 -775 -
797 776
798 777
799
800.. _timecode-flags:778.. _timecode-flags:
801 779
802Timecode Flags780Timecode Flags
Documentation/userspace-api/media/v4l/dev-capture.rst+2−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _capture:4.. _capture:
4 5
@@ -19,7 +20,6 @@ device. · 14 unmodified lines
19 20
20.. note:: The same device file names are used for video output devices.21.. note:: The same device file names are used for video output devices.
21 22
22
23Querying Capabilities23Querying Capabilities
24=====================24=====================
25 25
@@ -34,7 +34,6 @@ functions they may also support the :ref:`video overlay <overlay>` · 8 unmodified lines
34streaming I/O methods must be supported. Tuners and audio inputs are34streaming I/O methods must be supported. Tuners and audio inputs are
35optional.35optional.
36 36
37
38Supplemental Functions37Supplemental Functions
39======================38======================
40 39
@@ -45,7 +44,6 @@ Video capture devices shall support :ref:`audio input <audio>`, · 4 unmodified lines
45:ref:`video input <video>` ioctls must be supported by all video44:ref:`video input <video>` ioctls must be supported by all video
46capture devices.45capture devices.
47 46
48
49Image Format Negotiation47Image Format Negotiation
50========================48========================
51 49
@@ -55,7 +53,7 @@ capture, the latter how images are stored in memory, i. e. in RGB or YUV · 3 unmodified lines
55format, the number of bits per pixel or width and height. Together they53format, the number of bits per pixel or width and height. Together they
56also define how images are scaled in the process.54also define how images are scaled in the process.
57 55
58As usual these parameters are *not* reset at :ref:`open() <func-open>`56As usual these parameters are *not* reset at :c:func:`open()`
59time to permit Unix tool chains, programming a device and then reading57time to permit Unix tool chains, programming a device and then reading
60from it as if it was a plain file. Well written V4L2 applications ensure58from it as if it was a plain file. Well written V4L2 applications ensure
61they really get what they want, including cropping and scaling.59they really get what they want, including cropping and scaling.
@@ -95,7 +93,6 @@ and :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl, even if :ref:`VIDIOC_S_FMT <VIDIOC · 33 unmodified lines
95requests and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does.93requests and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does.
96:ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` is optional.94:ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` is optional.
97 95
98
99Reading Images96Reading Images
100==============97==============
101 98
Documentation/userspace-api/media/v4l/dev-output.rst+2−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _output:4.. _output:
4 5
@@ -18,7 +19,6 @@ device. · 13 unmodified lines
18 19
19.. note:: The same device file names are used also for video capture devices.20.. note:: The same device file names are used also for video capture devices.
20 21
21
22Querying Capabilities22Querying Capabilities
23=====================23=====================
24 24
@@ -32,7 +32,6 @@ functions they may also support the :ref:`raw VBI output <raw-vbi>` · 7 unmodified lines
32streaming I/O methods must be supported. Modulators and audio outputs32streaming I/O methods must be supported. Modulators and audio outputs
33are optional.33are optional.
34 34
35
36Supplemental Functions35Supplemental Functions
37======================36======================
38 37
@@ -43,7 +42,6 @@ Video output devices shall support :ref:`audio output <audio>`, · 4 unmodified lines
43:ref:`video output <video>` ioctls must be supported by all video42:ref:`video output <video>` ioctls must be supported by all video
44output devices.43output devices.
45 44
46
47Image Format Negotiation45Image Format Negotiation
48========================46========================
49 47
@@ -53,7 +51,7 @@ the latter how images are stored in memory, i. e. in RGB or YUV format, · 3 unmodified lines
53the number of bits per pixel or width and height. Together they also51the number of bits per pixel or width and height. Together they also
54define how images are scaled in the process.52define how images are scaled in the process.
55 53
56As usual these parameters are *not* reset at :ref:`open() <func-open>`54As usual these parameters are *not* reset at :c:func:`open()`
57time to permit Unix tool chains, programming a device and then writing55time to permit Unix tool chains, programming a device and then writing
58to it as if it was a plain file. Well written V4L2 applications ensure56to it as if it was a plain file. Well written V4L2 applications ensure
59they really get what they want, including cropping and scaling.57they really get what they want, including cropping and scaling.
@@ -92,7 +90,6 @@ and :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl, even if :ref:`VIDIOC_S_FMT <VIDIOC · 32 unmodified lines
92requests and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does.90requests and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does.
93:ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` is optional.91:ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` is optional.
94 92
95
96Writing Images93Writing Images
97==============94==============
98 95
Documentation/userspace-api/media/v4l/dev-raw-vbi.rst+6−13
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _raw-vbi:4.. _raw-vbi:
4 5
@@ -32,7 +33,6 @@ applications must call the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl. · 27 unmodified lines
32Accessed as ``/dev/vbi``, raw VBI capturing or output is the default33Accessed as ``/dev/vbi``, raw VBI capturing or output is the default
33device function.34device function.
34 35
35
36Querying Capabilities36Querying Capabilities
37=====================37=====================
38 38
@@ -44,7 +44,6 @@ in the ``capabilities`` field of struct · 5 unmodified lines
44read/write, streaming or asynchronous I/O methods must be supported. VBI44read/write, streaming or asynchronous I/O methods must be supported. VBI
45devices may or may not have a tuner or modulator.45devices may or may not have a tuner or modulator.
46 46
47
48Supplemental Functions47Supplemental Functions
49======================48======================
50 49
@@ -53,7 +52,6 @@ VBI devices shall support :ref:`video input or output <video>`, · 2 unmodified lines
53ioctls as needed. The :ref:`video standard <standard>` ioctls provide52ioctls as needed. The :ref:`video standard <standard>` ioctls provide
54information vital to program a VBI device, therefore must be supported.53information vital to program a VBI device, therefore must be supported.
55 54
56
57Raw VBI Format Negotiation55Raw VBI Format Negotiation
58==========================56==========================
59 57
@@ -62,7 +60,7 @@ frequency. To properly interpret the data V4L2 specifies an ioctl to · 2 unmodified lines
62query the sampling parameters. Moreover, to allow for some flexibility60query the sampling parameters. Moreover, to allow for some flexibility
63applications can also suggest different parameters.61applications can also suggest different parameters.
64 62
65As usual these parameters are *not* reset at :ref:`open() <func-open>`63As usual these parameters are *not* reset at :c:func:`open()`
66time to permit Unix tool chains, programming a device and then reading64time to permit Unix tool chains, programming a device and then reading
67from it as if it was a plain file. Well written V4L2 applications should65from it as if it was a plain file. Well written V4L2 applications should
68always ensure they really get what they want, requesting reasonable66always ensure they really get what they want, requesting reasonable
@@ -91,8 +89,8 @@ happen for instance when the video and VBI areas to capture would · 22 unmodified lines
91overlap, or when the driver supports multiple opens and another process89overlap, or when the driver supports multiple opens and another process
92already requested VBI capturing or output. Anyway, applications must90already requested VBI capturing or output. Anyway, applications must
93expect other resource allocation points which may return ``EBUSY``, at the91expect other resource allocation points which may return ``EBUSY``, at the
94:ref:`VIDIOC_STREAMON` ioctl and the first :ref:`read() <func-read>`92:ref:`VIDIOC_STREAMON` ioctl and the first :c:func:`read()`
95, :ref:`write() <func-write>` and :ref:`select() <func-select>` calls.93, :c:func:`write()` and :c:func:`select()` calls.
96 94
97VBI devices must implement both the :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and95VBI devices must implement both the :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and
98:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl, even if :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ignores all requests96:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl, even if :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ignores all requests
@@ -182,7 +180,6 @@ and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does · 83 unmodified lines
182 - This array is reserved for future extensions. Drivers and180 - This array is reserved for future extensions. Drivers and
183 applications must set it to zero.181 applications must set it to zero.
184 182
185
186.. tabularcolumns:: |p{4.4cm}|p{1.5cm}|p{11.6cm}|183.. tabularcolumns:: |p{4.4cm}|p{1.5cm}|p{11.6cm}|
187 184
188.. _vbifmt-flags:185.. _vbifmt-flags:
@@ -218,7 +215,6 @@ and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does · 29 unmodified lines
218 non-zero.215 non-zero.
219 216
220 217
221
222.. _vbi-hsync:218.. _vbi-hsync:
223 219
224.. kernel-figure:: vbi_hsync.svg220.. kernel-figure:: vbi_hsync.svg
@@ -227,7 +223,6 @@ and always returns default parameters as :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` does · 2 unmodified lines
227 223
228 **Figure 4.1. Line synchronization**224 **Figure 4.1. Line synchronization**
229 225
230
231.. _vbi-525:226.. _vbi-525:
232 227
233.. kernel-figure:: vbi_525.svg228.. kernel-figure:: vbi_525.svg
@@ -251,7 +246,6 @@ negotiation, or after switching the video standard which may invalidate · 17 unmodified lines
251the negotiated VBI parameters, should be refused by the driver. A format246the negotiated VBI parameters, should be refused by the driver. A format
252change during active I/O is not permitted.247change during active I/O is not permitted.
253 248
254
255Reading and writing VBI images249Reading and writing VBI images
256==============================250==============================
257 251
@@ -261,7 +255,6 @@ consisting of two fields of VBI images immediately following in memory. · 3 unmodified lines
261 255
262The total size of a frame computes as follows:256The total size of a frame computes as follows:
263 257
264
265.. code-block:: c258.. code-block:: c
266 259
267 (count[0] + count[1]) * samples_per_line * sample size in bytes260 (count[0] + count[1]) * samples_per_line * sample size in bytes
@@ -276,8 +269,8 @@ The latter bears the possibility of synchronizing video and VBI data by · 8 unmodified lines
276using buffer timestamps.269using buffer timestamps.
277 270
278Remember the :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` ioctl and the271Remember the :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` ioctl and the
279first :ref:`read() <func-read>`, :ref:`write() <func-write>` and272first :c:func:`read()`, :c:func:`write()` and
280:ref:`select() <func-select>` call can be resource allocation273:c:func:`select()` call can be resource allocation
281points returning an ``EBUSY`` error code if the required hardware resources274points returning an ``EBUSY`` error code if the required hardware resources
282are temporarily unavailable, for example the device is already in use by275are temporarily unavailable, for example the device is already in use by
283another process.276another process.
Documentation/userspace-api/media/v4l/dev-rds.rst+3−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _rds:4.. _rds:
4 5
@@ -28,7 +29,6 @@ The RDS interface does not support this format. Should support for MMBS · 23 unmodified lines
28the linux-media mailing list:29the linux-media mailing list:
29`https://linuxtv.org/lists.php <https://linuxtv.org/lists.php>`__.30`https://linuxtv.org/lists.php <https://linuxtv.org/lists.php>`__.
30 31
31
32Querying Capabilities32Querying Capabilities
33=====================33=====================
34 34
@@ -68,31 +68,27 @@ like program identification codes and radio text, the flag · 33 unmodified lines
68:ref:`Writing RDS data <writing-rds-data>` and68:ref:`Writing RDS data <writing-rds-data>` and
69:ref:`FM Transmitter Control Reference <fm-tx-controls>`.69:ref:`FM Transmitter Control Reference <fm-tx-controls>`.
70 70
71
72.. _reading-rds-data:71.. _reading-rds-data:
73 72
74Reading RDS data73Reading RDS data
75================74================
76 75
77RDS data can be read from the radio device with the76RDS data can be read from the radio device with the
78:ref:`read() <func-read>` function. The data is packed in groups of77:c:func:`read()` function. The data is packed in groups of
79three bytes.78three bytes.
80 79
81
82.. _writing-rds-data:80.. _writing-rds-data:
83 81
84Writing RDS data82Writing RDS data
85================83================
86 84
87RDS data can be written to the radio device with the85RDS data can be written to the radio device with the
88:ref:`write() <func-write>` function. The data is packed in groups of86:c:func:`write()` function. The data is packed in groups of
89three bytes, as follows:87three bytes, as follows:
90 88
91
92RDS datastructures89RDS datastructures
93==================90==================
94 91
95
96.. c:type:: v4l2_rds_data92.. c:type:: v4l2_rds_data
97 93
98.. tabularcolumns:: |p{2.5cm}|p{2.5cm}|p{12.5cm}|94.. tabularcolumns:: |p{2.5cm}|p{2.5cm}|p{12.5cm}|
@@ -113,7 +109,6 @@ RDS datastructures · 14 unmodified lines
113 - Block description109 - Block description
114 110
115 111
116
117.. _v4l2-rds-block:112.. _v4l2-rds-block:
118 113
119.. tabularcolumns:: |p{2.9cm}|p{14.6cm}|114.. tabularcolumns:: |p{2.9cm}|p{14.6cm}|
@@ -136,7 +131,6 @@ RDS datastructures · 16 unmodified lines
136 reception of this block.131 reception of this block.
137 132
138 133
139
140.. _v4l2-rds-block-codes:134.. _v4l2-rds-block-codes:
141 135
142.. tabularcolumns:: |p{6.4cm}|p{2.0cm}|p{1.2cm}|p{7.9cm}|136.. tabularcolumns:: |p{6.4cm}|p{2.0cm}|p{1.2cm}|p{7.9cm}|
Documentation/userspace-api/media/v4l/dev-sliced-vbi.rst+7−24
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _sliced:4.. _sliced:
4 5
@@ -27,7 +28,6 @@ however the default function here is video capturing or output. · 22 unmodified lines
27Different file descriptors must be used to pass raw and sliced VBI data28Different file descriptors must be used to pass raw and sliced VBI data
28simultaneously, if this is supported by the driver.29simultaneously, if this is supported by the driver.
29 30
30
31Querying Capabilities31Querying Capabilities
32=====================32=====================
33 33
@@ -39,7 +39,6 @@ respectively, in the ``capabilities`` field of struct · 5 unmodified lines
39read/write, streaming or asynchronous :ref:`I/O methods <io>` must be39read/write, streaming or asynchronous :ref:`I/O methods <io>` must be
40supported. Sliced VBI devices may have a tuner or modulator.40supported. Sliced VBI devices may have a tuner or modulator.
41 41
42
43Supplemental Functions42Supplemental Functions
44======================43======================
45 44
@@ -49,7 +48,6 @@ capabilities, and they may support :ref:`control` ioctls. · 3 unmodified lines
49The :ref:`video standard <standard>` ioctls provide information vital48The :ref:`video standard <standard>` ioctls provide information vital
50to program a sliced VBI device, therefore must be supported.49to program a sliced VBI device, therefore must be supported.
51 50
52
53.. _sliced-vbi-format-negotitation:51.. _sliced-vbi-format-negotitation:
54 52
55Sliced VBI Format Negotiation53Sliced VBI Format Negotiation
@@ -96,9 +94,8 @@ at this point, it may return an ``EBUSY`` error code if the required · 40 unmodified lines
96resources are temporarily unavailable. Other resource allocation points94resources are temporarily unavailable. Other resource allocation points
97which may return ``EBUSY`` can be the95which may return ``EBUSY`` can be the
98:ref:`VIDIOC_STREAMON` ioctl and the first96:ref:`VIDIOC_STREAMON` ioctl and the first
99:ref:`read() <func-read>`, :ref:`write() <func-write>` and97:c:func:`read()`, :c:func:`write()` and
100:ref:`select() <func-select>` call.98:c:func:`select()` call.
101
102 99
103.. c:type:: v4l2_sliced_vbi_format100.. c:type:: v4l2_sliced_vbi_format
104 101
@@ -191,7 +188,7 @@ struct v4l2_sliced_vbi_format · 86 unmodified lines
191 * - __u32188 * - __u32
192 - ``io_size``189 - ``io_size``
193 - :cspan:`2` Maximum number of bytes passed by one190 - :cspan:`2` Maximum number of bytes passed by one
194 :ref:`read() <func-read>` or :ref:`write() <func-write>` call,191 :c:func:`read()` or :c:func:`write()` call,
195 and the buffer size in bytes for the192 and the buffer size in bytes for the
196 :ref:`VIDIOC_QBUF` and193 :ref:`VIDIOC_QBUF` and
197 :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl. Drivers set this field194 :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl. Drivers set this field
@@ -274,7 +271,6 @@ Sliced VBI services · 76 unmodified lines
274 271
275 \normalsize272 \normalsize
276 273
277
278Drivers may return an ``EINVAL`` error code when applications attempt to274Drivers may return an ``EINVAL`` error code when applications attempt to
279read or write data without prior format negotiation, after switching the275read or write data without prior format negotiation, after switching the
280video standard (which may invalidate the negotiated VBI parameters) and276video standard (which may invalidate the negotiated VBI parameters) and
@@ -284,13 +280,12 @@ return an ``EBUSY`` error code when applications attempt to change the · 3 unmodified lines
284format while i/o is in progress (between a280format while i/o is in progress (between a
285:ref:`VIDIOC_STREAMON` and281:ref:`VIDIOC_STREAMON` and
286:ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` call, and after the first282:ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` call, and after the first
287:ref:`read() <func-read>` or :ref:`write() <func-write>` call).283:c:func:`read()` or :c:func:`write()` call).
288
289 284
290Reading and writing sliced VBI data285Reading and writing sliced VBI data
291===================================286===================================
292 287
293A single :ref:`read() <func-read>` or :ref:`write() <func-write>`288A single :c:func:`read()` or :c:func:`write()`
294call must pass all data belonging to one video frame. That is an array289call must pass all data belonging to one video frame. That is an array
295of struct :c:type:`v4l2_sliced_vbi_data` structures with one or290of struct :c:type:`v4l2_sliced_vbi_data` structures with one or
296more elements and a total size not exceeding ``io_size`` bytes. Likewise291more elements and a total size not exceeding ``io_size`` bytes. Likewise
@@ -298,7 +293,6 @@ in streaming I/O mode one buffer of ``io_size`` bytes must contain data · 1 unmodified line
298of one video frame. The ``id`` of unused293of one video frame. The ``id`` of unused
299struct :c:type:`v4l2_sliced_vbi_data` elements must be zero.294struct :c:type:`v4l2_sliced_vbi_data` elements must be zero.
300 295
301
302.. c:type:: v4l2_sliced_vbi_data296.. c:type:: v4l2_sliced_vbi_data
303 297
304struct v4l2_sliced_vbi_data298struct v4l2_sliced_vbi_data
@@ -344,9 +338,8 @@ struct v4l2_sliced_vbi_data · 39 unmodified lines
344 bytes at the end of this array are undefined, drivers and338 bytes at the end of this array are undefined, drivers and
345 applications shall ignore them.339 applications shall ignore them.
346 340
347
348Packets are always passed in ascending line number order, without341Packets are always passed in ascending line number order, without
349duplicate line numbers. The :ref:`write() <func-write>` function and342duplicate line numbers. The :c:func:`write()` function and
350the :ref:`VIDIOC_QBUF` ioctl must return an ``EINVAL``343the :ref:`VIDIOC_QBUF` ioctl must return an ``EINVAL``
351error code when applications violate this rule. They must also return an344error code when applications violate this rule. They must also return an
352EINVAL error code when applications pass an incorrect field or line345EINVAL error code when applications pass an incorrect field or line
@@ -370,7 +363,6 @@ streaming (:ref:`memory mapping <mmap>` and/or · 17 unmodified lines
370:ref:`user pointer <userp>`) I/O. The latter bears the possibility of363:ref:`user pointer <userp>`) I/O. The latter bears the possibility of
371synchronizing video and VBI data by using buffer timestamps.364synchronizing video and VBI data by using buffer timestamps.
372 365
373
374Sliced VBI Data in MPEG Streams366Sliced VBI Data in MPEG Streams
375===============================367===============================
376 368
@@ -405,7 +397,6 @@ data insertion is not supported by the device. · 28 unmodified lines
405The following subsections specify the format of the embedded sliced VBI397The following subsections specify the format of the embedded sliced VBI
406data.398data.
407 399
408
409MPEG Stream Embedded, Sliced VBI Data Format: NONE400MPEG Stream Embedded, Sliced VBI Data Format: NONE
410--------------------------------------------------401--------------------------------------------------
411 402
@@ -417,7 +408,6 @@ nor driver shall insert "empty" embedded sliced VBI data packets in the · 5 unmodified lines
417MPEG stream when this format is set. No MPEG stream data structures are408MPEG stream when this format is set. No MPEG stream data structures are
418specified for this format.409specified for this format.
419 410
420
421MPEG Stream Embedded, Sliced VBI Data Format: IVTV411MPEG Stream Embedded, Sliced VBI Data Format: IVTV
422--------------------------------------------------412--------------------------------------------------
423 413
@@ -460,7 +450,6 @@ the end with unspecified fill bytes to align the end of the payload to a · 36 unmodified lines
460with 18 lines/field with 43 bytes of data/line and a 4 byte magic450with 18 lines/field with 43 bytes of data/line and a 4 byte magic
461number).451number).
462 452
463
464.. c:type:: v4l2_mpeg_vbi_fmt_ivtv453.. c:type:: v4l2_mpeg_vbi_fmt_ivtv
465 454
466struct v4l2_mpeg_vbi_fmt_ivtv455struct v4l2_mpeg_vbi_fmt_ivtv
@@ -523,7 +512,6 @@ Magic Constants for struct v4l2_mpeg_vbi_fmt_ivtv magic field · 56 unmodified lines
523 valid and that 36 lines of sliced VBI data are present.512 valid and that 36 lines of sliced VBI data are present.
524 513
525 514
526
527.. c:type:: v4l2_mpeg_vbi_itv0515.. c:type:: v4l2_mpeg_vbi_itv0
528 516
529.. c:type:: v4l2_mpeg_vbi_ITV0517.. c:type:: v4l2_mpeg_vbi_ITV0
@@ -548,7 +536,6 @@ structs v4l2_mpeg_vbi_itv0 and v4l2_mpeg_vbi_ITV0 · 18 unmodified lines
548 value:536 value:
549 537
550 538
551
552 ::539 ::
553 540
554 linemask[0] b0: line 6 first field541 linemask[0] b0: line 6 first field
@@ -574,7 +561,6 @@ structs v4l2_mpeg_vbi_itv0 and v4l2_mpeg_vbi_ITV0 · 19 unmodified lines
574 applications.561 applications.
575 562
576 563
577
578.. _v4l2-mpeg-vbi-itv0-1:564.. _v4l2-mpeg-vbi-itv0-1:
579 565
580struct v4l2_mpeg_vbi_ITV0566struct v4l2_mpeg_vbi_ITV0
@@ -596,7 +582,6 @@ struct v4l2_mpeg_vbi_ITV0 · 15 unmodified lines
596 lines 6 through 23 of the second field.582 lines 6 through 23 of the second field.
597 583
598 584
599
600.. c:type:: v4l2_mpeg_vbi_itv0_line585.. c:type:: v4l2_mpeg_vbi_itv0_line
601 586
602struct v4l2_mpeg_vbi_itv0_line587struct v4l2_mpeg_vbi_itv0_line
@@ -619,7 +604,6 @@ struct v4l2_mpeg_vbi_itv0_line · 16 unmodified lines
619 - The sliced VBI data for the line.604 - The sliced VBI data for the line.
620 605
621 606
622
623.. _ITV0-Line-Identifier-Constants:607.. _ITV0-Line-Identifier-Constants:
624 608
625Line Identifiers for struct v4l2_mpeg_vbi_itv0_line id field609Line Identifiers for struct v4l2_mpeg_vbi_itv0_line id field
@@ -653,7 +637,6 @@ Line Identifiers for struct v4l2_mpeg_vbi_itv0_line id field · 27 unmodified lines
653 description of the line payload.637 description of the line payload.
654 638
655 639
656
657.. [#f1]640.. [#f1]
658 According to :ref:`ETS 300 706 <ets300706>` lines 6-22 of the first641 According to :ref:`ETS 300 706 <ets300706>` lines 6-22 of the first
659 field and lines 5-22 of the second field may carry Teletext data.642 field and lines 5-22 of the second field may carry Teletext data.
Documentation/userspace-api/media/v4l/diff-v4l.rst+6−33
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _diff-v4l:4.. _diff-v4l:
4 5
@@ -13,7 +14,6 @@ the much improved V4L2 API replaces the V4L API. The support for the old · 8 unmodified lines
13V4L calls were removed from Kernel, but the library :ref:`libv4l`14V4L calls were removed from Kernel, but the library :ref:`libv4l`
14supports the conversion of a V4L API system call into a V4L2 one.15supports the conversion of a V4L API system call into a V4L2 one.
15 16
16
17Opening and Closing Devices17Opening and Closing Devices
18===========================18===========================
19 19
@@ -32,7 +32,6 @@ recommend that V4L2 drivers by default register devices with the same · 12 unmodified lines
32numbers, but the system administrator can assign arbitrary minor numbers32numbers, but the system administrator can assign arbitrary minor numbers
33using driver module options. The major device number remains 81.33using driver module options. The major device number remains 81.
34 34
35
36.. _v4l-dev:35.. _v4l-dev:
37 36
38.. flat-table:: V4L Device Types, Names and Numbers37.. flat-table:: V4L Device Types, Names and Numbers
@@ -53,14 +52,12 @@ using driver module options. The major device number remains 81. · 14 unmodified lines
53 - ``/dev/vbi``, ``/dev/vbi0`` to ``/dev/vbi31``52 - ``/dev/vbi``, ``/dev/vbi0`` to ``/dev/vbi31``
54 - 224-25553 - 224-255
55 54
56
57V4L prohibits (or used to prohibit) multiple opens of a device file.55V4L prohibits (or used to prohibit) multiple opens of a device file.
58V4L2 drivers *may* support multiple opens, see :ref:`open` for details56V4L2 drivers *may* support multiple opens, see :ref:`open` for details
59and consequences.57and consequences.
60 58
61V4L drivers respond to V4L2 ioctls with an ``EINVAL`` error code.59V4L drivers respond to V4L2 ioctls with an ``EINVAL`` error code.
62 60
63
64Querying Capabilities61Querying Capabilities
65=====================62=====================
66 63
@@ -151,7 +148,6 @@ introduction. · 84 unmodified lines
151 - ``-``148 - ``-``
152 - See above.149 - See above.
153 150
154
155The ``audios`` field was replaced by ``capabilities`` flag151The ``audios`` field was replaced by ``capabilities`` flag
156``V4L2_CAP_AUDIO``, indicating *if* the device has any audio inputs or152``V4L2_CAP_AUDIO``, indicating *if* the device has any audio inputs or
157outputs. To determine their number applications can enumerate audio153outputs. To determine their number applications can enumerate audio
@@ -164,7 +160,6 @@ were removed. Calling the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` or · 6 unmodified lines
164dimensions returns the closest size possible, taking into account the160dimensions returns the closest size possible, taking into account the
165current video standard, cropping and scaling limitations.161current video standard, cropping and scaling limitations.
166 162
167
168Video Sources163Video Sources
169=============164=============
170 165
@@ -180,7 +175,6 @@ The ``channel`` field counting inputs was renamed to ``index``, the · 9 unmodified lines
180video input types were renamed as follows:175video input types were renamed as follows:
181 176
182 177
183
184.. flat-table::178.. flat-table::
185 :header-rows: 1179 :header-rows: 1
186 :stub-columns: 0180 :stub-columns: 0
@@ -192,7 +186,6 @@ video input types were renamed as follows: · 5 unmodified lines
192 * - ``VIDEO_TYPE_CAMERA``186 * - ``VIDEO_TYPE_CAMERA``
193 - ``V4L2_INPUT_TYPE_CAMERA``187 - ``V4L2_INPUT_TYPE_CAMERA``
194 188
195
196Unlike the ``tuners`` field expressing the number of tuners of this189Unlike the ``tuners`` field expressing the number of tuners of this
197input, V4L2 assumes each video input is connected to at most one tuner.190input, V4L2 assumes each video input is connected to at most one tuner.
198However a tuner can have more than one input, i. e. RF connectors, and a191However a tuner can have more than one input, i. e. RF connectors, and a
@@ -216,7 +209,6 @@ addition together with the ``norm`` field and has been removed in the · 17 unmodified lines
216meantime. V4L2 has a similar, albeit more comprehensive approach to209meantime. V4L2 has a similar, albeit more comprehensive approach to
217video standards, see :ref:`standard` for more information.210video standards, see :ref:`standard` for more information.
218 211
219
220Tuning212Tuning
221======213======
222 214
@@ -260,7 +252,6 @@ frequency where renamed to · 37 unmodified lines
260to a struct :c:type:`v4l2_frequency` instead of an252to a struct :c:type:`v4l2_frequency` instead of an
261unsigned long integer.253unsigned long integer.
262 254
263
264.. _v4l-image-properties:255.. _v4l-image-properties:
265 256
266Image Properties257Image Properties
@@ -274,7 +265,6 @@ replaced by V4L2 controls accessible with the · 7 unmodified lines
274:ref:`VIDIOC_S_CTRL <VIDIOC_G_CTRL>` ioctls:265:ref:`VIDIOC_S_CTRL <VIDIOC_G_CTRL>` ioctls:
275 266
276 267
277
278.. flat-table::268.. flat-table::
279 :header-rows: 1269 :header-rows: 1
280 :stub-columns: 0270 :stub-columns: 0
@@ -292,7 +282,6 @@ replaced by V4L2 controls accessible with the · 11 unmodified lines
292 * - ``whiteness``282 * - ``whiteness``
293 - ``V4L2_CID_WHITENESS``283 - ``V4L2_CID_WHITENESS``
294 284
295
296The V4L picture controls are assumed to range from 0 to 65535 with no285The V4L picture controls are assumed to range from 0 to 65535 with no
297particular reset value. The V4L2 API permits arbitrary limits and286particular reset value. The V4L2 API permits arbitrary limits and
298defaults which can be queried with the287defaults which can be queried with the
@@ -306,7 +295,6 @@ of the image depth and others need not know. The ``palette`` field moved · 7 unmodified lines
306into the struct :c:type:`v4l2_pix_format`:295into the struct :c:type:`v4l2_pix_format`:
307 296
308 297
309
310.. flat-table::298.. flat-table::
311 :header-rows: 1299 :header-rows: 1
312 :stub-columns: 0300 :stub-columns: 0
@@ -346,11 +334,9 @@ into the struct :c:type:`v4l2_pix_format`: · 33 unmodified lines
346 * - ``VIDEO_PALETTE_YUV410P``334 * - ``VIDEO_PALETTE_YUV410P``
347 - :ref:`V4L2_PIX_FMT_YVU410 <V4L2-PIX-FMT-YVU410>`335 - :ref:`V4L2_PIX_FMT_YVU410 <V4L2-PIX-FMT-YVU410>`
348 336
349
350V4L2 image formats are defined in :ref:`pixfmt`. The image format can337V4L2 image formats are defined in :ref:`pixfmt`. The image format can
351be selected with the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl.338be selected with the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl.
352 339
353
354Audio340Audio
355=====341=====
356 342
@@ -384,7 +370,6 @@ The following fields where replaced by V4L2 controls accessible with the · 27 unmodified lines
384:ref:`VIDIOC_S_CTRL <VIDIOC_G_CTRL>` ioctls:370:ref:`VIDIOC_S_CTRL <VIDIOC_G_CTRL>` ioctls:
385 371
386 372
387
388.. flat-table::373.. flat-table::
389 :header-rows: 1374 :header-rows: 1
390 :stub-columns: 0375 :stub-columns: 0
@@ -400,7 +385,6 @@ The following fields where replaced by V4L2 controls accessible with the · 9 unmodified lines
400 * - ``balance``385 * - ``balance``
401 - ``V4L2_CID_AUDIO_BALANCE``386 - ``V4L2_CID_AUDIO_BALANCE``
402 387
403
404To determine which of these controls are supported by a driver V4L388To determine which of these controls are supported by a driver V4L
405provides the ``flags`` ``VIDEO_AUDIO_VOLUME``, ``VIDEO_AUDIO_BASS``,389provides the ``flags`` ``VIDEO_AUDIO_VOLUME``, ``VIDEO_AUDIO_BASS``,
406``VIDEO_AUDIO_TREBLE`` and ``VIDEO_AUDIO_BALANCE``. In the V4L2 API the390``VIDEO_AUDIO_TREBLE`` and ``VIDEO_AUDIO_BALANCE``. In the V4L2 API the
@@ -416,7 +400,6 @@ V4L2 API permits arbitrary limits and defaults which can be queried with · 9 unmodified lines
416the :ref:`VIDIOC_QUERYCTRL` ioctl. For general400the :ref:`VIDIOC_QUERYCTRL` ioctl. For general
417information about controls see :ref:`control`.401information about controls see :ref:`control`.
418 402
419
420Frame Buffer Overlay403Frame Buffer Overlay
421====================404====================
422 405
@@ -463,7 +446,6 @@ size is determined by ``w.width`` and ``w.height``. · 40 unmodified lines
463The ``VIDIOCCAPTURE`` ioctl to enable or disable overlay was renamed to446The ``VIDIOCCAPTURE`` ioctl to enable or disable overlay was renamed to
464:ref:`VIDIOC_OVERLAY`.447:ref:`VIDIOC_OVERLAY`.
465 448
466
467Cropping449Cropping
468========450========
469 451
@@ -490,21 +472,19 @@ struct :c:type:`v4l2_window`. These structures are used to · 20 unmodified lines
490select a capture or overlay format with the472select a capture or overlay format with the
491:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl.473:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl.
492 474
493
494Reading Images, Memory Mapping475Reading Images, Memory Mapping
495==============================476==============================
496 477
497
498Capturing using the read method478Capturing using the read method
499-------------------------------479-------------------------------
500 480
501There is no essential difference between reading images from a V4L or481There is no essential difference between reading images from a V4L or
502V4L2 device using the :ref:`read() <func-read>` function, however V4L2482V4L2 device using the :c:func:`read()` function, however V4L2
503drivers are not required to support this I/O method. Applications can483drivers are not required to support this I/O method. Applications can
504determine if the function is available with the484determine if the function is available with the
505:ref:`VIDIOC_QUERYCAP` ioctl. All V4L2 devices485:ref:`VIDIOC_QUERYCAP` ioctl. All V4L2 devices
506exchanging data with applications must support the486exchanging data with applications must support the
507:ref:`select() <func-select>` and :ref:`poll() <func-poll>`487:c:func:`select()` and :c:func:`poll()`
508functions.488functions.
509 489
510To select an image format and size, V4L provides the ``VIDIOCSPICT`` and490To select an image format and size, V4L provides the ``VIDIOCSPICT`` and
@@ -517,7 +497,6 @@ negotiation ioctls :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and · 6 unmodified lines
517 497
518For more information about the V4L2 read interface see :ref:`rw`.498For more information about the V4L2 read interface see :ref:`rw`.
519 499
520
521Capturing using memory mapping500Capturing using memory mapping
522------------------------------501------------------------------
523 502
@@ -528,7 +507,6 @@ read method. V4L2 supports memory mapping as well, with a few · 4 unmodified lines
528differences.507differences.
529 508
530 509
531
532.. flat-table::510.. flat-table::
533 :header-rows: 1511 :header-rows: 1
534 :stub-columns: 0512 :stub-columns: 0
@@ -550,7 +528,7 @@ differences. · 15 unmodified lines
550 ``VIDIOCGMBUF`` ioctl is available to query the number of buffers,528 ``VIDIOCGMBUF`` ioctl is available to query the number of buffers,
551 the offset of each buffer from the start of the virtual file, and529 the offset of each buffer from the start of the virtual file, and
552 the overall amount of memory used, which can be used as arguments530 the overall amount of memory used, which can be used as arguments
553 for the :ref:`mmap() <func-mmap>` function.531 for the :c:func:`mmap()` function.
554 - Buffers are individually mapped. The offset and size of each532 - Buffers are individually mapped. The offset and size of each
555 buffer can be determined with the533 buffer can be determined with the
556 :ref:`VIDIOC_QUERYBUF` ioctl.534 :ref:`VIDIOC_QUERYBUF` ioctl.
@@ -568,7 +546,7 @@ differences. · 11 unmodified lines
568 the incoming queue. Filled buffers are dequeued from the outgoing546 the incoming queue. Filled buffers are dequeued from the outgoing
569 queue with the :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl. To wait547 queue with the :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl. To wait
570 until filled buffers become available this function,548 until filled buffers become available this function,
571 :ref:`select() <func-select>` or :ref:`poll() <func-poll>` can549 :c:func:`select()` or :c:func:`poll()` can
572 be used. The :ref:`VIDIOC_STREAMON` ioctl550 be used. The :ref:`VIDIOC_STREAMON` ioctl
573 must be called once after enqueuing one or more buffers to start551 must be called once after enqueuing one or more buffers to start
574 capturing. Its counterpart552 capturing. Its counterpart
@@ -577,11 +555,9 @@ differences. · 2 unmodified lines
577 signal status, if known, with the555 signal status, if known, with the
578 :ref:`VIDIOC_ENUMINPUT` ioctl.556 :ref:`VIDIOC_ENUMINPUT` ioctl.
579 557
580
581For a more in-depth discussion of memory mapping and examples, see558For a more in-depth discussion of memory mapping and examples, see
582:ref:`mmap`.559:ref:`mmap`.
583 560
584
585Reading Raw VBI Data561Reading Raw VBI Data
586====================562====================
587 563
@@ -592,7 +568,6 @@ the V4L VBI interface. Reading from the device yields a raw VBI image · 4 unmodified lines
592with the following parameters:568with the following parameters:
593 569
594 570
595
596.. flat-table::571.. flat-table::
597 :header-rows: 1572 :header-rows: 1
598 :stub-columns: 0573 :stub-columns: 0
@@ -616,7 +591,6 @@ with the following parameters: · 17 unmodified lines
616 * - flags591 * - flags
617 - 0592 - 0
618 593
619
620Undocumented in the V4L specification, in Linux 2.3 the594Undocumented in the V4L specification, in Linux 2.3 the
621``VIDIOCGVBIFMT`` and ``VIDIOCSVBIFMT`` ioctls using struct595``VIDIOCGVBIFMT`` and ``VIDIOCSVBIFMT`` ioctls using struct
622``vbi_format`` were added to determine the VBI image596``vbi_format`` were added to determine the VBI image
@@ -630,11 +604,10 @@ remaining fields are probably equivalent to struct · 7 unmodified lines
630 604
631Apparently only the Zoran (ZR 36120) driver implements these ioctls. The605Apparently only the Zoran (ZR 36120) driver implements these ioctls. The
632semantics differ from those specified for V4L2 in two ways. The606semantics differ from those specified for V4L2 in two ways. The
633parameters are reset on :ref:`open() <func-open>` and607parameters are reset on :c:func:`open()` and
634``VIDIOCSVBIFMT`` always returns an ``EINVAL`` error code if the parameters608``VIDIOCSVBIFMT`` always returns an ``EINVAL`` error code if the parameters
635are invalid.609are invalid.
636 610
637
638Miscellaneous611Miscellaneous
639=============612=============
640 613
Documentation/userspace-api/media/v4l/dmabuf.rst+4−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _dmabuf:4.. _dmabuf:
4 5
@@ -36,7 +37,6 @@ are passed in struct :c:type:`v4l2_buffer` (or in struct · 31 unmodified lines
36driver must be switched into DMABUF I/O mode by calling the37driver must be switched into DMABUF I/O mode by calling the
37:ref:`VIDIOC_REQBUFS <VIDIOC_REQBUFS>` with the desired buffer type.38:ref:`VIDIOC_REQBUFS <VIDIOC_REQBUFS>` with the desired buffer type.
38 39
39
40Example: Initiating streaming I/O with DMABUF file descriptors40Example: Initiating streaming I/O with DMABUF file descriptors
41==============================================================41==============================================================
42 42
@@ -135,10 +135,10 @@ buffers it must wait until an empty buffer can be dequeued and reused. · 92 unmodified lines
135Two methods exist to suspend execution of the application until one or135Two methods exist to suspend execution of the application until one or
136more buffers can be dequeued. By default :ref:`VIDIOC_DQBUF136more buffers can be dequeued. By default :ref:`VIDIOC_DQBUF
137<VIDIOC_QBUF>` blocks when no buffer is in the outgoing queue. When the137<VIDIOC_QBUF>` blocks when no buffer is in the outgoing queue. When the
138``O_NONBLOCK`` flag was given to the :ref:`open() <func-open>` function,138``O_NONBLOCK`` flag was given to the :c:func:`open()` function,
139:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` returns immediately with an ``EAGAIN``139:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` returns immediately with an ``EAGAIN``
140error code when no buffer is available. The140error code when no buffer is available. The
141:ref:`select() <func-select>` and :ref:`poll() <func-poll>`141:c:func:`select()` and :c:func:`poll()`
142functions are always available.142functions are always available.
143 143
144To start and stop capturing or displaying applications call the144To start and stop capturing or displaying applications call the
@@ -158,5 +158,5 @@ Drivers implementing DMABUF importing I/O must support the · 13 unmodified lines
158:ref:`VIDIOC_REQBUFS <VIDIOC_REQBUFS>`, :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`,158:ref:`VIDIOC_REQBUFS <VIDIOC_REQBUFS>`, :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`,
159:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`, :ref:`VIDIOC_STREAMON159:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`, :ref:`VIDIOC_STREAMON
160<VIDIOC_STREAMON>` and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls,160<VIDIOC_STREAMON>` and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls,
161and the :ref:`select() <func-select>` and :ref:`poll() <func-poll>`161and the :c:func:`select()` and :c:func:`poll()`
162functions.162functions.
Documentation/userspace-api/media/v4l/format.rst+3−4
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _format:4.. _format:
4 5
@@ -6,7 +7,6 @@ · 1 unmodified line
6Data Formats7Data Formats
7************8************
8 9
9
10Data Format Negotiation10Data Format Negotiation
11=======================11=======================
12 12
@@ -53,8 +53,8 @@ image size. · 40 unmodified lines
53When applications omit the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl its locking side53When applications omit the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl its locking side
54effects are implied by the next step, the selection of an I/O method54effects are implied by the next step, the selection of an I/O method
55with the :ref:`VIDIOC_REQBUFS` ioctl or implicit55with the :ref:`VIDIOC_REQBUFS` ioctl or implicit
56with the first :ref:`read() <func-read>` or56with the first :c:func:`read()` or
57:ref:`write() <func-write>` call.57:c:func:`write()` call.
58 58
59Generally only one logical stream can be assigned to a file descriptor,59Generally only one logical stream can be assigned to a file descriptor,
60the exception being drivers permitting simultaneous video capturing and60the exception being drivers permitting simultaneous video capturing and
@@ -67,7 +67,6 @@ All drivers exchanging data with applications must support the · 6 unmodified lines
67:ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl. Implementation of the67:ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl. Implementation of the
68:ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` is highly recommended but optional.68:ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` is highly recommended but optional.
69 69
70
71Image Format Enumeration70Image Format Enumeration
72========================71========================
73 72
Documentation/userspace-api/media/v4l/func-close.rst+2−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-close:4.. _func-close:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-close - Close a V4L2 device13v4l2-close - Close a V4L2 device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,16 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: int close( int fd )22.. c:function:: int close( int fd )
24 :name: v4l2-close
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :ref:`open() <func-open>`.28 File descriptor returned by :c:func:`open()`.
31
32 29
33Description30Description
34===========31===========
@@ -38,7 +35,6 @@ associated with the file descriptor are freed. However data format · 3 unmodified lines
38parameters, current input or output, control values or other properties35parameters, current input or output, control values or other properties
39remain unchanged.36remain unchanged.
40 37
41
42Return Value38Return Value
43============39============
44 40
Documentation/userspace-api/media/v4l/func-ioctl.rst+3−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-ioctl:4.. _func-ioctl:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-ioctl - Program a V4L2 device13v4l2-ioctl - Program a V4L2 device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,15 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <sys/ioctl.h>20 #include <sys/ioctl.h>
21 21
22 22``int ioctl(int fd, int request, void *argp)``
23.. c:function:: int ioctl( int fd, int request, void *argp )
24 :name: v4l2-ioctl
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :ref:`open() <func-open>`.28 File descriptor returned by :c:func:`open()`.
31 29
32``request``30``request``
33 V4L2 ioctl request code as defined in the ``videodev2.h`` header31 V4L2 ioctl request code as defined in the ``videodev2.h`` header
@@ -36,7 +34,6 @@ Arguments · 2 unmodified lines
36``argp``34``argp``
37 Pointer to a function parameter, usually a structure.35 Pointer to a function parameter, usually a structure.
38 36
39
40Description37Description
41===========38===========
42 39
@@ -50,7 +47,6 @@ include the version in the kernel sources on the system they compile on. · 7 unmodified lines
50All V4L2 ioctl requests, their respective function and parameters are47All V4L2 ioctl requests, their respective function and parameters are
51specified in :ref:`user-func`.48specified in :ref:`user-func`.
52 49
53
54Return Value50Return Value
55============51============
56 52
Documentation/userspace-api/media/v4l/func-mmap.rst+7−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-mmap:4.. _func-mmap:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-mmap - Map device memory into application address space13v4l2-mmap - Map device memory into application address space
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -20,9 +20,7 @@ Synopsis · 2 unmodified lines
20 #include <unistd.h>20 #include <unistd.h>
21 #include <sys/mman.h>21 #include <sys/mman.h>
22 22
23
24.. c:function:: void *mmap( void *start, size_t length, int prot, int flags, int fd, off_t offset )23.. c:function:: void *mmap( void *start, size_t length, int prot, int flags, int fd, off_t offset )
25 :name: v4l2-mmap
26 24
27Arguments25Arguments
28=========26=========
@@ -54,7 +52,7 @@ Arguments · 25 unmodified lines
54 #. The Linux ``videobuf`` kernel module, which is used by some52 #. The Linux ``videobuf`` kernel module, which is used by some
55 drivers supports only ``PROT_READ`` | ``PROT_WRITE``. When the53 drivers supports only ``PROT_READ`` | ``PROT_WRITE``. When the
56 driver does not support the desired protection, the54 driver does not support the desired protection, the
57 :ref:`mmap() <func-mmap>` function fails.55 :c:func:`mmap()` function fails.
58 56
59 #. Device memory accesses (e. g. the memory on a graphics card57 #. Device memory accesses (e. g. the memory on a graphics card
60 with video capturing hardware) may incur a performance penalty58 with video capturing hardware) may incur a performance penalty
@@ -70,7 +68,7 @@ Arguments · 9 unmodified lines
70 68
71 ``MAP_FIXED`` requests that the driver selects no other address than69 ``MAP_FIXED`` requests that the driver selects no other address than
72 the one specified. If the specified address cannot be used,70 the one specified. If the specified address cannot be used,
73 :ref:`mmap() <func-mmap>` will fail. If ``MAP_FIXED`` is specified,71 :c:func:`mmap()` will fail. If ``MAP_FIXED`` is specified,
74 ``start`` must be a multiple of the pagesize. Use of this option is72 ``start`` must be a multiple of the pagesize. Use of this option is
75 discouraged.73 discouraged.
76 74
@@ -87,7 +85,7 @@ Arguments · 10 unmodified lines
87 flags.85 flags.
88 86
89``fd``87``fd``
90 File descriptor returned by :ref:`open() <func-open>`.88 File descriptor returned by :c:func:`open()`.
91 89
92``offset``90``offset``
93 Offset of the buffer in device memory. This must be the same value91 Offset of the buffer in device memory. This must be the same value
@@ -97,11 +95,10 @@ Arguments · 3 unmodified lines
97 in the struct :c:type:`v4l2_plane` ``m`` union95 in the struct :c:type:`v4l2_plane` ``m`` union
98 ``mem_offset`` field for the multi-planar API.96 ``mem_offset`` field for the multi-planar API.
99 97
100
101Description98Description
102===========99===========
103 100
104The :ref:`mmap() <func-mmap>` function asks to map ``length`` bytes starting at101The :c:func:`mmap()` function asks to map ``length`` bytes starting at
105``offset`` in the memory of the device specified by ``fd`` into the102``offset`` in the memory of the device specified by ``fd`` into the
106application address space, preferably at address ``start``. This latter103application address space, preferably at address ``start``. This latter
107address is a hint only, and is usually specified as 0.104address is a hint only, and is usually specified as 0.
@@ -111,13 +108,12 @@ Suitable length and offset parameters are queried with the · 3 unmodified lines
111allocated with the :ref:`VIDIOC_REQBUFS` ioctl108allocated with the :ref:`VIDIOC_REQBUFS` ioctl
112before they can be queried.109before they can be queried.
113 110
114To unmap buffers the :ref:`munmap() <func-munmap>` function is used.111To unmap buffers the :c:func:`munmap()` function is used.
115
116 112
117Return Value113Return Value
118============114============
119 115
120On success :ref:`mmap() <func-mmap>` returns a pointer to the mapped buffer. On116On success :c:func:`mmap()` returns a pointer to the mapped buffer. On
121error ``MAP_FAILED`` (-1) is returned, and the ``errno`` variable is set117error ``MAP_FAILED`` (-1) is returned, and the ``errno`` variable is set
122appropriately. Possible error codes are:118appropriately. Possible error codes are:
123 119
Documentation/userspace-api/media/v4l/func-munmap.rst+5−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-munmap:4.. _func-munmap:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-munmap - Unmap device memory13v4l2-munmap - Unmap device memory
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -20,37 +20,33 @@ Synopsis · 2 unmodified lines
20 #include <unistd.h>20 #include <unistd.h>
21 #include <sys/mman.h>21 #include <sys/mman.h>
22 22
23
24.. c:function:: int munmap( void *start, size_t length )23.. c:function:: int munmap( void *start, size_t length )
25 :name: v4l2-munmap
26 24
27Arguments25Arguments
28=========26=========
29 27
30``start``28``start``
31 Address of the mapped buffer as returned by the29 Address of the mapped buffer as returned by the
32 :ref:`mmap() <func-mmap>` function.30 :c:func:`mmap()` function.
33 31
34``length``32``length``
35 Length of the mapped buffer. This must be the same value as given to33 Length of the mapped buffer. This must be the same value as given to
36 :ref:`mmap() <func-mmap>` and returned by the driver in the struct34 :c:func:`mmap()` and returned by the driver in the struct
37 :c:type:`v4l2_buffer` ``length`` field for the35 :c:type:`v4l2_buffer` ``length`` field for the
38 single-planar API and in the struct36 single-planar API and in the struct
39 :c:type:`v4l2_plane` ``length`` field for the37 :c:type:`v4l2_plane` ``length`` field for the
40 multi-planar API.38 multi-planar API.
41 39
42
43Description40Description
44===========41===========
45 42
46Unmaps a previously with the :ref:`mmap() <func-mmap>` function mapped43Unmaps a previously with the :c:func:`mmap()` function mapped
47buffer and frees it, if possible.44buffer and frees it, if possible.
48 45
49
50Return Value46Return Value
51============47============
52 48
53On success :ref:`munmap() <func-munmap>` returns 0, on failure -1 and the49On success :c:func:`munmap()` returns 0, on failure -1 and the
54``errno`` variable is set appropriately:50``errno`` variable is set appropriately:
55 51
56EINVAL52EINVAL
Documentation/userspace-api/media/v4l/func-open.rst+5−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-open:4.. _func-open:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-open - Open a V4L2 device13v4l2-open - Open a V4L2 device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,9 +19,7 @@ Synopsis · 1 unmodified line
19 19
20 #include <fcntl.h>20 #include <fcntl.h>
21 21
22
23.. c:function:: int open( const char *device_name, int flags )22.. c:function:: int open( const char *device_name, int flags )
24 :name: v4l2-open
25 23
26Arguments24Arguments
27=========25=========
@@ -34,7 +32,7 @@ Arguments · 6 unmodified lines
34 technicality, input devices still support only reading and output32 technicality, input devices still support only reading and output
35 devices only writing.33 devices only writing.
36 34
37 When the ``O_NONBLOCK`` flag is given, the :ref:`read() <func-read>`35 When the ``O_NONBLOCK`` flag is given, the :c:func:`read()`
38 function and the :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl will36 function and the :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl will
39 return the ``EAGAIN`` error code when no data is available or no37 return the ``EAGAIN`` error code when no data is available or no
40 buffer is in the driver outgoing queue, otherwise these functions38 buffer is in the driver outgoing queue, otherwise these functions
@@ -43,22 +41,20 @@ Arguments · 2 unmodified lines
43 41
44 Other flags have no effect.42 Other flags have no effect.
45 43
46
47Description44Description
48===========45===========
49 46
50To open a V4L2 device applications call :ref:`open() <func-open>` with the47To open a V4L2 device applications call :c:func:`open()` with the
51desired device name. This function has no side effects; all data format48desired device name. This function has no side effects; all data format
52parameters, current input or output, control values or other properties49parameters, current input or output, control values or other properties
53remain unchanged. At the first :ref:`open() <func-open>` call after loading the50remain unchanged. At the first :c:func:`open()` call after loading the
54driver they will be reset to default values, drivers are never in an51driver they will be reset to default values, drivers are never in an
55undefined state.52undefined state.
56 53
57
58Return Value54Return Value
59============55============
60 56
61On success :ref:`open() <func-open>` returns the new file descriptor. On error57On success :c:func:`open()` returns the new file descriptor. On error
62-1 is returned, and the ``errno`` variable is set appropriately.58-1 is returned, and the ``errno`` variable is set appropriately.
63Possible error codes are:59Possible error codes are:
64 60
Documentation/userspace-api/media/v4l/func-poll.rst+18−22
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-poll:4.. _func-poll:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-poll - Wait for some event on a file descriptor13v4l2-poll - Wait for some event on a file descriptor
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,19 +19,16 @@ Synopsis · 1 unmodified line
19 19
20 #include <sys/poll.h>20 #include <sys/poll.h>
21 21
22
23.. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )22.. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )
24 :name: v4l2-poll
25 23
26Arguments24Arguments
27=========25=========
28 26
29 27
30
31Description28Description
32===========29===========
33 30
34With the :ref:`poll() <func-poll>` function applications can suspend execution31With the :c:func:`poll()` function applications can suspend execution
35until the driver has captured data or is ready to accept data for32until the driver has captured data or is ready to accept data for
36output.33output.
37 34
@@ -44,57 +41,56 @@ display. When buffers are already in the outgoing queue of the driver · 6 unmodified lines
44(capture) or the incoming queue isn't full (display) the function41(capture) or the incoming queue isn't full (display) the function
45returns immediately.42returns immediately.
46 43
47On success :ref:`poll() <func-poll>` returns the number of file descriptors44On success :c:func:`poll()` returns the number of file descriptors
48that have been selected (that is, file descriptors for which the45that have been selected (that is, file descriptors for which the
49``revents`` field of the respective :c:func:`struct pollfd` structure46``revents`` field of the respective ``struct pollfd`` structure
50is non-zero). Capture devices set the ``POLLIN`` and ``POLLRDNORM``47is non-zero). Capture devices set the ``POLLIN`` and ``POLLRDNORM``
51flags in the ``revents`` field, output devices the ``POLLOUT`` and48flags in the ``revents`` field, output devices the ``POLLOUT`` and
52``POLLWRNORM`` flags. When the function timed out it returns a value of49``POLLWRNORM`` flags. When the function timed out it returns a value of
53zero, on failure it returns -1 and the ``errno`` variable is set50zero, on failure it returns -1 and the ``errno`` variable is set
54appropriately. When the application did not call51appropriately. When the application did not call
55:ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` the :ref:`poll() <func-poll>`52:ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` the :c:func:`poll()`
56function succeeds, but sets the ``POLLERR`` flag in the ``revents``53function succeeds, but sets the ``POLLERR`` flag in the ``revents``
57field. When the application has called54field. When the application has called
58:ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` for a capture device but55:ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` for a capture device but
59hasn't yet called :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`, the56hasn't yet called :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`, the
60:ref:`poll() <func-poll>` function succeeds and sets the ``POLLERR`` flag in57:c:func:`poll()` function succeeds and sets the ``POLLERR`` flag in
61the ``revents`` field. For output devices this same situation will cause58the ``revents`` field. For output devices this same situation will cause
62:ref:`poll() <func-poll>` to succeed as well, but it sets the ``POLLOUT`` and59:c:func:`poll()` to succeed as well, but it sets the ``POLLOUT`` and
63``POLLWRNORM`` flags in the ``revents`` field.60``POLLWRNORM`` flags in the ``revents`` field.
64 61
65If an event occurred (see :ref:`VIDIOC_DQEVENT`)62If an event occurred (see :ref:`VIDIOC_DQEVENT`)
66then ``POLLPRI`` will be set in the ``revents`` field and63then ``POLLPRI`` will be set in the ``revents`` field and
67:ref:`poll() <func-poll>` will return.64:c:func:`poll()` will return.
68 65
69When use of the :ref:`read() <func-read>` function has been negotiated and the66When use of the :c:func:`read()` function has been negotiated and the
70driver does not capture yet, the :ref:`poll() <func-poll>` function starts67driver does not capture yet, the :c:func:`poll()` function starts
71capturing. When that fails it returns a ``POLLERR`` as above. Otherwise68capturing. When that fails it returns a ``POLLERR`` as above. Otherwise
72it waits until data has been captured and can be read. When the driver69it waits until data has been captured and can be read. When the driver
73captures continuously (as opposed to, for example, still images) the70captures continuously (as opposed to, for example, still images) the
74function may return immediately.71function may return immediately.
75 72
76When use of the :ref:`write() <func-write>` function has been negotiated and the73When use of the :c:func:`write()` function has been negotiated and the
77driver does not stream yet, the :ref:`poll() <func-poll>` function starts74driver does not stream yet, the :c:func:`poll()` function starts
78streaming. When that fails it returns a ``POLLERR`` as above. Otherwise75streaming. When that fails it returns a ``POLLERR`` as above. Otherwise
79it waits until the driver is ready for a non-blocking76it waits until the driver is ready for a non-blocking
80:ref:`write() <func-write>` call.77:c:func:`write()` call.
81 78
82If the caller is only interested in events (just ``POLLPRI`` is set in79If the caller is only interested in events (just ``POLLPRI`` is set in
83the ``events`` field), then :ref:`poll() <func-poll>` will *not* start80the ``events`` field), then :c:func:`poll()` will *not* start
84streaming if the driver does not stream yet. This makes it possible to81streaming if the driver does not stream yet. This makes it possible to
85just poll for events and not for buffers.82just poll for events and not for buffers.
86 83
87All drivers implementing the :ref:`read() <func-read>` or :ref:`write() <func-write>`84All drivers implementing the :c:func:`read()` or :c:func:`write()`
88function or streaming I/O must also support the :ref:`poll() <func-poll>`85function or streaming I/O must also support the :c:func:`poll()`
89function.86function.
90 87
91For more details see the :ref:`poll() <func-poll>` manual page.88For more details see the :c:func:`poll()` manual page.
92
93 89
94Return Value90Return Value
95============91============
96 92
97On success, :ref:`poll() <func-poll>` returns the number structures which have93On success, :c:func:`poll()` returns the number structures which have
98non-zero ``revents`` fields, or zero if the call timed out. On error -194non-zero ``revents`` fields, or zero if the call timed out. On error -1
99is returned, and the ``errno`` variable is set appropriately:95is returned, and the ``errno`` variable is set appropriately:
100 96
Documentation/userspace-api/media/v4l/func-read.rst+18−21
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-read:4.. _func-read:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-read - Read from a V4L2 device13v4l2-read - Read from a V4L2 device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,15 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: ssize_t read( int fd, void *buf, size_t count )22.. c:function:: ssize_t read( int fd, void *buf, size_t count )
24 :name: v4l2-read
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :ref:`open() <func-open>`.28 File descriptor returned by :c:func:`open()`.
31 29
32``buf``30``buf``
33 Buffer to be filled31 Buffer to be filled
@@ -38,48 +36,48 @@ Arguments · 4 unmodified lines
38Description36Description
39===========37===========
40 38
41:ref:`read() <func-read>` attempts to read up to ``count`` bytes from file39:c:func:`read()` attempts to read up to ``count`` bytes from file
42descriptor ``fd`` into the buffer starting at ``buf``. The layout of the40descriptor ``fd`` into the buffer starting at ``buf``. The layout of the
43data in the buffer is discussed in the respective device interface41data in the buffer is discussed in the respective device interface
44section, see ##. If ``count`` is zero, :ref:`read() <func-read>` returns zero42section, see ##. If ``count`` is zero, :c:func:`read()` returns zero
45and has no other results. If ``count`` is greater than ``SSIZE_MAX``,43and has no other results. If ``count`` is greater than ``SSIZE_MAX``,
46the result is unspecified. Regardless of the ``count`` value each44the result is unspecified. Regardless of the ``count`` value each
47:ref:`read() <func-read>` call will provide at most one frame (two fields)45:c:func:`read()` call will provide at most one frame (two fields)
48worth of data.46worth of data.
49 47
50By default :ref:`read() <func-read>` blocks until data becomes available. When48By default :c:func:`read()` blocks until data becomes available. When
51the ``O_NONBLOCK`` flag was given to the :ref:`open() <func-open>`49the ``O_NONBLOCK`` flag was given to the :c:func:`open()`
52function it returns immediately with an ``EAGAIN`` error code when no data50function it returns immediately with an ``EAGAIN`` error code when no data
53is available. The :ref:`select() <func-select>` or51is available. The :c:func:`select()` or
54:ref:`poll() <func-poll>` functions can always be used to suspend52:c:func:`poll()` functions can always be used to suspend
55execution until data becomes available. All drivers supporting the53execution until data becomes available. All drivers supporting the
56:ref:`read() <func-read>` function must also support :ref:`select() <func-select>` and54:c:func:`read()` function must also support :c:func:`select()` and
57:ref:`poll() <func-poll>`.55:c:func:`poll()`.
58 56
59Drivers can implement read functionality in different ways, using a57Drivers can implement read functionality in different ways, using a
60single or multiple buffers and discarding the oldest or newest frames58single or multiple buffers and discarding the oldest or newest frames
61once the internal buffers are filled.59once the internal buffers are filled.
62 60
63:ref:`read() <func-read>` never returns a "snapshot" of a buffer being filled.61:c:func:`read()` never returns a "snapshot" of a buffer being filled.
64Using a single buffer the driver will stop capturing when the62Using a single buffer the driver will stop capturing when the
65application starts reading the buffer until the read is finished. Thus63application starts reading the buffer until the read is finished. Thus
66only the period of the vertical blanking interval is available for64only the period of the vertical blanking interval is available for
67reading, or the capture rate must fall below the nominal frame rate of65reading, or the capture rate must fall below the nominal frame rate of
68the video standard.66the video standard.
69 67
70The behavior of :ref:`read() <func-read>` when called during the active picture68The behavior of :c:func:`read()` when called during the active picture
71period or the vertical blanking separating the top and bottom field69period or the vertical blanking separating the top and bottom field
72depends on the discarding policy. A driver discarding the oldest frames70depends on the discarding policy. A driver discarding the oldest frames
73keeps capturing into an internal buffer, continuously overwriting the71keeps capturing into an internal buffer, continuously overwriting the
74previously, not read frame, and returns the frame being received at the72previously, not read frame, and returns the frame being received at the
75time of the :ref:`read() <func-read>` call as soon as it is complete.73time of the :c:func:`read()` call as soon as it is complete.
76 74
77A driver discarding the newest frames stops capturing until the next75A driver discarding the newest frames stops capturing until the next
78:ref:`read() <func-read>` call. The frame being received at :ref:`read() <func-read>`76:c:func:`read()` call. The frame being received at :c:func:`read()`
79time is discarded, returning the following frame instead. Again this77time is discarded, returning the following frame instead. Again this
80implies a reduction of the capture rate to one half or less of the78implies a reduction of the capture rate to one half or less of the
81nominal frame rate. An example of this model is the video read mode of79nominal frame rate. An example of this model is the video read mode of
82the bttv driver, initiating a DMA to user memory when :ref:`read() <func-read>`80the bttv driver, initiating a DMA to user memory when :c:func:`read()`
83is called and returning when the DMA finished.81is called and returning when the DMA finished.
84 82
85In the multiple buffer model drivers maintain a ring of internal83In the multiple buffer model drivers maintain a ring of internal
@@ -94,14 +92,13 @@ the driver with the :ref:`VIDIOC_G_PARM <VIDIOC_G_PARM>` and · 8 unmodified lines
94however. The discarding policy is not reported and cannot be changed.92however. The discarding policy is not reported and cannot be changed.
95For minimum requirements see :ref:`devices`.93For minimum requirements see :ref:`devices`.
96 94
97
98Return Value95Return Value
99============96============
100 97
101On success, the number of bytes read is returned. It is not an error if98On success, the number of bytes read is returned. It is not an error if
102this number is smaller than the number of bytes requested, or the amount99this number is smaller than the number of bytes requested, or the amount
103of data required for one frame. This may happen for example because100of data required for one frame. This may happen for example because
104:ref:`read() <func-read>` was interrupted by a signal. On error, -1 is101:c:func:`read()` was interrupted by a signal. On error, -1 is
105returned, and the ``errno`` variable is set appropriately. In this case102returned, and the ``errno`` variable is set appropriately. In this case
106the next read will start at the beginning of a new frame. Possible error103the next read will start at the beginning of a new frame. Possible error
107codes are:104codes are:
@@ -129,5 +126,5 @@ EIO · 21 unmodified lines
129 communicate with a remote device (USB camera etc.).126 communicate with a remote device (USB camera etc.).
130 127
131EINVAL128EINVAL
132 The :ref:`read() <func-read>` function is not supported by this driver, not129 The :c:func:`read()` function is not supported by this driver, not
133 on this device, or generally not on this type of device.130 on this device, or generally not on this type of device.
Documentation/userspace-api/media/v4l/func-select.rst+19−23
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-select:4.. _func-select:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-select - Synchronous I/O multiplexing13v4l2-select - Synchronous I/O multiplexing
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -21,9 +21,7 @@ Synopsis · 3 unmodified lines
21 #include <sys/types.h>21 #include <sys/types.h>
22 #include <unistd.h>22 #include <unistd.h>
23 23
24
25.. c:function:: int select( int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, struct timeval *timeout )24.. c:function:: int select( int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, struct timeval *timeout )
26 :name: v4l2-select
27 25
28Arguments26Arguments
29=========27=========
@@ -43,11 +41,10 @@ Arguments · 13 unmodified lines
43``timeout``41``timeout``
44 Maximum time to wait.42 Maximum time to wait.
45 43
46
47Description44Description
48===========45===========
49 46
50With the :ref:`select() <func-select>` function applications can suspend47With the :c:func:`select()` function applications can suspend
51execution until the driver has captured data or is ready to accept data48execution until the driver has captured data or is ready to accept data
52for output.49for output.
53 50
@@ -56,40 +53,39 @@ buffer has been filled or displayed and can be dequeued with the · 2 unmodified lines
56:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl. When buffers are already in53:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctl. When buffers are already in
57the outgoing queue of the driver the function returns immediately.54the outgoing queue of the driver the function returns immediately.
58 55
59On success :ref:`select() <func-select>` returns the total number of bits set in56On success :c:func:`select()` returns the total number of bits set in
60:c:func:`struct fd_set`. When the function timed out it returns57``fd_set``. When the function timed out it returns
61a value of zero. On failure it returns -1 and the ``errno`` variable is58a value of zero. On failure it returns -1 and the ``errno`` variable is
62set appropriately. When the application did not call59set appropriately. When the application did not call
63:ref:`VIDIOC_QBUF` or60:ref:`VIDIOC_QBUF` or
64:ref:`VIDIOC_STREAMON` yet the :ref:`select() <func-select>`61:ref:`VIDIOC_STREAMON` yet the :c:func:`select()`
65function succeeds, setting the bit of the file descriptor in ``readfds``62function succeeds, setting the bit of the file descriptor in ``readfds``
66or ``writefds``, but subsequent :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`63or ``writefds``, but subsequent :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`
67calls will fail. [#f1]_64calls will fail. [#f1]_
68 65
69When use of the :ref:`read() <func-read>` function has been negotiated and the66When use of the :c:func:`read()` function has been negotiated and the
70driver does not capture yet, the :ref:`select() <func-select>` function starts67driver does not capture yet, the :c:func:`select()` function starts
71capturing. When that fails, :ref:`select() <func-select>` returns successful and68capturing. When that fails, :c:func:`select()` returns successful and
72a subsequent :ref:`read() <func-read>` call, which also attempts to start69a subsequent :c:func:`read()` call, which also attempts to start
73capturing, will return an appropriate error code. When the driver70capturing, will return an appropriate error code. When the driver
74captures continuously (as opposed to, for example, still images) and71captures continuously (as opposed to, for example, still images) and
75data is already available the :ref:`select() <func-select>` function returns72data is already available the :c:func:`select()` function returns
76immediately.73immediately.
77 74
78When use of the :ref:`write() <func-write>` function has been negotiated the75When use of the :c:func:`write()` function has been negotiated the
79:ref:`select() <func-select>` function just waits until the driver is ready for a76:c:func:`select()` function just waits until the driver is ready for a
80non-blocking :ref:`write() <func-write>` call.77non-blocking :c:func:`write()` call.
81 78
82All drivers implementing the :ref:`read() <func-read>` or :ref:`write() <func-write>`79All drivers implementing the :c:func:`read()` or :c:func:`write()`
83function or streaming I/O must also support the :ref:`select() <func-select>`80function or streaming I/O must also support the :c:func:`select()`
84function.81function.
85 82
86For more details see the :ref:`select() <func-select>` manual page.83For more details see the :c:func:`select()` manual page.
87
88 84
89Return Value85Return Value
90============86============
91 87
92On success, :ref:`select() <func-select>` returns the number of descriptors88On success, :c:func:`select()` returns the number of descriptors
93contained in the three returned descriptor sets, which will be zero if89contained in the three returned descriptor sets, which will be zero if
94the timeout expired. On error -1 is returned, and the ``errno`` variable90the timeout expired. On error -1 is returned, and the ``errno`` variable
95is set appropriately; the sets and ``timeout`` are undefined. Possible91is set appropriately; the sets and ``timeout`` are undefined. Possible
@@ -115,6 +111,6 @@ EINVAL · 19 unmodified lines
115 ``FD_SETSIZE``.111 ``FD_SETSIZE``.
116 112
117.. [#f1]113.. [#f1]
118 The Linux kernel implements :ref:`select() <func-select>` like the114 The Linux kernel implements :c:func:`select()` like the
119 :ref:`poll() <func-poll>` function, but :ref:`select() <func-select>` cannot115 :c:func:`poll()` function, but :c:func:`select()` cannot
120 return a ``POLLERR``.116 return a ``POLLERR``.
Documentation/userspace-api/media/v4l/func-write.rst+5−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _func-write:4.. _func-write:
4 5
@@ -11,7 +12,6 @@ Name · 6 unmodified lines
11 12
12v4l2-write - Write to a V4L2 device13v4l2-write - Write to a V4L2 device
13 14
14
15Synopsis15Synopsis
16========16========
17 17
@@ -19,15 +19,13 @@ Synopsis · 1 unmodified line
19 19
20 #include <unistd.h>20 #include <unistd.h>
21 21
22
23.. c:function:: ssize_t write( int fd, void *buf, size_t count )22.. c:function:: ssize_t write( int fd, void *buf, size_t count )
24 :name: v4l2-write
25 23
26Arguments24Arguments
27=========25=========
28 26
29``fd``27``fd``
30 File descriptor returned by :ref:`open() <func-open>`.28 File descriptor returned by :c:func:`open()`.
31 29
32``buf``30``buf``
33 Buffer with data to be written31 Buffer with data to be written
@@ -38,10 +36,10 @@ Arguments · 4 unmodified lines
38Description36Description
39===========37===========
40 38
41:ref:`write() <func-write>` writes up to ``count`` bytes to the device39:c:func:`write()` writes up to ``count`` bytes to the device
42referenced by the file descriptor ``fd`` from the buffer starting at40referenced by the file descriptor ``fd`` from the buffer starting at
43``buf``. When the hardware outputs are not active yet, this function41``buf``. When the hardware outputs are not active yet, this function
44enables them. When ``count`` is zero, :ref:`write() <func-write>` returns 042enables them. When ``count`` is zero, :c:func:`write()` returns 0
45without any other effect.43without any other effect.
46 44
47When the application does not provide more data in time, the previous45When the application does not provide more data in time, the previous
@@ -49,7 +47,6 @@ video frame, raw VBI image, sliced VPS or WSS data is displayed again. · 1 unmodified line
49Sliced Teletext or Closed Caption data is not repeated, the driver47Sliced Teletext or Closed Caption data is not repeated, the driver
50inserts a blank line instead.48inserts a blank line instead.
51 49
52
53Return Value50Return Value
54============51============
55 52
@@ -80,5 +77,5 @@ EIO · 24 unmodified lines
80 I/O error. This indicates some hardware problem.77 I/O error. This indicates some hardware problem.
81 78
82EINVAL79EINVAL
83 The :ref:`write() <func-write>` function is not supported by this driver,80 The :c:func:`write()` function is not supported by this driver,
84 not on this device, or generally not on this type of device.81 not on this device, or generally not on this type of device.
Documentation/userspace-api/media/v4l/hist-v4l2.rst+4−66
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _hist-v4l2:4.. _hist-v4l2:
4 5
@@ -14,18 +15,17 @@ not just an extension but a replacement for the V4L API. However it took · 9 unmodified lines
14another four years and two stable kernel releases until the new API was15another four years and two stable kernel releases until the new API was
15finally accepted for inclusion into the kernel in its present form.16finally accepted for inclusion into the kernel in its present form.
16 17
17
18Early Versions18Early Versions
19==============19==============
20 20
211998-08-20: First version.211998-08-20: First version.
22 22
231998-08-27: The :ref:`select() <func-select>` function was introduced.231998-08-27: The :c:func:`select()` function was introduced.
24 24
251998-09-10: New video standard interface.251998-09-10: New video standard interface.
26 26
271998-09-18: The ``VIDIOC_NONCAP`` ioctl was replaced by the otherwise271998-09-18: The ``VIDIOC_NONCAP`` ioctl was replaced by the otherwise
28meaningless ``O_TRUNC`` :ref:`open() <func-open>` flag, and the28meaningless ``O_TRUNC`` :c:func:`open()` flag, and the
29aliases ``O_NONCAP`` and ``O_NOIO`` were defined. Applications can set29aliases ``O_NONCAP`` and ``O_NOIO`` were defined. Applications can set
30this flag if they intend to access controls only, as opposed to capture30this flag if they intend to access controls only, as opposed to capture
31applications which need exclusive access. The ``VIDEO_STD_XXX``31applications which need exclusive access. The ``VIDEO_STD_XXX``
@@ -65,7 +65,6 @@ output devices were added. · 33 unmodified lines
65 65
661999-01-19: The ``VIDIOC_NEXTBUF`` ioctl was removed.661999-01-19: The ``VIDIOC_NEXTBUF`` ioctl was removed.
67 67
68
69V4L2 Version 0.16 1999-01-3168V4L2 Version 0.16 1999-01-31
70============================69============================
71 70
@@ -73,7 +72,6 @@ V4L2 Version 0.16 1999-01-31 · 1 unmodified line
73are gone. VIDIOC_QBUF takes a v4l2_buffer as a parameter. Added72are gone. VIDIOC_QBUF takes a v4l2_buffer as a parameter. Added
74digital zoom (cropping) controls.73digital zoom (cropping) controls.
75 74
76
77V4L2 Version 0.18 1999-03-1675V4L2 Version 0.18 1999-03-16
78============================76============================
79 77
@@ -81,7 +79,6 @@ Added a v4l to V4L2 ioctl compatibility layer to videodev.c. Driver · 1 unmodified line
81writers, this changes how you implement your ioctl handler. See the79writers, this changes how you implement your ioctl handler. See the
82Driver Writer's Guide. Added some more control id codes.80Driver Writer's Guide. Added some more control id codes.
83 81
84
85V4L2 Version 0.19 1999-06-0582V4L2 Version 0.19 1999-06-05
86============================83============================
87 84
@@ -107,7 +104,6 @@ malfunction of this ioctl. · 19 unmodified lines
107 104
1081999-06-05: Changed the value of V4L2_CID_WHITENESS.1051999-06-05: Changed the value of V4L2_CID_WHITENESS.
109 106
110
111V4L2 Version 0.20 (1999-09-10)107V4L2 Version 0.20 (1999-09-10)
112==============================108==============================
113 109
@@ -128,14 +124,12 @@ common Linux driver API conventions. · 14 unmodified lines
128 VIDIOC_STREAMON, VIDIOC_STREAMOFF, VIDIOC_S_FREQ,124 VIDIOC_STREAMON, VIDIOC_STREAMOFF, VIDIOC_S_FREQ,
129 VIDIOC_S_INPUT, VIDIOC_S_OUTPUT, VIDIOC_S_EFFECT. For example125 VIDIOC_S_INPUT, VIDIOC_S_OUTPUT, VIDIOC_S_EFFECT. For example
130 126
131
132 .. code-block:: c127 .. code-block:: c
133 128
134 err = ioctl (fd, VIDIOC_XXX, V4L2_XXX);129 err = ioctl (fd, VIDIOC_XXX, V4L2_XXX);
135 130
136 becomes131 becomes
137 132
138
139 .. code-block:: c133 .. code-block:: c
140 134
141 int a = V4L2_XXX; err = ioctl(fd, VIDIOC_XXX, &a);135 int a = V4L2_XXX; err = ioctl(fd, VIDIOC_XXX, &a);
@@ -202,7 +196,6 @@ common Linux driver API conventions. · 60 unmodified lines
202 field counts captured frames, it is ignored by output devices. When a196 field counts captured frames, it is ignored by output devices. When a
203 capture driver drops a frame, the sequence number of that frame is skipped.197 capture driver drops a frame, the sequence number of that frame is skipped.
204 198
205
206V4L2 Version 0.20 incremental changes199V4L2 Version 0.20 incremental changes
207=====================================200=====================================
208 201
@@ -290,13 +283,11 @@ A number of changes were made to the raw VBI interface. · 81 unmodified lines
290 were added. The former is an alias for the old ``V4L2_TYPE_VBI``, the283 were added. The former is an alias for the old ``V4L2_TYPE_VBI``, the
291 latter was missing in the ``videodev.h`` file.284 latter was missing in the ``videodev.h`` file.
292 285
293
294V4L2 Version 0.20 2002-07-25286V4L2 Version 0.20 2002-07-25
295============================287============================
296 288
297Added sliced VBI interface proposal.289Added sliced VBI interface proposal.
298 290
299
300V4L2 in Linux 2.5.46, 2002-10291V4L2 in Linux 2.5.46, 2002-10
301=============================292=============================
302 293
@@ -307,7 +298,7 @@ This unnamed version was finally merged into Linux 2.5.46. · 4 unmodified lines
3071. As specified in :ref:`related`, drivers must make related device2981. As specified in :ref:`related`, drivers must make related device
308 functions available under all minor device numbers.299 functions available under all minor device numbers.
309 300
3102. The :ref:`open() <func-open>` function requires access mode3012. The :c:func:`open()` function requires access mode
311 ``O_RDWR`` regardless of the device type. All V4L2 drivers302 ``O_RDWR`` regardless of the device type. All V4L2 drivers
312 exchanging data with applications must support the ``O_NONBLOCK``303 exchanging data with applications must support the ``O_NONBLOCK``
313 flag. The ``O_NOIO`` flag, a V4L2 symbol which aliased the304 flag. The ``O_NOIO`` flag, a V4L2 symbol which aliased the
@@ -435,7 +426,6 @@ This unnamed version was finally merged into Linux 2.5.46. · 121 unmodified lines
435 the buffer type names changed as follows.426 the buffer type names changed as follows.
436 427
437 428
438
439 .. flat-table::429 .. flat-table::
440 :header-rows: 1430 :header-rows: 1
441 :stub-columns: 0431 :stub-columns: 0
@@ -597,7 +587,6 @@ This unnamed version was finally merged into Linux 2.5.46. · 155 unmodified lines
597 V4L2 documentation was inaccurate, this has been corrected in587 V4L2 documentation was inaccurate, this has been corrected in
598 :ref:`pixfmt`.588 :ref:`pixfmt`.
599 589
600
601V4L2 2003-06-19590V4L2 2003-06-19
602===============591===============
603 592
@@ -648,7 +637,6 @@ V4L2 2003-06-19 · 44 unmodified lines
648 Kernel 2.6.39. Drivers and applications assuming a constant parameter637 Kernel 2.6.39. Drivers and applications assuming a constant parameter
649 need an update.638 need an update.
650 639
651
652V4L2 2003-11-05640V4L2 2003-11-05
653===============641===============
654 642
@@ -657,7 +645,6 @@ V4L2 2003-11-05 · 2 unmodified lines
657 refer to bytes in memory, in ascending address order.645 refer to bytes in memory, in ascending address order.
658 646
659 647
660
661 .. flat-table::648 .. flat-table::
662 :header-rows: 1649 :header-rows: 1
663 :stub-columns: 0650 :stub-columns: 0
@@ -678,7 +665,6 @@ V4L2 2003-11-05 · 14 unmodified lines
678 - R, G, B, X665 - R, G, B, X
679 - B, G, R, X666 - B, G, R, X
680 667
681
682 The ``V4L2_PIX_FMT_BGR24`` example was always correct.668 The ``V4L2_PIX_FMT_BGR24`` example was always correct.
683 669
684 In :ref:`v4l-image-properties` the mapping of the V4L670 In :ref:`v4l-image-properties` the mapping of the V4L
@@ -689,7 +675,6 @@ V4L2 2003-11-05 · 4 unmodified lines
689 RGB pixel formats differently. These issues have yet to be addressed,675 RGB pixel formats differently. These issues have yet to be addressed,
690 for details see :ref:`pixfmt-rgb`.676 for details see :ref:`pixfmt-rgb`.
691 677
692
693V4L2 in Linux 2.6.6, 2004-05-09678V4L2 in Linux 2.6.6, 2004-05-09
694===============================679===============================
695 680
@@ -698,7 +683,6 @@ V4L2 in Linux 2.6.6, 2004-05-09 · 2 unmodified lines
698 ioctl, while the read-only version was renamed to683 ioctl, while the read-only version was renamed to
699 ``VIDIOC_CROPCAP_OLD``. The old ioctl was removed on Kernel 2.6.39.684 ``VIDIOC_CROPCAP_OLD``. The old ioctl was removed on Kernel 2.6.39.
700 685
701
702V4L2 in Linux 2.6.8686V4L2 in Linux 2.6.8
703===================687===================
704 688
@@ -709,7 +693,6 @@ V4L2 in Linux 2.6.8 · 4 unmodified lines
709 the new ``V4L2_BUF_FLAG_INPUT`` flag. The ``flags`` field is no693 the new ``V4L2_BUF_FLAG_INPUT`` flag. The ``flags`` field is no
710 longer read-only.694 longer read-only.
711 695
712
713V4L2 spec erratum 2004-08-01696V4L2 spec erratum 2004-08-01
714============================697============================
715 698
@@ -727,7 +710,6 @@ V4L2 spec erratum 2004-08-01 · 11 unmodified lines
727 also missing from examples. Also on the ``VIDIOC_DQBUF`` page the ``EIO``710 also missing from examples. Also on the ``VIDIOC_DQBUF`` page the ``EIO``
728 error code was not documented.711 error code was not documented.
729 712
730
731V4L2 in Linux 2.6.14713V4L2 in Linux 2.6.14
732====================714====================
733 715
@@ -735,7 +717,6 @@ V4L2 in Linux 2.6.14 · 1 unmodified line
735 :ref:`sliced` and replaces the interface first proposed in V4L2717 :ref:`sliced` and replaces the interface first proposed in V4L2
736 specification 0.8.718 specification 0.8.
737 719
738
739V4L2 in Linux 2.6.15720V4L2 in Linux 2.6.15
740====================721====================
741 722
@@ -755,7 +736,6 @@ V4L2 in Linux 2.6.15 · 13 unmodified lines
755 ``VIDIOC_G_MPEGCOMP`` and ``VIDIOC_S_MPEGCOMP`` ioctls where removed736 ``VIDIOC_G_MPEGCOMP`` and ``VIDIOC_S_MPEGCOMP`` ioctls where removed
756 in Linux 2.6.25.)737 in Linux 2.6.25.)
757 738
758
759V4L2 spec erratum 2005-11-27739V4L2 spec erratum 2005-11-27
760============================740============================
761 741
@@ -765,7 +745,6 @@ cropping is supported. In the video standard selection example in · 3 unmodified lines
765:ref:`standard` the :ref:`VIDIOC_S_STD <VIDIOC_G_STD>` call used745:ref:`standard` the :ref:`VIDIOC_S_STD <VIDIOC_G_STD>` call used
766the wrong argument type.746the wrong argument type.
767 747
768
769V4L2 spec erratum 2006-01-10748V4L2 spec erratum 2006-01-10
770============================749============================
771 750
@@ -778,14 +757,12 @@ V4L2 spec erratum 2006-01-10 · 6 unmodified lines
778 write-only as stated on its reference page. The ioctl changed in 2003757 write-only as stated on its reference page. The ioctl changed in 2003
779 as noted above.758 as noted above.
780 759
781
782V4L2 spec erratum 2006-02-03760V4L2 spec erratum 2006-02-03
783============================761============================
784 762
7851. In struct v4l2_captureparm and struct v4l2_outputparm the ``timeperframe``7631. In struct v4l2_captureparm and struct v4l2_outputparm the ``timeperframe``
786 field gives the time in seconds, not microseconds.764 field gives the time in seconds, not microseconds.
787 765
788
789V4L2 spec erratum 2006-02-04766V4L2 spec erratum 2006-02-04
790============================767============================
791 768
@@ -808,7 +785,6 @@ V4L2 in Linux 2.6.17 · 16 unmodified lines
808 ``V4L2_TUNER_MODE_STEREO`` for this purpose is deprecated now. See785 ``V4L2_TUNER_MODE_STEREO`` for this purpose is deprecated now. See
809 the :ref:`VIDIOC_G_TUNER <VIDIOC_G_TUNER>` section for details.786 the :ref:`VIDIOC_G_TUNER <VIDIOC_G_TUNER>` section for details.
810 787
811
812V4L2 spec erratum 2006-09-23 (Draft 0.15)788V4L2 spec erratum 2006-09-23 (Draft 0.15)
813=========================================789=========================================
814 790
@@ -837,7 +813,6 @@ V4L2 spec erratum 2006-09-23 (Draft 0.15) · 22 unmodified lines
837 extended from 224-239 to 224-255. Accordingly device file names813 extended from 224-239 to 224-255. Accordingly device file names
838 ``/dev/vbi0`` to ``/dev/vbi31`` are possible now.814 ``/dev/vbi0`` to ``/dev/vbi31`` are possible now.
839 815
840
841V4L2 in Linux 2.6.18816V4L2 in Linux 2.6.18
842====================817====================
843 818
@@ -852,7 +827,6 @@ V4L2 in Linux 2.6.18 · 8 unmodified lines
852 ``V4L2_CTRL_FLAG_INACTIVE`` and ``V4L2_CTRL_FLAG_SLIDER``827 ``V4L2_CTRL_FLAG_INACTIVE`` and ``V4L2_CTRL_FLAG_SLIDER``
853 (:ref:`control-flags`). See :ref:`extended-controls` for details.828 (:ref:`control-flags`). See :ref:`extended-controls` for details.
854 829
855
856V4L2 in Linux 2.6.19830V4L2 in Linux 2.6.19
857====================831====================
858 832
@@ -874,14 +848,12 @@ V4L2 in Linux 2.6.19 · 15 unmodified lines
8743. A new pixel format ``V4L2_PIX_FMT_RGB444`` (:ref:`pixfmt-rgb`) was8483. A new pixel format ``V4L2_PIX_FMT_RGB444`` (:ref:`pixfmt-rgb`) was
875 added.849 added.
876 850
877
878V4L2 spec erratum 2006-10-12 (Draft 0.17)851V4L2 spec erratum 2006-10-12 (Draft 0.17)
879=========================================852=========================================
880 853
8811. ``V4L2_PIX_FMT_HM12`` (:ref:`reserved-formats`) is a YUV 4:2:0, not8541. ``V4L2_PIX_FMT_HM12`` (:ref:`reserved-formats`) is a YUV 4:2:0, not
882 4:2:2 format.855 4:2:2 format.
883 856
884
885V4L2 in Linux 2.6.21857V4L2 in Linux 2.6.21
886====================858====================
887 859
@@ -889,7 +861,6 @@ V4L2 in Linux 2.6.21 · 1 unmodified line
889 General Public License version two or later, and under a 3-clause861 General Public License version two or later, and under a 3-clause
890 BSD-style license.862 BSD-style license.
891 863
892
893V4L2 in Linux 2.6.22864V4L2 in Linux 2.6.22
894====================865====================
895 866
@@ -914,7 +885,6 @@ V4L2 in Linux 2.6.22 · 18 unmodified lines
914 This may **break compatibility** with existing applications. Drivers885 This may **break compatibility** with existing applications. Drivers
915 supporting the "host order RGB32" format are not known.886 supporting the "host order RGB32" format are not known.
916 887
917
918V4L2 in Linux 2.6.24888V4L2 in Linux 2.6.24
919====================889====================
920 890
@@ -922,7 +892,6 @@ V4L2 in Linux 2.6.24 · 1 unmodified line
922 ``V4L2_PIX_FMT_YUV555``, ``V4L2_PIX_FMT_YUV565`` and892 ``V4L2_PIX_FMT_YUV555``, ``V4L2_PIX_FMT_YUV565`` and
923 ``V4L2_PIX_FMT_YUV32`` were added.893 ``V4L2_PIX_FMT_YUV32`` were added.
924 894
925
926V4L2 in Linux 2.6.25895V4L2 in Linux 2.6.25
927====================896====================
928 897
@@ -949,7 +918,6 @@ V4L2 in Linux 2.6.25 · 20 unmodified lines
949 interface in Linux 2.6.18, where finally removed from the918 interface in Linux 2.6.18, where finally removed from the
950 ``videodev2.h`` header file.919 ``videodev2.h`` header file.
951 920
952
953V4L2 in Linux 2.6.26921V4L2 in Linux 2.6.26
954====================922====================
955 923
@@ -959,7 +927,6 @@ V4L2 in Linux 2.6.26 · 3 unmodified lines
9592. Added user controls ``V4L2_CID_CHROMA_AGC`` and9272. Added user controls ``V4L2_CID_CHROMA_AGC`` and
960 ``V4L2_CID_COLOR_KILLER``.928 ``V4L2_CID_COLOR_KILLER``.
961 929
962
963V4L2 in Linux 2.6.27930V4L2 in Linux 2.6.27
964====================931====================
965 932
@@ -971,7 +938,6 @@ V4L2 in Linux 2.6.27 · 5 unmodified lines
971 ``V4L2_PIX_FMT_PCA561``, ``V4L2_PIX_FMT_SGBRG8``,938 ``V4L2_PIX_FMT_PCA561``, ``V4L2_PIX_FMT_SGBRG8``,
972 ``V4L2_PIX_FMT_PAC207`` and ``V4L2_PIX_FMT_PJPG`` were added.939 ``V4L2_PIX_FMT_PAC207`` and ``V4L2_PIX_FMT_PJPG`` were added.
973 940
974
975V4L2 in Linux 2.6.28941V4L2 in Linux 2.6.28
976====================942====================
977 943
@@ -983,7 +949,6 @@ V4L2 in Linux 2.6.28 · 5 unmodified lines
9833. The pixel formats ``V4L2_PIX_FMT_SGRBG10`` and9493. The pixel formats ``V4L2_PIX_FMT_SGRBG10`` and
984 ``V4L2_PIX_FMT_SGRBG10DPCM8`` were added.950 ``V4L2_PIX_FMT_SGRBG10DPCM8`` were added.
985 951
986
987V4L2 in Linux 2.6.29952V4L2 in Linux 2.6.29
988====================953====================
989 954
@@ -999,7 +964,6 @@ V4L2 in Linux 2.6.29 · 9 unmodified lines
999 ``V4L2_CID_ZOOM_RELATIVE``, ``V4L2_CID_ZOOM_CONTINUOUS`` and964 ``V4L2_CID_ZOOM_RELATIVE``, ``V4L2_CID_ZOOM_CONTINUOUS`` and
1000 ``V4L2_CID_PRIVACY``.965 ``V4L2_CID_PRIVACY``.
1001 966
1002
1003V4L2 in Linux 2.6.30967V4L2 in Linux 2.6.30
1004====================968====================
1005 969
@@ -1007,7 +971,6 @@ V4L2 in Linux 2.6.30 · 1 unmodified line
1007 971
10082. New control ``V4L2_CID_COLORFX`` was added.9722. New control ``V4L2_CID_COLORFX`` was added.
1009 973
1010
1011V4L2 in Linux 2.6.32974V4L2 in Linux 2.6.32
1012====================975====================
1013 976
@@ -1034,21 +997,18 @@ V4L2 in Linux 2.6.32 · 20 unmodified lines
10349. Added Remote Controller chapter, describing the default Remote9979. Added Remote Controller chapter, describing the default Remote
1035 Controller mapping for media devices.998 Controller mapping for media devices.
1036 999
1037
1038V4L2 in Linux 2.6.331000V4L2 in Linux 2.6.33
1039====================1001====================
1040 1002
10411. Added support for Digital Video timings in order to support HDTV10031. Added support for Digital Video timings in order to support HDTV
1042 receivers and transmitters.1004 receivers and transmitters.
1043 1005
1044
1045V4L2 in Linux 2.6.341006V4L2 in Linux 2.6.34
1046====================1007====================
1047 1008
10481. Added ``V4L2_CID_IRIS_ABSOLUTE`` and ``V4L2_CID_IRIS_RELATIVE``10091. Added ``V4L2_CID_IRIS_ABSOLUTE`` and ``V4L2_CID_IRIS_RELATIVE``
1049 controls to the :ref:`Camera controls class <camera-controls>`.1010 controls to the :ref:`Camera controls class <camera-controls>`.
1050 1011
1051
1052V4L2 in Linux 2.6.371012V4L2 in Linux 2.6.37
1053====================1013====================
1054 1014
@@ -1057,7 +1017,6 @@ V4L2 in Linux 2.6.37 · 2 unmodified lines
1057 applications found that used it. It was originally scheduled for1017 applications found that used it. It was originally scheduled for
1058 removal in 2.6.35.1018 removal in 2.6.35.
1059 1019
1060
1061V4L2 in Linux 2.6.391020V4L2 in Linux 2.6.39
1062====================1021====================
1063 1022
@@ -1067,7 +1026,6 @@ V4L2 in Linux 2.6.39 · 3 unmodified lines
1067 drivers and applications. See :ref:`multi-planar API <planar-apis>`1026 drivers and applications. See :ref:`multi-planar API <planar-apis>`
1068 for details.1027 for details.
1069 1028
1070
1071V4L2 in Linux 3.11029V4L2 in Linux 3.1
1072=================1030=================
1073 1031
@@ -1078,7 +1036,6 @@ V4L2 in Linux 3.1 · 4 unmodified lines
1078 1036
1079 Added V4L2_CTRL_TYPE_BITMASK.1037 Added V4L2_CTRL_TYPE_BITMASK.
1080 1038
1081
1082V4L2 in Linux 3.21039V4L2 in Linux 3.2
1083=================1040=================
1084 1041
@@ -1089,7 +1046,6 @@ V4L2 in Linux 3.2 · 4 unmodified lines
1089 Does not affect the compatibility of current drivers and1046 Does not affect the compatibility of current drivers and
1090 applications. See :ref:`selection API <selection-api>` for details.1047 applications. See :ref:`selection API <selection-api>` for details.
1091 1048
1092
1093V4L2 in Linux 3.31049V4L2 in Linux 3.3
1094=================1050=================
1095 1051
@@ -1099,7 +1055,6 @@ V4L2 in Linux 3.3 · 3 unmodified lines
10992. Added the device_caps field to struct v4l2_capabilities and added10552. Added the device_caps field to struct v4l2_capabilities and added
1100 the new V4L2_CAP_DEVICE_CAPS capability.1056 the new V4L2_CAP_DEVICE_CAPS capability.
1101 1057
1102
1103V4L2 in Linux 3.41058V4L2 in Linux 3.4
1104=================1059=================
1105 1060
@@ -1110,7 +1065,6 @@ V4L2 in Linux 3.4 · 4 unmodified lines
1110 :ref:`VIDIOC_QUERY_DV_TIMINGS` and1065 :ref:`VIDIOC_QUERY_DV_TIMINGS` and
1111 :ref:`VIDIOC_DV_TIMINGS_CAP`.1066 :ref:`VIDIOC_DV_TIMINGS_CAP`.
1112 1067
1113
1114V4L2 in Linux 3.51068V4L2 in Linux 3.5
1115=================1069=================
1116 1070
@@ -1137,7 +1091,6 @@ V4L2 in Linux 3.5 · 20 unmodified lines
1137 ``V4L2_CID_AUTO_FOCUS_START``, ``V4L2_CID_AUTO_FOCUS_STOP``,1091 ``V4L2_CID_AUTO_FOCUS_START``, ``V4L2_CID_AUTO_FOCUS_STOP``,
1138 ``V4L2_CID_AUTO_FOCUS_STATUS`` and ``V4L2_CID_AUTO_FOCUS_RANGE``.1092 ``V4L2_CID_AUTO_FOCUS_STATUS`` and ``V4L2_CID_AUTO_FOCUS_RANGE``.
1139 1093
1140
1141V4L2 in Linux 3.61094V4L2 in Linux 3.6
1142=================1095=================
1143 1096
@@ -1150,7 +1103,6 @@ V4L2 in Linux 3.6 · 6 unmodified lines
11503. Added support for frequency band enumerations:11033. Added support for frequency band enumerations:
1151 :ref:`VIDIOC_ENUM_FREQ_BANDS`.1104 :ref:`VIDIOC_ENUM_FREQ_BANDS`.
1152 1105
1153
1154V4L2 in Linux 3.91106V4L2 in Linux 3.9
1155=================1107=================
1156 1108
@@ -1160,7 +1112,6 @@ V4L2 in Linux 3.9 · 3 unmodified lines
11602. Added ``V4L2_EVENT_CTRL_CH_RANGE`` control event changes flag. See11122. Added ``V4L2_EVENT_CTRL_CH_RANGE`` control event changes flag. See
1161 :ref:`ctrl-changes-flags`.1113 :ref:`ctrl-changes-flags`.
1162 1114
1163
1164V4L2 in Linux 3.101115V4L2 in Linux 3.10
1165==================1116==================
1166 1117
@@ -1172,32 +1123,27 @@ V4L2 in Linux 3.10 · 5 unmodified lines
11722. Added new debugging ioctl11232. Added new debugging ioctl
1173 :ref:`VIDIOC_DBG_G_CHIP_INFO`.1124 :ref:`VIDIOC_DBG_G_CHIP_INFO`.
1174 1125
1175
1176V4L2 in Linux 3.111126V4L2 in Linux 3.11
1177==================1127==================
1178 1128
11791. Remove obsolete ``VIDIOC_DBG_G_CHIP_IDENT`` ioctl.11291. Remove obsolete ``VIDIOC_DBG_G_CHIP_IDENT`` ioctl.
1180 1130
1181
1182V4L2 in Linux 3.141131V4L2 in Linux 3.14
1183==================1132==================
1184 1133
11851. In struct v4l2_rect, the type of ``width`` and11341. In struct v4l2_rect, the type of ``width`` and
1186 ``height`` fields changed from _s32 to _u32.1135 ``height`` fields changed from _s32 to _u32.
1187 1136
1188
1189V4L2 in Linux 3.151137V4L2 in Linux 3.15
1190==================1138==================
1191 1139
11921. Added Software Defined Radio (SDR) Interface.11401. Added Software Defined Radio (SDR) Interface.
1193 1141
1194
1195V4L2 in Linux 3.161142V4L2 in Linux 3.16
1196==================1143==================
1197 1144
11981. Added event V4L2_EVENT_SOURCE_CHANGE.11451. Added event V4L2_EVENT_SOURCE_CHANGE.
1199 1146
1200
1201V4L2 in Linux 3.171147V4L2 in Linux 3.17
1202==================1148==================
1203 1149
@@ -1207,14 +1153,12 @@ V4L2 in Linux 3.17 · 3 unmodified lines
12072. Added compound control types and11532. Added compound control types and
1208 :ref:`VIDIOC_QUERY_EXT_CTRL <VIDIOC_QUERYCTRL>`.1154 :ref:`VIDIOC_QUERY_EXT_CTRL <VIDIOC_QUERYCTRL>`.
1209 1155
1210
1211V4L2 in Linux 3.181156V4L2 in Linux 3.18
1212==================1157==================
1213 1158
12141. Added ``V4L2_CID_PAN_SPEED`` and ``V4L2_CID_TILT_SPEED`` camera11591. Added ``V4L2_CID_PAN_SPEED`` and ``V4L2_CID_TILT_SPEED`` camera
1215 controls.1160 controls.
1216 1161
1217
1218V4L2 in Linux 3.191162V4L2 in Linux 3.19
1219==================1163==================
1220 1164
@@ -1232,13 +1176,11 @@ V4L2 in Linux 4.4 · 11 unmodified lines
1232 1176
12333. Added transmitter support for Software Defined Radio (SDR) Interface.11773. Added transmitter support for Software Defined Radio (SDR) Interface.
1234 1178
1235
1236.. _other:1179.. _other:
1237 1180
1238Relation of V4L2 to other Linux multimedia APIs1181Relation of V4L2 to other Linux multimedia APIs
1239===============================================1182===============================================
1240 1183
1241
1242.. _xvideo:1184.. _xvideo:
1243 1185
1244X Video Extension1186X Video Extension
@@ -1284,7 +1226,6 @@ YUV to RGB conversion and scaling for faster video playback, and added · 39 unmodified lines
1284an interface to MPEG-2 decoding hardware. This API is useful to display1226an interface to MPEG-2 decoding hardware. This API is useful to display
1285images captured with V4L2 devices.1227images captured with V4L2 devices.
1286 1228
1287
1288Digital Video1229Digital Video
1289-------------1230-------------
1290 1231
@@ -1294,13 +1235,11 @@ homepage at `https://linuxtv.org <https://linuxtv.org>`__. The Linux · 3 unmodified lines
1294DVB API has no connection to the V4L2 API except that drivers for hybrid1235DVB API has no connection to the V4L2 API except that drivers for hybrid
1295hardware may support both.1236hardware may support both.
1296 1237
1297
1298Audio Interfaces1238Audio Interfaces
1299----------------1239----------------
1300 1240
1301[to do - OSS/ALSA]1241[to do - OSS/ALSA]
1302 1242
1303
1304.. _experimental:1243.. _experimental:
1305 1244
1306Experimental API Elements1245Experimental API Elements
@@ -1314,7 +1253,6 @@ change in the future. · 7 unmodified lines
1314 1253
1315- :ref:`VIDIOC_DBG_G_CHIP_INFO` ioctl.1254- :ref:`VIDIOC_DBG_G_CHIP_INFO` ioctl.
1316 1255
1317
1318.. _obsolete:1256.. _obsolete:
1319 1257
1320Obsolete API Elements1258Obsolete API Elements
Documentation/userspace-api/media/v4l/io.rst+3−3
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _io:4.. _io:
4 5
@@ -9,8 +10,8 @@ The V4L2 API defines several different methods to read from or write to · 4 unmodified lines
9a device. All drivers exchanging data with applications must support at10a device. All drivers exchanging data with applications must support at
10least one of them.11least one of them.
11 12
12The classic I/O method using the :ref:`read() <func-read>` and13The classic I/O method using the :c:func:`read()` and
13:ref:`write() <func-write>` function is automatically selected after opening a14:c:func:`write()` function is automatically selected after opening a
14V4L2 device. When the driver does not support this method attempts to15V4L2 device. When the driver does not support this method attempts to
15read or write will fail at any time.16read or write will fail at any time.
16 17
@@ -38,7 +39,6 @@ closing and reopening the device. · 21 unmodified lines
38 39
39The following sections describe the various I/O methods in more detail.40The following sections describe the various I/O methods in more detail.
40 41
41
42.. toctree::42.. toctree::
43 :maxdepth: 143 :maxdepth: 1
44 44
Documentation/userspace-api/media/v4l/libv4l-introduction.rst+13−17
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _libv4l-introduction:4.. _libv4l-introduction:
4 5
@@ -17,7 +18,6 @@ An example of using libv4l is provided by · 12 unmodified lines
17 18
18libv4l consists of 3 different libraries:19libv4l consists of 3 different libraries:
19 20
20
21libv4lconvert21libv4lconvert
22=============22=============
23 23
@@ -65,7 +65,6 @@ libv4lconvert/processing. These controls are stored application wide · 41 unmodified lines
65libv4lconvert/processing offers the actual video processing65libv4lconvert/processing offers the actual video processing
66functionality.66functionality.
67 67
68
69libv4l168libv4l1
70=======69=======
71 70
@@ -78,7 +77,6 @@ just pass calls through. · 6 unmodified lines
78Since those functions are emulations of the old V4L1 API, it shouldn't77Since those functions are emulations of the old V4L1 API, it shouldn't
79be used for new applications.78be used for new applications.
80 79
81
82libv4l280libv4l2
83=======81=======
84 82
@@ -105,7 +103,6 @@ available in the driver. :ref:`VIDIOC_ENUM_FMT <VIDIOC_ENUM_FMT>` · 20 unmodified lines
105keeps enumerating the hardware supported formats, plus the emulated103keeps enumerating the hardware supported formats, plus the emulated
106formats offered by libv4l at the end.104formats offered by libv4l at the end.
107 105
108
109.. _libv4l-ops:106.. _libv4l-ops:
110 107
111Libv4l device control functions108Libv4l device control functions
@@ -115,17 +112,17 @@ The common file operation methods are provided by libv4l. · 3 unmodified lines
115 112
116Those functions operate just like the gcc function ``dup()`` and113Those functions operate just like the gcc function ``dup()`` and
117V4L2 functions114V4L2 functions
118:c:func:`open() <v4l2-open>`, :c:func:`close() <v4l2-close>`,115:c:func:`open()`, :c:func:`close()`,
119:c:func:`ioctl() <v4l2-ioctl>`, :c:func:`read() <v4l2-read>`,116:c:func:`ioctl()`, :c:func:`read()`,
120:c:func:`mmap() <v4l2-mmap>` and :c:func:`munmap() <v4l2-munmap>`:117:c:func:`mmap()` and :c:func:`munmap()`:
121 118
122.. c:function:: int v4l2_open(const char *file, int oflag, ...)119.. c:function:: int v4l2_open(const char *file, int oflag, ...)
123 120
124 operates like the :c:func:`open() <v4l2-open>` function.121 operates like the :c:func:`open()` function.
125 122
126.. c:function:: int v4l2_close(int fd)123.. c:function:: int v4l2_close(int fd)
127 124
128 operates like the :c:func:`close() <v4l2-close>` function.125 operates like the :c:func:`close()` function.
129 126
130.. c:function:: int v4l2_dup(int fd)127.. c:function:: int v4l2_dup(int fd)
131 128
@@ -133,19 +130,19 @@ V4L2 functions · 1 unmodified line
133 130
134.. c:function:: int v4l2_ioctl (int fd, unsigned long int request, ...)131.. c:function:: int v4l2_ioctl (int fd, unsigned long int request, ...)
135 132
136 operates like the :c:func:`ioctl() <v4l2-ioctl>` function.133 operates like the :c:func:`ioctl()` function.
137 134
138.. c:function:: int v4l2_read (int fd, void* buffer, size_t n)135.. c:function:: int v4l2_read (int fd, void* buffer, size_t n)
139 136
140 operates like the :c:func:`read() <v4l2-read>` function.137 operates like the :c:func:`read()` function.
141 138
142.. c:function:: void v4l2_mmap(void *start, size_t length, int prot, int flags, int fd, int64_t offset);139.. c:function:: void v4l2_mmap(void *start, size_t length, int prot, int flags, int fd, int64_t offset);
143 140
144 operates like the :c:func:`munmap() <v4l2-munmap>` function.141 operates like the :c:func:`munmap()` function.
145 142
146.. c:function:: int v4l2_munmap(void *_start, size_t length);143.. c:function:: int v4l2_munmap(void *_start, size_t length);
147 144
148 operates like the :c:func:`munmap() <v4l2-munmap>` function.145 operates like the :c:func:`munmap()` function.
149 146
150Those functions provide additional control:147Those functions provide additional control:
151 148
@@ -168,14 +165,13 @@ Those functions provide additional control: · 16 unmodified lines
168 of the given v4l control id. when the cid does not exist, could not be165 of the given v4l control id. when the cid does not exist, could not be
169 accessed for some reason, or some error occurred 0 is returned.166 accessed for some reason, or some error occurred 0 is returned.
170 167
171
172v4l1compat.so wrapper library168v4l1compat.so wrapper library
173=============================169=============================
174 170
175This library intercepts calls to171This library intercepts calls to
176:c:func:`open() <v4l2-open>`, :c:func:`close() <v4l2-close>`,172:c:func:`open()`, :c:func:`close()`,
177:c:func:`ioctl() <v4l2-ioctl>`, :c:func:`mmap() <v4l2-mmap>` and173:c:func:`ioctl()`, :c:func:`mmap()` and
178:c:func:`munmap() <v4l2-munmap>`174:c:func:`munmap()`
179operations and redirects them to the libv4l counterparts, by using175operations and redirects them to the libv4l counterparts, by using
180``LD_PRELOAD=/usr/lib/v4l1compat.so``. It also emulates V4L1 calls via V4L2176``LD_PRELOAD=/usr/lib/v4l1compat.so``. It also emulates V4L1 calls via V4L2
181API.177API.
Documentation/userspace-api/media/v4l/mmap.rst+13−13
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _mmap:4.. _mmap:
4 5
@@ -35,22 +36,22 @@ This ioctl can also be used to change the number of buffers or to free · 30 unmodified lines
35the allocated memory, provided none of the buffers are still mapped.36the allocated memory, provided none of the buffers are still mapped.
36 37
37Before applications can access the buffers they must map them into their38Before applications can access the buffers they must map them into their
38address space with the :ref:`mmap() <func-mmap>` function. The39address space with the :c:func:`mmap()` function. The
39location of the buffers in device memory can be determined with the40location of the buffers in device memory can be determined with the
40:ref:`VIDIOC_QUERYBUF` ioctl. In the single-planar41:ref:`VIDIOC_QUERYBUF` ioctl. In the single-planar
41API case, the ``m.offset`` and ``length`` returned in a struct42API case, the ``m.offset`` and ``length`` returned in a struct
42:c:type:`v4l2_buffer` are passed as sixth and second43:c:type:`v4l2_buffer` are passed as sixth and second
43parameter to the :ref:`mmap() <func-mmap>` function. When using the44parameter to the :c:func:`mmap()` function. When using the
44multi-planar API, struct :c:type:`v4l2_buffer` contains an45multi-planar API, struct :c:type:`v4l2_buffer` contains an
45array of struct :c:type:`v4l2_plane` structures, each46array of struct :c:type:`v4l2_plane` structures, each
46containing its own ``m.offset`` and ``length``. When using the47containing its own ``m.offset`` and ``length``. When using the
47multi-planar API, every plane of every buffer has to be mapped48multi-planar API, every plane of every buffer has to be mapped
48separately, so the number of calls to :ref:`mmap() <func-mmap>` should49separately, so the number of calls to :c:func:`mmap()` should
49be equal to number of buffers times number of planes in each buffer. The50be equal to number of buffers times number of planes in each buffer. The
50offset and length values must not be modified. Remember, the buffers are51offset and length values must not be modified. Remember, the buffers are
51allocated in physical memory, as opposed to virtual memory, which can be52allocated in physical memory, as opposed to virtual memory, which can be
52swapped out to disk. Applications should free the buffers as soon as53swapped out to disk. Applications should free the buffers as soon as
53possible with the :ref:`munmap() <func-munmap>` function.54possible with the :c:func:`munmap()` function.
54 55
55Example: Mapping buffers in the single-planar API56Example: Mapping buffers in the single-planar API
56=================================================57=================================================
@@ -122,7 +123,6 @@ Example: Mapping buffers in the single-planar API · 65 unmodified lines
122 for (i = 0; i < reqbuf.count; i++)123 for (i = 0; i < reqbuf.count; i++)
123 munmap(buffers[i].start, buffers[i].length);124 munmap(buffers[i].start, buffers[i].length);
124 125
125
126Example: Mapping buffers in the multi-planar API126Example: Mapping buffers in the multi-planar API
127================================================127================================================
128 128
@@ -238,10 +238,10 @@ be determined at any time using the :ref:`VIDIOC_QUERYBUF` ioctl. Two · 109 unmodified lines
238methods exist to suspend execution of the application until one or more238methods exist to suspend execution of the application until one or more
239buffers can be dequeued. By default :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`239buffers can be dequeued. By default :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`
240blocks when no buffer is in the outgoing queue. When the ``O_NONBLOCK``240blocks when no buffer is in the outgoing queue. When the ``O_NONBLOCK``
241flag was given to the :ref:`open() <func-open>` function,241flag was given to the :c:func:`open()` function,
242:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` returns immediately with an ``EAGAIN``242:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` returns immediately with an ``EAGAIN``
243error code when no buffer is available. The :ref:`select() <func-select>`243error code when no buffer is available. The :c:func:`select()`
244or :ref:`poll() <func-poll>` functions are always available.244or :c:func:`poll()` functions are always available.
245 245
246To start and stop capturing or output applications call the246To start and stop capturing or output applications call the
247:ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` and :ref:`VIDIOC_STREAMOFF247:ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>` and :ref:`VIDIOC_STREAMOFF
@@ -259,15 +259,15 @@ Drivers implementing memory mapping I/O must support the · 11 unmodified lines
259<VIDIOC_QUERYBUF>`, :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`, :ref:`VIDIOC_DQBUF259<VIDIOC_QUERYBUF>`, :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`, :ref:`VIDIOC_DQBUF
260<VIDIOC_QBUF>`, :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>`260<VIDIOC_QBUF>`, :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>`
261and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls, the :ref:`mmap()261and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls, the :ref:`mmap()
262<func-mmap>`, :ref:`munmap() <func-munmap>`, :ref:`select()262<func-mmap>`, :c:func:`munmap()`, :ref:`select()
263<func-select>` and :ref:`poll() <func-poll>` function. [#f3]_263<func-select>` and :c:func:`poll()` function. [#f3]_
264 264
265[capture example]265[capture example]
266 266
267.. [#f1]267.. [#f1]
268 One could use one file descriptor and set the buffer type field268 One could use one file descriptor and set the buffer type field
269 accordingly when calling :ref:`VIDIOC_QBUF` etc.,269 accordingly when calling :ref:`VIDIOC_QBUF` etc.,
270 but it makes the :ref:`select() <func-select>` function ambiguous. We also270 but it makes the :c:func:`select()` function ambiguous. We also
271 like the clean approach of one file descriptor per logical stream.271 like the clean approach of one file descriptor per logical stream.
272 Video overlay for example is also a logical stream, although the CPU272 Video overlay for example is also a logical stream, although the CPU
273 is not needed for continuous operation.273 is not needed for continuous operation.
@@ -280,6 +280,6 @@ and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls, the :ref:`mmap() · 6 unmodified lines
280 scatter-gather lists and the like.280 scatter-gather lists and the like.
281 281
282.. [#f3]282.. [#f3]
283 At the driver level :ref:`select() <func-select>` and :ref:`poll() <func-poll>` are283 At the driver level :c:func:`select()` and :c:func:`poll()` are
284 the same, and :ref:`select() <func-select>` is too important to be optional.284 the same, and :c:func:`select()` is too important to be optional.
285 The rest should be evident.285 The rest should be evident.
Documentation/userspace-api/media/v4l/open.rst+6−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _open:4.. _open:
4 5
@@ -140,7 +141,6 @@ means applications cannot *reliably* scan for loaded or installed · 135 unmodified lines
140drivers. The user must enter a device name, or the application can try141drivers. The user must enter a device name, or the application can try
141the conventional device names.142the conventional device names.
142 143
143
144.. _related:144.. _related:
145 145
146Related Devices146Related Devices
@@ -157,7 +157,7 @@ support all functions. However, in practice this never worked: this · 10 unmodified lines
157support it and if they did it was certainly never tested. In addition,157support it and if they did it was certainly never tested. In addition,
158switching a device node between different functions only works when158switching a device node between different functions only works when
159using the streaming I/O API, not with the159using the streaming I/O API, not with the
160:ref:`read() <func-read>`/\ :ref:`write() <func-write>` API.160:c:func:`read()`/\ :c:func:`write()` API.
161 161
162Today each V4L2 device node supports just one function.162Today each V4L2 device node supports just one function.
163 163
@@ -178,7 +178,6 @@ the Media Controller. If you want to work on this please write to the · 14 unmodified lines
178linux-media mailing list:178linux-media mailing list:
179`https://linuxtv.org/lists.php <https://linuxtv.org/lists.php>`__.179`https://linuxtv.org/lists.php <https://linuxtv.org/lists.php>`__.
180 180
181
182Multiple Opens181Multiple Opens
183==============182==============
184 183
@@ -192,8 +191,8 @@ device should not change the state of the device. [#f2]_ · 7 unmodified lines
192Once an application has allocated the memory buffers needed for191Once an application has allocated the memory buffers needed for
193streaming data (by calling the :ref:`VIDIOC_REQBUFS`192streaming data (by calling the :ref:`VIDIOC_REQBUFS`
194or :ref:`VIDIOC_CREATE_BUFS` ioctls, or193or :ref:`VIDIOC_CREATE_BUFS` ioctls, or
195implicitly by calling the :ref:`read() <func-read>` or194implicitly by calling the :c:func:`read()` or
196:ref:`write() <func-write>` functions) that application (filehandle)195:c:func:`write()` functions) that application (filehandle)
197becomes the owner of the device. It is no longer allowed to make changes196becomes the owner of the device. It is no longer allowed to make changes
198that would affect the buffer sizes (e.g. by calling the197that would affect the buffer sizes (e.g. by calling the
199:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl) and other applications are198:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl) and other applications are
@@ -206,7 +205,6 @@ requested type of data, and to change related properties, to this file · 6 unmodified lines
206descriptor. Applications can request additional access privileges using205descriptor. Applications can request additional access privileges using
207the priority mechanism described in :ref:`app-pri`.206the priority mechanism described in :ref:`app-pri`.
208 207
209
210Shared Data Streams208Shared Data Streams
211===================209===================
212 210
@@ -215,12 +213,11 @@ the same data stream on a device by copying buffers, time multiplexing · 2 unmodified lines
215or similar means. This is better handled by a proxy application in user213or similar means. This is better handled by a proxy application in user
216space.214space.
217 215
218
219Functions216Functions
220=========217=========
221 218
222To open and close V4L2 devices applications use the219To open and close V4L2 devices applications use the
223:ref:`open() <func-open>` and :ref:`close() <func-close>` function,220:c:func:`open()` and :c:func:`close()` function,
224respectively. Devices are programmed using the221respectively. Devices are programmed using the
225:ref:`ioctl() <func-ioctl>` function as explained in the following222:ref:`ioctl() <func-ioctl>` function as explained in the following
226sections.223sections.
@@ -228,7 +225,7 @@ sections. · 1 unmodified line
228.. [#f1]225.. [#f1]
229 There are still some old and obscure drivers that have not been226 There are still some old and obscure drivers that have not been
230 updated to allow for multiple opens. This implies that for such227 updated to allow for multiple opens. This implies that for such
231 drivers :ref:`open() <func-open>` can return an ``EBUSY`` error code228 drivers :c:func:`open()` can return an ``EBUSY`` error code
232 when the device is already in use.229 when the device is already in use.
233 230
234.. [#f2]231.. [#f2]
Documentation/userspace-api/media/v4l/rw.rst+9−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _rw:4.. _rw:
4 5
@@ -6,8 +7,8 @@ · 1 unmodified line
6Read/Write7Read/Write
7**********8**********
8 9
9Input and output devices support the :ref:`read() <func-read>` and10Input and output devices support the :c:func:`read()` and
10:ref:`write() <func-write>` function, respectively, when the11:c:func:`write()` function, respectively, when the
11``V4L2_CAP_READWRITE`` flag in the ``capabilities`` field of struct12``V4L2_CAP_READWRITE`` flag in the ``capabilities`` field of struct
12:c:type:`v4l2_capability` returned by the13:c:type:`v4l2_capability` returned by the
13:ref:`VIDIOC_QUERYCAP` ioctl is set.14:ref:`VIDIOC_QUERYCAP` ioctl is set.
@@ -22,18 +23,17 @@ However this is also the simplest I/O method, requiring little or no · 8 unmodified lines
22setup to exchange data. It permits command line stunts like this (the23setup to exchange data. It permits command line stunts like this (the
23vidctrl tool is fictitious):24vidctrl tool is fictitious):
24 25
25
26.. code-block:: none26.. code-block:: none
27 27
28 $ vidctrl /dev/video --input=0 --format=YUYV --size=352x28828 $ vidctrl /dev/video --input=0 --format=YUYV --size=352x288
29 $ dd if=/dev/video of=myimage.422 bs=202752 count=129 $ dd if=/dev/video of=myimage.422 bs=202752 count=1
30 30
31To read from the device applications use the :ref:`read() <func-read>`31To read from the device applications use the :c:func:`read()`
32function, to write the :ref:`write() <func-write>` function. Drivers32function, to write the :c:func:`write()` function. Drivers
33must implement one I/O method if they exchange data with applications,33must implement one I/O method if they exchange data with applications,
34but it need not be this. [#f1]_ When reading or writing is supported, the34but it need not be this. [#f1]_ When reading or writing is supported, the
35driver must also support the :ref:`select() <func-select>` and35driver must also support the :c:func:`select()` and
36:ref:`poll() <func-poll>` function. [#f2]_36:c:func:`poll()` function. [#f2]_
37 37
38.. [#f1]38.. [#f1]
39 It would be desirable if applications could depend on drivers39 It would be desirable if applications could depend on drivers
@@ -43,5 +43,5 @@ driver must also support the :ref:`select() <func-select>` and · 3 unmodified lines
43 capturing still images.43 capturing still images.
44 44
45.. [#f2]45.. [#f2]
46 At the driver level :ref:`select() <func-select>` and :ref:`poll() <func-poll>` are46 At the driver level :c:func:`select()` and :c:func:`poll()` are
47 the same, and :ref:`select() <func-select>` is too important to be optional.47 the same, and :c:func:`select()` is too important to be optional.
Documentation/userspace-api/media/v4l/streaming-par.rst+3−2
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _streaming-par:4.. _streaming-par:
4 5
@@ -14,13 +15,13 @@ The current video standard determines a nominal number of frames per · 9 unmodified lines
14second. If less than this number of frames is to be captured or output,15second. If less than this number of frames is to be captured or output,
15applications can request frame skipping or duplicating on the driver16applications can request frame skipping or duplicating on the driver
16side. This is especially useful when using the17side. This is especially useful when using the
17:ref:`read() <func-read>` or :ref:`write() <func-write>`, which are18:c:func:`read()` or :c:func:`write()`, which are
18not augmented by timestamps or sequence counters, and to avoid19not augmented by timestamps or sequence counters, and to avoid
19unnecessary data copying.20unnecessary data copying.
20 21
21Finally these ioctls can be used to determine the number of buffers used22Finally these ioctls can be used to determine the number of buffers used
22internally by a driver in read/write mode. For implications see the23internally by a driver in read/write mode. For implications see the
23section discussing the :ref:`read() <func-read>` function.24section discussing the :c:func:`read()` function.
24 25
25To get and set the streaming parameters applications call the26To get and set the streaming parameters applications call the
26:ref:`VIDIOC_G_PARM <VIDIOC_G_PARM>` and27:ref:`VIDIOC_G_PARM <VIDIOC_G_PARM>` and
Documentation/userspace-api/media/v4l/userp.rst+6−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _userp:4.. _userp:
4 5
@@ -78,10 +79,10 @@ buffers it must wait until an empty buffer can be dequeued and reused. · 73 unmodified lines
78Two methods exist to suspend execution of the application until one or79Two methods exist to suspend execution of the application until one or
79more buffers can be dequeued. By default :ref:`VIDIOC_DQBUF80more buffers can be dequeued. By default :ref:`VIDIOC_DQBUF
80<VIDIOC_QBUF>` blocks when no buffer is in the outgoing queue. When the81<VIDIOC_QBUF>` blocks when no buffer is in the outgoing queue. When the
81``O_NONBLOCK`` flag was given to the :ref:`open() <func-open>` function,82``O_NONBLOCK`` flag was given to the :c:func:`open()` function,
82:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` returns immediately with an ``EAGAIN``83:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` returns immediately with an ``EAGAIN``
83error code when no buffer is available. The :ref:`select()84error code when no buffer is available. The :ref:`select()
84<func-select>` or :ref:`poll() <func-poll>` function are always85<func-select>` or :c:func:`poll()` function are always
85available.86available.
86 87
87To start and stop capturing or output applications call the88To start and stop capturing or output applications call the
@@ -101,7 +102,7 @@ Drivers implementing user pointer I/O must support the · 13 unmodified lines
101:ref:`VIDIOC_REQBUFS <VIDIOC_REQBUFS>`, :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`,102:ref:`VIDIOC_REQBUFS <VIDIOC_REQBUFS>`, :ref:`VIDIOC_QBUF <VIDIOC_QBUF>`,
102:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`, :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>`103:ref:`VIDIOC_DQBUF <VIDIOC_QBUF>`, :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>`
103and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls, the104and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls, the
104:ref:`select() <func-select>` and :ref:`poll() <func-poll>` function. [#f2]_105:c:func:`select()` and :c:func:`poll()` function. [#f2]_
105 106
106.. [#f1]107.. [#f1]
107 We expect that frequently used buffers are typically not swapped out.108 We expect that frequently used buffers are typically not swapped out.
@@ -116,6 +117,6 @@ and :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` ioctls, the · 8 unmodified lines
116 because an application may share them with other processes.117 because an application may share them with other processes.
117 118
118.. [#f2]119.. [#f2]
119 At the driver level :ref:`select() <func-select>` and :ref:`poll() <func-poll>` are120 At the driver level :c:func:`select()` and :c:func:`poll()` are
120 the same, and :ref:`select() <func-select>` is too important to be optional.121 the same, and :c:func:`select()` is too important to be optional.
121 The rest should be evident.122 The rest should be evident.
Documentation/userspace-api/media/v4l/vidioc-create-bufs.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_CREATE_BUFS:4.. _VIDIOC_CREATE_BUFS:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_CREATE_BUFS - Create buffers for Memory Mapped or User Pointer or DMA Buffer I/O13VIDIOC_CREATE_BUFS - Create buffers for Memory Mapped or User Pointer or DMA Buffer I/O
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_CREATE_BUFS, struct v4l2_create_buffers *argp )18.. c:macro:: VIDIOC_CREATE_BUFS
19 :name: VIDIOC_CREATE_BUFS
20 19
20``int ioctl(int fd, VIDIOC_CREATE_BUFS, struct v4l2_create_buffers *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_create_buffers`.29 Pointer to struct :c:type:`v4l2_create_buffers`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -71,7 +70,6 @@ the actual number allocated and the starting index in the ``count`` and · 36 unmodified lines
71the ``index`` fields respectively. On return ``count`` can be smaller70the ``index`` fields respectively. On return ``count`` can be smaller
72than the number requested.71than the number requested.
73 72
74
75.. c:type:: v4l2_create_buffers73.. c:type:: v4l2_create_buffers
76 74
77.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|75.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -119,7 +117,6 @@ than the number requested. · 41 unmodified lines
119 - A place holder for future extensions. Drivers and applications117 - A place holder for future extensions. Drivers and applications
120 must set the array to zero.118 must set the array to zero.
121 119
122
123Return Value120Return Value
124============121============
125 122
Documentation/userspace-api/media/v4l/vidioc-cropcap.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_CROPCAP:4.. _VIDIOC_CROPCAP:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_CROPCAP - Information about the video cropping and scaling abilities13VIDIOC_CROPCAP - Information about the video cropping and scaling abilities
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_CROPCAP, struct v4l2_cropcap *argp )18.. c:macro:: VIDIOC_CROPCAP
19 :name: VIDIOC_CROPCAP
20 19
20``int ioctl(int fd, VIDIOC_CROPCAP, struct v4l2_cropcap *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_cropcap`.29 Pointer to struct :c:type:`v4l2_cropcap`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -95,7 +94,6 @@ overlay devices. · 60 unmodified lines
95 Starting with kernel 4.13 both variations are allowed.94 Starting with kernel 4.13 both variations are allowed.
96 95
97 96
98
99.. _v4l2-rect-crop:97.. _v4l2-rect-crop:
100 98
101.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|99.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -120,7 +118,6 @@ overlay devices. · 18 unmodified lines
120 - ``height``118 - ``height``
121 - Height of the rectangle, in pixels.119 - Height of the rectangle, in pixels.
122 120
123
124Return Value121Return Value
125============122============
126 123
Documentation/userspace-api/media/v4l/vidioc-dbg-g-chip-info.rst+4−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_DBG_G_CHIP_INFO:4.. _VIDIOC_DBG_G_CHIP_INFO:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_DBG_G_CHIP_INFO - Identify the chips on a TV card13VIDIOC_DBG_G_CHIP_INFO - Identify the chips on a TV card
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_DBG_G_CHIP_INFO, struct v4l2_dbg_chip_info *argp )18.. c:macro:: VIDIOC_DBG_G_CHIP_INFO
19 :name: VIDIOC_DBG_G_CHIP_INFO
20 19
20``int ioctl(int fd, VIDIOC_DBG_G_CHIP_INFO, struct v4l2_dbg_chip_info *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_dbg_chip_info`.29 Pointer to struct :c:type:`v4l2_dbg_chip_info`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -76,7 +75,6 @@ is available from the LinuxTV v4l-dvb repository; see · 41 unmodified lines
76`https://linuxtv.org/repo/ <https://linuxtv.org/repo/>`__ for access75`https://linuxtv.org/repo/ <https://linuxtv.org/repo/>`__ for access
77instructions.76instructions.
78 77
79
80.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|78.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|
81 79
82.. _name-v4l2-dbg-match:80.. _name-v4l2-dbg-match:
@@ -103,7 +101,6 @@ instructions. · 20 unmodified lines
103 -101 -
104 102
105 103
106
107.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|104.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
108 105
109.. c:type:: v4l2_dbg_chip_info106.. c:type:: v4l2_dbg_chip_info
@@ -130,7 +127,6 @@ instructions. · 20 unmodified lines
130 - Reserved fields, both application and driver must set these to 0.127 - Reserved fields, both application and driver must set these to 0.
131 128
132 129
133
134.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|130.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
135 131
136.. _name-chip-match-types:132.. _name-chip-match-types:
@@ -148,7 +144,6 @@ instructions. · 11 unmodified lines
148 - 4144 - 4
149 - Match the nth sub-device.145 - Match the nth sub-device.
150 146
151
152Return Value147Return Value
153============148============
154 149
Documentation/userspace-api/media/v4l/vidioc-dbg-g-register.rst+7−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_DBG_G_REGISTER:4.. _VIDIOC_DBG_G_REGISTER:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_DBG_G_REGISTER - VIDIOC_DBG_S_REGISTER - Read or write hardware registers13VIDIOC_DBG_G_REGISTER - VIDIOC_DBG_S_REGISTER - Read or write hardware registers
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_DBG_G_REGISTER, struct v4l2_dbg_register *argp )18.. c:macro:: VIDIOC_DBG_G_REGISTER
19 :name: VIDIOC_DBG_G_REGISTER19
20``int ioctl(int fd, VIDIOC_DBG_G_REGISTER, struct v4l2_dbg_register *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_DBG_S_REGISTER, const struct v4l2_dbg_register *argp )22.. c:macro:: VIDIOC_DBG_S_REGISTER
22 :name: VIDIOC_DBG_S_REGISTER
23 23
24``int ioctl(int fd, VIDIOC_DBG_S_REGISTER, const struct v4l2_dbg_register *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_dbg_register`.33 Pointer to struct :c:type:`v4l2_dbg_register`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -85,7 +85,6 @@ It is available from the LinuxTV v4l-dvb repository; see · 47 unmodified lines
85`https://linuxtv.org/repo/ <https://linuxtv.org/repo/>`__ for access85`https://linuxtv.org/repo/ <https://linuxtv.org/repo/>`__ for access
86instructions.86instructions.
87 87
88
89.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|88.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|
90 89
91.. c:type:: v4l2_dbg_match90.. c:type:: v4l2_dbg_match
@@ -112,7 +111,6 @@ instructions. · 20 unmodified lines
112 -111 -
113 112
114 113
115
116.. c:type:: v4l2_dbg_register114.. c:type:: v4l2_dbg_register
117 115
118.. flat-table:: struct v4l2_dbg_register116.. flat-table:: struct v4l2_dbg_register
@@ -133,7 +131,6 @@ instructions. · 14 unmodified lines
133 - The value read from, or to be written into the register.131 - The value read from, or to be written into the register.
134 132
135 133
136
137.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|134.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
138 135
139.. _chip-match-types:136.. _chip-match-types:
@@ -151,7 +148,6 @@ instructions. · 11 unmodified lines
151 - 4148 - 4
152 - Match the nth sub-device.149 - Match the nth sub-device.
153 150
154
155Return Value151Return Value
156============152============
157 153
Documentation/userspace-api/media/v4l/vidioc-decoder-cmd.rst+8−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_DECODER_CMD:4.. _VIDIOC_DECODER_CMD:
4 5
@@ -11,28 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_DECODER_CMD - VIDIOC_TRY_DECODER_CMD - Execute an decoder command13VIDIOC_DECODER_CMD - VIDIOC_TRY_DECODER_CMD - Execute an decoder command
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_DECODER_CMD, struct v4l2_decoder_cmd *argp )18.. c:macro:: VIDIOC_DECODER_CMD
19 :name: VIDIOC_DECODER_CMD
20 19
20``int ioctl(int fd, VIDIOC_DECODER_CMD, struct v4l2_decoder_cmd *argp)``
21 21
22.. c:function:: int ioctl( int fd, VIDIOC_TRY_DECODER_CMD, struct v4l2_decoder_cmd *argp )22.. c:macro:: VIDIOC_TRY_DECODER_CMD
23 :name: VIDIOC_TRY_DECODER_CMD
24 23
24``int ioctl(int fd, VIDIOC_TRY_DECODER_CMD, struct v4l2_decoder_cmd *argp)``
25 25
26Arguments26Arguments
27=========27=========
28 28
29``fd``29``fd``
30 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
31 31
32``argp``32``argp``
33 pointer to struct :c:type:`v4l2_decoder_cmd`.33 pointer to struct :c:type:`v4l2_decoder_cmd`.
34 34
35
36Description35Description
37===========36===========
38 37
@@ -47,11 +46,11 @@ this structure. · 8 unmodified lines
47The ``cmd`` field must contain the command code. Some commands use the46The ``cmd`` field must contain the command code. Some commands use the
48``flags`` field for additional information.47``flags`` field for additional information.
49 48
50A :ref:`write() <func-write>` or :ref:`VIDIOC_STREAMON`49A :c:func:`write()` or :ref:`VIDIOC_STREAMON`
51call sends an implicit START command to the decoder if it has not been50call sends an implicit START command to the decoder if it has not been
52started yet. Applies to both queues of mem2mem decoders.51started yet. Applies to both queues of mem2mem decoders.
53 52
54A :ref:`close() <func-close>` or :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>`53A :c:func:`close()` or :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>`
55call of a streaming file descriptor sends an implicit immediate STOP54call of a streaming file descriptor sends an implicit immediate STOP
56command to the decoder, and all buffered data is discarded. Applies to both55command to the decoder, and all buffered data is discarded. Applies to both
57queues of mem2mem decoders.56queues of mem2mem decoders.
@@ -60,7 +59,6 @@ In principle, these ioctls are optional, not all drivers may support them. They · 2 unmodified lines
60introduced in Linux 3.3. They are, however, mandatory for stateful mem2mem decoders59introduced in Linux 3.3. They are, however, mandatory for stateful mem2mem decoders
61(as further documented in :ref:`decoder`).60(as further documented in :ref:`decoder`).
62 61
63
64.. tabularcolumns:: |p{1.1cm}|p{2.4cm}|p{1.2cm}|p{1.6cm}|p{10.6cm}|62.. tabularcolumns:: |p{1.1cm}|p{2.4cm}|p{1.2cm}|p{1.6cm}|p{10.6cm}|
65 63
66.. c:type:: v4l2_decoder_cmd64.. c:type:: v4l2_decoder_cmd
@@ -131,7 +129,6 @@ introduced in Linux 3.3. They are, however, mandatory for stateful mem2mem decod · 64 unmodified lines
131 -129 -
132 130
133 131
134
135.. tabularcolumns:: |p{5.6cm}|p{0.6cm}|p{11.3cm}|132.. tabularcolumns:: |p{5.6cm}|p{0.6cm}|p{11.3cm}|
136 133
137.. _decoder-cmds:134.. _decoder-cmds:
Documentation/userspace-api/media/v4l/vidioc-dqevent.rst+4−15
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_DQEVENT:4.. _VIDIOC_DQEVENT:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_DQEVENT - Dequeue event13VIDIOC_DQEVENT - Dequeue event
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_DQEVENT, struct v4l2_event *argp )18.. c:macro:: VIDIOC_DQEVENT
19 :name: VIDIOC_DQEVENT
20 19
20``int ioctl(int fd, VIDIOC_DQEVENT, struct v4l2_event *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_event`.29 Pointer to struct :c:type:`v4l2_event`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -38,7 +37,6 @@ structure are filled by the driver. The file handle will also receive · 3 unmodified lines
38exceptions which the application may get by e.g. using the select system37exceptions which the application may get by e.g. using the select system
39call.38call.
40 39
41
42.. tabularcolumns:: |p{3.0cm}|p{4.4cm}|p{2.4cm}|p{7.7cm}|40.. tabularcolumns:: |p{3.0cm}|p{4.4cm}|p{2.4cm}|p{7.7cm}|
43 41
44.. c:type:: v4l2_event42.. c:type:: v4l2_event
@@ -100,7 +98,6 @@ call. · 55 unmodified lines
100 zero.98 zero.
101 99
102 100
103
104.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|101.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
105 102
106.. cssclass:: longtable103.. cssclass:: longtable
@@ -191,7 +188,6 @@ call. · 84 unmodified lines
191 - Base event number for driver-private events.188 - Base event number for driver-private events.
192 189
193 190
194
195.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|191.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
196 192
197.. c:type:: v4l2_event_vsync193.. c:type:: v4l2_event_vsync
@@ -206,7 +202,6 @@ call. · 8 unmodified lines
206 - The upcoming field. See enum :c:type:`v4l2_field`.202 - The upcoming field. See enum :c:type:`v4l2_field`.
207 203
208 204
209
210.. tabularcolumns:: |p{3.5cm}|p{3.0cm}|p{1.8cm}|p{8.5cm}|205.. tabularcolumns:: |p{3.5cm}|p{3.0cm}|p{1.8cm}|p{8.5cm}|
211 206
212.. c:type:: v4l2_event_ctrl207.. c:type:: v4l2_event_ctrl
@@ -257,7 +252,6 @@ call. · 44 unmodified lines
257 :ref:`v4l2_queryctrl <v4l2-queryctrl>`.252 :ref:`v4l2_queryctrl <v4l2-queryctrl>`.
258 253
259 254
260
261.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|255.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
262 256
263.. c:type:: v4l2_event_frame_sync257.. c:type:: v4l2_event_frame_sync
@@ -272,7 +266,6 @@ call. · 8 unmodified lines
272 - The sequence number of the frame being received.266 - The sequence number of the frame being received.
273 267
274 268
275
276.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|269.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
277 270
278.. c:type:: v4l2_event_src_change271.. c:type:: v4l2_event_src_change
@@ -288,7 +281,6 @@ call. · 9 unmodified lines
288 :ref:`src-changes-flags`.281 :ref:`src-changes-flags`.
289 282
290 283
291
292.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|284.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
293 285
294.. c:type:: v4l2_event_motion_det286.. c:type:: v4l2_event_motion_det
@@ -318,7 +310,6 @@ call. · 23 unmodified lines
318 automatically assigned to the default region 0.310 automatically assigned to the default region 0.
319 311
320 312
321
322.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|313.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
323 314
324.. _ctrl-changes-flags:315.. _ctrl-changes-flags:
@@ -344,7 +335,6 @@ call. · 19 unmodified lines
344 step or the default value of the control changed.335 step or the default value of the control changed.
345 336
346 337
347
348.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|338.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
349 339
350.. _src-changes-flags:340.. _src-changes-flags:
@@ -375,7 +365,6 @@ call. · 24 unmodified lines
375 loss of signal and so restarting streaming I/O is required in order for365 loss of signal and so restarting streaming I/O is required in order for
376 the hardware to synchronize to the video signal.366 the hardware to synchronize to the video signal.
377 367
378
379Return Value368Return Value
380============369============
381 370
Documentation/userspace-api/media/v4l/vidioc-dv-timings-cap.rst+7−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_DV_TIMINGS_CAP:4.. _VIDIOC_DV_TIMINGS_CAP:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_DV_TIMINGS_CAP - VIDIOC_SUBDEV_DV_TIMINGS_CAP - The capabilities of the Digital Video receiver/transmitter13VIDIOC_DV_TIMINGS_CAP - VIDIOC_SUBDEV_DV_TIMINGS_CAP - The capabilities of the Digital Video receiver/transmitter
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_DV_TIMINGS_CAP, struct v4l2_dv_timings_cap *argp )18.. c:macro:: VIDIOC_DV_TIMINGS_CAP
19 :name: VIDIOC_DV_TIMINGS_CAP19
20``int ioctl(int fd, VIDIOC_DV_TIMINGS_CAP, struct v4l2_dv_timings_cap *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_DV_TIMINGS_CAP, struct v4l2_dv_timings_cap *argp )22.. c:macro:: VIDIOC_SUBDEV_DV_TIMINGS_CAP
22 :name: VIDIOC_SUBDEV_DV_TIMINGS_CAP
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_DV_TIMINGS_CAP, struct v4l2_dv_timings_cap *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_dv_timings_cap`.33 Pointer to struct :c:type:`v4l2_dv_timings_cap`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -55,7 +55,6 @@ the desired pad number in the struct · 17 unmodified lines
55zero the ``reserved`` array. Attempts to query capabilities on a pad55zero the ``reserved`` array. Attempts to query capabilities on a pad
56that doesn't support them will return an ``EINVAL`` error code.56that doesn't support them will return an ``EINVAL`` error code.
57 57
58
59.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{13.3cm}|58.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{13.3cm}|
60 59
61.. c:type:: v4l2_bt_timings_cap60.. c:type:: v4l2_bt_timings_cap
@@ -97,7 +96,6 @@ that doesn't support them will return an ``EINVAL`` error code. · 35 unmodified lines
97 Drivers must set the array to zero.96 Drivers must set the array to zero.
98 97
99 98
100
101.. tabularcolumns:: |p{1.0cm}|p{4.0cm}|p{3.5cm}|p{9.2cm}|99.. tabularcolumns:: |p{1.0cm}|p{4.0cm}|p{3.5cm}|p{9.2cm}|
102 100
103.. c:type:: v4l2_dv_timings_cap101.. c:type:: v4l2_dv_timings_cap
@@ -153,7 +151,6 @@ that doesn't support them will return an ``EINVAL`` error code. · 49 unmodified lines
153 - Can support non-standard timings, i.e. timings not belonging to151 - Can support non-standard timings, i.e. timings not belonging to
154 the standards set in the ``standards`` field.152 the standards set in the ``standards`` field.
155 153
156
157Return Value154Return Value
158============155============
159 156
Documentation/userspace-api/media/v4l/vidioc-encoder-cmd.rst+11−14
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENCODER_CMD:4.. _VIDIOC_ENCODER_CMD:
4 5
@@ -11,22 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENCODER_CMD - VIDIOC_TRY_ENCODER_CMD - Execute an encoder command13VIDIOC_ENCODER_CMD - VIDIOC_TRY_ENCODER_CMD - Execute an encoder command
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENCODER_CMD, struct v4l2_encoder_cmd *argp )18.. c:macro:: VIDIOC_ENCODER_CMD
19 :name: VIDIOC_ENCODER_CMD19
20``int ioctl(int fd, VIDIOC_ENCODER_CMD, struct v4l2_encoder_cmd *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_TRY_ENCODER_CMD, struct v4l2_encoder_cmd *argp )22.. c:macro:: VIDIOC_TRY_ENCODER_CMD
22 :name: VIDIOC_TRY_ENCODER_CMD
23 23
24``int ioctl(int fd, VIDIOC_TRY_ENCODER_CMD, struct v4l2_encoder_cmd *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_encoder_cmd`.33 Pointer to struct :c:type:`v4l2_encoder_cmd`.
@@ -47,16 +48,16 @@ this structure. · 14 unmodified lines
47The ``cmd`` field must contain the command code. Some commands use the48The ``cmd`` field must contain the command code. Some commands use the
48``flags`` field for additional information.49``flags`` field for additional information.
49 50
50After a STOP command, :ref:`read() <func-read>` calls will read51After a STOP command, :c:func:`read()` calls will read
51the remaining data buffered by the driver. When the buffer is empty,52the remaining data buffered by the driver. When the buffer is empty,
52:ref:`read() <func-read>` will return zero and the next :ref:`read() <func-read>`53:c:func:`read()` will return zero and the next :c:func:`read()`
53call will restart the encoder.54call will restart the encoder.
54 55
55A :ref:`read() <func-read>` or :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>`56A :c:func:`read()` or :ref:`VIDIOC_STREAMON <VIDIOC_STREAMON>`
56call sends an implicit START command to the encoder if it has not been57call sends an implicit START command to the encoder if it has not been
57started yet. Applies to both queues of mem2mem encoders.58started yet. Applies to both queues of mem2mem encoders.
58 59
59A :ref:`close() <func-close>` or :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>`60A :c:func:`close()` or :ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>`
60call of a streaming file descriptor sends an implicit immediate STOP to61call of a streaming file descriptor sends an implicit immediate STOP to
61the encoder, and all buffered data is discarded. Applies to both queues of62the encoder, and all buffered data is discarded. Applies to both queues of
62mem2mem encoders.63mem2mem encoders.
@@ -65,7 +66,6 @@ These ioctls are optional, not all drivers may support them. They were · 2 unmodified lines
65introduced in Linux 2.6.21. They are, however, mandatory for stateful mem2mem66introduced in Linux 2.6.21. They are, however, mandatory for stateful mem2mem
66encoders (as further documented in :ref:`encoder`).67encoders (as further documented in :ref:`encoder`).
67 68
68
69.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|69.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
70 70
71.. c:type:: v4l2_encoder_cmd71.. c:type:: v4l2_encoder_cmd
@@ -89,7 +89,6 @@ encoders (as further documented in :ref:`encoder`). · 17 unmodified lines
89 the array to zero.89 the array to zero.
90 90
91 91
92
93.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|92.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
94 93
95.. _encoder-cmds:94.. _encoder-cmds:
@@ -134,7 +133,6 @@ encoders (as further documented in :ref:`encoder`). · 38 unmodified lines
134 the encoder is already running, this command does nothing. No133 the encoder is already running, this command does nothing. No
135 flags are defined for this command.134 flags are defined for this command.
136 135
137
138.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|136.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
139 137
140.. _encoder-flags:138.. _encoder-flags:
@@ -151,7 +149,6 @@ encoders (as further documented in :ref:`encoder`). · 10 unmodified lines
151 149
152 Does not apply to :ref:`encoder`.150 Does not apply to :ref:`encoder`.
153 151
154
155Return Value152Return Value
156============153============
157 154
Documentation/userspace-api/media/v4l/vidioc-enum-dv-timings.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUM_DV_TIMINGS:4.. _VIDIOC_ENUM_DV_TIMINGS:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUM_DV_TIMINGS - VIDIOC_SUBDEV_ENUM_DV_TIMINGS - Enumerate supported Digital Video timings13VIDIOC_ENUM_DV_TIMINGS - VIDIOC_SUBDEV_ENUM_DV_TIMINGS - Enumerate supported Digital Video timings
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUM_DV_TIMINGS, struct v4l2_enum_dv_timings *argp )18.. c:macro:: VIDIOC_ENUM_DV_TIMINGS
19 :name: VIDIOC_ENUM_DV_TIMINGS19
20``int ioctl(int fd, VIDIOC_ENUM_DV_TIMINGS, struct v4l2_enum_dv_timings *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_ENUM_DV_TIMINGS, struct v4l2_enum_dv_timings *argp )22.. c:macro:: VIDIOC_SUBDEV_ENUM_DV_TIMINGS
22 :name: VIDIOC_SUBDEV_ENUM_DV_TIMINGS
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_ENUM_DV_TIMINGS, struct v4l2_enum_dv_timings *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_enum_dv_timings`.33 Pointer to struct :c:type:`v4l2_enum_dv_timings`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -65,7 +65,6 @@ pad number in the struct · 27 unmodified lines
65Attempts to enumerate timings on a pad that doesn't support them will65Attempts to enumerate timings on a pad that doesn't support them will
66return an ``EINVAL`` error code.66return an ``EINVAL`` error code.
67 67
68
69.. c:type:: v4l2_enum_dv_timings68.. c:type:: v4l2_enum_dv_timings
70 69
71.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|70.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -91,7 +90,6 @@ return an ``EINVAL`` error code. · 19 unmodified lines
91 - ``timings``90 - ``timings``
92 - The timings.91 - The timings.
93 92
94
95Return Value93Return Value
96============94============
97 95
Documentation/userspace-api/media/v4l/vidioc-enum-fmt.rst+4−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUM_FMT:4.. _VIDIOC_ENUM_FMT:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUM_FMT - Enumerate image formats13VIDIOC_ENUM_FMT - Enumerate image formats
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUM_FMT, struct v4l2_fmtdesc *argp )18.. c:macro:: VIDIOC_ENUM_FMT
19 :name: VIDIOC_ENUM_FMT
20 19
20``int ioctl(int fd, VIDIOC_ENUM_FMT, struct v4l2_fmtdesc *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_fmtdesc`.29 Pointer to struct :c:type:`v4l2_fmtdesc`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -72,7 +71,6 @@ the ``mbus_code`` field is handled differently: · 37 unmodified lines
72 formats shall not depend on the active configuration of the video device71 formats shall not depend on the active configuration of the video device
73 or device pipeline.72 or device pipeline.
74 73
75
76.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|74.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
77 75
78.. c:type:: v4l2_fmtdesc76.. c:type:: v4l2_fmtdesc
@@ -137,7 +135,6 @@ the ``mbus_code`` field is handled differently: · 58 unmodified lines
137 zero.135 zero.
138 136
139 137
140
141.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|138.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
142 139
143.. _fmtdesc-flags:140.. _fmtdesc-flags:
@@ -227,7 +224,6 @@ the ``mbus_code`` field is handled differently: · 83 unmodified lines
227 device when calling the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl with224 device when calling the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl with
228 :ref:`V4L2_PIX_FMT_FLAG_SET_CSC <v4l2-pix-fmt-flag-set-csc>` set.225 :ref:`V4L2_PIX_FMT_FLAG_SET_CSC <v4l2-pix-fmt-flag-set-csc>` set.
229 226
230
231Return Value227Return Value
232============228============
233 229
Documentation/userspace-api/media/v4l/vidioc-enum-frameintervals.rst+4−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUM_FRAMEINTERVALS:4.. _VIDIOC_ENUM_FRAMEINTERVALS:
4 5
@@ -11,25 +12,23 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUM_FRAMEINTERVALS - Enumerate frame intervals13VIDIOC_ENUM_FRAMEINTERVALS - Enumerate frame intervals
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUM_FRAMEINTERVALS, struct v4l2_frmivalenum *argp )18.. c:macro:: VIDIOC_ENUM_FRAMEINTERVALS
19 :name: VIDIOC_ENUM_FRAMEINTERVALS
20 19
20``int ioctl(int fd, VIDIOC_ENUM_FRAMEINTERVALS, struct v4l2_frmivalenum *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_frmivalenum`29 Pointer to struct :c:type:`v4l2_frmivalenum`
30 that contains a pixel format and size and receives a frame interval.30 that contains a pixel format and size and receives a frame interval.
31 31
32
33Description32Description
34===========33===========
35 34
@@ -91,7 +90,6 @@ other ioctl calls while it runs the frame interval enumeration. · 55 unmodified lines
91 90
92 frame_rate = 1 / frame_interval91 frame_rate = 1 / frame_interval
93 92
94
95Structs93Structs
96=======94=======
97 95
@@ -99,7 +97,6 @@ In the structs below, *IN* denotes a value that has to be filled in by · 1 unmodified line
99the application, *OUT* denotes values that the driver fills in. The97the application, *OUT* denotes values that the driver fills in. The
100application should zero out all members except for the *IN* fields.98application should zero out all members except for the *IN* fields.
101 99
102
103.. c:type:: v4l2_frmival_stepwise100.. c:type:: v4l2_frmival_stepwise
104 101
105.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|102.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -120,7 +117,6 @@ application should zero out all members except for the *IN* fields. · 14 unmodified lines
120 - Frame interval step size [s].117 - Frame interval step size [s].
121 118
122 119
123
124.. c:type:: v4l2_frmivalenum120.. c:type:: v4l2_frmivalenum
125 121
126.. tabularcolumns:: |p{1.8cm}|p{4.4cm}|p{2.4cm}|p{8.9cm}|122.. tabularcolumns:: |p{1.8cm}|p{4.4cm}|p{2.4cm}|p{8.9cm}|
@@ -163,11 +159,9 @@ application should zero out all members except for the *IN* fields. · 36 unmodified lines
163 applications.159 applications.
164 160
165 161
166
167Enums162Enums
168=====163=====
169 164
170
171.. c:type:: v4l2_frmivaltypes165.. c:type:: v4l2_frmivaltypes
172 166
173.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|167.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
@@ -187,7 +181,6 @@ Enums · 13 unmodified lines
187 - 3181 - 3
188 - Step-wise defined frame interval.182 - Step-wise defined frame interval.
189 183
190
191Return Value184Return Value
192============185============
193 186
Documentation/userspace-api/media/v4l/vidioc-enum-framesizes.rst+4−12
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUM_FRAMESIZES:4.. _VIDIOC_ENUM_FRAMESIZES:
4 5
@@ -11,26 +12,24 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUM_FRAMESIZES - Enumerate frame sizes13VIDIOC_ENUM_FRAMESIZES - Enumerate frame sizes
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUM_FRAMESIZES, struct v4l2_frmsizeenum *argp )18.. c:macro:: VIDIOC_ENUM_FRAMESIZES
19 :name: VIDIOC_ENUM_FRAMESIZES
20 19
20``int ioctl(int fd, VIDIOC_ENUM_FRAMESIZES, struct v4l2_frmsizeenum *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_frmsizeenum`29 Pointer to struct :c:type:`v4l2_frmsizeenum`
30 that contains an index and pixel format and receives a frame width30 that contains an index and pixel format and receives a frame width
31 and height.31 and height.
32 32
33
34Description33Description
35===========34===========
36 35
@@ -81,7 +80,6 @@ without any interaction from the application itself. This means that the · 44 unmodified lines
81enumeration data is consistent if the application does not perform any80enumeration data is consistent if the application does not perform any
82other ioctl calls while it runs the frame size enumeration.81other ioctl calls while it runs the frame size enumeration.
83 82
84
85Structs83Structs
86=======84=======
87 85
@@ -89,7 +87,6 @@ In the structs below, *IN* denotes a value that has to be filled in by · 1 unmodified line
89the application, *OUT* denotes values that the driver fills in. The87the application, *OUT* denotes values that the driver fills in. The
90application should zero out all members except for the *IN* fields.88application should zero out all members except for the *IN* fields.
91 89
92
93.. c:type:: v4l2_frmsize_discrete90.. c:type:: v4l2_frmsize_discrete
94 91
95.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|92.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -107,7 +104,6 @@ application should zero out all members except for the *IN* fields. · 11 unmodified lines
107 - Height of the frame [pixel].104 - Height of the frame [pixel].
108 105
109 106
110
111.. c:type:: v4l2_frmsize_stepwise107.. c:type:: v4l2_frmsize_stepwise
112 108
113.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|109.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -137,7 +133,6 @@ application should zero out all members except for the *IN* fields. · 23 unmodified lines
137 - Frame height step size [pixel].133 - Frame height step size [pixel].
138 134
139 135
140
141.. c:type:: v4l2_frmsizeenum136.. c:type:: v4l2_frmsizeenum
142 137
143.. tabularcolumns:: |p{1.4cm}|p{5.9cm}|p{2.3cm}|p{8.0cm}|138.. tabularcolumns:: |p{1.4cm}|p{5.9cm}|p{2.3cm}|p{8.0cm}|
@@ -173,11 +168,9 @@ application should zero out all members except for the *IN* fields. · 29 unmodified lines
173 applications.168 applications.
174 169
175 170
176
177Enums171Enums
178=====172=====
179 173
180
181.. c:type:: v4l2_frmsizetypes174.. c:type:: v4l2_frmsizetypes
182 175
183.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|176.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
@@ -197,7 +190,6 @@ Enums · 13 unmodified lines
197 - 3190 - 3
198 - Step-wise defined frame size.191 - Step-wise defined frame size.
199 192
200
201Return Value193Return Value
202============194============
203 195
Documentation/userspace-api/media/v4l/vidioc-enum-freq-bands.rst+4−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUM_FREQ_BANDS:4.. _VIDIOC_ENUM_FREQ_BANDS:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUM_FREQ_BANDS - Enumerate supported frequency bands13VIDIOC_ENUM_FREQ_BANDS - Enumerate supported frequency bands
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUM_FREQ_BANDS, struct v4l2_frequency_band *argp )18.. c:macro:: VIDIOC_ENUM_FREQ_BANDS
19 :name: VIDIOC_ENUM_FREQ_BANDS
20 19
20``int ioctl(int fd, VIDIOC_ENUM_FREQ_BANDS, struct v4l2_frequency_band *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_frequency_band`.29 Pointer to struct :c:type:`v4l2_frequency_band`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -41,7 +40,6 @@ fields, and zero out the ``reserved`` array of a struct · 6 unmodified lines
41This ioctl is supported if the ``V4L2_TUNER_CAP_FREQ_BANDS`` capability40This ioctl is supported if the ``V4L2_TUNER_CAP_FREQ_BANDS`` capability
42of the corresponding tuner/modulator is set.41of the corresponding tuner/modulator is set.
43 42
44
45.. tabularcolumns:: |p{2.9cm}|p{2.9cm}|p{5.8cm}|p{2.9cm}|p{3.0cm}|43.. tabularcolumns:: |p{2.9cm}|p{2.9cm}|p{5.8cm}|p{2.9cm}|p{3.0cm}|
46 44
47.. c:type:: v4l2_frequency_band45.. c:type:: v4l2_frequency_band
@@ -110,7 +108,6 @@ of the corresponding tuner/modulator is set. · 62 unmodified lines
110 Applications and drivers must set the array to zero.108 Applications and drivers must set the array to zero.
111 109
112 110
113
114.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|111.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
115 112
116.. _band-modulation:113.. _band-modulation:
@@ -130,7 +127,6 @@ of the corresponding tuner/modulator is set. · 13 unmodified lines
130 - 0x08127 - 0x08
131 - Amplitude Modulation, commonly used for analog radio.128 - Amplitude Modulation, commonly used for analog radio.
132 129
133
134Return Value130Return Value
135============131============
136 132
Documentation/userspace-api/media/v4l/vidioc-enumaudio.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUMAUDIO:4.. _VIDIOC_ENUMAUDIO:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUMAUDIO - Enumerate audio inputs13VIDIOC_ENUMAUDIO - Enumerate audio inputs
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUMAUDIO, struct v4l2_audio *argp )18.. c:macro:: VIDIOC_ENUMAUDIO
19 :name: VIDIOC_ENUMAUDIO
20 19
20``int ioctl(int fd, VIDIOC_ENUMAUDIO, struct v4l2_audio *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_audio`.29 Pointer to struct :c:type:`v4l2_audio`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -43,7 +42,6 @@ zero, incrementing by one until the driver returns ``EINVAL``. · 8 unmodified lines
43See :ref:`VIDIOC_G_AUDIO <VIDIOC_G_AUDIO>` for a description of struct42See :ref:`VIDIOC_G_AUDIO <VIDIOC_G_AUDIO>` for a description of struct
44:c:type:`v4l2_audio`.43:c:type:`v4l2_audio`.
45 44
46
47Return Value45Return Value
48============46============
49 47
Documentation/userspace-api/media/v4l/vidioc-enumaudioout.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUMAUDOUT:4.. _VIDIOC_ENUMAUDOUT:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUMAUDOUT - Enumerate audio outputs13VIDIOC_ENUMAUDOUT - Enumerate audio outputs
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUMAUDOUT, struct v4l2_audioout *argp )18.. c:macro:: VIDIOC_ENUMAUDOUT
19 :name: VIDIOC_ENUMAUDOUT
20 19
20``int ioctl(int fd, VIDIOC_ENUMAUDOUT, struct v4l2_audioout *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_audioout`.29 Pointer to struct :c:type:`v4l2_audioout`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -48,7 +47,6 @@ zero, incrementing by one until the driver returns ``EINVAL``. · 13 unmodified lines
48See :ref:`VIDIOC_G_AUDIOout <VIDIOC_G_AUDOUT>` for a description of struct47See :ref:`VIDIOC_G_AUDIOout <VIDIOC_G_AUDOUT>` for a description of struct
49:c:type:`v4l2_audioout`.48:c:type:`v4l2_audioout`.
50 49
51
52Return Value50Return Value
53============51============
54 52
Documentation/userspace-api/media/v4l/vidioc-enuminput.rst+4−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUMINPUT:4.. _VIDIOC_ENUMINPUT:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUMINPUT - Enumerate video inputs13VIDIOC_ENUMINPUT - Enumerate video inputs
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUMINPUT, struct v4l2_input *argp )18.. c:macro:: VIDIOC_ENUMINPUT
19 :name: VIDIOC_ENUMINPUT
20 19
20``int ioctl(int fd, VIDIOC_ENUMINPUT, struct v4l2_input *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_input`.29 Pointer to struct :c:type:`v4l2_input`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -39,7 +38,6 @@ fill the rest of the structure or return an ``EINVAL`` error code when the · 4 unmodified lines
39index is out of bounds. To enumerate all inputs applications shall begin38index is out of bounds. To enumerate all inputs applications shall begin
40at index zero, incrementing by one until the driver returns ``EINVAL``.39at index zero, incrementing by one until the driver returns ``EINVAL``.
41 40
42
43.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|41.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
44 42
45.. c:type:: v4l2_input43.. c:type:: v4l2_input
@@ -103,7 +101,6 @@ at index zero, incrementing by one until the driver returns ``EINVAL``. · 57 unmodified lines
103 zero.101 zero.
104 102
105 103
106
107.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|104.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
108 105
109.. _input-type:106.. _input-type:
@@ -126,7 +123,6 @@ at index zero, incrementing by one until the driver returns ``EINVAL``. · 16 unmodified lines
126 - This input is a touch device for capturing raw touch data.123 - This input is a touch device for capturing raw touch data.
127 124
128 125
129
130.. tabularcolumns:: |p{4.8cm}|p{2.6cm}|p{10.1cm}|126.. tabularcolumns:: |p{4.8cm}|p{2.6cm}|p{10.1cm}|
131 127
132.. _input-status:128.. _input-status:
@@ -198,7 +194,6 @@ at index zero, incrementing by one until the driver returns ``EINVAL``. · 65 unmodified lines
198 - VTR time constant. [?]194 - VTR time constant. [?]
199 195
200 196
201
202.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|197.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
203 198
204.. _input-capabilities:199.. _input-capabilities:
@@ -222,7 +217,6 @@ at index zero, incrementing by one until the driver returns ``EINVAL``. · 17 unmodified lines
222 ``V4L2_SEL_TGT_NATIVE_SIZE`` selection target, see217 ``V4L2_SEL_TGT_NATIVE_SIZE`` selection target, see
223 :ref:`v4l2-selections-common`.218 :ref:`v4l2-selections-common`.
224 219
225
226Return Value220Return Value
227============221============
228 222
Documentation/userspace-api/media/v4l/vidioc-enumoutput.rst+4−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUMOUTPUT:4.. _VIDIOC_ENUMOUTPUT:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUMOUTPUT - Enumerate video outputs13VIDIOC_ENUMOUTPUT - Enumerate video outputs
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUMOUTPUT, struct v4l2_output *argp )18.. c:macro:: VIDIOC_ENUMOUTPUT
19 :name: VIDIOC_ENUMOUTPUT
20 19
20``int ioctl(int fd, VIDIOC_ENUMOUTPUT, struct v4l2_output *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_output`.29 Pointer to struct :c:type:`v4l2_output`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -40,7 +39,6 @@ when the index is out of bounds. To enumerate all outputs applications · 5 unmodified lines
40shall begin at index zero, incrementing by one until the driver returns39shall begin at index zero, incrementing by one until the driver returns
41``EINVAL``.40``EINVAL``.
42 41
43
44.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|42.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
45 43
46.. c:type:: v4l2_output44.. c:type:: v4l2_output
@@ -98,7 +96,6 @@ shall begin at index zero, incrementing by one until the driver returns · 51 unmodified lines
98 zero.96 zero.
99 97
100 98
101
102.. tabularcolumns:: |p{7.0cm}|p{1.8cm}|p{8.7cm}|99.. tabularcolumns:: |p{7.0cm}|p{1.8cm}|p{8.7cm}|
103 100
104.. _output-type:101.. _output-type:
@@ -121,7 +118,6 @@ shall begin at index zero, incrementing by one until the driver returns · 16 unmodified lines
121 - The video output will be copied to a :ref:`video overlay <overlay>`.118 - The video output will be copied to a :ref:`video overlay <overlay>`.
122 119
123 120
124
125.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|121.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
126 122
127.. _output-capabilities:123.. _output-capabilities:
@@ -145,7 +141,6 @@ shall begin at index zero, incrementing by one until the driver returns · 17 unmodified lines
145 ``V4L2_SEL_TGT_NATIVE_SIZE`` selection target, see141 ``V4L2_SEL_TGT_NATIVE_SIZE`` selection target, see
146 :ref:`v4l2-selections-common`.142 :ref:`v4l2-selections-common`.
147 143
148
149Return Value144Return Value
150============145============
151 146
Documentation/userspace-api/media/v4l/vidioc-enumstd.rst+7−16
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_ENUMSTD:4.. _VIDIOC_ENUMSTD:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_ENUMSTD - VIDIOC_SUBDEV_ENUMSTD - Enumerate supported video standards13VIDIOC_ENUMSTD - VIDIOC_SUBDEV_ENUMSTD - Enumerate supported video standards
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_ENUMSTD, struct v4l2_standard *argp )18.. c:macro:: VIDIOC_ENUMSTD
19 :name: VIDIOC_ENUMSTD19
20``int ioctl(int fd, VIDIOC_ENUMSTD, struct v4l2_standard *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_ENUMSTD, struct v4l2_standard *argp )22.. c:macro:: VIDIOC_SUBDEV_ENUMSTD
22 :name: VIDIOC_SUBDEV_ENUMSTD
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_ENUMSTD, struct v4l2_standard *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_standard`.33 Pointer to struct :c:type:`v4l2_standard`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -45,7 +45,6 @@ zero, incrementing by one until the driver returns ``EINVAL``. Drivers may · 7 unmodified lines
45enumerate a different set of standards after switching the video input45enumerate a different set of standards after switching the video input
46or output. [#f1]_46or output. [#f1]_
47 47
48
49.. c:type:: v4l2_standard48.. c:type:: v4l2_standard
50 49
51.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|50.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -85,7 +84,6 @@ or output. [#f1]_ · 33 unmodified lines
85 zero.84 zero.
86 85
87 86
88
89.. c:type:: v4l2_fract87.. c:type:: v4l2_fract
90 88
91.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|89.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -102,7 +100,6 @@ or output. [#f1]_ · 10 unmodified lines
102 - ``denominator``100 - ``denominator``
103 -101 -
104 102
105
106.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|103.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
107 104
108.. _v4l2-std-id:105.. _v4l2-std-id:
@@ -120,7 +117,6 @@ or output. [#f1]_ · 11 unmodified lines
120 standards.117 standards.
121 118
122 119
123
124.. code-block:: c120.. code-block:: c
125 121
126 #define V4L2_STD_PAL_B ((v4l2_std_id)0x00000001)122 #define V4L2_STD_PAL_B ((v4l2_std_id)0x00000001)
@@ -142,7 +138,6 @@ rate, and PAL color modulation with a 4.43 MHz color subcarrier. Some · 15 unmodified lines
142PAL video recorders can play back NTSC tapes in this mode for display on138PAL video recorders can play back NTSC tapes in this mode for display on
143a 50/60 Hz agnostic PAL TV.139a 50/60 Hz agnostic PAL TV.
144 140
145
146.. code-block:: c141.. code-block:: c
147 142
148 #define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000)143 #define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000)
@@ -152,7 +147,6 @@ a 50/60 Hz agnostic PAL TV. · 3 unmodified lines
152``V4L2_STD_NTSC_443`` is a hybrid standard with 525 lines, 60 Hz refresh147``V4L2_STD_NTSC_443`` is a hybrid standard with 525 lines, 60 Hz refresh
153rate, and NTSC color modulation with a 4.43 MHz color subcarrier.148rate, and NTSC color modulation with a 4.43 MHz color subcarrier.
154 149
155
156.. code-block:: c150.. code-block:: c
157 151
158 #define V4L2_STD_NTSC_M_KR ((v4l2_std_id)0x00008000)152 #define V4L2_STD_NTSC_M_KR ((v4l2_std_id)0x00008000)
@@ -175,7 +169,6 @@ terrestrial digital TV standards. Presently the V4L2 API does not · 16 unmodified lines
175support digital TV. See also the Linux DVB API at169support digital TV. See also the Linux DVB API at
176`https://linuxtv.org <https://linuxtv.org>`__.170`https://linuxtv.org <https://linuxtv.org>`__.
177 171
178
179.. code-block:: c172.. code-block:: c
180 173
181 #define V4L2_STD_PAL_BG (V4L2_STD_PAL_B |174 #define V4L2_STD_PAL_BG (V4L2_STD_PAL_B |
@@ -228,7 +221,6 @@ support digital TV. See also the Linux DVB API at · 46 unmodified lines
228 #define V4L2_STD_ALL (V4L2_STD_525_60 |221 #define V4L2_STD_ALL (V4L2_STD_525_60 |
229 V4L2_STD_625_50)222 V4L2_STD_625_50)
230 223
231
232.. raw:: latex224.. raw:: latex
233 225
234 \begingroup226 \begingroup
@@ -303,7 +295,6 @@ support digital TV. See also the Linux DVB API at · 68 unmodified lines
303 \endgroup295 \endgroup
304 296
305 297
306
307Return Value298Return Value
308============299============
309 300
Documentation/userspace-api/media/v4l/vidioc-expbuf.rst+4−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_EXPBUF:4.. _VIDIOC_EXPBUF:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_EXPBUF - Export a buffer as a DMABUF file descriptor.13VIDIOC_EXPBUF - Export a buffer as a DMABUF file descriptor.
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_EXPBUF, struct v4l2_exportbuffer *argp )18.. c:macro:: VIDIOC_EXPBUF
19 :name: VIDIOC_EXPBUF
20 19
20``int ioctl(int fd, VIDIOC_EXPBUF, struct v4l2_exportbuffer *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_exportbuffer`.29 Pointer to struct :c:type:`v4l2_exportbuffer`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -63,11 +62,9 @@ for details about importing DMABUF files into V4L2 nodes. It is · 28 unmodified lines
63recommended to close a DMABUF file when it is no longer used to allow62recommended to close a DMABUF file when it is no longer used to allow
64the associated memory to be reclaimed.63the associated memory to be reclaimed.
65 64
66
67Examples65Examples
68========66========
69 67
70
71.. code-block:: c68.. code-block:: c
72 69
73 int buffer_export(int v4lfd, enum v4l2_buf_type bt, int index, int *dmafd)70 int buffer_export(int v4lfd, enum v4l2_buf_type bt, int index, int *dmafd)
@@ -87,7 +84,6 @@ Examples · 13 unmodified lines
87 return 0;84 return 0;
88 }85 }
89 86
90
91.. code-block:: c87.. code-block:: c
92 88
93 int buffer_export_mp(int v4lfd, enum v4l2_buf_type bt, int index,89 int buffer_export_mp(int v4lfd, enum v4l2_buf_type bt, int index,
@@ -114,7 +110,6 @@ Examples · 20 unmodified lines
114 return 0;110 return 0;
115 }111 }
116 112
117
118.. c:type:: v4l2_exportbuffer113.. c:type:: v4l2_exportbuffer
119 114
120.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|115.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -155,7 +150,6 @@ Examples · 34 unmodified lines
155 - Reserved field for future use. Drivers and applications must set150 - Reserved field for future use. Drivers and applications must set
156 the array to zero.151 the array to zero.
157 152
158
159Return Value153Return Value
160============154============
161 155
Documentation/userspace-api/media/v4l/vidioc-g-audio.rst+7−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_AUDIO:4.. _VIDIOC_G_AUDIO:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_AUDIO - VIDIOC_S_AUDIO - Query or select the current audio input and its attributes13VIDIOC_G_AUDIO - VIDIOC_S_AUDIO - Query or select the current audio input and its attributes
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_AUDIO, struct v4l2_audio *argp )18.. c:macro:: VIDIOC_G_AUDIO
19 :name: VIDIOC_G_AUDIO19
20``int ioctl(int fd, VIDIOC_G_AUDIO, struct v4l2_audio *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_AUDIO, const struct v4l2_audio *argp )22.. c:macro:: VIDIOC_S_AUDIO
22 :name: VIDIOC_S_AUDIO
23 23
24``int ioctl(int fd, VIDIOC_S_AUDIO, const struct v4l2_audio *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_audio`.33 Pointer to struct :c:type:`v4l2_audio`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -49,7 +49,6 @@ ioctl. Drivers may switch to a different audio mode if the request · 11 unmodified lines
49cannot be satisfied. However, this is a write-only ioctl, it does not49cannot be satisfied. However, this is a write-only ioctl, it does not
50return the actual new audio mode.50return the actual new audio mode.
51 51
52
53.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|52.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
54 53
55.. c:type:: v4l2_audio54.. c:type:: v4l2_audio
@@ -80,7 +79,6 @@ return the actual new audio mode. · 24 unmodified lines
80 the array to zero.79 the array to zero.
81 80
82 81
83
84.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|82.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
85 83
86.. _audio-capability:84.. _audio-capability:
@@ -101,7 +99,6 @@ return the actual new audio mode. · 14 unmodified lines
101 - Automatic Volume Level mode is supported.99 - Automatic Volume Level mode is supported.
102 100
103 101
104
105.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|102.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
106 103
107.. _audio-mode:104.. _audio-mode:
@@ -115,7 +112,6 @@ return the actual new audio mode. · 7 unmodified lines
115 - 0x00001112 - 0x00001
116 - AVL mode is on.113 - AVL mode is on.
117 114
118
119Return Value115Return Value
120============116============
121 117
Documentation/userspace-api/media/v4l/vidioc-g-audioout.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_AUDOUT:4.. _VIDIOC_G_AUDOUT:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_AUDOUT - VIDIOC_S_AUDOUT - Query or select the current audio output13VIDIOC_G_AUDOUT - VIDIOC_S_AUDOUT - Query or select the current audio output
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_AUDOUT, struct v4l2_audioout *argp )18.. c:macro:: VIDIOC_G_AUDOUT
19 :name: VIDIOC_G_AUDOUT19
20``int ioctl(int fd, VIDIOC_G_AUDOUT, struct v4l2_audioout *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_AUDOUT, const struct v4l2_audioout *argp )22.. c:macro:: VIDIOC_S_AUDOUT
22 :name: VIDIOC_S_AUDOUT
23 23
24``int ioctl(int fd, VIDIOC_S_AUDOUT, const struct v4l2_audioout *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_audioout`.33 Pointer to struct :c:type:`v4l2_audioout`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -56,7 +56,6 @@ as ``VIDIOC_G_AUDOUT`` does. · 18 unmodified lines
56 Connectors on a TV card to loop back the received audio signal56 Connectors on a TV card to loop back the received audio signal
57 to a sound card are not audio outputs in this sense.57 to a sound card are not audio outputs in this sense.
58 58
59
60.. c:type:: v4l2_audioout59.. c:type:: v4l2_audioout
61 60
62.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|61.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -87,7 +86,6 @@ as ``VIDIOC_G_AUDOUT`` does. · 24 unmodified lines
87 - Reserved for future extensions. Drivers and applications must set86 - Reserved for future extensions. Drivers and applications must set
88 the array to zero.87 the array to zero.
89 88
90
91Return Value89Return Value
92============90============
93 91
Documentation/userspace-api/media/v4l/vidioc-g-crop.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_CROP:4.. _VIDIOC_G_CROP:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_CROP - VIDIOC_S_CROP - Get or set the current cropping rectangle13VIDIOC_G_CROP - VIDIOC_S_CROP - Get or set the current cropping rectangle
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_CROP, struct v4l2_crop *argp )18.. c:macro:: VIDIOC_G_CROP
19 :name: VIDIOC_G_CROP19
20``int ioctl(int fd, VIDIOC_G_CROP, struct v4l2_crop *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_CROP, const struct v4l2_crop *argp )22.. c:macro:: VIDIOC_S_CROP
22 :name: VIDIOC_S_CROP
23 23
24``int ioctl(int fd, VIDIOC_S_CROP, const struct v4l2_crop *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_crop`.33 Pointer to struct :c:type:`v4l2_crop`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -69,7 +69,6 @@ been negotiated. · 31 unmodified lines
69When cropping is not supported then no parameters are changed and69When cropping is not supported then no parameters are changed and
70:ref:`VIDIOC_S_CROP <VIDIOC_G_CROP>` returns the ``EINVAL`` error code.70:ref:`VIDIOC_S_CROP <VIDIOC_G_CROP>` returns the ``EINVAL`` error code.
71 71
72
73.. c:type:: v4l2_crop72.. c:type:: v4l2_crop
74 73
75.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|74.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -100,7 +99,6 @@ When cropping is not supported then no parameters are changed and · 24 unmodified lines
100 99
101 Starting with kernel 4.13 both variations are allowed.100 Starting with kernel 4.13 both variations are allowed.
102 101
103
104Return Value102Return Value
105============103============
106 104
Documentation/userspace-api/media/v4l/vidioc-g-ctrl.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_CTRL:4.. _VIDIOC_G_CTRL:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_CTRL - VIDIOC_S_CTRL - Get or set the value of a control13VIDIOC_G_CTRL - VIDIOC_S_CTRL - Get or set the value of a control
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_CTRL, struct v4l2_control *argp )18.. c:macro:: VIDIOC_G_CTRL
19 :name: VIDIOC_G_CTRL19
20``int ioctl(int fd, VIDIOC_G_CTRL, struct v4l2_control *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_CTRL, struct v4l2_control *argp )22.. c:macro:: VIDIOC_S_CTRL
22 :name: VIDIOC_S_CTRL
23 23
24``int ioctl(int fd, VIDIOC_S_CTRL, struct v4l2_control *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_control`.33 Pointer to struct :c:type:`v4l2_control`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -55,7 +55,6 @@ These ioctls work only with user controls. For other control classes the · 17 unmodified lines
55:ref:`VIDIOC_S_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>` or55:ref:`VIDIOC_S_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>` or
56:ref:`VIDIOC_TRY_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>` must be used.56:ref:`VIDIOC_TRY_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>` must be used.
57 57
58
59.. c:type:: v4l2_control58.. c:type:: v4l2_control
60 59
61.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|60.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -72,7 +71,6 @@ These ioctls work only with user controls. For other control classes the · 10 unmodified lines
72 - ``value``71 - ``value``
73 - New value or current value.72 - New value or current value.
74 73
75
76Return Value74Return Value
77============75============
78 76
Documentation/userspace-api/media/v4l/vidioc-g-dv-timings.rst+13−13
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_DV_TIMINGS:4.. _VIDIOC_G_DV_TIMINGS:
4 5
@@ -11,33 +12,34 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_DV_TIMINGS - VIDIOC_S_DV_TIMINGS - VIDIOC_SUBDEV_G_DV_TIMINGS - VIDIOC_SUBDEV_S_DV_TIMINGS - Get or set DV timings for input or output13VIDIOC_G_DV_TIMINGS - VIDIOC_S_DV_TIMINGS - VIDIOC_SUBDEV_G_DV_TIMINGS - VIDIOC_SUBDEV_S_DV_TIMINGS - Get or set DV timings for input or output
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_DV_TIMINGS, struct v4l2_dv_timings *argp )18.. c:macro:: VIDIOC_G_DV_TIMINGS
19 :name: VIDIOC_G_DV_TIMINGS19
20``int ioctl(int fd, VIDIOC_G_DV_TIMINGS, struct v4l2_dv_timings *argp)``
21
22.. c:macro:: VIDIOC_S_DV_TIMINGS
23
24``int ioctl(int fd, VIDIOC_S_DV_TIMINGS, struct v4l2_dv_timings *argp)``
20 25
21.. c:function:: int ioctl( int fd, VIDIOC_S_DV_TIMINGS, struct v4l2_dv_timings *argp )26.. c:macro:: VIDIOC_SUBDEV_G_DV_TIMINGS
22 :name: VIDIOC_S_DV_TIMINGS
23 27
24.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_DV_TIMINGS, struct v4l2_dv_timings *argp )28``int ioctl(int fd, VIDIOC_SUBDEV_G_DV_TIMINGS, struct v4l2_dv_timings *argp)``
25 :name: VIDIOC_SUBDEV_G_DV_TIMINGS
26 29
27.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_DV_TIMINGS, struct v4l2_dv_timings *argp )30.. c:macro:: VIDIOC_SUBDEV_S_DV_TIMINGS
28 :name: VIDIOC_SUBDEV_S_DV_TIMINGS
29 31
32``int ioctl(int fd, VIDIOC_SUBDEV_S_DV_TIMINGS, struct v4l2_dv_timings *argp)``
30 33
31Arguments34Arguments
32=========35=========
33 36
34``fd``37``fd``
35 File descriptor returned by :ref:`open() <func-open>`.38 File descriptor returned by :c:func:`open()`.
36 39
37``argp``40``argp``
38 Pointer to struct :c:type:`v4l2_dv_timings`.41 Pointer to struct :c:type:`v4l2_dv_timings`.
39 42
40
41Description43Description
42===========44===========
43 45
@@ -60,7 +62,6 @@ the current input or output does not support DV timings (e.g. if · 16 unmodified lines
60:ref:`VIDIOC_ENUMINPUT` does not set the62:ref:`VIDIOC_ENUMINPUT` does not set the
61``V4L2_IN_CAP_DV_TIMINGS`` flag), then ``ENODATA`` error code is returned.63``V4L2_IN_CAP_DV_TIMINGS`` flag), then ``ENODATA`` error code is returned.
62 64
63
64Return Value65Return Value
65============66============
66 67
@@ -170,7 +171,6 @@ EPERM · 103 unmodified lines
170 - Reserved for future extensions. Drivers and applications must set171 - Reserved for future extensions. Drivers and applications must set
171 the array to zero.172 the array to zero.
172 173
173
174.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|174.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|
175 175
176.. c:type:: v4l2_dv_timings176.. c:type:: v4l2_dv_timings
Documentation/userspace-api/media/v4l/vidioc-g-edid.rst+12−13
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_EDID:4.. _VIDIOC_G_EDID:
4 5
@@ -11,34 +12,34 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_EDID - VIDIOC_S_EDID - VIDIOC_SUBDEV_G_EDID - VIDIOC_SUBDEV_S_EDID - Get or set the EDID of a video receiver/transmitter13VIDIOC_G_EDID - VIDIOC_S_EDID - VIDIOC_SUBDEV_G_EDID - VIDIOC_SUBDEV_S_EDID - Get or set the EDID of a video receiver/transmitter
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_EDID, struct v4l2_edid *argp )18.. c:macro:: VIDIOC_G_EDID
19 :name: VIDIOC_G_EDID19
20``int ioctl(int fd, VIDIOC_G_EDID, struct v4l2_edid *argp)``
21
22.. c:macro:: VIDIOC_S_EDID
20 23
21.. c:function:: int ioctl( int fd, VIDIOC_S_EDID, struct v4l2_edid *argp )24``int ioctl(int fd, VIDIOC_S_EDID, struct v4l2_edid *argp)``
22 :name: VIDIOC_S_EDID
23 25
26.. c:macro:: VIDIOC_SUBDEV_G_EDID
24 27
25.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_EDID, struct v4l2_edid *argp )28``int ioctl(int fd, VIDIOC_SUBDEV_G_EDID, struct v4l2_edid *argp)``
26 :name: VIDIOC_SUBDEV_G_EDID
27 29
28.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_EDID, struct v4l2_edid *argp )30.. c:macro:: VIDIOC_SUBDEV_S_EDID
29 :name: VIDIOC_SUBDEV_S_EDID
30 31
32``int ioctl(int fd, VIDIOC_SUBDEV_S_EDID, struct v4l2_edid *argp)``
31 33
32Arguments34Arguments
33=========35=========
34 36
35``fd``37``fd``
36 File descriptor returned by :ref:`open() <func-open>`.38 File descriptor returned by :c:func:`open()`.
37 39
38``argp``40``argp``
39 Pointer to struct :c:type:`v4l2_edid`.41 Pointer to struct :c:type:`v4l2_edid`.
40 42
41
42Description43Description
43===========44===========
44 45
@@ -97,7 +98,6 @@ this will drive the hotplug pin low and/or block the source from reading · 52 unmodified lines
97the EDID data in some way. In any case, the end result is the same: the98the EDID data in some way. In any case, the end result is the same: the
98EDID is no longer available.99EDID is no longer available.
99 100
100
101.. c:type:: v4l2_edid101.. c:type:: v4l2_edid
102 102
103.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|103.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -132,7 +132,6 @@ EDID is no longer available. · 28 unmodified lines
132 - Pointer to memory that contains the EDID. The minimum size is132 - Pointer to memory that contains the EDID. The minimum size is
133 ``blocks`` * 128.133 ``blocks`` * 128.
134 134
135
136Return Value135Return Value
137============136============
138 137
Documentation/userspace-api/media/v4l/vidioc-g-enc-index.rst+4−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_ENC_INDEX:4.. _VIDIOC_G_ENC_INDEX:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_ENC_INDEX - Get meta data about a compressed video stream13VIDIOC_G_ENC_INDEX - Get meta data about a compressed video stream
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_ENC_INDEX, struct v4l2_enc_idx *argp )18.. c:macro:: VIDIOC_G_ENC_INDEX
19 :name: VIDIOC_G_ENC_INDEX
20 19
20``int ioctl(int fd, VIDIOC_G_ENC_INDEX, struct v4l2_enc_idx *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_enc_idx`.29 Pointer to struct :c:type:`v4l2_enc_idx`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -55,7 +54,6 @@ will be zero. · 20 unmodified lines
55Currently this ioctl is only defined for MPEG-2 program streams and54Currently this ioctl is only defined for MPEG-2 program streams and
56video elementary streams.55video elementary streams.
57 56
58
59.. tabularcolumns:: |p{3.8cm}|p{5.6cm}|p{8.1cm}|57.. tabularcolumns:: |p{3.8cm}|p{5.6cm}|p{8.1cm}|
60 58
61.. c:type:: v4l2_enc_idx59.. c:type:: v4l2_enc_idx
@@ -83,7 +81,6 @@ video elementary streams. · 21 unmodified lines
83 their ``offset``.81 their ``offset``.
84 82
85 83
86
87.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|84.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
88 85
89.. c:type:: v4l2_enc_idx_entry86.. c:type:: v4l2_enc_idx_entry
@@ -116,7 +113,6 @@ video elementary streams. · 26 unmodified lines
116 - Reserved for future extensions. Drivers must set the array to113 - Reserved for future extensions. Drivers must set the array to
117 zero.114 zero.
118 115
119
120.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|116.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
121 117
122.. _enc-idx-flags:118.. _enc-idx-flags:
@@ -140,7 +136,6 @@ video elementary streams. · 17 unmodified lines
140 - *AND* the flags field with this mask to obtain the picture coding136 - *AND* the flags field with this mask to obtain the picture coding
141 type.137 type.
142 138
143
144Return Value139Return Value
145============140============
146 141
Documentation/userspace-api/media/v4l/vidioc-g-ext-ctrls.rst+8−13
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_EXT_CTRLS:4.. _VIDIOC_G_EXT_CTRLS:
4 5
@@ -11,32 +12,30 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_EXT_CTRLS - VIDIOC_S_EXT_CTRLS - VIDIOC_TRY_EXT_CTRLS - Get or set the value of several controls, try control values13VIDIOC_G_EXT_CTRLS - VIDIOC_S_EXT_CTRLS - VIDIOC_TRY_EXT_CTRLS - Get or set the value of several controls, try control values
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_EXT_CTRLS, struct v4l2_ext_controls *argp )18.. c:macro:: VIDIOC_G_EXT_CTRLS
19 :name: VIDIOC_G_EXT_CTRLS
20 19
20``int ioctl(int fd, VIDIOC_G_EXT_CTRLS, struct v4l2_ext_controls *argp)``
21 21
22.. c:function:: int ioctl( int fd, VIDIOC_S_EXT_CTRLS, struct v4l2_ext_controls *argp )22.. c:macro:: VIDIOC_S_EXT_CTRLS
23 :name: VIDIOC_S_EXT_CTRLS
24 23
24``int ioctl(int fd, VIDIOC_S_EXT_CTRLS, struct v4l2_ext_controls *argp)``
25 25
26.. c:function:: int ioctl( int fd, VIDIOC_TRY_EXT_CTRLS, struct v4l2_ext_controls *argp )26.. c:macro:: VIDIOC_TRY_EXT_CTRLS
27 :name: VIDIOC_TRY_EXT_CTRLS
28 27
28``int ioctl(int fd, VIDIOC_TRY_EXT_CTRLS, struct v4l2_ext_controls *argp)``
29 29
30Arguments30Arguments
31=========31=========
32 32
33``fd``33``fd``
34 File descriptor returned by :ref:`open() <func-open>`.34 File descriptor returned by :c:func:`open()`.
35 35
36``argp``36``argp``
37 Pointer to struct :c:type:`v4l2_ext_controls`.37 Pointer to struct :c:type:`v4l2_ext_controls`.
38 38
39
40Description39Description
41===========40===========
42 41
@@ -119,7 +118,6 @@ correct. This prevents the situation where only some of the controls · 76 unmodified lines
119were set/get. Only low-level errors (e. g. a failed i2c command) can118were set/get. Only low-level errors (e. g. a failed i2c command) can
120still cause this situation.119still cause this situation.
121 120
122
123.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{1.5cm}|p{11.8cm}|121.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{1.5cm}|p{11.8cm}|
124 122
125.. c:type:: v4l2_ext_control123.. c:type:: v4l2_ext_control
@@ -195,7 +193,6 @@ still cause this situation. · 69 unmodified lines
195 * - }193 * - }
196 -194 -
197 195
198
199.. tabularcolumns:: |p{4.0cm}|p{2.2cm}|p{2.1cm}|p{8.2cm}|196.. tabularcolumns:: |p{4.0cm}|p{2.2cm}|p{2.1cm}|p{8.2cm}|
200 197
201.. c:type:: v4l2_ext_controls198.. c:type:: v4l2_ext_controls
@@ -309,7 +306,6 @@ still cause this situation. · 107 unmodified lines
309 306
310 Ignored if ``count`` equals zero.307 Ignored if ``count`` equals zero.
311 308
312
313.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|309.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
314 310
315.. _ctrl-class:311.. _ctrl-class:
@@ -363,7 +359,6 @@ still cause this situation. · 47 unmodified lines
363 - The class containing RF tuner controls. These controls are359 - The class containing RF tuner controls. These controls are
364 described in :ref:`rf-tuner-controls`.360 described in :ref:`rf-tuner-controls`.
365 361
366
367Return Value362Return Value
368============363============
369 364
Documentation/userspace-api/media/v4l/vidioc-g-fbuf.rst+7−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_FBUF:4.. _VIDIOC_G_FBUF:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_FBUF - VIDIOC_S_FBUF - Get or set frame buffer overlay parameters13VIDIOC_G_FBUF - VIDIOC_S_FBUF - Get or set frame buffer overlay parameters
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_FBUF, struct v4l2_framebuffer *argp )18.. c:macro:: VIDIOC_G_FBUF
19 :name: VIDIOC_G_FBUF19
20``int ioctl(int fd, VIDIOC_G_FBUF, struct v4l2_framebuffer *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_FBUF, const struct v4l2_framebuffer *argp )22.. c:macro:: VIDIOC_S_FBUF
22 :name: VIDIOC_S_FBUF
23 23
24``int ioctl(int fd, VIDIOC_S_FBUF, const struct v4l2_framebuffer *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_framebuffer`.33 Pointer to struct :c:type:`v4l2_framebuffer`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -75,7 +75,6 @@ jeopardize the system security, its stability or even damage the · 37 unmodified lines
75hardware, therefore only the superuser can set the parameters for a75hardware, therefore only the superuser can set the parameters for a
76destructive video overlay.76destructive video overlay.
77 77
78
79.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|78.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|
80 79
81.. c:type:: v4l2_framebuffer80.. c:type:: v4l2_framebuffer
@@ -208,7 +207,6 @@ destructive video overlay. · 126 unmodified lines
208 - ``priv``207 - ``priv``
209 - Reserved. Drivers and applications must set this field to zero.208 - Reserved. Drivers and applications must set this field to zero.
210 209
211
212.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|210.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
213 211
214.. _framebuffer-cap:212.. _framebuffer-cap:
@@ -257,7 +255,6 @@ destructive video overlay. · 42 unmodified lines
257 chroma-key colors are replaced by framebuffer pixels, which is255 chroma-key colors are replaced by framebuffer pixels, which is
258 exactly opposite of ``V4L2_FBUF_CAP_CHROMAKEY``256 exactly opposite of ``V4L2_FBUF_CAP_CHROMAKEY``
259 257
260
261.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|258.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
262 259
263.. _framebuffer-flags:260.. _framebuffer-flags:
@@ -332,7 +329,6 @@ destructive video overlay. · 68 unmodified lines
332 other, so same ``chromakey`` field of struct329 other, so same ``chromakey`` field of struct
333 :c:type:`v4l2_window` is being used.330 :c:type:`v4l2_window` is being used.
334 331
335
336Return Value332Return Value
337============333============
338 334
Documentation/userspace-api/media/v4l/vidioc-g-fmt.rst+11−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_FMT:4.. _VIDIOC_G_FMT:
4 5
@@ -11,29 +12,30 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_FMT - VIDIOC_S_FMT - VIDIOC_TRY_FMT - Get or set the data format, try a format13VIDIOC_G_FMT - VIDIOC_S_FMT - VIDIOC_TRY_FMT - Get or set the data format, try a format
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_FMT, struct v4l2_format *argp )18.. c:macro:: VIDIOC_G_FMT
19 :name: VIDIOC_G_FMT19
20``int ioctl(int fd, VIDIOC_G_FMT, struct v4l2_format *argp)``
21
22.. c:macro:: VIDIOC_S_FMT
23
24``int ioctl(int fd, VIDIOC_S_FMT, struct v4l2_format *argp)``
20 25
21.. c:function:: int ioctl( int fd, VIDIOC_S_FMT, struct v4l2_format *argp )26.. c:macro:: VIDIOC_TRY_FMT
22 :name: VIDIOC_S_FMT
23 27
24.. c:function:: int ioctl( int fd, VIDIOC_TRY_FMT, struct v4l2_format *argp )28``int ioctl(int fd, VIDIOC_TRY_FMT, struct v4l2_format *argp)``
25 :name: VIDIOC_TRY_FMT
26 29
27Arguments30Arguments
28=========31=========
29 32
30``fd``33``fd``
31 File descriptor returned by :ref:`open() <func-open>`.34 File descriptor returned by :c:func:`open()`.
32 35
33``argp``36``argp``
34 Pointer to struct :c:type:`v4l2_format`.37 Pointer to struct :c:type:`v4l2_format`.
35 38
36
37Description39Description
38===========40===========
39 41
@@ -85,7 +87,6 @@ recommended drivers are not required to implement this ioctl. · 45 unmodified lines
85The format as returned by :ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` must be identical to what87The format as returned by :ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` must be identical to what
86:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` returns for the same input or output.88:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` returns for the same input or output.
87 89
88
89.. c:type:: v4l2_format90.. c:type:: v4l2_format
90 91
91.. tabularcolumns:: |p{1.2cm}|p{4.6cm}|p{3.0cm}|p{8.6cm}|92.. tabularcolumns:: |p{1.2cm}|p{4.6cm}|p{3.0cm}|p{8.6cm}|
@@ -135,7 +136,6 @@ The format as returned by :ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` must be identical · 43 unmodified lines
135 * - }136 * - }
136 -137 -
137 138
138
139Return Value139Return Value
140============140============
141 141
Documentation/userspace-api/media/v4l/vidioc-g-frequency.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_FREQUENCY:4.. _VIDIOC_G_FREQUENCY:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_FREQUENCY - VIDIOC_S_FREQUENCY - Get or set tuner or modulator radio frequency13VIDIOC_G_FREQUENCY - VIDIOC_S_FREQUENCY - Get or set tuner or modulator radio frequency
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_FREQUENCY, struct v4l2_frequency *argp )18.. c:macro:: VIDIOC_G_FREQUENCY
19 :name: VIDIOC_G_FREQUENCY19
20``int ioctl(int fd, VIDIOC_G_FREQUENCY, struct v4l2_frequency *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_FREQUENCY, const struct v4l2_frequency *argp )22.. c:macro:: VIDIOC_S_FREQUENCY
22 :name: VIDIOC_S_FREQUENCY
23 23
24``int ioctl(int fd, VIDIOC_S_FREQUENCY, const struct v4l2_frequency *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_frequency`.33 Pointer to struct :c:type:`v4l2_frequency`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -51,7 +51,6 @@ structure. When the requested frequency is not possible the driver · 13 unmodified lines
51assumes the closest possible value. However :ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` is a51assumes the closest possible value. However :ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` is a
52write-only ioctl, it does not return the actual new frequency.52write-only ioctl, it does not return the actual new frequency.
53 53
54
55.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|54.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
56 55
57.. c:type:: v4l2_frequency56.. c:type:: v4l2_frequency
@@ -89,7 +88,6 @@ write-only ioctl, it does not return the actual new frequency. · 31 unmodified lines
89 - Reserved for future extensions. Drivers and applications must set88 - Reserved for future extensions. Drivers and applications must set
90 the array to zero.89 the array to zero.
91 90
92
93Return Value91Return Value
94============92============
95 93
Documentation/userspace-api/media/v4l/vidioc-g-input.rst+7−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_INPUT:4.. _VIDIOC_G_INPUT:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_INPUT - VIDIOC_S_INPUT - Query or select the current video input13VIDIOC_G_INPUT - VIDIOC_S_INPUT - Query or select the current video input
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_INPUT, int *argp )18.. c:macro:: VIDIOC_G_INPUT
19 :name: VIDIOC_G_INPUT19
20``int ioctl(int fd, VIDIOC_G_INPUT, int *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_INPUT, int *argp )22.. c:macro:: VIDIOC_S_INPUT
22 :name: VIDIOC_S_INPUT
23 23
24``int ioctl(int fd, VIDIOC_S_INPUT, int *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer an integer with input index.33 Pointer an integer with input index.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -52,7 +52,6 @@ other parameters. · 14 unmodified lines
52Information about video inputs is available using the52Information about video inputs is available using the
53:ref:`VIDIOC_ENUMINPUT` ioctl.53:ref:`VIDIOC_ENUMINPUT` ioctl.
54 54
55
56Return Value55Return Value
57============56============
58 57
Documentation/userspace-api/media/v4l/vidioc-g-jpegcomp.rst+7−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_JPEGCOMP:4.. _VIDIOC_G_JPEGCOMP:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_JPEGCOMP - VIDIOC_S_JPEGCOMP13VIDIOC_G_JPEGCOMP - VIDIOC_S_JPEGCOMP
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_JPEGCOMP, v4l2_jpegcompression *argp )18.. c:macro:: VIDIOC_G_JPEGCOMP
19 :name: VIDIOC_G_JPEGCOMP19
20``int ioctl(int fd, VIDIOC_G_JPEGCOMP, v4l2_jpegcompression *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_JPEGCOMP, const v4l2_jpegcompression *argp )22.. c:macro:: VIDIOC_S_JPEGCOMP
22 :name: VIDIOC_S_JPEGCOMP
23 23
24``int ioctl(int fd, VIDIOC_S_JPEGCOMP, const v4l2_jpegcompression *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_jpegcompression`.33 Pointer to struct :c:type:`v4l2_jpegcompression`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -54,7 +54,6 @@ stored in the JPEG-encoded fields. These define how the JPEG field is · 16 unmodified lines
54encoded. If you omit them, applications assume you've used standard54encoded. If you omit them, applications assume you've used standard
55encoding. You usually do want to add them.55encoding. You usually do want to add them.
56 56
57
58.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{13.3cm}|57.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{13.3cm}|
59 58
60.. c:type:: v4l2_jpegcompression59.. c:type:: v4l2_jpegcompression
@@ -92,7 +91,6 @@ encoding. You usually do want to add them. · 31 unmodified lines
92 control is exposed by a driver applications should use it instead91 control is exposed by a driver applications should use it instead
93 and ignore this field.92 and ignore this field.
94 93
95
96.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|94.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
97 95
98.. _jpeg-markers:96.. _jpeg-markers:
@@ -118,7 +116,6 @@ encoding. You usually do want to add them. · 19 unmodified lines
118 - (1<<7)116 - (1<<7)
119 - App segment, driver will always use APP0117 - App segment, driver will always use APP0
120 118
121
122Return Value119Return Value
123============120============
124 121
Documentation/userspace-api/media/v4l/vidioc-g-modulator.rst+7−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_MODULATOR:4.. _VIDIOC_G_MODULATOR:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_MODULATOR - VIDIOC_S_MODULATOR - Get or set modulator attributes13VIDIOC_G_MODULATOR - VIDIOC_S_MODULATOR - Get or set modulator attributes
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_MODULATOR, struct v4l2_modulator *argp )18.. c:macro:: VIDIOC_G_MODULATOR
19 :name: VIDIOC_G_MODULATOR19
20``int ioctl(int fd, VIDIOC_G_MODULATOR, struct v4l2_modulator *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_MODULATOR, const struct v4l2_modulator *argp )22.. c:macro:: VIDIOC_S_MODULATOR
22 :name: VIDIOC_S_MODULATOR
23 23
24``int ioctl(int fd, VIDIOC_S_MODULATOR, const struct v4l2_modulator *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_modulator`.33 Pointer to struct :c:type:`v4l2_modulator`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -60,7 +60,6 @@ context. · 22 unmodified lines
60To change the radio frequency the60To change the radio frequency the
61:ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` ioctl is available.61:ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` ioctl is available.
62 62
63
64.. tabularcolumns:: |p{2.9cm}|p{2.9cm}|p{5.8cm}|p{2.9cm}|p{3.0cm}|63.. tabularcolumns:: |p{2.9cm}|p{2.9cm}|p{5.8cm}|p{2.9cm}|p{3.0cm}|
65 64
66.. c:type:: v4l2_modulator65.. c:type:: v4l2_modulator
@@ -121,7 +120,6 @@ To change the radio frequency the · 54 unmodified lines
121 Drivers and applications must set the array to zero.120 Drivers and applications must set the array to zero.
122 121
123 122
124
125.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|123.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
126 124
127.. _modulator-txsubchans:125.. _modulator-txsubchans:
@@ -182,7 +180,6 @@ To change the radio frequency the · 54 unmodified lines
182 - 0x0010180 - 0x0010
183 - Enable the RDS encoder for a radio FM transmitter.181 - Enable the RDS encoder for a radio FM transmitter.
184 182
185
186Return Value183Return Value
187============184============
188 185
Documentation/userspace-api/media/v4l/vidioc-g-output.rst+7−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_OUTPUT:4.. _VIDIOC_G_OUTPUT:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_OUTPUT - VIDIOC_S_OUTPUT - Query or select the current video output13VIDIOC_G_OUTPUT - VIDIOC_S_OUTPUT - Query or select the current video output
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_OUTPUT, int *argp )18.. c:macro:: VIDIOC_G_OUTPUT
19 :name: VIDIOC_G_OUTPUT19
20``int ioctl(int fd, VIDIOC_G_OUTPUT, int *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_OUTPUT, int *argp )22.. c:macro:: VIDIOC_S_OUTPUT
22 :name: VIDIOC_S_OUTPUT
23 23
24``int ioctl(int fd, VIDIOC_S_OUTPUT, int *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to an integer with output index.33 Pointer to an integer with output index.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -53,7 +53,6 @@ negotiating any other parameters. · 15 unmodified lines
53Information about video outputs is available using the53Information about video outputs is available using the
54:ref:`VIDIOC_ENUMOUTPUT` ioctl.54:ref:`VIDIOC_ENUMOUTPUT` ioctl.
55 55
56
57Return Value56Return Value
58============57============
59 58
Documentation/userspace-api/media/v4l/vidioc-g-parm.rst+12−18
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_PARM:4.. _VIDIOC_G_PARM:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_PARM - VIDIOC_S_PARM - Get or set streaming parameters13VIDIOC_G_PARM - VIDIOC_S_PARM - Get or set streaming parameters
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_PARM, v4l2_streamparm *argp )18.. c:macro:: VIDIOC_G_PARM
19 :name: VIDIOC_G_PARM19
20``int ioctl(int fd, VIDIOC_G_PARM, v4l2_streamparm *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_PARM, v4l2_streamparm *argp )22.. c:macro:: VIDIOC_S_PARM
22 :name: VIDIOC_S_PARM
23 23
24``int ioctl(int fd, VIDIOC_S_PARM, v4l2_streamparm *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_streamparm`.33 Pointer to struct :c:type:`v4l2_streamparm`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -48,7 +48,7 @@ format, on the other hand, may change the frame interval. · 10 unmodified lines
48 48
49Further these ioctls can be used to determine the number of buffers used49Further these ioctls can be used to determine the number of buffers used
50internally by a driver in read/write mode. For implications see the50internally by a driver in read/write mode. For implications see the
51section discussing the :ref:`read() <func-read>` function.51section discussing the :c:func:`read()` function.
52 52
53To get and set the streaming parameters applications call the53To get and set the streaming parameters applications call the
54:ref:`VIDIOC_G_PARM <VIDIOC_G_PARM>` and54:ref:`VIDIOC_G_PARM <VIDIOC_G_PARM>` and
@@ -56,7 +56,6 @@ To get and set the streaming parameters applications call the · 1 unmodified line
56pointer to a struct :c:type:`v4l2_streamparm` which contains a56pointer to a struct :c:type:`v4l2_streamparm` which contains a
57union holding separate parameters for input and output devices.57union holding separate parameters for input and output devices.
58 58
59
60.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|59.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|
61 60
62.. c:type:: v4l2_streamparm61.. c:type:: v4l2_streamparm
@@ -89,7 +88,6 @@ union holding separate parameters for input and output devices. · 26 unmodified lines
89 -88 -
90 89
91 90
92
93.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|91.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
94 92
95.. c:type:: v4l2_captureparm93.. c:type:: v4l2_captureparm
@@ -138,7 +136,7 @@ union holding separate parameters for input and output devices. · 42 unmodified lines
138 * - __u32136 * - __u32
139 - ``readbuffers``137 - ``readbuffers``
140 - Applications set this field to the desired number of buffers used138 - Applications set this field to the desired number of buffers used
141 internally by the driver in :ref:`read() <func-read>` mode.139 internally by the driver in :c:func:`read()` mode.
142 Drivers return the actual number of buffers. When an application140 Drivers return the actual number of buffers. When an application
143 requests zero buffers, drivers should just return the current141 requests zero buffers, drivers should just return the current
144 setting rather than the minimum or an error code. For details see142 setting rather than the minimum or an error code. For details see
@@ -149,7 +147,6 @@ union holding separate parameters for input and output devices. · 4 unmodified lines
149 the array to zero.147 the array to zero.
150 148
151 149
152
153.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|150.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
154 151
155.. c:type:: v4l2_outputparm152.. c:type:: v4l2_outputparm
@@ -172,7 +169,7 @@ union holding separate parameters for input and output devices. · 16 unmodified lines
172 * - :cspan:`2`169 * - :cspan:`2`
173 170
174 The field is intended to repeat frames on the driver side in171 The field is intended to repeat frames on the driver side in
175 :ref:`write() <func-write>` mode (in streaming mode timestamps172 :c:func:`write()` mode (in streaming mode timestamps
176 can be used to throttle the output), saving I/O bandwidth.173 can be used to throttle the output), saving I/O bandwidth.
177 174
178 For stateful encoders (see :ref:`encoder`) this represents the175 For stateful encoders (see :ref:`encoder`) this represents the
@@ -199,7 +196,7 @@ union holding separate parameters for input and output devices. · 20 unmodified lines
199 * - __u32196 * - __u32
200 - ``writebuffers``197 - ``writebuffers``
201 - Applications set this field to the desired number of buffers used198 - Applications set this field to the desired number of buffers used
202 internally by the driver in :ref:`write() <func-write>` mode. Drivers199 internally by the driver in :c:func:`write()` mode. Drivers
203 return the actual number of buffers. When an application requests200 return the actual number of buffers. When an application requests
204 zero buffers, drivers should just return the current setting201 zero buffers, drivers should just return the current setting
205 rather than the minimum or an error code. For details see202 rather than the minimum or an error code. For details see
@@ -210,7 +207,6 @@ union holding separate parameters for input and output devices. · 4 unmodified lines
210 the array to zero.207 the array to zero.
211 208
212 209
213
214.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|210.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
215 211
216.. _parm-caps:212.. _parm-caps:
@@ -226,7 +222,6 @@ union holding separate parameters for input and output devices. · 9 unmodified lines
226 field.222 field.
227 223
228 224
229
230.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|225.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
231 226
232.. _parm-flags:227.. _parm-flags:
@@ -265,8 +260,7 @@ union holding separate parameters for input and output devices. · 32 unmodified lines
265 260
266 - Moving objects in the image might have excessive motion blur.261 - Moving objects in the image might have excessive motion blur.
267 262
268 - Capture might only work through the :ref:`read() <func-read>` call.263 - Capture might only work through the :c:func:`read()` call.
269
270 264
271Return Value265Return Value
272============266============
Documentation/userspace-api/media/v4l/vidioc-g-priority.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_PRIORITY:4.. _VIDIOC_G_PRIORITY:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_PRIORITY - VIDIOC_S_PRIORITY - Query or request the access priority associated with a file descriptor13VIDIOC_G_PRIORITY - VIDIOC_S_PRIORITY - Query or request the access priority associated with a file descriptor
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_PRIORITY, enum v4l2_priority *argp )18.. c:macro:: VIDIOC_G_PRIORITY
19 :name: VIDIOC_G_PRIORITY19
20``int ioctl(int fd, VIDIOC_G_PRIORITY, enum v4l2_priority *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_PRIORITY, const enum v4l2_priority *argp )22.. c:macro:: VIDIOC_S_PRIORITY
22 :name: VIDIOC_S_PRIORITY
23 23
24``int ioctl(int fd, VIDIOC_S_PRIORITY, const enum v4l2_priority *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to an enum :c:type:`v4l2_priority` type.33 Pointer to an enum :c:type:`v4l2_priority` type.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -43,7 +43,6 @@ To request an access priority applications store the desired priority in · 5 unmodified lines
43an enum v4l2_priority variable and call :ref:`VIDIOC_S_PRIORITY <VIDIOC_G_PRIORITY>` ioctl43an enum v4l2_priority variable and call :ref:`VIDIOC_S_PRIORITY <VIDIOC_G_PRIORITY>` ioctl
44with a pointer to this variable.44with a pointer to this variable.
45 45
46
47.. c:type:: v4l2_priority46.. c:type:: v4l2_priority
48 47
49.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|48.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
@@ -78,7 +77,6 @@ with a pointer to this variable. · 28 unmodified lines
78 it blocks any other fd from changing device properties. Usually77 it blocks any other fd from changing device properties. Usually
79 applications which must not be interrupted, like video recording.78 applications which must not be interrupted, like video recording.
80 79
81
82Return Value80Return Value
83============81============
84 82
Documentation/userspace-api/media/v4l/vidioc-g-selection.rst+6−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_SELECTION:4.. _VIDIOC_G_SELECTION:
4 5
@@ -11,23 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_SELECTION - VIDIOC_S_SELECTION - Get or set one of the selection rectangles13VIDIOC_G_SELECTION - VIDIOC_S_SELECTION - Get or set one of the selection rectangles
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_SELECTION, struct v4l2_selection *argp )18.. c:macro:: VIDIOC_G_SELECTION
19 :name: VIDIOC_G_SELECTION
20 19
20``int ioctl(int fd, VIDIOC_G_SELECTION, struct v4l2_selection *argp)``
21 21
22.. c:function:: int ioctl( int fd, VIDIOC_S_SELECTION, struct v4l2_selection *argp )22.. c:macro:: VIDIOC_S_SELECTION
23 :name: VIDIOC_S_SELECTION
24 23
24``int ioctl(int fd, VIDIOC_S_SELECTION, struct v4l2_selection *argp)``
25 25
26Arguments26Arguments
27=========27=========
28 28
29``fd``29``fd``
30 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
31 31
32``argp``32``argp``
33 Pointer to struct :c:type:`v4l2_selection`.33 Pointer to struct :c:type:`v4l2_selection`.
@@ -115,7 +115,6 @@ constraints. · 81 unmodified lines
115Selection targets and flags are documented in115Selection targets and flags are documented in
116:ref:`v4l2-selections-common`.116:ref:`v4l2-selections-common`.
117 117
118
119.. _sel-const-adjust:118.. _sel-const-adjust:
120 119
121.. kernel-figure:: constraints.svg120.. kernel-figure:: constraints.svg
@@ -128,7 +127,6 @@ Selection targets and flags are documented in · 6 unmodified lines
128 127
129 128
130 129
131
132.. c:type:: v4l2_selection130.. c:type:: v4l2_selection
133 131
134.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|132.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -168,7 +166,6 @@ Selection targets and flags are documented in · 33 unmodified lines
168 166
169 Starting with kernel 4.13 both variations are allowed.167 Starting with kernel 4.13 both variations are allowed.
170 168
171
172Return Value169Return Value
173============170============
174 171
Documentation/userspace-api/media/v4l/vidioc-g-sliced-vbi-cap.rst+4−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_SLICED_VBI_CAP:4.. _VIDIOC_G_SLICED_VBI_CAP:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_SLICED_VBI_CAP - Query sliced VBI capabilities13VIDIOC_G_SLICED_VBI_CAP - Query sliced VBI capabilities
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_SLICED_VBI_CAP, struct v4l2_sliced_vbi_cap *argp )18.. c:macro:: VIDIOC_G_SLICED_VBI_CAP
19 :name: VIDIOC_G_SLICED_VBI_CAP
20 19
20``int ioctl(int fd, VIDIOC_G_SLICED_VBI_CAP, struct v4l2_sliced_vbi_cap *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_sliced_vbi_cap`.29 Pointer to struct :c:type:`v4l2_sliced_vbi_cap`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -44,7 +43,6 @@ the sliced VBI API is unsupported or ``type`` is invalid. · 9 unmodified lines
44 The ``type`` field was added, and the ioctl changed from read-only43 The ``type`` field was added, and the ioctl changed from read-only
45 to write-read, in Linux 2.6.19.44 to write-read, in Linux 2.6.19.
46 45
47
48.. c:type:: v4l2_sliced_vbi_cap46.. c:type:: v4l2_sliced_vbi_cap
49 47
50.. tabularcolumns:: |p{1.2cm}|p{4.2cm}|p{4.1cm}|p{4.0cm}|p{4.0cm}|48.. tabularcolumns:: |p{1.2cm}|p{4.2cm}|p{4.1cm}|p{4.0cm}|p{4.0cm}|
@@ -120,7 +118,6 @@ the sliced VBI API is unsupported or ``type`` is invalid. · 69 unmodified lines
120 118
121 See also :ref:`vbi-525` and :ref:`vbi-625`.119 See also :ref:`vbi-525` and :ref:`vbi-625`.
122 120
123
124.. raw:: latex121.. raw:: latex
125 122
126 \scriptsize123 \scriptsize
@@ -183,7 +180,6 @@ the sliced VBI API is unsupported or ``type`` is invalid. · 56 unmodified lines
183 180
184 \normalsize181 \normalsize
185 182
186
187Return Value183Return Value
188============184============
189 185
Documentation/userspace-api/media/v4l/vidioc-g-std.rst+13−11
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_STD:4.. _VIDIOC_G_STD:
4 5
@@ -11,33 +12,34 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_STD - VIDIOC_S_STD - VIDIOC_SUBDEV_G_STD - VIDIOC_SUBDEV_S_STD - Query or select the video standard of the current input13VIDIOC_G_STD - VIDIOC_S_STD - VIDIOC_SUBDEV_G_STD - VIDIOC_SUBDEV_S_STD - Query or select the video standard of the current input
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_STD, v4l2_std_id *argp )18.. c:macro:: VIDIOC_G_STD
19 :name: VIDIOC_G_STD19
20``int ioctl(int fd, VIDIOC_G_STD, v4l2_std_id *argp)``
21
22.. c:macro:: VIDIOC_S_STD
20 23
21.. c:function:: int ioctl( int fd, VIDIOC_S_STD, const v4l2_std_id *argp )24``int ioctl(int fd, VIDIOC_S_STD, const v4l2_std_id *argp)``
22 :name: VIDIOC_S_STD
23 25
24.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_STD, v4l2_std_id *argp )26.. c:macro:: VIDIOC_SUBDEV_G_STD
25 :name: VIDIOC_SUBDEV_G_STD
26 27
27.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_STD, const v4l2_std_id *argp )28``int ioctl(int fd, VIDIOC_SUBDEV_G_STD, v4l2_std_id *argp)``
28 :name: VIDIOC_SUBDEV_S_STD
29 29
30.. c:macro:: VIDIOC_SUBDEV_S_STD
31
32``int ioctl(int fd, VIDIOC_SUBDEV_S_STD, const v4l2_std_id *argp)``
30 33
31Arguments34Arguments
32=========35=========
33 36
34``fd``37``fd``
35 File descriptor returned by :ref:`open() <func-open>`.38 File descriptor returned by :c:func:`open()`.
36 39
37``argp``40``argp``
38 Pointer to :c:type:`v4l2_std_id`.41 Pointer to :c:type:`v4l2_std_id`.
39 42
40
41Description43Description
42===========44===========
43 45
Documentation/userspace-api/media/v4l/vidioc-g-tuner.rst+7−12
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_G_TUNER:4.. _VIDIOC_G_TUNER:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_G_TUNER - VIDIOC_S_TUNER - Get or set tuner attributes13VIDIOC_G_TUNER - VIDIOC_S_TUNER - Get or set tuner attributes
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_G_TUNER, struct v4l2_tuner *argp )18.. c:macro:: VIDIOC_G_TUNER
19 :name: VIDIOC_G_TUNER19
20``int ioctl(int fd, VIDIOC_G_TUNER, struct v4l2_tuner *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_S_TUNER, const struct v4l2_tuner *argp )22.. c:macro:: VIDIOC_S_TUNER
22 :name: VIDIOC_S_TUNER
23 23
24``int ioctl(int fd, VIDIOC_S_TUNER, const struct v4l2_tuner *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_tuner`.33 Pointer to struct :c:type:`v4l2_tuner`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -59,7 +59,6 @@ to zero. The term 'tuner' means SDR receiver in this context. · 21 unmodified lines
59To change the radio frequency the59To change the radio frequency the
60:ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` ioctl is available.60:ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` ioctl is available.
61 61
62
63 .. tabularcolumns:: |p{1.3cm}|p{3.0cm}|p{6.6cm}|p{6.6cm}|62 .. tabularcolumns:: |p{1.3cm}|p{3.0cm}|p{6.6cm}|p{6.6cm}|
64 63
65.. c:type:: v4l2_tuner64.. c:type:: v4l2_tuner
@@ -183,7 +182,6 @@ To change the radio frequency the · 117 unmodified lines
183 Drivers and applications must set the array to zero.182 Drivers and applications must set the array to zero.
184 183
185 184
186
187.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|185.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
188 186
189.. c:type:: v4l2_tuner_type187.. c:type:: v4l2_tuner_type
@@ -207,7 +205,6 @@ To change the radio frequency the · 17 unmodified lines
207 - 5205 - 5
208 - Tuner controls the RF part of a Software Digital Radio (SDR)206 - Tuner controls the RF part of a Software Digital Radio (SDR)
209 207
210
211.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|208.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
212 209
213.. _tuner-capability:210.. _tuner-capability:
@@ -299,7 +296,6 @@ To change the radio frequency the · 85 unmodified lines
299 instead of 62.5 kHz.296 instead of 62.5 kHz.
300 297
301 298
302
303.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|299.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
304 300
305.. _tuner-rxsubchans:301.. _tuner-rxsubchans:
@@ -338,7 +334,6 @@ To change the radio frequency the · 32 unmodified lines
338 - The tuner receives an RDS channel.334 - The tuner receives an RDS channel.
339 335
340 336
341
342.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|337.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
343 338
344.. _tuner-audmode:339.. _tuner-audmode:
Documentation/userspace-api/media/v4l/vidioc-log-status.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_LOG_STATUS:4.. _VIDIOC_LOG_STATUS:
4 5
@@ -11,20 +12,18 @@ Name · 6 unmodified lines
11 12
12VIDIOC_LOG_STATUS - Log driver status information13VIDIOC_LOG_STATUS - Log driver status information
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_LOG_STATUS)18.. c:macro:: VIDIOC_LOG_STATUS
19 :name: VIDIOC_LOG_STATUS
20 19
20``int ioctl(int fd, VIDIOC_LOG_STATUS)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27
28 27
29Description28Description
30===========29===========
@@ -40,7 +39,6 @@ Mismatches may give an indication where the problem is. · 9 unmodified lines
40This ioctl is optional and not all drivers support it. It was introduced39This ioctl is optional and not all drivers support it. It was introduced
41in Linux 2.6.15.40in Linux 2.6.15.
42 41
43
44Return Value42Return Value
45============43============
46 44
Documentation/userspace-api/media/v4l/vidioc-overlay.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_OVERLAY:4.. _VIDIOC_OVERLAY:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_OVERLAY - Start or stop video overlay13VIDIOC_OVERLAY - Start or stop video overlay
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_OVERLAY, const int *argp )18.. c:macro:: VIDIOC_OVERLAY
19 :name: VIDIOC_OVERLAY
20 19
20``int ioctl(int fd, VIDIOC_OVERLAY, const int *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to an integer.29 Pointer to an integer.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -41,7 +40,6 @@ Drivers do not support :ref:`VIDIOC_STREAMON` or · 6 unmodified lines
41:ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` with40:ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>` with
42``V4L2_BUF_TYPE_VIDEO_OVERLAY``.41``V4L2_BUF_TYPE_VIDEO_OVERLAY``.
43 42
44
45Return Value43Return Value
46============44============
47 45
Documentation/userspace-api/media/v4l/vidioc-prepare-buf.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_PREPARE_BUF:4.. _VIDIOC_PREPARE_BUF:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_PREPARE_BUF - Prepare a buffer for I/O13VIDIOC_PREPARE_BUF - Prepare a buffer for I/O
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_PREPARE_BUF, struct v4l2_buffer *argp )18.. c:macro:: VIDIOC_PREPARE_BUF
19 :name: VIDIOC_PREPARE_BUF
20 19
20``int ioctl(int fd, VIDIOC_PREPARE_BUF, struct v4l2_buffer *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_buffer`.29 Pointer to struct :c:type:`v4l2_buffer`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -41,7 +40,6 @@ in advance saves time during the actual I/O. · 6 unmodified lines
41The struct :c:type:`v4l2_buffer` structure is specified in40The struct :c:type:`v4l2_buffer` structure is specified in
42:ref:`buffer`.41:ref:`buffer`.
43 42
44
45Return Value43Return Value
46============44============
47 45
Documentation/userspace-api/media/v4l/vidioc-qbuf.rst+8−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_QBUF:4.. _VIDIOC_QBUF:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_QBUF - VIDIOC_DQBUF - Exchange a buffer with the driver13VIDIOC_QBUF - VIDIOC_DQBUF - Exchange a buffer with the driver
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_QBUF, struct v4l2_buffer *argp )18.. c:macro:: VIDIOC_QBUF
19 :name: VIDIOC_QBUF19
20``int ioctl(int fd, VIDIOC_QBUF, struct v4l2_buffer *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_DQBUF, struct v4l2_buffer *argp )22.. c:macro:: VIDIOC_DQBUF
22 :name: VIDIOC_DQBUF
23 23
24``int ioctl(int fd, VIDIOC_DQBUF, struct v4l2_buffer *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_buffer`.33 Pointer to struct :c:type:`v4l2_buffer`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -142,13 +142,12 @@ API is used the ``m.fd`` fields of the passed array of struct · 104 unmodified lines
142 142
143By default ``VIDIOC_DQBUF`` blocks when no buffer is in the outgoing143By default ``VIDIOC_DQBUF`` blocks when no buffer is in the outgoing
144queue. When the ``O_NONBLOCK`` flag was given to the144queue. When the ``O_NONBLOCK`` flag was given to the
145:ref:`open() <func-open>` function, ``VIDIOC_DQBUF`` returns145:c:func:`open()` function, ``VIDIOC_DQBUF`` returns
146immediately with an ``EAGAIN`` error code when no buffer is available.146immediately with an ``EAGAIN`` error code when no buffer is available.
147 147
148The struct :c:type:`v4l2_buffer` structure is specified in148The struct :c:type:`v4l2_buffer` structure is specified in
149:ref:`buffer`.149:ref:`buffer`.
150 150
151
152Return Value151Return Value
153============152============
154 153
Documentation/userspace-api/media/v4l/vidioc-query-dv-timings.rst+7−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_QUERY_DV_TIMINGS:4.. _VIDIOC_QUERY_DV_TIMINGS:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_QUERY_DV_TIMINGS - VIDIOC_SUBDEV_QUERY_DV_TIMINGS - Sense the DV preset received by the current input13VIDIOC_QUERY_DV_TIMINGS - VIDIOC_SUBDEV_QUERY_DV_TIMINGS - Sense the DV preset received by the current input
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_QUERY_DV_TIMINGS, struct v4l2_dv_timings *argp )18.. c:macro:: VIDIOC_QUERY_DV_TIMINGS
19 :name: VIDIOC_QUERY_DV_TIMINGS19
20``int ioctl(int fd, VIDIOC_QUERY_DV_TIMINGS, struct v4l2_dv_timings *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_QUERY_DV_TIMINGS, struct v4l2_dv_timings *argp )22.. c:macro:: VIDIOC_SUBDEV_QUERY_DV_TIMINGS
22 :name: VIDIOC_SUBDEV_QUERY_DV_TIMINGS
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_QUERY_DV_TIMINGS, struct v4l2_dv_timings *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_dv_timings`.33 Pointer to struct :c:type:`v4l2_dv_timings`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -65,7 +65,6 @@ and returns ``ERANGE``. In that case the application can call · 27 unmodified lines
65found timings with the hardware's capabilities in order to give more65found timings with the hardware's capabilities in order to give more
66precise feedback to the user.66precise feedback to the user.
67 67
68
69Return Value68Return Value
70============69============
71 70
Documentation/userspace-api/media/v4l/vidioc-querybuf.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_QUERYBUF:4.. _VIDIOC_QUERYBUF:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_QUERYBUF - Query the status of a buffer13VIDIOC_QUERYBUF - Query the status of a buffer
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_QUERYBUF, struct v4l2_buffer *argp )18.. c:macro:: VIDIOC_QUERYBUF
19 :name: VIDIOC_QUERYBUF
20 19
20``int ioctl(int fd, VIDIOC_QUERYBUF, struct v4l2_buffer *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_buffer`.29 Pointer to struct :c:type:`v4l2_buffer`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -67,7 +66,6 @@ flags, they are meaningless in this context. · 32 unmodified lines
67The struct :c:type:`v4l2_buffer` structure is specified in66The struct :c:type:`v4l2_buffer` structure is specified in
68:ref:`buffer`.67:ref:`buffer`.
69 68
70
71Return Value69Return Value
72============70============
73 71
Documentation/userspace-api/media/v4l/vidioc-querycap.rst+6−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_QUERYCAP:4.. _VIDIOC_QUERYCAP:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_QUERYCAP - Query device capabilities13VIDIOC_QUERYCAP - Query device capabilities
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_QUERYCAP, struct v4l2_capability *argp )18.. c:macro:: VIDIOC_QUERYCAP
19 :name: VIDIOC_QUERYCAP
20 19
20``int ioctl(int fd, VIDIOC_QUERYCAP, struct v4l2_capability *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_capability`.29 Pointer to struct :c:type:`v4l2_capability`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -39,7 +38,6 @@ pointer to a struct :c:type:`v4l2_capability` which is · 4 unmodified lines
39filled by the driver. When the driver is not compatible with this38filled by the driver. When the driver is not compatible with this
40specification the ioctl returns an ``EINVAL`` error code.39specification the ioctl returns an ``EINVAL`` error code.
41 40
42
43.. tabularcolumns:: |p{1.5cm}|p{2.5cm}|p{13cm}|41.. tabularcolumns:: |p{1.5cm}|p{2.5cm}|p{13cm}|
44 42
45.. c:type:: v4l2_capability43.. c:type:: v4l2_capability
@@ -132,7 +130,6 @@ specification the ioctl returns an ``EINVAL`` error code. · 86 unmodified lines
132 zero.130 zero.
133 131
134 132
135
136.. tabularcolumns:: |p{6.1cm}|p{2.2cm}|p{8.7cm}|133.. tabularcolumns:: |p{6.1cm}|p{2.2cm}|p{8.7cm}|
137 134
138.. _device-capabilities:135.. _device-capabilities:
@@ -243,8 +240,8 @@ specification the ioctl returns an ``EINVAL`` error code. · 104 unmodified lines
243 - The device supports the :ref:`metadata` capture interface.240 - The device supports the :ref:`metadata` capture interface.
244 * - ``V4L2_CAP_READWRITE``241 * - ``V4L2_CAP_READWRITE``
245 - 0x01000000242 - 0x01000000
246 - The device supports the :ref:`read() <rw>` and/or243 - The device supports the :c:func:`read()` and/or
247 :ref:`write() <rw>` I/O methods.244 :c:func:`write()` I/O methods.
248 * - ``V4L2_CAP_ASYNCIO``245 * - ``V4L2_CAP_ASYNCIO``
249 - 0x02000000246 - 0x02000000
250 - The device supports the :ref:`asynchronous <async>` I/O methods.247 - The device supports the :ref:`asynchronous <async>` I/O methods.
@@ -269,7 +266,6 @@ specification the ioctl returns an ``EINVAL`` error code. · 18 unmodified lines
269 only appear in the ``capabilities`` field and never in the266 only appear in the ``capabilities`` field and never in the
270 ``device_caps`` field.267 ``device_caps`` field.
271 268
272
273Return Value269Return Value
274============270============
275 271
Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst+8−14
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_QUERYCTRL:4.. _VIDIOC_QUERYCTRL:
4 5
@@ -11,31 +12,29 @@ Name · 6 unmodified lines
11 12
12VIDIOC_QUERYCTRL - VIDIOC_QUERY_EXT_CTRL - VIDIOC_QUERYMENU - Enumerate controls and menu control items13VIDIOC_QUERYCTRL - VIDIOC_QUERY_EXT_CTRL - VIDIOC_QUERYMENU - Enumerate controls and menu control items
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, int VIDIOC_QUERYCTRL, struct v4l2_queryctrl *argp )18``int ioctl(int fd, int VIDIOC_QUERYCTRL, struct v4l2_queryctrl *argp)``
19 :name: VIDIOC_QUERYCTRL19
20.. c:macro:: VIDIOC_QUERY_EXT_CTRL
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_QUERY_EXT_CTRL, struct v4l2_query_ext_ctrl *argp )22``int ioctl(int fd, VIDIOC_QUERY_EXT_CTRL, struct v4l2_query_ext_ctrl *argp)``
22 :name: VIDIOC_QUERY_EXT_CTRL
23 23
24.. c:function:: int ioctl( int fd, VIDIOC_QUERYMENU, struct v4l2_querymenu *argp )24.. c:macro:: VIDIOC_QUERYMENU
25 :name: VIDIOC_QUERYMENU
26 25
26``int ioctl(int fd, VIDIOC_QUERYMENU, struct v4l2_querymenu *argp)``
27 27
28Arguments28Arguments
29=========29=========
30 30
31``fd``31``fd``
32 File descriptor returned by :ref:`open() <func-open>`.32 File descriptor returned by :c:func:`open()`.
33 33
34``argp``34``argp``
35 Pointer to struct :c:type:`v4l2_queryctrl`, :c:type:`v4l2_query_ext_ctrl`35 Pointer to struct :c:type:`v4l2_queryctrl`, :c:type:`v4l2_query_ext_ctrl`
36 or :c:type:`v4l2_querymenu` (depending on the ioctl).36 or :c:type:`v4l2_querymenu` (depending on the ioctl).
37 37
38
39Description38Description
40===========39===========
41 40
@@ -95,7 +94,6 @@ inclusive. · 53 unmodified lines
95 94
96See also the examples in :ref:`control`.95See also the examples in :ref:`control`.
97 96
98
99.. tabularcolumns:: |p{1.2cm}|p{3.6cm}|p{12.7cm}|97.. tabularcolumns:: |p{1.2cm}|p{3.6cm}|p{12.7cm}|
100 98
101.. _v4l2-queryctrl:99.. _v4l2-queryctrl:
@@ -174,7 +172,6 @@ See also the examples in :ref:`control`. · 72 unmodified lines
174 zero.172 zero.
175 173
176 174
177
178.. tabularcolumns:: |p{1.2cm}|p{5.0cm}|p{11.3cm}|175.. tabularcolumns:: |p{1.2cm}|p{5.0cm}|p{11.3cm}|
179 176
180.. _v4l2-query-ext-ctrl:177.. _v4l2-query-ext-ctrl:
@@ -275,7 +272,6 @@ See also the examples in :ref:`control`. · 94 unmodified lines
275 the array to zero.272 the array to zero.
276 273
277 274
278
279.. tabularcolumns:: |p{1.2cm}|p{1.0cm}|p{1.7cm}|p{13.0cm}|275.. tabularcolumns:: |p{1.2cm}|p{1.0cm}|p{1.7cm}|p{13.0cm}|
280 276
281.. _v4l2-querymenu:277.. _v4l2-querymenu:
@@ -311,7 +307,6 @@ See also the examples in :ref:`control`. · 29 unmodified lines
311 zero.307 zero.
312 308
313 309
314
315.. tabularcolumns:: |p{5.8cm}|p{1.4cm}|p{1.0cm}|p{1.4cm}|p{6.9cm}|310.. tabularcolumns:: |p{5.8cm}|p{1.4cm}|p{1.0cm}|p{1.4cm}|p{6.9cm}|
316 311
317.. c:type:: v4l2_ctrl_type312.. c:type:: v4l2_ctrl_type
@@ -582,7 +577,6 @@ See also the examples in :ref:`control`. · 264 unmodified lines
582 streaming is in progress since most drivers do not support changing577 streaming is in progress since most drivers do not support changing
583 the format in that case.578 the format in that case.
584 579
585
586Return Value580Return Value
587============581============
588 582
Documentation/userspace-api/media/v4l/vidioc-querystd.rst+7−8
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_QUERYSTD:4.. _VIDIOC_QUERYSTD:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_QUERYSTD - VIDIOC_SUBDEV_QUERYSTD - Sense the video standard received by the current input13VIDIOC_QUERYSTD - VIDIOC_SUBDEV_QUERYSTD - Sense the video standard received by the current input
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_QUERYSTD, v4l2_std_id *argp )18.. c:macro:: VIDIOC_QUERYSTD
19 :name: VIDIOC_QUERYSTD19
20``int ioctl(int fd, VIDIOC_QUERYSTD, v4l2_std_id *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_QUERYSTD, v4l2_std_id *argp )22.. c:macro:: VIDIOC_SUBDEV_QUERYSTD
22 :name: VIDIOC_SUBDEV_QUERYSTD
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_QUERYSTD, v4l2_std_id *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to :c:type:`v4l2_std_id`.33 Pointer to :c:type:`v4l2_std_id`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -58,7 +58,6 @@ or output. · 20 unmodified lines
58 standard is valid they will have to stop streaming, set the new58 standard is valid they will have to stop streaming, set the new
59 standard, allocate new buffers and start streaming again.59 standard, allocate new buffers and start streaming again.
60 60
61
62Return Value61Return Value
63============62============
64 63
Documentation/userspace-api/media/v4l/vidioc-reqbufs.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_REQBUFS:4.. _VIDIOC_REQBUFS:
4 5
@@ -11,19 +12,18 @@ Name · 6 unmodified lines
11 12
12VIDIOC_REQBUFS - Initiate Memory Mapping, User Pointer I/O or DMA buffer I/O13VIDIOC_REQBUFS - Initiate Memory Mapping, User Pointer I/O or DMA buffer I/O
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_REQBUFS, struct v4l2_requestbuffers *argp )18.. c:macro:: VIDIOC_REQBUFS
19 :name: VIDIOC_REQBUFS
20 19
20``int ioctl(int fd, VIDIOC_REQBUFS, struct v4l2_requestbuffers *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_requestbuffers`.29 Pointer to struct :c:type:`v4l2_requestbuffers`.
@@ -69,7 +69,6 @@ fds are closed. A ``count`` value of zero frees or orphans all buffers, after · 39 unmodified lines
69aborting or finishing any DMA in progress, an implicit69aborting or finishing any DMA in progress, an implicit
70:ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>`.70:ref:`VIDIOC_STREAMOFF <VIDIOC_STREAMON>`.
71 71
72
73.. c:type:: v4l2_requestbuffers72.. c:type:: v4l2_requestbuffers
74 73
75.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|74.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -158,7 +157,6 @@ aborting or finishing any DMA in progress, an implicit · 82 unmodified lines
158 :ref:`V4L2_BUF_FLAG_NO_CACHE_INVALIDATE <V4L2-BUF-FLAG-NO-CACHE-INVALIDATE>` and157 :ref:`V4L2_BUF_FLAG_NO_CACHE_INVALIDATE <V4L2-BUF-FLAG-NO-CACHE-INVALIDATE>` and
159 :ref:`V4L2_BUF_FLAG_NO_CACHE_CLEAN <V4L2-BUF-FLAG-NO-CACHE-CLEAN>`.158 :ref:`V4L2_BUF_FLAG_NO_CACHE_CLEAN <V4L2-BUF-FLAG-NO-CACHE-CLEAN>`.
160 159
161
162Return Value160Return Value
163============161============
164 162
Documentation/userspace-api/media/v4l/vidioc-s-hw-freq-seek.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_S_HW_FREQ_SEEK:4.. _VIDIOC_S_HW_FREQ_SEEK:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_S_HW_FREQ_SEEK - Perform a hardware frequency seek13VIDIOC_S_HW_FREQ_SEEK - Perform a hardware frequency seek
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_S_HW_FREQ_SEEK, struct v4l2_hw_freq_seek *argp )18.. c:macro:: VIDIOC_S_HW_FREQ_SEEK
19 :name: VIDIOC_S_HW_FREQ_SEEK
20 19
20``int ioctl(int fd, VIDIOC_S_HW_FREQ_SEEK, struct v4l2_hw_freq_seek *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_hw_freq_seek`.29 Pointer to struct :c:type:`v4l2_hw_freq_seek`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -59,7 +58,6 @@ set. · 24 unmodified lines
59If this ioctl is called from a non-blocking filehandle, then ``EAGAIN``58If this ioctl is called from a non-blocking filehandle, then ``EAGAIN``
60error code is returned and no seek takes place.59error code is returned and no seek takes place.
61 60
62
63.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|61.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
64 62
65.. c:type:: v4l2_hw_freq_seek63.. c:type:: v4l2_hw_freq_seek
@@ -116,7 +114,6 @@ error code is returned and no seek takes place. · 50 unmodified lines
116 - Reserved for future extensions. Applications must set the array to114 - Reserved for future extensions. Applications must set the array to
117 zero.115 zero.
118 116
119
120Return Value117Return Value
121============118============
122 119
Documentation/userspace-api/media/v4l/vidioc-streamon.rst+7−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_STREAMON:4.. _VIDIOC_STREAMON:
4 5
@@ -11,22 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_STREAMON - VIDIOC_STREAMOFF - Start or stop streaming I/O13VIDIOC_STREAMON - VIDIOC_STREAMOFF - Start or stop streaming I/O
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_STREAMON, const int *argp )18.. c:macro:: VIDIOC_STREAMON
19 :name: VIDIOC_STREAMON19
20``int ioctl(int fd, VIDIOC_STREAMON, const int *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_STREAMOFF, const int *argp )22.. c:macro:: VIDIOC_STREAMOFF
22 :name: VIDIOC_STREAMOFF
23 23
24``int ioctl(int fd, VIDIOC_STREAMOFF, const int *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to an integer.33 Pointer to an integer.
@@ -84,7 +85,6 @@ state as mentioned above. · 51 unmodified lines
84 no notion of starting or stopping "now". Buffer timestamps can be used85 no notion of starting or stopping "now". Buffer timestamps can be used
85 to synchronize with other events.86 to synchronize with other events.
86 87
87
88Return Value88Return Value
89============89============
90 90
Documentation/userspace-api/media/v4l/vidioc-subdev-enum-frame-interval.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL:4.. _VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL - Enumerate frame intervals13VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL - Enumerate frame intervals
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL, struct v4l2_subdev_frame_interval_enum * argp )18.. c:macro:: VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL
19 :name: VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL
20 19
20``int ioctl(int fd, VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL, struct v4l2_subdev_frame_interval_enum * argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_subdev_frame_interval_enum`.29 Pointer to struct :c:type:`v4l2_subdev_frame_interval_enum`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -97,7 +96,6 @@ multiple pads of the same sub-device is not defined. · 62 unmodified lines
97 - Reserved for future extensions. Applications and drivers must set96 - Reserved for future extensions. Applications and drivers must set
98 the array to zero.97 the array to zero.
99 98
100
101Return Value99Return Value
102============100============
103 101
Documentation/userspace-api/media/v4l/vidioc-subdev-enum-frame-size.rst+4−7
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_ENUM_FRAME_SIZE:4.. _VIDIOC_SUBDEV_ENUM_FRAME_SIZE:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_ENUM_FRAME_SIZE - Enumerate media bus frame sizes13VIDIOC_SUBDEV_ENUM_FRAME_SIZE - Enumerate media bus frame sizes
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_ENUM_FRAME_SIZE, struct v4l2_subdev_frame_size_enum * argp )18.. c:macro:: VIDIOC_SUBDEV_ENUM_FRAME_SIZE
19 :name: VIDIOC_SUBDEV_ENUM_FRAME_SIZE
20 19
20``int ioctl(int fd, VIDIOC_SUBDEV_ENUM_FRAME_SIZE, struct v4l2_subdev_frame_size_enum * argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_subdev_frame_size_enum`.29 Pointer to struct :c:type:`v4l2_subdev_frame_size_enum`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -62,7 +61,6 @@ current values of V4L2 controls. See · 27 unmodified lines
62:ref:`VIDIOC_SUBDEV_G_FMT` for more61:ref:`VIDIOC_SUBDEV_G_FMT` for more
63information about try formats.62information about try formats.
64 63
65
66.. c:type:: v4l2_subdev_frame_size_enum64.. c:type:: v4l2_subdev_frame_size_enum
67 65
68.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|66.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -103,7 +101,6 @@ information about try formats. · 34 unmodified lines
103 - Reserved for future extensions. Applications and drivers must set101 - Reserved for future extensions. Applications and drivers must set
104 the array to zero.102 the array to zero.
105 103
106
107Return Value104Return Value
108============105============
109 106
Documentation/userspace-api/media/v4l/vidioc-subdev-enum-mbus-code.rst+4−6
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_ENUM_MBUS_CODE:4.. _VIDIOC_SUBDEV_ENUM_MBUS_CODE:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_ENUM_MBUS_CODE - Enumerate media bus formats13VIDIOC_SUBDEV_ENUM_MBUS_CODE - Enumerate media bus formats
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_ENUM_MBUS_CODE, struct v4l2_subdev_mbus_code_enum * argp )18.. c:macro:: VIDIOC_SUBDEV_ENUM_MBUS_CODE
19 :name: VIDIOC_SUBDEV_ENUM_MBUS_CODE
20 19
20``int ioctl(int fd, VIDIOC_SUBDEV_ENUM_MBUS_CODE, struct v4l2_subdev_mbus_code_enum * argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_subdev_mbus_code_enum`.29 Pointer to struct :c:type:`v4l2_subdev_mbus_code_enum`.
30 30
31
32Description31Description
33===========32===========
34 33
@@ -47,7 +46,6 @@ other pads of the sub-device, as well as on the current active links. · 12 unmodified lines
47See :ref:`VIDIOC_SUBDEV_G_FMT` for more46See :ref:`VIDIOC_SUBDEV_G_FMT` for more
48information about the try formats.47information about the try formats.
49 48
50
51.. c:type:: v4l2_subdev_mbus_code_enum49.. c:type:: v4l2_subdev_mbus_code_enum
52 50
53.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|51.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
Documentation/userspace-api/media/v4l/vidioc-subdev-g-crop.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_G_CROP:4.. _VIDIOC_SUBDEV_G_CROP:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_G_CROP - VIDIOC_SUBDEV_S_CROP - Get or set the crop rectangle on a subdev pad13VIDIOC_SUBDEV_G_CROP - VIDIOC_SUBDEV_S_CROP - Get or set the crop rectangle on a subdev pad
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_CROP, struct v4l2_subdev_crop *argp )18.. c:macro:: VIDIOC_SUBDEV_G_CROP
19 :name: VIDIOC_SUBDEV_G_CROP19
20``int ioctl(int fd, VIDIOC_SUBDEV_G_CROP, struct v4l2_subdev_crop *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_CROP, const struct v4l2_subdev_crop *argp )22.. c:macro:: VIDIOC_SUBDEV_S_CROP
22 :name: VIDIOC_SUBDEV_S_CROP
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_S_CROP, const struct v4l2_subdev_crop *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_subdev_crop`.33 Pointer to struct :c:type:`v4l2_subdev_crop`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -76,7 +76,6 @@ rectangle doesn't match the device capabilities. They must instead · 38 unmodified lines
76modify the rectangle to match what the hardware can provide. The76modify the rectangle to match what the hardware can provide. The
77modified format should be as close as possible to the original request.77modified format should be as close as possible to the original request.
78 78
79
80.. c:type:: v4l2_subdev_crop79.. c:type:: v4l2_subdev_crop
81 80
82.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|81.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -101,7 +100,6 @@ modified format should be as close as possible to the original request. · 18 unmodified lines
101 - Reserved for future extensions. Applications and drivers must set100 - Reserved for future extensions. Applications and drivers must set
102 the array to zero.101 the array to zero.
103 102
104
105Return Value103Return Value
106============104============
107 105
Documentation/userspace-api/media/v4l/vidioc-subdev-g-fmt.rst+7−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_G_FMT:4.. _VIDIOC_SUBDEV_G_FMT:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_G_FMT - VIDIOC_SUBDEV_S_FMT - Get or set the data format on a subdev pad13VIDIOC_SUBDEV_G_FMT - VIDIOC_SUBDEV_S_FMT - Get or set the data format on a subdev pad
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_FMT, struct v4l2_subdev_format *argp )18.. c:macro:: VIDIOC_SUBDEV_G_FMT
19 :name: VIDIOC_SUBDEV_G_FMT19
20``int ioctl(int fd, VIDIOC_SUBDEV_G_FMT, struct v4l2_subdev_format *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_FMT, struct v4l2_subdev_format *argp )22.. c:macro:: VIDIOC_SUBDEV_S_FMT
22 :name: VIDIOC_SUBDEV_S_FMT
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_S_FMT, struct v4l2_subdev_format *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_subdev_format`.33 Pointer to struct :c:type:`v4l2_subdev_format`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -81,7 +81,6 @@ doesn't match the device capabilities. They must instead modify the · 43 unmodified lines
81format to match what the hardware can provide. The modified format81format to match what the hardware can provide. The modified format
82should be as close as possible to the original request.82should be as close as possible to the original request.
83 83
84
85.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|84.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
86 85
87.. c:type:: v4l2_subdev_format86.. c:type:: v4l2_subdev_format
@@ -108,7 +107,6 @@ should be as close as possible to the original request. · 20 unmodified lines
108 the array to zero.107 the array to zero.
109 108
110 109
111
112.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|110.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
113 111
114.. _v4l2-subdev-format-whence:112.. _v4l2-subdev-format-whence:
@@ -125,7 +123,6 @@ should be as close as possible to the original request. · 10 unmodified lines
125 - 1123 - 1
126 - Active formats, applied to the hardware.124 - Active formats, applied to the hardware.
127 125
128
129Return Value126Return Value
130============127============
131 128
Documentation/userspace-api/media/v4l/vidioc-subdev-g-frame-interval.rst+7−9
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_G_FRAME_INTERVAL:4.. _VIDIOC_SUBDEV_G_FRAME_INTERVAL:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_G_FRAME_INTERVAL - VIDIOC_SUBDEV_S_FRAME_INTERVAL - Get or set the frame interval on a subdev pad13VIDIOC_SUBDEV_G_FRAME_INTERVAL - VIDIOC_SUBDEV_S_FRAME_INTERVAL - Get or set the frame interval on a subdev pad
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_FRAME_INTERVAL, struct v4l2_subdev_frame_interval *argp )18.. c:macro:: VIDIOC_SUBDEV_G_FRAME_INTERVAL
19 :name: VIDIOC_SUBDEV_G_FRAME_INTERVAL19
20``int ioctl(int fd, VIDIOC_SUBDEV_G_FRAME_INTERVAL, struct v4l2_subdev_frame_interval *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_FRAME_INTERVAL, struct v4l2_subdev_frame_interval *argp )22.. c:macro:: VIDIOC_SUBDEV_S_FRAME_INTERVAL
22 :name: VIDIOC_SUBDEV_S_FRAME_INTERVAL
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_S_FRAME_INTERVAL, struct v4l2_subdev_frame_interval *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_subdev_frame_interval`.33 Pointer to struct :c:type:`v4l2_subdev_frame_interval`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -74,7 +74,6 @@ Sub-devices that support the frame interval ioctls should implement them · 36 unmodified lines
74on a single pad only. Their behaviour when supported on multiple pads of74on a single pad only. Their behaviour when supported on multiple pads of
75the same sub-device is not defined.75the same sub-device is not defined.
76 76
77
78.. c:type:: v4l2_subdev_frame_interval77.. c:type:: v4l2_subdev_frame_interval
79 78
80.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|79.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -95,7 +94,6 @@ the same sub-device is not defined. · 14 unmodified lines
95 - Reserved for future extensions. Applications and drivers must set94 - Reserved for future extensions. Applications and drivers must set
96 the array to zero.95 the array to zero.
97 96
98
99Return Value97Return Value
100============98============
101 99
Documentation/userspace-api/media/v4l/vidioc-subdev-g-selection.rst+7−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_G_SELECTION:4.. _VIDIOC_SUBDEV_G_SELECTION:
4 5
@@ -11,27 +12,26 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_G_SELECTION - VIDIOC_SUBDEV_S_SELECTION - Get or set selection rectangles on a subdev pad13VIDIOC_SUBDEV_G_SELECTION - VIDIOC_SUBDEV_S_SELECTION - Get or set selection rectangles on a subdev pad
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_G_SELECTION, struct v4l2_subdev_selection *argp )18.. c:macro:: VIDIOC_SUBDEV_G_SELECTION
19 :name: VIDIOC_SUBDEV_G_SELECTION19
20``int ioctl(int fd, VIDIOC_SUBDEV_G_SELECTION, struct v4l2_subdev_selection *argp)``
20 21
21.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_S_SELECTION, struct v4l2_subdev_selection *argp )22.. c:macro:: VIDIOC_SUBDEV_S_SELECTION
22 :name: VIDIOC_SUBDEV_S_SELECTION
23 23
24``int ioctl(int fd, VIDIOC_SUBDEV_S_SELECTION, struct v4l2_subdev_selection *argp)``
24 25
25Arguments26Arguments
26=========27=========
27 28
28``fd``29``fd``
29 File descriptor returned by :ref:`open() <func-open>`.30 File descriptor returned by :c:func:`open()`.
30 31
31``argp``32``argp``
32 Pointer to struct :c:type:`v4l2_subdev_selection`.33 Pointer to struct :c:type:`v4l2_subdev_selection`.
33 34
34
35Description35Description
36===========36===========
37 37
@@ -58,7 +58,6 @@ There are two types of selection targets: actual and bounds. The actual · 20 unmodified lines
58targets are the targets which configure the hardware. The BOUNDS target58targets are the targets which configure the hardware. The BOUNDS target
59will return a rectangle that contain all possible actual rectangles.59will return a rectangle that contain all possible actual rectangles.
60 60
61
62Discovering supported features61Discovering supported features
63------------------------------62------------------------------
64 63
@@ -69,7 +68,6 @@ return ``EINVAL``. · 4 unmodified lines
69Selection targets and flags are documented in68Selection targets and flags are documented in
70:ref:`v4l2-selections-common`.69:ref:`v4l2-selections-common`.
71 70
72
73.. c:type:: v4l2_subdev_selection71.. c:type:: v4l2_subdev_selection
74 72
75.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|73.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
@@ -100,7 +98,6 @@ Selection targets and flags are documented in · 24 unmodified lines
100 - Reserved for future extensions. Applications and drivers must set98 - Reserved for future extensions. Applications and drivers must set
101 the array to zero.99 the array to zero.
102 100
103
104Return Value101Return Value
105============102============
106 103
Documentation/userspace-api/media/v4l/vidioc-subdev-querycap.rst+4−5
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBDEV_QUERYCAP:4.. _VIDIOC_SUBDEV_QUERYCAP:
4 5
@@ -11,24 +12,22 @@ Name · 6 unmodified lines
11 12
12VIDIOC_SUBDEV_QUERYCAP - Query sub-device capabilities13VIDIOC_SUBDEV_QUERYCAP - Query sub-device capabilities
13 14
14
15Synopsis15Synopsis
16========16========
17 17
18.. c:function:: int ioctl( int fd, VIDIOC_SUBDEV_QUERYCAP, struct v4l2_subdev_capability *argp )18.. c:macro:: VIDIOC_SUBDEV_QUERYCAP
19 :name: VIDIOC_SUBDEV_QUERYCAP
20 19
20``int ioctl(int fd, VIDIOC_SUBDEV_QUERYCAP, struct v4l2_subdev_capability *argp)``
21 21
22Arguments22Arguments
23=========23=========
24 24
25``fd``25``fd``
26 File descriptor returned by :ref:`open() <func-open>`.26 File descriptor returned by :c:func:`open()`.
27 27
28``argp``28``argp``
29 Pointer to struct :c:type:`v4l2_subdev_capability`.29 Pointer to struct :c:type:`v4l2_subdev_capability`.
30 30
31
32Description31Description
33===========32===========
34 33
Documentation/userspace-api/media/v4l/vidioc-subscribe-event.rst+7−10
@@ -1,4 +1,5 @@
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2.. c:namespace:: V4L
2 3
3.. _VIDIOC_SUBSCRIBE_EVENT:4.. _VIDIOC_SUBSCRIBE_EVENT:
4.. _VIDIOC_UNSUBSCRIBE_EVENT:5.. _VIDIOC_UNSUBSCRIBE_EVENT:
@@ -12,34 +13,32 @@ Name · 7 unmodified lines
12 13
13VIDIOC_SUBSCRIBE_EVENT - VIDIOC_UNSUBSCRIBE_EVENT - Subscribe or unsubscribe event14VIDIOC_SUBSCRIBE_EVENT - VIDIOC_UNSUBSCRIBE_EVENT - Subscribe or unsubscribe event
14 15
15
16Synopsis16Synopsis
17========17========
18 18
19.. c:function:: int ioctl( int fd, VIDIOC_SUBSCRIBE_EVENT, struct v4l2_event_subscription *argp )19.. c:macro:: VIDIOC_SUBSCRIBE_EVENT
20 :name: VIDIOC_SUBSCRIBE_EVENT20
21``int ioctl(int fd, VIDIOC_SUBSCRIBE_EVENT, struct v4l2_event_subscription *argp)``
21 22
22.. c:function:: int ioctl( int fd, VIDIOC_UNSUBSCRIBE_EVENT, struct v4l2_event_subscription *argp )23.. c:macro:: VIDIOC_UNSUBSCRIBE_EVENT
23 :name: VIDIOC_UNSUBSCRIBE_EVENT
24 24
25``int ioctl(int fd, VIDIOC_UNSUBSCRIBE_EVENT, struct v4l2_event_subscription *argp)``
25 26
26Arguments27Arguments
27=========28=========
28 29
29``fd``30``fd``
30 File descriptor returned by :ref:`open() <func-open>`.31 File descriptor returned by :c:func:`open()`.
31 32
32``argp``33``argp``
33 Pointer to struct :c:type:`v4l2_event_subscription`.34 Pointer to struct :c:type:`v4l2_event_subscription`.
34 35
35
36Description36Description
37===========37===========
38 38
39Subscribe or unsubscribe V4L2 event. Subscribed events are dequeued by39Subscribe or unsubscribe V4L2 event. Subscribed events are dequeued by
40using the :ref:`VIDIOC_DQEVENT` ioctl.40using the :ref:`VIDIOC_DQEVENT` ioctl.
41 41
42
43.. tabularcolumns:: |p{4.6cm}|p{4.4cm}|p{8.7cm}|42.. tabularcolumns:: |p{4.6cm}|p{4.4cm}|p{8.7cm}|
44 43
45.. c:type:: v4l2_event_subscription44.. c:type:: v4l2_event_subscription
@@ -72,7 +71,6 @@ using the :ref:`VIDIOC_DQEVENT` ioctl. · 26 unmodified lines
72 the array to zero.71 the array to zero.
73 72
74 73
75
76.. tabularcolumns:: |p{6.8cm}|p{2.2cm}|p{8.5cm}|74.. tabularcolumns:: |p{6.8cm}|p{2.2cm}|p{8.5cm}|
77 75
78.. _event-flags:76.. _event-flags:
@@ -107,7 +105,6 @@ using the :ref:`VIDIOC_DQEVENT` ioctl. · 28 unmodified lines
107 Think carefully when you set this flag so you won't get into105 Think carefully when you set this flag so you won't get into
108 situations like that.106 situations like that.
109 107
110
111Return Value108Return Value
112============109============
113 110
Documentation/virt/uml/user_mode_linux_howto_v2.rst+1−0
@@ -679,6 +679,7 @@ Starting UML · 678 unmodified lines
679 679
680We can now run UML.680We can now run UML.
681::681::
682
682 # linux mem=2048M umid=TEST \683 # linux mem=2048M umid=TEST \
683 ubd0=Filesystem.img \684 ubd0=Filesystem.img \
684 vec0:transport=tap,ifname=tap0,depth=128,gro=1 \685 vec0:transport=tap,ifname=tap0,depth=128,gro=1 \
Documentation/vm/hmm.rst+1−1
@@ -360,7 +360,7 @@ between device driver specific code and shared common code: · 359 unmodified lines
360 system memory page, locks the page with ``lock_page()``, and fills in the360 system memory page, locks the page with ``lock_page()``, and fills in the
361 ``dst`` array entry with::361 ``dst`` array entry with::
362 362
363 dst[i] = migrate_pfn(page_to_pfn(dpage)) | MIGRATE_PFN_LOCKED;363 dst[i] = migrate_pfn(page_to_pfn(dpage)) | MIGRATE_PFN_LOCKED;
364 364
365 Now that the driver knows that this page is being migrated, it can365 Now that the driver knows that this page is being migrated, it can
366 invalidate device private MMU mappings and copy device private memory366 invalidate device private MMU mappings and copy device private memory
Documentation/vm/ksm.rst+1−1
@@ -26,7 +26,7 @@ tree. · 25 unmodified lines
26 26
27If a KSM page is shared between less than ``max_page_sharing`` VMAs,27If a KSM page is shared between less than ``max_page_sharing`` VMAs,
28the node of the stable tree that represents such KSM page points to a28the node of the stable tree that represents such KSM page points to a
29list of :c:type:`struct rmap_item` and the ``page->mapping`` of the29list of struct rmap_item and the ``page->mapping`` of the
30KSM page points to the stable tree node.30KSM page points to the stable tree node.
31 31
32When the sharing passes this threshold, KSM adds a second dimension to32When the sharing passes this threshold, KSM adds a second dimension to
Documentation/vm/memory-model.rst+3−3
@@ -24,7 +24,7 @@ whether it is possible to manually override that default. · 23 unmodified lines
24 although it is still in use by several architectures.24 although it is still in use by several architectures.
25 25
26All the memory models track the status of physical page frames using26All the memory models track the status of physical page frames using
27:c:type:`struct page` arranged in one or more arrays.27struct page arranged in one or more arrays.
28 28
29Regardless of the selected memory model, there exists one-to-one29Regardless of the selected memory model, there exists one-to-one
30mapping between the physical page frame number (PFN) and the30mapping between the physical page frame number (PFN) and the
@@ -111,7 +111,7 @@ maps for non-volatile memory devices and deferred initialization of · 80 unmodified lines
111the memory map for larger systems.111the memory map for larger systems.
112 112
113The SPARSEMEM model presents the physical memory as a collection of113The SPARSEMEM model presents the physical memory as a collection of
114sections. A section is represented with :c:type:`struct mem_section`114sections. A section is represented with struct mem_section
115that contains `section_mem_map` that is, logically, a pointer to an115that contains `section_mem_map` that is, logically, a pointer to an
116array of struct pages. However, it is stored with some other magic116array of struct pages. However, it is stored with some other magic
117that aids the sections management. The section size and maximal number117that aids the sections management. The section size and maximal number
@@ -172,7 +172,7 @@ management. · 54 unmodified lines
172 172
173The virtually mapped memory map allows storing `struct page` objects173The virtually mapped memory map allows storing `struct page` objects
174for persistent memory devices in pre-allocated storage on those174for persistent memory devices in pre-allocated storage on those
175devices. This storage is represented with :c:type:`struct vmem_altmap`175devices. This storage is represented with struct vmem_altmap
176that is eventually passed to vmemmap_populate() through a long chain176that is eventually passed to vmemmap_populate() through a long chain
177of function calls. The vmemmap_populate() implementation may use the177of function calls. The vmemmap_populate() implementation may use the
178`vmem_altmap` along with :c:func:`vmemmap_alloc_block_buf` helper to178`vmem_altmap` along with :c:func:`vmemmap_alloc_block_buf` helper to
MAINTAINERS+8−8
@@ -1500,7 +1500,7 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) · 1499 unmodified lines
1500S: Maintained1500S: Maintained
1501F: Documentation/devicetree/bindings/arm/actions.yaml1501F: Documentation/devicetree/bindings/arm/actions.yaml
1502F: Documentation/devicetree/bindings/clock/actions,owl-cmu.txt1502F: Documentation/devicetree/bindings/clock/actions,owl-cmu.txt
1503F: Documentation/devicetree/bindings/dma/owl-dma.txt1503F: Documentation/devicetree/bindings/dma/owl-dma.yaml
1504F: Documentation/devicetree/bindings/i2c/i2c-owl.txt1504F: Documentation/devicetree/bindings/i2c/i2c-owl.txt
1505F: Documentation/devicetree/bindings/interrupt-controller/actions,owl-sirq.yaml1505F: Documentation/devicetree/bindings/interrupt-controller/actions,owl-sirq.yaml
1506F: Documentation/devicetree/bindings/mmc/owl-mmc.yaml1506F: Documentation/devicetree/bindings/mmc/owl-mmc.yaml
@@ -5868,7 +5868,7 @@ L: linux-renesas-soc@vger.kernel.org · 4361 unmodified lines
5868S: Supported5868S: Supported
5869T: git git://linuxtv.org/pinchartl/media drm/du/next5869T: git git://linuxtv.org/pinchartl/media drm/du/next
5870F: Documentation/devicetree/bindings/display/bridge/renesas,dw-hdmi.txt5870F: Documentation/devicetree/bindings/display/bridge/renesas,dw-hdmi.txt
5871F: Documentation/devicetree/bindings/display/bridge/renesas,lvds.txt5871F: Documentation/devicetree/bindings/display/bridge/renesas,lvds.yaml
5872F: Documentation/devicetree/bindings/display/renesas,du.txt5872F: Documentation/devicetree/bindings/display/renesas,du.txt
5873F: drivers/gpu/drm/rcar-du/5873F: drivers/gpu/drm/rcar-du/
5874F: drivers/gpu/drm/shmobile/5874F: drivers/gpu/drm/shmobile/
@@ -7000,7 +7000,7 @@ M: Frank Li <Frank.li@nxp.com> · 1125 unmodified lines
7000L: linux-arm-kernel@lists.infradead.org7000L: linux-arm-kernel@lists.infradead.org
7001S: Maintained7001S: Maintained
7002F: Documentation/admin-guide/perf/imx-ddr.rst7002F: Documentation/admin-guide/perf/imx-ddr.rst
7003F: Documentation/devicetree/bindings/perf/fsl-imx-ddr.txt7003F: Documentation/devicetree/bindings/perf/fsl-imx-ddr.yaml
7004F: drivers/perf/fsl_imx8_ddr_perf.c7004F: drivers/perf/fsl_imx8_ddr_perf.c
7005 7005
7006FREESCALE IMX I2C DRIVER7006FREESCALE IMX I2C DRIVER
@@ -7008,7 +7008,7 @@ M: Oleksij Rempel <o.rempel@pengutronix.de> · 1 unmodified line
7008R: Pengutronix Kernel Team <kernel@pengutronix.de>7008R: Pengutronix Kernel Team <kernel@pengutronix.de>
7009L: linux-i2c@vger.kernel.org7009L: linux-i2c@vger.kernel.org
7010S: Maintained7010S: Maintained
7011F: Documentation/devicetree/bindings/i2c/i2c-imx.txt7011F: Documentation/devicetree/bindings/i2c/i2c-imx.yaml
7012F: drivers/i2c/busses/i2c-imx.c7012F: drivers/i2c/busses/i2c-imx.c
7013 7013
7014FREESCALE IMX LPI2C DRIVER7014FREESCALE IMX LPI2C DRIVER
@@ -7016,7 +7016,7 @@ M: Dong Aisheng <aisheng.dong@nxp.com> · 1 unmodified line
7016L: linux-i2c@vger.kernel.org7016L: linux-i2c@vger.kernel.org
7017L: linux-imx@nxp.com7017L: linux-imx@nxp.com
7018S: Maintained7018S: Maintained
7019F: Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.txt7019F: Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml
7020F: drivers/i2c/busses/i2c-imx-lpi2c.c7020F: drivers/i2c/busses/i2c-imx-lpi2c.c
7021 7021
7022FREESCALE QORIQ DPAA ETHERNET DRIVER7022FREESCALE QORIQ DPAA ETHERNET DRIVER
@@ -11677,7 +11677,7 @@ MIPS GENERIC PLATFORM · 4654 unmodified lines
11677M: Paul Burton <paulburton@kernel.org>11677M: Paul Burton <paulburton@kernel.org>
11678L: linux-mips@vger.kernel.org11678L: linux-mips@vger.kernel.org
11679S: Supported11679S: Supported
11680F: Documentation/devicetree/bindings/power/mti,mips-cpc.txt11680F: Documentation/devicetree/bindings/power/mti,mips-cpc.yaml
11681F: arch/mips/generic/11681F: arch/mips/generic/
11682F: arch/mips/tools/generic-board-config.sh11682F: arch/mips/tools/generic-board-config.sh
11683 11683
@@ -12568,7 +12568,7 @@ NXP SGTL5000 DRIVER · 884 unmodified lines
12568M: Fabio Estevam <festevam@gmail.com>12568M: Fabio Estevam <festevam@gmail.com>
12569L: alsa-devel@alsa-project.org (moderated for non-subscribers)12569L: alsa-devel@alsa-project.org (moderated for non-subscribers)
12570S: Maintained12570S: Maintained
12571F: Documentation/devicetree/bindings/sound/sgtl5000.txt12571F: Documentation/devicetree/bindings/sound/sgtl5000.yaml
12572F: sound/soc/codecs/sgtl5000*12572F: sound/soc/codecs/sgtl5000*
12573 12573
12574NXP SJA1105 ETHERNET SWITCH DRIVER12574NXP SJA1105 ETHERNET SWITCH DRIVER
@@ -16868,7 +16868,7 @@ SYNOPSYS DESIGNWARE DMAC DRIVER · 4293 unmodified lines
16868M: Viresh Kumar <vireshk@kernel.org>16868M: Viresh Kumar <vireshk@kernel.org>
16869R: Andy Shevchenko <andriy.shevchenko@linux.intel.com>16869R: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
16870S: Maintained16870S: Maintained
16871F: Documentation/devicetree/bindings/dma/snps-dma.txt16871F: Documentation/devicetree/bindings/dma/snps,dma-spear1340.yaml
16872F: drivers/dma/dw/16872F: drivers/dma/dw/
16873F: include/dt-bindings/dma/dw-dmac.h16873F: include/dt-bindings/dma/dw-dmac.h
16874F: include/linux/dma/dw.h16874F: include/linux/dma/dw.h
block/bio.c+2−2
@@ -327,7 +327,7 @@ static void bio_chain_endio(struct bio *bio) · 326 unmodified lines
327/**327/**
328 * bio_chain - chain bio completions328 * bio_chain - chain bio completions
329 * @bio: the target bio329 * @bio: the target bio
330 * @parent: the @bio's parent bio330 * @parent: the parent bio of @bio
331 *331 *
332 * The caller won't have a bi_end_io called when @bio completes - instead,332 * The caller won't have a bi_end_io called when @bio completes - instead,
333 * @parent's bi_end_io won't be called until both @parent and @bio have333 * @parent's bi_end_io won't be called until both @parent and @bio have
@@ -1093,7 +1093,7 @@ static int __bio_iov_append_get_pages(struct bio *bio, struct iov_iter *iter) · 759 unmodified lines
1093 * released.1093 * released.
1094 *1094 *
1095 * The function tries, but does not guarantee, to pin as many pages as1095 * The function tries, but does not guarantee, to pin as many pages as
1096 * fit into the bio, or are requested in *iter, whatever is smaller. If1096 * fit into the bio, or are requested in @iter, whatever is smaller. If
1097 * MM encounters an error pinning the requested pages, it stops. Error1097 * MM encounters an error pinning the requested pages, it stops. Error
1098 * is returned only if 0 pages could be pinned.1098 * is returned only if 0 pages could be pinned.
1099 */1099 */
drivers/base/core.c+5−2
@@ -4212,13 +4212,16 @@ define_dev_printk_level(_dev_info, KERN_INFO); · 4211 unmodified lines
4212 * -EPROBE_DEFER and propagate error upwards.4212 * -EPROBE_DEFER and propagate error upwards.
4213 * In case of -EPROBE_DEFER it sets also defer probe reason, which can be4213 * In case of -EPROBE_DEFER it sets also defer probe reason, which can be
4214 * checked later by reading devices_deferred debugfs attribute.4214 * checked later by reading devices_deferred debugfs attribute.
4215 * It replaces code sequence:4215 * It replaces code sequence::
4216 *
4216 * if (err != -EPROBE_DEFER)4217 * if (err != -EPROBE_DEFER)
4217 * dev_err(dev, ...);4218 * dev_err(dev, ...);
4218 * else4219 * else
4219 * dev_dbg(dev, ...);4220 * dev_dbg(dev, ...);
4220 * return err;4221 * return err;
4221 * with4222 *
4223 * with::
4224 *
4222 * return dev_err_probe(dev, err, ...);4225 * return dev_err_probe(dev, err, ...);
4223 *4226 *
4224 * Returns @err.4227 * Returns @err.
drivers/net/appletalk/Kconfig+1−1
@@ -48,7 +48,7 @@ config LTPC · 47 unmodified lines
48 If you are in doubt, this card is the one with the 65C02 chip on it.48 If you are in doubt, this card is the one with the 65C02 chip on it.
49 You also need version 1.3.3 or later of the netatalk package.49 You also need version 1.3.3 or later of the netatalk package.
50 This driver is experimental, which means that it may not work.50 This driver is experimental, which means that it may not work.
51 See the file <file:Documentation/networking/ltpc.rst>.51 See the file <file:Documentation/networking/device_drivers/appletalk/ltpc.rst>.
52 52
53config COPS53config COPS
54 tristate "COPS LocalTalk PC support"54 tristate "COPS LocalTalk PC support"
drivers/net/hamradio/scc.c+1−1
@@ -7,7 +7,7 @@ · 6 unmodified lines
7 * ------------------7 * ------------------
8 *8 *
9 * You can find a subset of the documentation in 9 * You can find a subset of the documentation in
10 * Documentation/networking/device_drivers/wan/z8530drv.rst.10 * Documentation/networking/device_drivers/hamradio/z8530drv.rst.
11 */11 */
12 12
13/*13/*
include/kunit/test.h+9−5
@@ -25,6 +25,7 @@ typedef void (*kunit_resource_free_t)(struct kunit_resource *); · 24 unmodified lines
25/**25/**
26 * struct kunit_resource - represents a *test managed resource*26 * struct kunit_resource - represents a *test managed resource*
27 * @data: for the user to store arbitrary data.27 * @data: for the user to store arbitrary data.
28 * @name: optional name
28 * @free: a user supplied function to free the resource. Populated by29 * @free: a user supplied function to free the resource. Populated by
29 * kunit_resource_alloc().30 * kunit_resource_alloc().
30 *31 *
@@ -80,10 +81,10 @@ typedef void (*kunit_resource_free_t)(struct kunit_resource *); · 49 unmodified lines
80 */81 */
81struct kunit_resource {82struct kunit_resource {
82 void *data;83 void *data;
83 const char *name; /* optional name */84 const char *name;
85 kunit_resource_free_t free;
84 86
85 /* private: internal use only. */87 /* private: internal use only. */
86 kunit_resource_free_t free;
87 struct kref refcount;88 struct kref refcount;
88 struct list_head node;89 struct list_head node;
89};90};
@@ -348,6 +349,7 @@ static inline void kunit_put_resource(struct kunit_resource *res) · 258 unmodified lines
348 * none is supplied, the resource data value is simply set to @data.349 * none is supplied, the resource data value is simply set to @data.
349 * If an init function is supplied, @data is passed to it instead.350 * If an init function is supplied, @data is passed to it instead.
350 * @free: a user-supplied function to free the resource (if needed).351 * @free: a user-supplied function to free the resource (if needed).
352 * @res: The resource.
351 * @data: value to pass to init function or set in resource data field.353 * @data: value to pass to init function or set in resource data field.
352 */354 */
353int kunit_add_resource(struct kunit *test,355int kunit_add_resource(struct kunit *test,
@@ -361,7 +363,9 @@ int kunit_add_resource(struct kunit *test, · 7 unmodified lines
361 * @test: The test context object.363 * @test: The test context object.
362 * @init: a user-supplied function to initialize the resource data, if needed.364 * @init: a user-supplied function to initialize the resource data, if needed.
363 * @free: a user-supplied function to free the resource data, if needed.365 * @free: a user-supplied function to free the resource data, if needed.
364 * @name_data: name and data to be set for resource.366 * @res: The resource.
367 * @name: name to be set for resource.
368 * @data: value to pass to init function or set in resource data field.
365 */369 */
366int kunit_add_named_resource(struct kunit *test,370int kunit_add_named_resource(struct kunit *test,
367 kunit_resource_init_t init,371 kunit_resource_init_t init,
@@ -499,8 +503,8 @@ static inline int kunit_destroy_named_resource(struct kunit *test, · 131 unmodified lines
499}503}
500 504
501/**505/**
502 * kunit_remove_resource: remove resource from resource list associated with506 * kunit_remove_resource() - remove resource from resource list associated with
503 * test.507 * test.
504 * @test: The test context object.508 * @test: The test context object.
505 * @res: The resource to be removed.509 * @res: The resource to be removed.
506 *510 *
include/linux/devfreq.h+1−6
@@ -228,12 +228,7 @@ int devfreq_resume_device(struct devfreq *devfreq); · 227 unmodified lines
228void devfreq_suspend(void);228void devfreq_suspend(void);
229void devfreq_resume(void);229void devfreq_resume(void);
230 230
231/**231/* update_devfreq() - Reevaluate the device and configure frequency */
232 * update_devfreq() - Reevaluate the device and configure frequency
233 * @devfreq: the devfreq device
234 *
235 * Note: devfreq->lock must be held
236 */
237int update_devfreq(struct devfreq *devfreq);232int update_devfreq(struct devfreq *devfreq);
238 233
239/* Helper functions for devfreq user device driver with OPP. */234/* Helper functions for devfreq user device driver with OPP. */
include/linux/input/sparse-keymap.h+1−0
@@ -20,6 +20,7 @@ · 19 unmodified lines
20 * private definitions.20 * private definitions.
21 * @code: Device-specific data identifying the button/switch21 * @code: Device-specific data identifying the button/switch
22 * @keycode: KEY_* code assigned to a key/button22 * @keycode: KEY_* code assigned to a key/button
23 * @sw: struct with code/value used by KE_SW and KE_VSW
23 * @sw.code: SW_* code assigned to a switch24 * @sw.code: SW_* code assigned to a switch
24 * @sw.value: Value that should be sent in an input even when KE_SW25 * @sw.value: Value that should be sent in an input even when KE_SW
25 * switch is toggled. KE_VSW switches ignore this field and26 * switch is toggled. KE_VSW switches ignore this field and
include/linux/math64.h+4−4
@@ -28,7 +28,7 @@ static inline u64 div_u64_rem(u64 dividend, u32 divisor, u32 *remainder) · 27 unmodified lines
28 return dividend / divisor;28 return dividend / divisor;
29}29}
30 30
31/**31/*
32 * div_s64_rem - signed 64bit divide with 32bit divisor with remainder32 * div_s64_rem - signed 64bit divide with 32bit divisor with remainder
33 * @dividend: signed 64bit dividend33 * @dividend: signed 64bit dividend
34 * @divisor: signed 32bit divisor34 * @divisor: signed 32bit divisor
@@ -42,7 +42,7 @@ static inline s64 div_s64_rem(s64 dividend, s32 divisor, s32 *remainder) · 7 unmodified lines
42 return dividend / divisor;42 return dividend / divisor;
43}43}
44 44
45/**45/*
46 * div64_u64_rem - unsigned 64bit divide with 64bit divisor and remainder46 * div64_u64_rem - unsigned 64bit divide with 64bit divisor and remainder
47 * @dividend: unsigned 64bit dividend47 * @dividend: unsigned 64bit dividend
48 * @divisor: unsigned 64bit divisor48 * @divisor: unsigned 64bit divisor
@@ -56,7 +56,7 @@ static inline u64 div64_u64_rem(u64 dividend, u64 divisor, u64 *remainder) · 7 unmodified lines
56 return dividend / divisor;56 return dividend / divisor;
57}57}
58 58
59/**59/*
60 * div64_u64 - unsigned 64bit divide with 64bit divisor60 * div64_u64 - unsigned 64bit divide with 64bit divisor
61 * @dividend: unsigned 64bit dividend61 * @dividend: unsigned 64bit dividend
62 * @divisor: unsigned 64bit divisor62 * @divisor: unsigned 64bit divisor
@@ -68,7 +68,7 @@ static inline u64 div64_u64(u64 dividend, u64 divisor) · 5 unmodified lines
68 return dividend / divisor;68 return dividend / divisor;
69}69}
70 70
71/**71/*
72 * div64_s64 - signed 64bit divide with 64bit divisor72 * div64_s64 - signed 64bit divide with 64bit divisor
73 * @dividend: signed 64bit dividend73 * @dividend: signed 64bit dividend
74 * @divisor: signed 64bit divisor74 * @divisor: signed 64bit divisor
include/linux/usb/typec_altmode.h+16−0
@@ -152,10 +152,26 @@ struct typec_altmode_driver { · 151 unmodified lines
152#define to_altmode_driver(d) container_of(d, struct typec_altmode_driver, \152#define to_altmode_driver(d) container_of(d, struct typec_altmode_driver, \
153 driver)153 driver)
154 154
155/**
156 * typec_altmode_register_driver - registers a USB Type-C alternate mode
157 * device driver
158 * @drv: pointer to struct typec_altmode_driver
159 *
160 * These drivers will be bind to the partner alternate mode devices. They will
161 * handle all SVID specific communication.
162 */
155#define typec_altmode_register_driver(drv) \163#define typec_altmode_register_driver(drv) \
156 __typec_altmode_register_driver(drv, THIS_MODULE)164 __typec_altmode_register_driver(drv, THIS_MODULE)
157int __typec_altmode_register_driver(struct typec_altmode_driver *drv,165int __typec_altmode_register_driver(struct typec_altmode_driver *drv,
158 struct module *module);166 struct module *module);
167/**
168 * typec_altmode_unregister_driver - unregisters a USB Type-C alternate mode
169 * device driver
170 * @drv: pointer to struct typec_altmode_driver
171 *
172 * These drivers will be bind to the partner alternate mode devices. They will
173 * handle all SVID specific communication.
174 */
159void typec_altmode_unregister_driver(struct typec_altmode_driver *drv);175void typec_altmode_unregister_driver(struct typec_altmode_driver *drv);
160 176
161#define module_typec_altmode_driver(__typec_altmode_driver) \177#define module_typec_altmode_driver(__typec_altmode_driver) \
include/net/cfg80211.h+1−0
@@ -474,6 +474,7 @@ struct ieee80211_sta_s1g_cap { · 473 unmodified lines
474 * @n_bitrates: Number of bitrates in @bitrates474 * @n_bitrates: Number of bitrates in @bitrates
475 * @ht_cap: HT capabilities in this band475 * @ht_cap: HT capabilities in this band
476 * @vht_cap: VHT capabilities in this band476 * @vht_cap: VHT capabilities in this band
477 * @s1g_cap: S1G capabilities in this band
477 * @edmg_cap: EDMG capabilities in this band478 * @edmg_cap: EDMG capabilities in this band
478 * @s1g_cap: S1G capabilities in this band (S1B band only, of course)479 * @s1g_cap: S1G capabilities in this band (S1B band only, of course)
479 * @n_iftype_data: number of iftype data entries480 * @n_iftype_data: number of iftype data entries
kernel/rcu/tree.c+6−8
@@ -3022,6 +3022,12 @@ struct kfree_rcu_cpu_work { · 3021 unmodified lines
3022 * @monitor_todo: Tracks whether a @monitor_work delayed work is pending3022 * @monitor_todo: Tracks whether a @monitor_work delayed work is pending
3023 * @initialized: The @rcu_work fields have been initialized3023 * @initialized: The @rcu_work fields have been initialized
3024 * @count: Number of objects for which GP not started3024 * @count: Number of objects for which GP not started
3025 * @bkvcache:
3026 * A simple cache list that contains objects for reuse purpose.
3027 * In order to save some per-cpu space the list is singular.
3028 * Even though it is lockless an access has to be protected by the
3029 * per-cpu lock.
3030 * @nr_bkv_objs: number of allocated objects at @bkvcache.
3025 *3031 *
3026 * This is a per-CPU structure. The reason that it is not included in3032 * This is a per-CPU structure. The reason that it is not included in
3027 * the rcu_data structure is to permit this code to be extracted from3033 * the rcu_data structure is to permit this code to be extracted from
@@ -3037,14 +3043,6 @@ struct kfree_rcu_cpu { · 9 unmodified lines
3037 bool monitor_todo;3043 bool monitor_todo;
3038 bool initialized;3044 bool initialized;
3039 int count;3045 int count;
3040
3041 /*
3042 * A simple cache list that contains objects for
3043 * reuse purpose. In order to save some per-cpu
3044 * space the list is singular. Even though it is
3045 * lockless an access has to be protected by the
3046 * per-cpu lock.
3047 */
3048 struct llist_head bkvcache;3046 struct llist_head bkvcache;
3049 int nr_bkv_objs;3047 int nr_bkv_objs;
3050};3048};
kernel/workqueue.c+3−0
@@ -1212,11 +1212,14 @@ out_put: · 1211 unmodified lines
1212 * stable state - idle, on timer or on worklist.1212 * stable state - idle, on timer or on worklist.
1213 *1213 *
1214 * Return:1214 * Return:
1215 *
1216 * ======== ================================================================
1215 * 1 if @work was pending and we successfully stole PENDING1217 * 1 if @work was pending and we successfully stole PENDING
1216 * 0 if @work was idle and we claimed PENDING1218 * 0 if @work was idle and we claimed PENDING
1217 * -EAGAIN if PENDING couldn't be grabbed at the moment, safe to busy-retry1219 * -EAGAIN if PENDING couldn't be grabbed at the moment, safe to busy-retry
1218 * -ENOENT if someone else is canceling @work, this state may persist1220 * -ENOENT if someone else is canceling @work, this state may persist
1219 * for arbitrarily long1221 * for arbitrarily long
1222 * ======== ================================================================
1220 *1223 *
1221 * Note:1224 * Note:
1222 * On >= 0 return, the caller owns @work's PENDING bit. To avoid getting1225 * On >= 0 return, the caller owns @work's PENDING bit. To avoid getting
mm/ksm.c+1−1
@@ -81,7 +81,7 @@ · 80 unmodified lines
81 * different KSM page copy of that content81 * different KSM page copy of that content
82 *82 *
83 * Internally, the regular nodes, "dups" and "chains" are represented83 * Internally, the regular nodes, "dups" and "chains" are represented
84 * using the same :c:type:`struct stable_node` structure.84 * using the same struct stable_node structure.
85 *85 *
86 * In addition to the stable tree, KSM uses a second data structure called the86 * In addition to the stable tree, KSM uses a second data structure called the
87 * unstable tree: this tree holds pointers to pages which have been found to87 * unstable tree: this tree holds pointers to pages which have been found to
mm/memblock.c+4−4
@@ -48,12 +48,12 @@ · 47 unmodified lines
48 * boot regardless of the possible restrictions and memory hot(un)plug;48 * boot regardless of the possible restrictions and memory hot(un)plug;
49 * the ``physmem`` type is only available on some architectures.49 * the ``physmem`` type is only available on some architectures.
50 *50 *
51 * Each region is represented by :c:type:`struct memblock_region` that51 * Each region is represented by struct memblock_region that
52 * defines the region extents, its attributes and NUMA node id on NUMA52 * defines the region extents, its attributes and NUMA node id on NUMA
53 * systems. Every memory type is described by the :c:type:`struct53 * systems. Every memory type is described by the struct memblock_type
54 * memblock_type` which contains an array of memory regions along with54 * which contains an array of memory regions along with
55 * the allocator metadata. The "memory" and "reserved" types are nicely55 * the allocator metadata. The "memory" and "reserved" types are nicely
56 * wrapped with :c:type:`struct memblock`. This structure is statically56 * wrapped with struct memblock. This structure is statically
57 * initialized at build time. The region arrays are initially sized to57 * initialized at build time. The region arrays are initially sized to
58 * %INIT_MEMBLOCK_REGIONS for "memory" and %INIT_MEMBLOCK_RESERVED_REGIONS58 * %INIT_MEMBLOCK_REGIONS for "memory" and %INIT_MEMBLOCK_RESERVED_REGIONS
59 * for "reserved". The region array for "physmem" is initially sized to59 * for "reserved". The region array for "physmem" is initially sized to
scripts/kernel-doc+223−82
@@ -56,6 +56,13 @@ Output format selection (mutually exclusive): · 55 unmodified lines
56 -rst Output reStructuredText format.56 -rst Output reStructuredText format.
57 -none Do not output documentation, only warnings.57 -none Do not output documentation, only warnings.
58 58
59Output format selection modifier (affects only ReST output):
60
61 -sphinx-version Use the ReST C domain dialect compatible with an
62 specific Sphinx Version.
63 If not specified, kernel-doc will auto-detect using
64 the sphinx-build version found on PATH.
65
59Output selection (mutually exclusive):66Output selection (mutually exclusive):
60 -export Only output documentation for symbols that have been67 -export Only output documentation for symbols that have been
61 exported using EXPORT_SYMBOL() or EXPORT_SYMBOL_GPL()68 exported using EXPORT_SYMBOL() or EXPORT_SYMBOL_GPL()
@@ -66,9 +73,8 @@ Output selection (mutually exclusive): · 4 unmodified lines
66 -function NAME Only output documentation for the given function(s)73 -function NAME Only output documentation for the given function(s)
67 or DOC: section title(s). All other functions and DOC:74 or DOC: section title(s). All other functions and DOC:
68 sections are ignored. May be specified multiple times.75 sections are ignored. May be specified multiple times.
69 -nofunction NAME Do NOT output documentation for the given function(s);76 -nosymbol NAME Exclude the specified symbols from the output
70 only output documentation for the other functions and77 documentation. May be specified multiple times.
71 DOC: sections. May be specified multiple times.
72 78
73Output selection modifiers:79Output selection modifiers:
74 -no-doc-sections Do not output DOC: sections.80 -no-doc-sections Do not output DOC: sections.
@@ -271,6 +277,8 @@ if ($#ARGV == -1) { · 196 unmodified lines
271}277}
272 278
273my $kernelversion;279my $kernelversion;
280my ($sphinx_major, $sphinx_minor, $sphinx_patch);
281
274my $dohighlight = "";282my $dohighlight = "";
275 283
276my $verbose = 0;284my $verbose = 0;
@@ -286,9 +294,8 @@ my $modulename = "Kernel API"; · 9 unmodified lines
286use constant {294use constant {
287 OUTPUT_ALL => 0, # output all symbols and doc sections295 OUTPUT_ALL => 0, # output all symbols and doc sections
288 OUTPUT_INCLUDE => 1, # output only specified symbols296 OUTPUT_INCLUDE => 1, # output only specified symbols
289 OUTPUT_EXCLUDE => 2, # output everything except specified symbols297 OUTPUT_EXPORTED => 2, # output exported symbols
290 OUTPUT_EXPORTED => 3, # output exported symbols298 OUTPUT_INTERNAL => 3, # output non-exported symbols
291 OUTPUT_INTERNAL => 4, # output non-exported symbols
292};299};
293my $output_selection = OUTPUT_ALL;300my $output_selection = OUTPUT_ALL;
294my $show_not_found = 0; # No longer used301my $show_not_found = 0; # No longer used
@@ -313,6 +320,7 @@ my $man_date = ('January', 'February', 'March', 'April', 'May', 'June', · 18 unmodified lines
313# CAVEAT EMPTOR! Some of the others I localised may not want to be, which320# CAVEAT EMPTOR! Some of the others I localised may not want to be, which
314# could cause "use of undefined value" or other bugs.321# could cause "use of undefined value" or other bugs.
315my ($function, %function_table, %parametertypes, $declaration_purpose);322my ($function, %function_table, %parametertypes, $declaration_purpose);
323my %nosymbol_table = ();
316my $declaration_start_line;324my $declaration_start_line;
317my ($type, $declaration_name, $return_type);325my ($type, $declaration_name, $return_type);
318my ($newsection, $newcontents, $prototype, $brcount, %source_map);326my ($newsection, $newcontents, $prototype, $brcount, %source_map);
@@ -432,10 +440,9 @@ while ($ARGV[0] =~ m/^--?(.*)/) { · 113 unmodified lines
432 $output_selection = OUTPUT_INCLUDE;440 $output_selection = OUTPUT_INCLUDE;
433 $function = shift @ARGV;441 $function = shift @ARGV;
434 $function_table{$function} = 1;442 $function_table{$function} = 1;
435 } elsif ($cmd eq "nofunction") { # output all except specific functions443 } elsif ($cmd eq "nosymbol") { # Exclude specific symbols
436 $output_selection = OUTPUT_EXCLUDE;444 my $symbol = shift @ARGV;
437 $function = shift @ARGV;445 $nosymbol_table{$symbol} = 1;
438 $function_table{$function} = 1;
439 } elsif ($cmd eq "export") { # only exported symbols446 } elsif ($cmd eq "export") { # only exported symbols
440 $output_selection = OUTPUT_EXPORTED;447 $output_selection = OUTPUT_EXPORTED;
441 %function_table = ();448 %function_table = ();
@@ -457,6 +464,23 @@ while ($ARGV[0] =~ m/^--?(.*)/) { · 15 unmodified lines
457 $enable_lineno = 1;464 $enable_lineno = 1;
458 } elsif ($cmd eq 'show-not-found') {465 } elsif ($cmd eq 'show-not-found') {
459 $show_not_found = 1; # A no-op but don't fail466 $show_not_found = 1; # A no-op but don't fail
467 } elsif ($cmd eq "sphinx-version") {
468 my $ver_string = shift @ARGV;
469 if ($ver_string =~ m/^(\d+)(\.\d+)?(\.\d+)?/) {
470 $sphinx_major = $1;
471 if (defined($2)) {
472 $sphinx_minor = substr($2,1);
473 } else {
474 $sphinx_minor = 0;
475 }
476 if (defined($3)) {
477 $sphinx_patch = substr($3,1)
478 } else {
479 $sphinx_patch = 0;
480 }
481 } else {
482 die "Sphinx version should either major.minor or major.minor.patch format\n";
483 }
460 } else {484 } else {
461 # Unknown argument485 # Unknown argument
462 usage();486 usage();
@@ -465,6 +489,51 @@ while ($ARGV[0] =~ m/^--?(.*)/) { · 2 unmodified lines
465 489
466# continue execution near EOF;490# continue execution near EOF;
467 491
492# The C domain dialect changed on Sphinx 3. So, we need to check the
493# version in order to produce the right tags.
494sub findprog($)
495{
496 foreach(split(/:/, $ENV{PATH})) {
497 return "$_/$_[0]" if(-x "$_/$_[0]");
498 }
499}
500
501sub get_sphinx_version()
502{
503 my $ver;
504
505 my $cmd = "sphinx-build";
506 if (!findprog($cmd)) {
507 my $cmd = "sphinx-build3";
508 if (!findprog($cmd)) {
509 $sphinx_major = 1;
510 $sphinx_minor = 2;
511 $sphinx_patch = 0;
512 printf STDERR "Warning: Sphinx version not found. Using default (Sphinx version %d.%d.%d)\n",
513 $sphinx_major, $sphinx_minor, $sphinx_patch;
514 return;
515 }
516 }
517
518 open IN, "$cmd --version 2>&1 |";
519 while (<IN>) {
520 if (m/^\s*sphinx-build\s+([\d]+)\.([\d\.]+)(\+\/[\da-f]+)?$/) {
521 $sphinx_major = $1;
522 $sphinx_minor = $2;
523 $sphinx_patch = $3;
524 last;
525 }
526 # Sphinx 1.2.x uses a different format
527 if (m/^\s*Sphinx.*\s+([\d]+)\.([\d\.]+)$/) {
528 $sphinx_major = $1;
529 $sphinx_minor = $2;
530 $sphinx_patch = $3;
531 last;
532 }
533 }
534 close IN;
535}
536
468# get kernel version from env537# get kernel version from env
469sub get_kernel_version() {538sub get_kernel_version() {
470 my $version = 'unknown kernel version';539 my $version = 'unknown kernel version';
@@ -531,11 +600,11 @@ sub dump_doc_section { · 60 unmodified lines
531 return;600 return;
532 }601 }
533 602
603 return if (defined($nosymbol_table{$name}));
604
534 if (($output_selection == OUTPUT_ALL) ||605 if (($output_selection == OUTPUT_ALL) ||
535 ($output_selection == OUTPUT_INCLUDE &&606 (($output_selection == OUTPUT_INCLUDE) &&
536 defined($function_table{$name})) ||607 defined($function_table{$name})))
537 ($output_selection == OUTPUT_EXCLUDE &&
538 !defined($function_table{$name})))
539 {608 {
540 dump_section($file, $name, $contents);609 dump_section($file, $name, $contents);
541 output_blockhead({'sectionlist' => \@sectionlist,610 output_blockhead({'sectionlist' => \@sectionlist,
@@ -618,10 +687,10 @@ sub output_function_man(%) { · 76 unmodified lines
618 $type = $args{'parametertypes'}{$parameter};687 $type = $args{'parametertypes'}{$parameter};
619 if ($type =~ m/([^\(]*\(\*)\s*\)\s*\(([^\)]*)\)/) {688 if ($type =~ m/([^\(]*\(\*)\s*\)\s*\(([^\)]*)\)/) {
620 # pointer-to-function689 # pointer-to-function
621 print ".BI \"" . $parenth . $1 . "\" " . $parameter . " \") (" . $2 . ")" . $post . "\"\n";690 print ".BI \"" . $parenth . $1 . "\" " . " \") (" . $2 . ")" . $post . "\"\n";
622 } else {691 } else {
623 $type =~ s/([^\*])$/$1 /;692 $type =~ s/([^\*])$/$1 /;
624 print ".BI \"" . $parenth . $type . "\" " . $parameter . " \"" . $post . "\"\n";693 print ".BI \"" . $parenth . $type . "\" " . " \"" . $post . "\"\n";
625 }694 }
626 $count++;695 $count++;
627 $parenth = "";696 $parenth = "";
@@ -761,6 +830,8 @@ sub output_blockhead_rst(%) { · 133 unmodified lines
761 my ($parameter, $section);830 my ($parameter, $section);
762 831
763 foreach $section (@{$args{'sectionlist'}}) {832 foreach $section (@{$args{'sectionlist'}}) {
833 next if (defined($nosymbol_table{$section}));
834
764 if ($output_selection != OUTPUT_INCLUDE) {835 if ($output_selection != OUTPUT_INCLUDE) {
765 print "**$section**\n\n";836 print "**$section**\n\n";
766 }837 }
@@ -846,16 +917,37 @@ sub output_function_rst(%) { · 79 unmodified lines
846 my ($parameter, $section);917 my ($parameter, $section);
847 my $oldprefix = $lineprefix;918 my $oldprefix = $lineprefix;
848 my $start = "";919 my $start = "";
849 920 my $is_macro = 0;
850 if ($args{'typedef'}) {921
851 print ".. c:type:: ". $args{'function'} . "\n\n";922 if ($sphinx_major < 3) {
852 print_lineno($declaration_start_line);923 if ($args{'typedef'}) {
853 print " **Typedef**: ";924 print ".. c:type:: ". $args{'function'} . "\n\n";
854 $lineprefix = "";925 print_lineno($declaration_start_line);
855 output_highlight_rst($args{'purpose'});926 print " **Typedef**: ";
856 $start = "\n\n**Syntax**\n\n ``";927 $lineprefix = "";
928 output_highlight_rst($args{'purpose'});
929 $start = "\n\n**Syntax**\n\n ``";
930 $is_macro = 1;
931 } else {
932 print ".. c:function:: ";
933 }
857 } else {934 } else {
858 print ".. c:function:: ";935 if ($args{'typedef'} || $args{'functiontype'} eq "") {
936 $is_macro = 1;
937 print ".. c:macro:: ". $args{'function'} . "\n\n";
938 } else {
939 print ".. c:function:: ";
940 }
941
942 if ($args{'typedef'}) {
943 print_lineno($declaration_start_line);
944 print " **Typedef**: ";
945 $lineprefix = "";
946 output_highlight_rst($args{'purpose'});
947 $start = "\n\n**Syntax**\n\n ``";
948 } else {
949 print "``" if ($is_macro);
950 }
859 }951 }
860 if ($args{'functiontype'} ne "") {952 if ($args{'functiontype'} ne "") {
861 $start .= $args{'functiontype'} . " " . $args{'function'} . " (";953 $start .= $args{'functiontype'} . " " . $args{'function'} . " (";
@@ -876,13 +968,15 @@ sub output_function_rst(%) { · 14 unmodified lines
876 # pointer-to-function968 # pointer-to-function
877 print $1 . $parameter . ") (" . $2 . ")";969 print $1 . $parameter . ") (" . $2 . ")";
878 } else {970 } else {
879 print $type . " " . $parameter;971 print $type;
880 }972 }
881 }973 }
882 if ($args{'typedef'}) {974 if ($is_macro) {
883 print ");``\n\n";975 print ")``\n\n";
884 } else {976 } else {
885 print ")\n\n";977 print ")\n\n";
978 }
979 if (!$args{'typedef'}) {
886 print_lineno($declaration_start_line);980 print_lineno($declaration_start_line);
887 $lineprefix = " ";981 $lineprefix = " ";
888 output_highlight_rst($args{'purpose'});982 output_highlight_rst($args{'purpose'});
@@ -897,7 +991,7 @@ sub output_function_rst(%) { · 8 unmodified lines
897 $type = $args{'parametertypes'}{$parameter};991 $type = $args{'parametertypes'}{$parameter};
898 992
899 if ($type ne "") {993 if ($type ne "") {
900 print "``$type $parameter``\n";994 print "``$type``\n";
901 } else {995 } else {
902 print "``$parameter``\n";996 print "``$parameter``\n";
903 }997 }
@@ -938,9 +1032,14 @@ sub output_enum_rst(%) { · 34 unmodified lines
938 my ($parameter);1032 my ($parameter);
939 my $oldprefix = $lineprefix;1033 my $oldprefix = $lineprefix;
940 my $count;1034 my $count;
941 my $name = "enum " . $args{'enum'};
942 1035
943 print "\n\n.. c:type:: " . $name . "\n\n";1036 if ($sphinx_major < 3) {
1037 my $name = "enum " . $args{'enum'};
1038 print "\n\n.. c:type:: " . $name . "\n\n";
1039 } else {
1040 my $name = $args{'enum'};
1041 print "\n\n.. c:enum:: " . $name . "\n\n";
1042 }
944 print_lineno($declaration_start_line);1043 print_lineno($declaration_start_line);
945 $lineprefix = " ";1044 $lineprefix = " ";
946 output_highlight_rst($args{'purpose'});1045 output_highlight_rst($args{'purpose'});
@@ -966,8 +1065,13 @@ sub output_typedef_rst(%) { · 19 unmodified lines
966 my %args = %{$_[0]};1065 my %args = %{$_[0]};
967 my ($parameter);1066 my ($parameter);
968 my $oldprefix = $lineprefix;1067 my $oldprefix = $lineprefix;
969 my $name = "typedef " . $args{'typedef'};1068 my $name;
970 1069
1070 if ($sphinx_major < 3) {
1071 $name = "typedef " . $args{'typedef'};
1072 } else {
1073 $name = $args{'typedef'};
1074 }
971 print "\n\n.. c:type:: " . $name . "\n\n";1075 print "\n\n.. c:type:: " . $name . "\n\n";
972 print_lineno($declaration_start_line);1076 print_lineno($declaration_start_line);
973 $lineprefix = " ";1077 $lineprefix = " ";
@@ -982,9 +1086,14 @@ sub output_struct_rst(%) { · 8 unmodified lines
982 my %args = %{$_[0]};1086 my %args = %{$_[0]};
983 my ($parameter);1087 my ($parameter);
984 my $oldprefix = $lineprefix;1088 my $oldprefix = $lineprefix;
985 my $name = $args{'type'} . " " . $args{'struct'};
986 1089
987 print "\n\n.. c:type:: " . $name . "\n\n";1090 if ($sphinx_major < 3) {
1091 my $name = $args{'type'} . " " . $args{'struct'};
1092 print "\n\n.. c:type:: " . $name . "\n\n";
1093 } else {
1094 my $name = $args{'struct'};
1095 print "\n\n.. c:struct:: " . $name . "\n\n";
1096 }
988 print_lineno($declaration_start_line);1097 print_lineno($declaration_start_line);
989 $lineprefix = " ";1098 $lineprefix = " ";
990 output_highlight_rst($args{'purpose'});1099 output_highlight_rst($args{'purpose'});
@@ -1043,12 +1152,14 @@ sub output_declaration { · 52 unmodified lines
1043 my $name = shift;1152 my $name = shift;
1044 my $functype = shift;1153 my $functype = shift;
1045 my $func = "output_${functype}_$output_mode";1154 my $func = "output_${functype}_$output_mode";
1155
1156 return if (defined($nosymbol_table{$name}));
1157
1046 if (($output_selection == OUTPUT_ALL) ||1158 if (($output_selection == OUTPUT_ALL) ||
1047 (($output_selection == OUTPUT_INCLUDE ||1159 (($output_selection == OUTPUT_INCLUDE ||
1048 $output_selection == OUTPUT_EXPORTED) &&1160 $output_selection == OUTPUT_EXPORTED) &&
1049 defined($function_table{$name})) ||1161 defined($function_table{$name})) ||
1050 (($output_selection == OUTPUT_EXCLUDE ||1162 ($output_selection == OUTPUT_INTERNAL &&
1051 $output_selection == OUTPUT_INTERNAL) &&
1052 !($functype eq "function" && defined($function_table{$name}))))1163 !($functype eq "function" && defined($function_table{$name}))))
1053 {1164 {
1054 &$func(@_);1165 &$func(@_);
@@ -1229,6 +1340,8 @@ sub show_warnings($$) { · 174 unmodified lines
1229 my $functype = shift;1340 my $functype = shift;
1230 my $name = shift;1341 my $name = shift;
1231 1342
1343 return 0 if (defined($nosymbol_table{$name}));
1344
1232 return 1 if ($output_selection == OUTPUT_ALL);1345 return 1 if ($output_selection == OUTPUT_ALL);
1233 1346
1234 if ($output_selection == OUTPUT_EXPORTED) {1347 if ($output_selection == OUTPUT_EXPORTED) {
@@ -1252,27 +1365,28 @@ sub show_warnings($$) { · 17 unmodified lines
1252 return 0;1365 return 0;
1253 }1366 }
1254 }1367 }
1255 if ($output_selection == OUTPUT_EXCLUDE) {
1256 if (!defined($function_table{$name})) {
1257 return 1;
1258 } else {
1259 return 0;
1260 }
1261 }
1262 die("Please add the new output type at show_warnings()");1368 die("Please add the new output type at show_warnings()");
1263}1369}
1264 1370
1265sub dump_enum($$) {1371sub dump_enum($$) {
1266 my $x = shift;1372 my $x = shift;
1267 my $file = shift;1373 my $file = shift;
1374 my $members;
1375
1268 1376
1269 $x =~ s@/\*.*?\*/@@gos; # strip comments.1377 $x =~ s@/\*.*?\*/@@gos; # strip comments.
1270 # strip #define macros inside enums1378 # strip #define macros inside enums
1271 $x =~ s@#\s*((define|ifdef)\s+|endif)[^;]*;@@gos;1379 $x =~ s@#\s*((define|ifdef)\s+|endif)[^;]*;@@gos;
1272 1380
1273 if ($x =~ /enum\s+(\w*)\s*\{(.*)\}/) {1381 if ($x =~ /typedef\s+enum\s*\{(.*)\}\s*(\w*)\s*;/) {
1382 $declaration_name = $2;
1383 $members = $1;
1384 } elsif ($x =~ /enum\s+(\w*)\s*\{(.*)\}/) {
1274 $declaration_name = $1;1385 $declaration_name = $1;
1275 my $members = $2;1386 $members = $2;
1387 }
1388
1389 if ($declaration_name) {
1276 my %_members;1390 my %_members;
1277 1391
1278 $members =~ s/\s+$//;1392 $members =~ s/\s+$//;
@@ -1307,8 +1421,7 @@ sub dump_enum($$) { · 28 unmodified lines
1307 'sections' => \%sections,1421 'sections' => \%sections,
1308 'purpose' => $declaration_purpose1422 'purpose' => $declaration_purpose
1309 });1423 });
1310 }1424 } else {
1311 else {
1312 print STDERR "${file}:$.: error: Cannot parse enum!\n";1425 print STDERR "${file}:$.: error: Cannot parse enum!\n";
1313 ++$errors;1426 ++$errors;
1314 }1427 }
@@ -1403,7 +1516,7 @@ sub create_parameterlist($$$$) { · 88 unmodified lines
1403 # Treat preprocessor directive as a typeless variable just to fill1516 # Treat preprocessor directive as a typeless variable just to fill
1404 # corresponding data structures "correctly". Catch it later in1517 # corresponding data structures "correctly". Catch it later in
1405 # output_* subs.1518 # output_* subs.
1406 push_parameter($arg, "", $file);1519 push_parameter($arg, "", "", $file);
1407 } elsif ($arg =~ m/\(.+\)\s*\(/) {1520 } elsif ($arg =~ m/\(.+\)\s*\(/) {
1408 # pointer-to-function1521 # pointer-to-function
1409 $arg =~ tr/#/,/;1522 $arg =~ tr/#/,/;
@@ -1412,7 +1525,7 @@ sub create_parameterlist($$$$) { · 2 unmodified lines
1412 $type = $arg;1525 $type = $arg;
1413 $type =~ s/([^\(]+\(\*?)\s*$param/$1/;1526 $type =~ s/([^\(]+\(\*?)\s*$param/$1/;
1414 save_struct_actual($param);1527 save_struct_actual($param);
1415 push_parameter($param, $type, $file, $declaration_name);1528 push_parameter($param, $type, $arg, $file, $declaration_name);
1416 } elsif ($arg) {1529 } elsif ($arg) {
1417 $arg =~ s/\s*:\s*/:/g;1530 $arg =~ s/\s*:\s*/:/g;
1418 $arg =~ s/\s*\[/\[/g;1531 $arg =~ s/\s*\[/\[/g;
@@ -1437,26 +1550,28 @@ sub create_parameterlist($$$$) { · 18 unmodified lines
1437 foreach $param (@args) {1550 foreach $param (@args) {
1438 if ($param =~ m/^(\*+)\s*(.*)/) {1551 if ($param =~ m/^(\*+)\s*(.*)/) {
1439 save_struct_actual($2);1552 save_struct_actual($2);
1440 push_parameter($2, "$type $1", $file, $declaration_name);1553
1554 push_parameter($2, "$type $1", $arg, $file, $declaration_name);
1441 }1555 }
1442 elsif ($param =~ m/(.*?):(\d+)/) {1556 elsif ($param =~ m/(.*?):(\d+)/) {
1443 if ($type ne "") { # skip unnamed bit-fields1557 if ($type ne "") { # skip unnamed bit-fields
1444 save_struct_actual($1);1558 save_struct_actual($1);
1445 push_parameter($1, "$type:$2", $file, $declaration_name)1559 push_parameter($1, "$type:$2", $arg, $file, $declaration_name)
1446 }1560 }
1447 }1561 }
1448 else {1562 else {
1449 save_struct_actual($param);1563 save_struct_actual($param);
1450 push_parameter($param, $type, $file, $declaration_name);1564 push_parameter($param, $type, $arg, $file, $declaration_name);
1451 }1565 }
1452 }1566 }
1453 }1567 }
1454 }1568 }
1455}1569}
1456 1570
1457sub push_parameter($$$$) {1571sub push_parameter($$$$$) {
1458 my $param = shift;1572 my $param = shift;
1459 my $type = shift;1573 my $type = shift;
1574 my $org_arg = shift;
1460 my $file = shift;1575 my $file = shift;
1461 my $declaration_name = shift;1576 my $declaration_name = shift;
1462 1577
@@ -1520,8 +1635,8 @@ sub push_parameter($$$$) { · 57 unmodified lines
1520 # "[blah" in a parameter string;1635 # "[blah" in a parameter string;
1521 ###$param =~ s/\s*//g;1636 ###$param =~ s/\s*//g;
1522 push @parameterlist, $param;1637 push @parameterlist, $param;
1523 $type =~ s/\s\s+/ /g;1638 $org_arg =~ s/\s\s+/ /g;
1524 $parametertypes{$param} = $type;1639 $parametertypes{$param} = $org_arg;
1525}1640}
1526 1641
1527sub check_sections($$$$$) {1642sub check_sections($$$$$) {
@@ -1595,7 +1710,7 @@ sub dump_function($$) { · 67 unmodified lines
1595 my $file = shift;1710 my $file = shift;
1596 my $noret = 0;1711 my $noret = 0;
1597 1712
1598 print_lineno($.);1713 print_lineno($new_start_line);
1599 1714
1600 $prototype =~ s/^static +//;1715 $prototype =~ s/^static +//;
1601 $prototype =~ s/^extern +//;1716 $prototype =~ s/^extern +//;
@@ -1672,30 +1787,48 @@ sub dump_function($$) { · 70 unmodified lines
1672 return;1787 return;
1673 }1788 }
1674 1789
1675 my $prms = join " ", @parameterlist;1790 my $prms = join " ", @parameterlist;
1676 check_sections($file, $declaration_name, "function", $sectcheck, $prms);1791 check_sections($file, $declaration_name, "function", $sectcheck, $prms);
1677 1792
1678 # This check emits a lot of warnings at the moment, because many1793 # This check emits a lot of warnings at the moment, because many
1679 # functions don't have a 'Return' doc section. So until the number1794 # functions don't have a 'Return' doc section. So until the number
1680 # of warnings goes sufficiently down, the check is only performed in1795 # of warnings goes sufficiently down, the check is only performed in
1681 # verbose mode.1796 # verbose mode.
1682 # TODO: always perform the check.1797 # TODO: always perform the check.
1683 if ($verbose && !$noret) {1798 if ($verbose && !$noret) {
1684 check_return_section($file, $declaration_name, $return_type);1799 check_return_section($file, $declaration_name, $return_type);
1685 }1800 }
1686 1801
1687 output_declaration($declaration_name,1802 # The function parser can be called with a typedef parameter.
1688 'function',1803 # Handle it.
1689 {'function' => $declaration_name,1804 if ($return_type =~ /typedef/) {
1690 'module' => $modulename,1805 output_declaration($declaration_name,
1691 'functiontype' => $return_type,1806 'function',
1692 'parameterlist' => \@parameterlist,1807 {'function' => $declaration_name,
1693 'parameterdescs' => \%parameterdescs,1808 'typedef' => 1,
1694 'parametertypes' => \%parametertypes,1809 'module' => $modulename,
1695 'sectionlist' => \@sectionlist,1810 'functiontype' => $return_type,
1696 'sections' => \%sections,1811 'parameterlist' => \@parameterlist,
1697 'purpose' => $declaration_purpose1812 'parameterdescs' => \%parameterdescs,
1698 });1813 'parametertypes' => \%parametertypes,
1814 'sectionlist' => \@sectionlist,
1815 'sections' => \%sections,
1816 'purpose' => $declaration_purpose
1817 });
1818 } else {
1819 output_declaration($declaration_name,
1820 'function',
1821 {'function' => $declaration_name,
1822 'module' => $modulename,
1823 'functiontype' => $return_type,
1824 'parameterlist' => \@parameterlist,
1825 'parameterdescs' => \%parameterdescs,
1826 'parametertypes' => \%parametertypes,
1827 'sectionlist' => \@sectionlist,
1828 'sections' => \%sections,
1829 'purpose' => $declaration_purpose
1830 });
1831 }
1699}1832}
1700 1833
1701sub reset_state {1834sub reset_state {
@@ -1873,6 +2006,7 @@ sub process_export_file($) { · 171 unmodified lines
1873 2006
1874 while (<IN>) {2007 while (<IN>) {
1875 if (/$export_symbol/) {2008 if (/$export_symbol/) {
2009 next if (defined($nosymbol_table{$2}));
1876 $function_table{$2} = 1;2010 $function_table{$2} = 1;
1877 }2011 }
1878 }2012 }
@@ -1904,7 +2038,7 @@ sub process_name($$) { · 25 unmodified lines
1904 if (/$doc_block/o) {2038 if (/$doc_block/o) {
1905 $state = STATE_DOCBLOCK;2039 $state = STATE_DOCBLOCK;
1906 $contents = "";2040 $contents = "";
1907 $new_start_line = $. + 1;2041 $new_start_line = $.;
1908 2042
1909 if ( $1 eq "" ) {2043 if ( $1 eq "" ) {
1910 $section = $section_intro;2044 $section = $section_intro;
@@ -1987,6 +2121,7 @@ sub process_body($$) { · 76 unmodified lines
1987 if ($state == STATE_BODY_WITH_BLANK_LINE && /^\s*\*\s?\S/) {2121 if ($state == STATE_BODY_WITH_BLANK_LINE && /^\s*\*\s?\S/) {
1988 dump_section($file, $section, $contents);2122 dump_section($file, $section, $contents);
1989 $section = $section_default;2123 $section = $section_default;
2124 $new_start_line = $.;
1990 $contents = "";2125 $contents = "";
1991 }2126 }
1992 2127
@@ -2042,6 +2177,7 @@ sub process_body($$) { · 49 unmodified lines
2042 $prototype = "";2177 $prototype = "";
2043 $state = STATE_PROTO;2178 $state = STATE_PROTO;
2044 $brcount = 0;2179 $brcount = 0;
2180 $new_start_line = $. + 1;
2045 } elsif (/$doc_content/) {2181 } elsif (/$doc_content/) {
2046 if ($1 eq "") {2182 if ($1 eq "") {
2047 if ($section eq $section_context) {2183 if ($section eq $section_context) {
@@ -2189,7 +2325,7 @@ sub process_file($) { · 141 unmodified lines
2189 2325
2190 $file = map_filename($orig_file);2326 $file = map_filename($orig_file);
2191 2327
2192 if (!open(IN,"<$file")) {2328 if (!open(IN_FILE,"<$file")) {
2193 print STDERR "Error: Cannot open file $file\n";2329 print STDERR "Error: Cannot open file $file\n";
2194 ++$errors;2330 ++$errors;
2195 return;2331 return;
@@ -2198,9 +2334,9 @@ sub process_file($) { · 2 unmodified lines
2198 $. = 1;2334 $. = 1;
2199 2335
2200 $section_counter = 0;2336 $section_counter = 0;
2201 while (<IN>) {2337 while (<IN_FILE>) {
2202 while (s/\\\s*$//) {2338 while (s/\\\s*$//) {
2203 $_ .= <IN>;2339 $_ .= <IN_FILE>;
2204 }2340 }
2205 # Replace tabs by spaces2341 # Replace tabs by spaces
2206 while ($_ =~ s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e) {};2342 while ($_ =~ s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e) {};
@@ -2232,9 +2368,14 @@ sub process_file($) { · 25 unmodified lines
2232 print STDERR "${file}:1: warning: no structured comments found\n";2368 print STDERR "${file}:1: warning: no structured comments found\n";
2233 }2369 }
2234 }2370 }
2371 close IN_FILE;
2235}2372}
2236 2373
2237 2374
2375if ($output_mode eq "rst") {
2376 get_sphinx_version() if (!$sphinx_major);
2377}
2378
2238$kernelversion = get_kernel_version();2379$kernelversion = get_kernel_version();
2239 2380
2240# generate a sequence of code that will splice in highlighting information2381# generate a sequence of code that will splice in highlighting information