Commit de34f4da authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'media/v4.9-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media

Pull media updates from Mauro Carvalho Chehab:

 - Documentation improvements: conversion of all non-DocBook documents
   to Sphinx and lots of fixes to the uAPI media book

 - New PCI driver for Techwell TW5864 media grabber boards

 - New SoC driver for ATMEL Image Sensor Controller

 - Removal of some obsolete SoC drivers (s5p-tv driver and soc_camera
   drivers)

 - Addition of ST CEC driver

 - Lots of drivers fixes, improvements and additions

* tag 'media/v4.9-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (464 commits)
  [media] ttusb_dec: avoid the risk of go past buffer
  [media] cx23885: Fix some smatch warnings
  [media] si2165: switch to regmap
  [media] si2165: use i2c_client->dev instead of i2c_adapter->dev for logging
  [media] si2165: Remove legacy attach
  [media] cx231xx: attach si2165 driver via i2c_client
  [media] cx231xx: Prepare for attaching new style i2c_client DVB demod drivers
  [media] cx23885: attach si2165 driver via i2c_client
  [media] si2165: support i2c_client attach
  [media] si2165: avoid division by zero
  [media] rcar-vin: add R-Car gen2 fallback compatibility string
  [media] lgdt3306a: remove 20*50 msec unnecessary timeout
  [media] cx25821: Remove deprecated create_singlethread_workqueue
  [media] cx25821: Drop Freeing of Workqueue
  [media] cxd2841er: force 8MHz bandwidth for DVB-C if specified bw not supported
  [media] redrat3: hardware-specific parameters
  [media] redrat3: remove hw_timeout member
  [media] cxd2841er: BER and SNR reading for ISDB-T
  [media] dvb-usb: avoid link error with dib3000m{b,c|
  [media] dvb-usb: split out common parts of dibusb
  ...
parents 56e520c7 9fce0c22
...@@ -342,6 +342,8 @@ latex_documents = [ ...@@ -342,6 +342,8 @@ latex_documents = [
'The kernel development community', 'manual'), 'The kernel development community', 'manual'),
('gpu/index', 'gpu.tex', 'Linux GPU Driver Developer\'s Guide', ('gpu/index', 'gpu.tex', 'Linux GPU Driver Developer\'s Guide',
'The kernel development community', 'manual'), 'The kernel development community', 'manual'),
('media/index', 'media.tex', 'Linux Media Subsystem Documentation',
'The kernel development community', 'manual'),
] ]
# The name of an image file (relative to this directory) to place at the top of # The name of an image file (relative to this directory) to place at the top of
......
Atmel Image Sensor Controller (ISC)
----------------------------------------------
Required properties for ISC:
- compatible
Must be "atmel,sama5d2-isc".
- reg
Physical base address and length of the registers set for the device.
- interrupts
Should contain IRQ line for the ISC.
- clocks
List of clock specifiers, corresponding to entries in
the clock-names property;
Please refer to clock-bindings.txt.
- clock-names
Required elements: "hclock", "iscck", "gck".
- #clock-cells
Should be 0.
- clock-output-names
Should be "isc-mck".
- pinctrl-names, pinctrl-0
Please refer to pinctrl-bindings.txt.
ISC supports a single port node with parallel bus. It should contain one
'port' child node with child 'endpoint' node. Please refer to the bindings
defined in Documentation/devicetree/bindings/media/video-interfaces.txt.
Example:
isc: isc@f0008000 {
compatible = "atmel,sama5d2-isc";
reg = <0xf0008000 0x4000>;
interrupts = <46 IRQ_TYPE_LEVEL_HIGH 5>;
clocks = <&isc_clk>, <&iscck>, <&isc_gclk>;
clock-names = "hclock", "iscck", "gck";
#clock-cells = <0>;
clock-output-names = "isc-mck";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_isc_base &pinctrl_isc_data_8bit &pinctrl_isc_data_9_10 &pinctrl_isc_data_11_12>;
port {
isc_0: endpoint {
remote-endpoint = <&ov7740_0>;
hsync-active = <1>;
vsync-active = <0>;
pclk-sample = <1>;
};
};
};
i2c1: i2c@fc028000 {
ov7740: camera@21 {
compatible = "ovti,ov7740";
reg = <0x21>;
clocks = <&isc>;
clock-names = "xvclk";
assigned-clocks = <&isc>;
assigned-clock-rates = <24000000>;
port {
ov7740_0: endpoint {
remote-endpoint = <&isc_0>;
};
};
};
};
...@@ -16,9 +16,10 @@ Required properties: ...@@ -16,9 +16,10 @@ Required properties:
- clocks : list of clock specifiers, corresponding to entries in - clocks : list of clock specifiers, corresponding to entries in
clock-names property; clock-names property;
- clock-names : must contain "ppmuispx", "ppmuispx", "lite0", "lite1" - clock-names : must contain "ppmuispx", "ppmuispx", "lite0", "lite1"
"mpll", "sysreg", "isp", "drc", "fd", "mcuisp", "uart", "mpll", "sysreg", "isp", "drc", "fd", "mcuisp", "gicisp",
"ispdiv0", "ispdiv1", "mcuispdiv0", "mcuispdiv1", "aclk200", "pwm_isp", "mcuctl_isp", "uart", "ispdiv0", "ispdiv1",
"div_aclk200", "aclk400mcuisp", "div_aclk400mcuisp" entries, "mcuispdiv0", "mcuispdiv1", "aclk200", "div_aclk200",
"aclk400mcuisp", "div_aclk400mcuisp" entries,
matching entries in the clocks property. matching entries in the clocks property.
pmu subnode pmu subnode
----------- -----------
......
* Analog Devices AD5820 autofocus coil
Required Properties:
- compatible: Must contain "adi,ad5820"
- reg: I2C slave address
- VANA-supply: supply of voltage for VANA pin
Example:
ad5820: coil@c {
compatible = "adi,ad5820";
reg = <0x0c>;
VANA-supply = <&vaux4>;
};
...@@ -15,6 +15,11 @@ Required Properties : ...@@ -15,6 +15,11 @@ Required Properties :
"adi,adv7282" "adi,adv7282"
"adi,adv7282-m" "adi,adv7282-m"
Optional Properties :
- powerdown-gpios: reference to the GPIO connected to the powerdown pin,
if any.
Example: Example:
i2c0@1c22000 { i2c0@1c22000 {
......
...@@ -7,12 +7,14 @@ conversion of AXI transactions in order to reduce the memory bandwidth. ...@@ -7,12 +7,14 @@ conversion of AXI transactions in order to reduce the memory bandwidth.
There are three types of FCP: FCP for Codec (FCPC), FCP for VSP (FCPV) and FCP There are three types of FCP: FCP for Codec (FCPC), FCP for VSP (FCPV) and FCP
for FDP (FCPF). Their configuration and behaviour depend on the module they for FDP (FCPF). Their configuration and behaviour depend on the module they
are paired with. These DT bindings currently support the FCPV only. are paired with. These DT bindings currently support the FCPV and FCPF.
- compatible: Must be one or more of the following - compatible: Must be one or more of the following
- "renesas,r8a7795-fcpv" for R8A7795 (R-Car H3) compatible 'FCP for VSP' - "renesas,r8a7795-fcpv" for R8A7795 (R-Car H3) compatible 'FCP for VSP'
- "renesas,r8a7795-fcpf" for R8A7795 (R-Car H3) compatible 'FCP for FDP'
- "renesas,fcpv" for generic compatible 'FCP for VSP' - "renesas,fcpv" for generic compatible 'FCP for VSP'
- "renesas,fcpf" for generic compatible 'FCP for FDP'
When compatible with the generic version, nodes must list the When compatible with the generic version, nodes must list the
SoC-specific version corresponding to the platform first, followed by the SoC-specific version corresponding to the platform first, followed by the
...@@ -21,6 +23,10 @@ are paired with. These DT bindings currently support the FCPV only. ...@@ -21,6 +23,10 @@ are paired with. These DT bindings currently support the FCPV only.
- reg: the register base and size for the device registers - reg: the register base and size for the device registers
- clocks: Reference to the functional clock - clocks: Reference to the functional clock
Optional properties:
- power-domains : power-domain property defined with a power domain specifier
to respective power domain.
Device node example Device node example
------------------- -------------------
...@@ -29,4 +35,5 @@ Device node example ...@@ -29,4 +35,5 @@ Device node example
compatible = "renesas,r8a7795-fcpv", "renesas,fcpv"; compatible = "renesas,r8a7795-fcpv", "renesas,fcpv";
reg = <0 0xfea2f000 0 0x200>; reg = <0 0xfea2f000 0 0x200>;
clocks = <&cpg CPG_MOD 602>; clocks = <&cpg CPG_MOD 602>;
power-domains = <&sysc R8A7795_PD_A3VP>;
}; };
st-hva: multi-format video encoder for STMicroelectronics SoC.
Required properties:
- compatible: should be "st,st-hva".
- reg: HVA physical address location and length, esram address location and
length.
- reg-names: names of the registers listed in registers property in the same
order.
- interrupts: HVA interrupt number.
- clocks: from common clock binding: handle hardware IP needed clocks, the
number of clocks may depend on the SoC type.
See ../clock/clock-bindings.txt for details.
- clock-names: names of the clocks listed in clocks property in the same order.
Example:
hva@8c85000{
compatible = "st,st-hva";
reg = <0x8c85000 0x400>, <0x6000000 0x40000>;
reg-names = "hva_registers", "hva_esram";
interrupts = <GIC_SPI 58 IRQ_TYPE_NONE>,
<GIC_SPI 59 IRQ_TYPE_NONE>;
clock-names = "clk_hva";
clocks = <&clk_s_c0_flexgen CLK_HVA>;
};
STMicroelectronics STIH4xx HDMI CEC driver
Required properties:
- compatible : value should be "st,stih-cec"
- reg : Physical base address of the IP registers and length of memory
mapped region.
- clocks : from common clock binding: handle to HDMI CEC clock
- interrupts : HDMI CEC interrupt number to the CPU.
- pinctrl-names: Contains only one value - "default"
- pinctrl-0: Specifies the pin control groups used for CEC hardware.
- resets: Reference to a reset controller
Example for STIH407:
sti-cec@094a087c {
compatible = "st,stih-cec";
reg = <0x94a087c 0x64>;
clocks = <&clk_sysin>;
clock-names = "cec-clk";
interrupts = <GIC_SPI 140 IRQ_TYPE_NONE>;
interrupt-names = "cec-irq";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_cec0_default>;
resets = <&softreset STIH407_LPM_SOFTRESET>;
};
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
ignore define _DVBAUDIO_H_ ignore define _DVBAUDIO_H_
# Typedef pointing to structs # Typedef pointing to structs
replace typedef audio_karaoke_t audio-karaoke replace typedef audio_karaoke_t :c:type:`audio_karaoke`
# Undocumented audio caps, as this is a deprecated API anyway # Undocumented audio caps, as this is a deprecated API anyway
ignore define AUDIO_CAP_DTS ignore define AUDIO_CAP_DTS
...@@ -16,5 +16,5 @@ ignore define AUDIO_CAP_SDDS ...@@ -16,5 +16,5 @@ ignore define AUDIO_CAP_SDDS
ignore define AUDIO_CAP_AC3 ignore define AUDIO_CAP_AC3
# some typedefs should point to struct/enums # some typedefs should point to struct/enums
replace typedef audio_mixer_t audio-mixer replace typedef audio_mixer_t :c:type:`audio_mixer`
replace typedef audio_status_t audio-status replace typedef audio_status_t :c:type:`audio_status`
...@@ -2,23 +2,23 @@ ...@@ -2,23 +2,23 @@
ignore define _DVBCA_H_ ignore define _DVBCA_H_
# struct ca_slot_info defines # struct ca_slot_info defines
replace define CA_CI ca-slot-info replace define CA_CI :c:type:`ca_slot_info`
replace define CA_CI_LINK ca-slot-info replace define CA_CI_LINK :c:type:`ca_slot_info`
replace define CA_CI_PHYS ca-slot-info replace define CA_CI_PHYS :c:type:`ca_slot_info`
replace define CA_DESCR ca-slot-info replace define CA_DESCR :c:type:`ca_slot_info`
replace define CA_SC ca-slot-info replace define CA_SC :c:type:`ca_slot_info`
replace define CA_CI_MODULE_PRESENT ca-slot-info replace define CA_CI_MODULE_PRESENT :c:type:`ca_slot_info`
replace define CA_CI_MODULE_READY ca-slot-info replace define CA_CI_MODULE_READY :c:type:`ca_slot_info`
# struct ca_descr_info defines # struct ca_descr_info defines
replace define CA_ECD ca-descr-info replace define CA_ECD :c:type:`ca_descr_info`
replace define CA_NDS ca-descr-info replace define CA_NDS :c:type:`ca_descr_info`
replace define CA_DSS ca-descr-info replace define CA_DSS :c:type:`ca_descr_info`
# some typedefs should point to struct/enums # some typedefs should point to struct/enums
replace typedef ca_pid_t ca-pid replace typedef ca_pid_t :c:type:`ca_pid`
replace typedef ca_slot_info_t ca-slot-info replace typedef ca_slot_info_t :c:type:`ca_slot_info`
replace typedef ca_descr_info_t ca-descr-info replace typedef ca_descr_info_t :c:type:`ca_descr_info`
replace typedef ca_caps_t ca-caps replace typedef ca_caps_t :c:type:`ca_caps`
replace typedef ca_msg_t ca-msg replace typedef ca_msg_t :c:type:`ca_msg`
replace typedef ca_descr_t ca-descr replace typedef ca_descr_t :c:type:`ca_descr`
# Ignore header name # Ignore header name
ignore define _CEC_UAPI_H ignore define _CEC_UAPI_H
# Rename some symbols, to avoid namespace conflicts
replace struct cec_event_state_change cec-event-state-change_s
replace struct cec_event_lost_msgs cec-event-lost-msgs_s
replace enum cec_mode_initiator cec-mode-initiator_e
replace enum cec_mode_follower cec-mode-follower_e
# define macros to ignore # define macros to ignore
ignore define CEC_MAX_MSG_SIZE ignore define CEC_MAX_MSG_SIZE
......
...@@ -21,10 +21,14 @@ nitpick_ignore = [ ...@@ -21,10 +21,14 @@ nitpick_ignore = [
("c:func", "clock_gettime"), ("c:func", "clock_gettime"),
("c:func", "close"), ("c:func", "close"),
("c:func", "container_of"), ("c:func", "container_of"),
("c:func", "copy_from_user"),
("c:func", "copy_to_user"),
("c:func", "determine_valid_ioctls"), ("c:func", "determine_valid_ioctls"),
("c:func", "ERR_PTR"), ("c:func", "ERR_PTR"),
("c:func", "i2c_new_device"),
("c:func", "ioctl"), ("c:func", "ioctl"),
("c:func", "IS_ERR"), ("c:func", "IS_ERR"),
("c:func", "KERNEL_VERSION"),
("c:func", "mmap"), ("c:func", "mmap"),
("c:func", "open"), ("c:func", "open"),
("c:func", "pci_name"), ("c:func", "pci_name"),
...@@ -36,58 +40,70 @@ nitpick_ignore = [ ...@@ -36,58 +40,70 @@ nitpick_ignore = [
("c:func", "struct fd_set"), ("c:func", "struct fd_set"),
("c:func", "struct pollfd"), ("c:func", "struct pollfd"),
("c:func", "usb_make_path"), ("c:func", "usb_make_path"),
("c:func", "wait_finish"),
("c:func", "wait_prepare"),
("c:func", "write"), ("c:func", "write"),
("c:type", "atomic_t"), ("c:type", "atomic_t"),
("c:type", "bool"), ("c:type", "bool"),
("c:type", "boolean"),
("c:type", "buf_queue"), ("c:type", "buf_queue"),
("c:type", "device"), ("c:type", "device"),
("c:type", "device_driver"), ("c:type", "device_driver"),
("c:type", "device_node"), ("c:type", "device_node"),
("c:type", "enum"), ("c:type", "enum"),
("c:type", "fd"),
("c:type", "fd_set"),
("c:type", "file"), ("c:type", "file"),
("c:type", "i2c_adapter"), ("c:type", "i2c_adapter"),
("c:type", "i2c_board_info"), ("c:type", "i2c_board_info"),
("c:type", "i2c_client"), ("c:type", "i2c_client"),
("c:type", "int16_t"),
("c:type", "ktime_t"), ("c:type", "ktime_t"),
("c:type", "led_classdev_flash"), ("c:type", "led_classdev_flash"),
("c:type", "list_head"), ("c:type", "list_head"),
("c:type", "lock_class_key"), ("c:type", "lock_class_key"),
("c:type", "module"), ("c:type", "module"),
("c:type", "mutex"), ("c:type", "mutex"),
("c:type", "NULL"),
("c:type", "off_t"),
("c:type", "pci_dev"), ("c:type", "pci_dev"),
("c:type", "pdvbdev"), ("c:type", "pdvbdev"),
("c:type", "poll_table"),
("c:type", "platform_device"),
("c:type", "pollfd"),
("c:type", "poll_table_struct"), ("c:type", "poll_table_struct"),
("c:type", "s32"), ("c:type", "s32"),
("c:type", "s64"), ("c:type", "s64"),
("c:type", "sd"), ("c:type", "sd"),
("c:type", "size_t"),
("c:type", "spi_board_info"), ("c:type", "spi_board_info"),
("c:type", "spi_device"), ("c:type", "spi_device"),
("c:type", "spi_master"), ("c:type", "spi_master"),
("c:type", "struct fb_fix_screeninfo"), ("c:type", "ssize_t"),
("c:type", "struct pollfd"), ("c:type", "fb_fix_screeninfo"),
("c:type", "struct timeval"), ("c:type", "pollfd"),
("c:type", "struct video_capability"), ("c:type", "timeval"),
("c:type", "video_capability"),
("c:type", "timeval"),
("c:type", "__u16"),
("c:type", "u16"), ("c:type", "u16"),
("c:type", "__u32"),
("c:type", "u32"), ("c:type", "u32"),
("c:type", "__u64"),
("c:type", "u64"), ("c:type", "u64"),
("c:type", "u8"), ("c:type", "u8"),
("c:type", "uint16_t"),
("c:type", "uint32_t"),
("c:type", "union"), ("c:type", "union"),
("c:type", "__user"),
("c:type", "usb_device"), ("c:type", "usb_device"),
("c:type", "usb_interface"),
("c:type", "v4l2_std_id"),
("c:type", "video_system_t"),
("c:type", "vm_area_struct"),
# Opaque structures
("cpp:type", "boolean"), ("c:type", "v4l2_m2m_dev"),
("cpp:type", "fd"),
("cpp:type", "fd_set"),
("cpp:type", "int16_t"),
("cpp:type", "NULL"),
("cpp:type", "off_t"),
("cpp:type", "pollfd"),
("cpp:type", "size_t"),
("cpp:type", "ssize_t"),
("cpp:type", "timeval"),
("cpp:type", "__u16"),
("cpp:type", "__u32"),
("cpp:type", "__u64"),
("cpp:type", "uint16_t"),
("cpp:type", "uint32_t"),
("cpp:type", "video_system_t"),
] ]
...@@ -4,29 +4,29 @@ ignore define _UAPI_DVBDMX_H_ ...@@ -4,29 +4,29 @@ ignore define _UAPI_DVBDMX_H_
# Ignore limit constants # Ignore limit constants
ignore define DMX_FILTER_SIZE ignore define DMX_FILTER_SIZE
# dmx-pes-type-t enum symbols # dmx_pes_type_t enum symbols
replace enum dmx_ts_pes dmx-pes-type-t replace enum dmx_ts_pes :c:type:`dmx_pes_type`
replace symbol DMX_PES_AUDIO0 dmx-pes-type-t replace symbol DMX_PES_AUDIO0 :c:type:`dmx_pes_type`
replace symbol DMX_PES_VIDEO0 dmx-pes-type-t replace symbol DMX_PES_VIDEO0 :c:type:`dmx_pes_type`
replace symbol DMX_PES_TELETEXT0 dmx-pes-type-t replace symbol DMX_PES_TELETEXT0 :c:type:`dmx_pes_type`
replace symbol DMX_PES_SUBTITLE0 dmx-pes-type-t replace symbol DMX_PES_SUBTITLE0 :c:type:`dmx_pes_type`
replace symbol DMX_PES_PCR0 dmx-pes-type-t replace symbol DMX_PES_PCR0 :c:type:`dmx_pes_type`
replace symbol DMX_PES_AUDIO1 dmx-pes-type-t replace symbol DMX_PES_AUDIO1 :c:type:`dmx_pes_type`
replace symbol DMX_PES_VIDEO1 dmx-pes-type-t replace symbol DMX_PES_VIDEO1 :c:type:`dmx_pes_type`
replace symbol DMX_PES_TELETEXT1 dmx-pes-type-t replace symbol DMX_PES_TELETEXT1 :c:type:`dmx_pes_type`
replace symbol DMX_PES_SUBTITLE1 dmx-pes-type-t replace symbol DMX_PES_SUBTITLE1 :c:type:`dmx_pes_type`
replace symbol DMX_PES_PCR1 dmx-pes-type-t replace symbol DMX_PES_PCR1 :c:type:`dmx_pes_type`
replace symbol DMX_PES_AUDIO2 dmx-pes-type-t replace symbol DMX_PES_AUDIO2 :c:type:`dmx_pes_type`
replace symbol DMX_PES_VIDEO2 dmx-pes-type-t replace symbol DMX_PES_VIDEO2 :c:type:`dmx_pes_type`
replace symbol DMX_PES_TELETEXT2 dmx-pes-type-t replace symbol DMX_PES_TELETEXT2 :c:type:`dmx_pes_type`
replace symbol DMX_PES_SUBTITLE2 dmx-pes-type-t replace symbol DMX_PES_SUBTITLE2 :c:type:`dmx_pes_type`
replace symbol DMX_PES_PCR2 dmx-pes-type-t replace symbol DMX_PES_PCR2 :c:type:`dmx_pes_type`
replace symbol DMX_PES_AUDIO3 dmx-pes-type-t replace symbol DMX_PES_AUDIO3 :c:type:`dmx_pes_type`
replace symbol DMX_PES_VIDEO3 dmx-pes-type-t replace symbol DMX_PES_VIDEO3 :c:type:`dmx_pes_type`
replace symbol DMX_PES_TELETEXT3 dmx-pes-type-t replace symbol DMX_PES_TELETEXT3 :c:type:`dmx_pes_type`
replace symbol DMX_PES_SUBTITLE3 dmx-pes-type-t replace symbol DMX_PES_SUBTITLE3 :c:type:`dmx_pes_type`
replace symbol DMX_PES_PCR3 dmx-pes-type-t replace symbol DMX_PES_PCR3 :c:type:`dmx_pes_type`
replace symbol DMX_PES_OTHER dmx-pes-type-t replace symbol DMX_PES_OTHER :c:type:`dmx_pes_type`
# Ignore obsolete symbols # Ignore obsolete symbols
ignore define DMX_PES_AUDIO ignore define DMX_PES_AUDIO
...@@ -36,28 +36,31 @@ ignore define DMX_PES_SUBTITLE ...@@ -36,28 +36,31 @@ ignore define DMX_PES_SUBTITLE
ignore define DMX_PES_PCR ignore define DMX_PES_PCR
# dmx_input_t symbols # dmx_input_t symbols
replace enum dmx_input dmx-input-t replace enum dmx_input :c:type:`dmx_input`
replace symbol DMX_IN_FRONTEND dmx-input-t replace symbol DMX_IN_FRONTEND :c:type:`dmx_input`
replace symbol DMX_IN_DVR dmx-input-t replace symbol DMX_IN_DVR :c:type:`dmx_input`
# dmx_source_t symbols # dmx_source_t symbols
replace enum dmx_source dmx-source-t replace enum dmx_source :c:type:`dmx_source`
replace symbol DMX_SOURCE_FRONT0 dmx-source-t replace symbol DMX_SOURCE_FRONT0 :c:type:`dmx_source`
replace symbol DMX_SOURCE_FRONT1 dmx-source-t replace symbol DMX_SOURCE_FRONT1 :c:type:`dmx_source`
replace symbol DMX_SOURCE_FRONT2 dmx-source-t replace symbol DMX_SOURCE_FRONT2 :c:type:`dmx_source`
replace symbol DMX_SOURCE_FRONT3 dmx-source-t replace symbol DMX_SOURCE_FRONT3 :c:type:`dmx_source`
replace symbol DMX_SOURCE_DVR0 dmx-source-t replace symbol DMX_SOURCE_DVR0 :c:type:`dmx_source`
replace symbol DMX_SOURCE_DVR1 dmx-source-t replace symbol DMX_SOURCE_DVR1 :c:type:`dmx_source`
replace symbol DMX_SOURCE_DVR2 dmx-source-t replace symbol DMX_SOURCE_DVR2 :c:type:`dmx_source`
replace symbol DMX_SOURCE_DVR3 dmx-source-t replace symbol DMX_SOURCE_DVR3 :c:type:`dmx_source`
# Flags for struct dmx_sct_filter_params # Flags for struct dmx_sct_filter_params
replace define DMX_CHECK_CRC dmx-sct-filter-params replace define DMX_CHECK_CRC :c:type:`dmx_sct_filter_params`
replace define DMX_ONESHOT dmx-sct-filter-params replace define DMX_ONESHOT :c:type:`dmx_sct_filter_params`
replace define DMX_IMMEDIATE_START dmx-sct-filter-params replace define DMX_IMMEDIATE_START :c:type:`dmx_sct_filter_params`
replace define DMX_KERNEL_CLIENT dmx-sct-filter-params replace define DMX_KERNEL_CLIENT :c:type:`dmx_sct_filter_params`
# some typedefs should point to struct/enums # some typedefs should point to struct/enums
replace typedef dmx_caps_t dmx-caps replace typedef dmx_caps_t :c:type:`dmx_caps`
replace typedef dmx_filter_t dmx-filter replace typedef dmx_filter_t :c:type:`dmx_filter`
replace typedef dmx_pes_type_t :c:type:`dmx_pes_type`
replace typedef dmx_input_t :c:type:`dmx_input`
replace typedef dmx_source_t :c:type:`dmx_source`
...@@ -26,22 +26,22 @@ ignore define MAX_DTV_STATS ...@@ -26,22 +26,22 @@ ignore define MAX_DTV_STATS
ignore define DTV_IOCTL_MAX_MSGS ignore define DTV_IOCTL_MAX_MSGS
# Stats enum is documented altogether # Stats enum is documented altogether
replace enum fecap_scale_params frontend-stat-properties replace enum fecap_scale_params :ref:`frontend-stat-properties`
replace symbol FE_SCALE_COUNTER frontend-stat-properties replace symbol FE_SCALE_COUNTER frontend-stat-properties
replace symbol FE_SCALE_DECIBEL frontend-stat-properties replace symbol FE_SCALE_DECIBEL frontend-stat-properties
replace symbol FE_SCALE_NOT_AVAILABLE frontend-stat-properties replace symbol FE_SCALE_NOT_AVAILABLE frontend-stat-properties
replace symbol FE_SCALE_RELATIVE frontend-stat-properties replace symbol FE_SCALE_RELATIVE frontend-stat-properties
# the same reference is used for both get and set ioctls # the same reference is used for both get and set ioctls
replace ioctl FE_SET_PROPERTY FE_GET_PROPERTY replace ioctl FE_SET_PROPERTY :c:type:`FE_GET_PROPERTY`
# Ignore struct used only internally at Kernel # Ignore struct used only internally at Kernel
ignore struct dtv_cmds_h ignore struct dtv_cmds_h
# Typedefs that use the enum reference # Typedefs that use the enum reference
replace typedef fe_sec_voltage_t fe-sec-voltage replace typedef fe_sec_voltage_t :c:type:`fe_sec_voltage`
# Replaces for flag constants # Replaces for flag constants
replace define FE_TUNE_MODE_ONESHOT fe_set_frontend_tune_mode replace define FE_TUNE_MODE_ONESHOT :c:func:`FE_SET_FRONTEND_TUNE_MODE`
replace define LNA_AUTO dtv-lna replace define LNA_AUTO dtv-lna
replace define NO_STREAM_ID_FILTER dtv-stream-id replace define NO_STREAM_ID_FILTER dtv-stream-id
Linux Media Subsystem Documentation Linux Media Subsystem Documentation
=================================== ===================================
.. Sphinx 1.4.x has a definition for DUrole that doesn't work on alltt blocks
.. raw:: latex
\renewcommand*{\DUrole}[2]{ #2 }
Contents: Contents:
.. toctree:: .. toctree::
......
...@@ -30,7 +30,7 @@ divided into five parts. ...@@ -30,7 +30,7 @@ divided into five parts.
called as DVB API, in fact it covers several different video standards called as DVB API, in fact it covers several different video standards
including DVB-T/T2, DVB-S/S2, DVB-C, ATSC, ISDB-T, ISDB-S, DTMB, etc. The including DVB-T/T2, DVB-S/S2, DVB-C, ATSC, ISDB-T, ISDB-S, DTMB, etc. The
complete list of supported standards can be found at complete list of supported standards can be found at
:ref:`fe-delivery-system-t`. :c:type:`fe_delivery_system`.
3. The :ref:`third part <remote_controllers>` covers the Remote Controller API. 3. The :ref:`third part <remote_controllers>` covers the Remote Controller API.
......
...@@ -36,39 +36,50 @@ CEC Adapter ...@@ -36,39 +36,50 @@ CEC Adapter
The struct cec_adapter represents the CEC adapter hardware. It is created by The struct cec_adapter represents the CEC adapter hardware. It is created by
calling cec_allocate_adapter() and deleted by calling cec_delete_adapter(): calling cec_allocate_adapter() and deleted by calling cec_delete_adapter():
struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops, .. c:function::
struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
void *priv, const char *name, u32 caps, u8 available_las, void *priv, const char *name, u32 caps, u8 available_las,
struct device *parent); struct device *parent);
void cec_delete_adapter(struct cec_adapter *adap);
.. c:function::
void cec_delete_adapter(struct cec_adapter *adap);
To create an adapter you need to pass the following information: To create an adapter you need to pass the following information:
ops: adapter operations which are called by the CEC framework and that you ops:
have to implement. adapter operations which are called by the CEC framework and that you
have to implement.
priv: will be stored in adap->priv and can be used by the adapter ops. priv:
will be stored in adap->priv and can be used by the adapter ops.
name: the name of the CEC adapter. Note: this name will be copied. name:
the name of the CEC adapter. Note: this name will be copied.
caps: capabilities of the CEC adapter. These capabilities determine the caps:
capabilities of the CEC adapter. These capabilities determine the
capabilities of the hardware and which parts are to be handled capabilities of the hardware and which parts are to be handled
by userspace and which parts are handled by kernelspace. The by userspace and which parts are handled by kernelspace. The
capabilities are returned by CEC_ADAP_G_CAPS. capabilities are returned by CEC_ADAP_G_CAPS.
available_las: the number of simultaneous logical addresses that this available_las:
the number of simultaneous logical addresses that this
adapter can handle. Must be 1 <= available_las <= CEC_MAX_LOG_ADDRS. adapter can handle. Must be 1 <= available_las <= CEC_MAX_LOG_ADDRS.
parent: the parent device. parent:
the parent device.
To register the /dev/cecX device node and the remote control device (if To register the /dev/cecX device node and the remote control device (if
CEC_CAP_RC is set) you call: CEC_CAP_RC is set) you call:
int cec_register_adapter(struct cec_adapter *adap); .. c:function::
int cec_register_adapter(struct cec_adapter \*adap);
To unregister the devices call: To unregister the devices call:
void cec_unregister_adapter(struct cec_adapter *adap); .. c:function::
void cec_unregister_adapter(struct cec_adapter \*adap);
Note: if cec_register_adapter() fails, then call cec_delete_adapter() to Note: if cec_register_adapter() fails, then call cec_delete_adapter() to
clean up. But if cec_register_adapter() succeeded, then only call clean up. But if cec_register_adapter() succeeded, then only call
...@@ -83,18 +94,23 @@ Implementing the Low-Level CEC Adapter ...@@ -83,18 +94,23 @@ Implementing the Low-Level CEC Adapter
The following low-level adapter operations have to be implemented in The following low-level adapter operations have to be implemented in
your driver: your driver:
struct cec_adap_ops { .. c:type:: struct cec_adap_ops
/* Low-level callbacks */
int (*adap_enable)(struct cec_adapter *adap, bool enable); .. code-block:: none
int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr); struct cec_adap_ops
int (*adap_transmit)(struct cec_adapter *adap, u8 attempts, {
u32 signal_free_time, struct cec_msg *msg); /* Low-level callbacks */
void (*adap_log_status)(struct cec_adapter *adap); int (*adap_enable)(struct cec_adapter *adap, bool enable);
int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
u32 signal_free_time, struct cec_msg *msg);
void (\*adap_log_status)(struct cec_adapter *adap);
/* High-level callbacks */ /* High-level callbacks */
... ...
}; };
The three low-level ops deal with various aspects of controlling the CEC adapter The three low-level ops deal with various aspects of controlling the CEC adapter
hardware: hardware:
...@@ -102,6 +118,7 @@ hardware: ...@@ -102,6 +118,7 @@ hardware:
To enable/disable the hardware: To enable/disable the hardware:
.. c:function::
int (*adap_enable)(struct cec_adapter *adap, bool enable); int (*adap_enable)(struct cec_adapter *adap, bool enable);
This callback enables or disables the CEC hardware. Enabling the CEC hardware This callback enables or disables the CEC hardware. Enabling the CEC hardware
...@@ -115,6 +132,7 @@ Note that adap_enable must return 0 if enable is false. ...@@ -115,6 +132,7 @@ Note that adap_enable must return 0 if enable is false.
To enable/disable the 'monitor all' mode: To enable/disable the 'monitor all' mode:
.. c:function::
int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable); int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
If enabled, then the adapter should be put in a mode to also monitor messages If enabled, then the adapter should be put in a mode to also monitor messages
...@@ -127,6 +145,7 @@ Note that adap_monitor_all_enable must return 0 if enable is false. ...@@ -127,6 +145,7 @@ Note that adap_monitor_all_enable must return 0 if enable is false.
To program a new logical address: To program a new logical address:
.. c:function::
int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr); int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
If logical_addr == CEC_LOG_ADDR_INVALID then all programmed logical addresses If logical_addr == CEC_LOG_ADDR_INVALID then all programmed logical addresses
...@@ -140,6 +159,7 @@ Note that adap_log_addr must return 0 if logical_addr is CEC_LOG_ADDR_INVALID. ...@@ -140,6 +159,7 @@ Note that adap_log_addr must return 0 if logical_addr is CEC_LOG_ADDR_INVALID.
To transmit a new message: To transmit a new message:
.. c:function::
int (*adap_transmit)(struct cec_adapter *adap, u8 attempts, int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
u32 signal_free_time, struct cec_msg *msg); u32 signal_free_time, struct cec_msg *msg);
...@@ -158,6 +178,7 @@ microseconds (one data bit period is 2.4 ms). ...@@ -158,6 +178,7 @@ microseconds (one data bit period is 2.4 ms).
To log the current CEC hardware status: To log the current CEC hardware status:
.. c:function::
void (*adap_status)(struct cec_adapter *adap, struct seq_file *file); void (*adap_status)(struct cec_adapter *adap, struct seq_file *file);
This optional callback can be used to show the status of the CEC hardware. This optional callback can be used to show the status of the CEC hardware.
...@@ -169,29 +190,41 @@ driven) by calling into the framework in the following situations: ...@@ -169,29 +190,41 @@ driven) by calling into the framework in the following situations:
When a transmit finished (successfully or otherwise): When a transmit finished (successfully or otherwise):
void cec_transmit_done(struct cec_adapter *adap, u8 status, u8 arb_lost_cnt, .. c:function::
void cec_transmit_done(struct cec_adapter *adap, u8 status, u8 arb_lost_cnt,
u8 nack_cnt, u8 low_drive_cnt, u8 error_cnt); u8 nack_cnt, u8 low_drive_cnt, u8 error_cnt);
The status can be one of: The status can be one of:
CEC_TX_STATUS_OK: the transmit was successful. CEC_TX_STATUS_OK:
CEC_TX_STATUS_ARB_LOST: arbitration was lost: another CEC initiator the transmit was successful.
took control of the CEC line and you lost the arbitration.
CEC_TX_STATUS_NACK: the message was nacked (for a directed message) or CEC_TX_STATUS_ARB_LOST:
acked (for a broadcast message). A retransmission is needed. arbitration was lost: another CEC initiator
CEC_TX_STATUS_LOW_DRIVE: low drive was detected on the CEC bus. This took control of the CEC line and you lost the arbitration.
indicates that a follower detected an error on the bus and requested a
retransmission. CEC_TX_STATUS_NACK:
CEC_TX_STATUS_ERROR: some unspecified error occurred: this can be one of the message was nacked (for a directed message) or
the previous two if the hardware cannot differentiate or something else acked (for a broadcast message). A retransmission is needed.
entirely.
CEC_TX_STATUS_MAX_RETRIES: could not transmit the message after CEC_TX_STATUS_LOW_DRIVE:
trying multiple times. Should only be set by the driver if it has hardware low drive was detected on the CEC bus. This indicates that
support for retrying messages. If set, then the framework assumes that it a follower detected an error on the bus and requested a
doesn't have to make another attempt to transmit the message since the retransmission.
hardware did that already.
CEC_TX_STATUS_ERROR:
The *_cnt arguments are the number of error conditions that were seen. some unspecified error occurred: this can be one of
the previous two if the hardware cannot differentiate or something
else entirely.
CEC_TX_STATUS_MAX_RETRIES:
could not transmit the message after trying multiple times.
Should only be set by the driver if it has hardware support for
retrying messages. If set, then the framework assumes that it
doesn't have to make another attempt to transmit the message
since the hardware did that already.
The \*_cnt arguments are the number of error conditions that were seen.
This may be 0 if no information is available. Drivers that do not support This may be 0 if no information is available. Drivers that do not support
hardware retry can just set the counter corresponding to the transmit error hardware retry can just set the counter corresponding to the transmit error
to 1, if the hardware does support retry then either set these counters to to 1, if the hardware does support retry then either set these counters to
...@@ -200,7 +233,8 @@ times, or fill in the correct values as reported by the hardware. ...@@ -200,7 +233,8 @@ times, or fill in the correct values as reported by the hardware.
When a CEC message was received: When a CEC message was received:
void cec_received_msg(struct cec_adapter *adap, struct cec_msg *msg); .. c:function::
void cec_received_msg(struct cec_adapter *adap, struct cec_msg *msg);
Speaks for itself. Speaks for itself.
...@@ -210,17 +244,20 @@ Implementing the High-Level CEC Adapter ...@@ -210,17 +244,20 @@ Implementing the High-Level CEC Adapter
The low-level operations drive the hardware, the high-level operations are The low-level operations drive the hardware, the high-level operations are
CEC protocol driven. The following high-level callbacks are available: CEC protocol driven. The following high-level callbacks are available:
struct cec_adap_ops { .. code-block:: none
/* Low-level callbacks */
...
/* High-level CEC message callback */ struct cec_adap_ops {
int (*received)(struct cec_adapter *adap, struct cec_msg *msg); /\* Low-level callbacks \*/
}; ...
/\* High-level CEC message callback \*/
int (\*received)(struct cec_adapter \*adap, struct cec_msg \*msg);
};
The received() callback allows the driver to optionally handle a newly The received() callback allows the driver to optionally handle a newly
received CEC message received CEC message
.. c:function::
int (*received)(struct cec_adapter *adap, struct cec_msg *msg); int (*received)(struct cec_adapter *adap, struct cec_msg *msg);
If the driver wants to process a CEC message, then it can implement this If the driver wants to process a CEC message, then it can implement this
...@@ -234,13 +271,16 @@ CEC framework functions ...@@ -234,13 +271,16 @@ CEC framework functions
CEC Adapter drivers can call the following CEC framework functions: CEC Adapter drivers can call the following CEC framework functions:
int cec_transmit_msg(struct cec_adapter *adap, struct cec_msg *msg, .. c:function::
bool block); int cec_transmit_msg(struct cec_adapter *adap, struct cec_msg *msg,
bool block);
Transmit a CEC message. If block is true, then wait until the message has been Transmit a CEC message. If block is true, then wait until the message has been
transmitted, otherwise just queue it and return. transmitted, otherwise just queue it and return.
void cec_s_phys_addr(struct cec_adapter *adap, u16 phys_addr, bool block); .. c:function::
void cec_s_phys_addr(struct cec_adapter *adap, u16 phys_addr,
bool block);
Change the physical address. This function will set adap->phys_addr and Change the physical address. This function will set adap->phys_addr and
send an event if it has changed. If cec_s_log_addrs() has been called and send an event if it has changed. If cec_s_log_addrs() has been called and
...@@ -254,8 +294,9 @@ then the CEC adapter will be disabled. If you change a valid physical address ...@@ -254,8 +294,9 @@ then the CEC adapter will be disabled. If you change a valid physical address
to another valid physical address, then this function will first set the to another valid physical address, then this function will first set the
address to CEC_PHYS_ADDR_INVALID before enabling the new physical address. address to CEC_PHYS_ADDR_INVALID before enabling the new physical address.
int cec_s_log_addrs(struct cec_adapter *adap, .. c:function::
struct cec_log_addrs *log_addrs, bool block); int cec_s_log_addrs(struct cec_adapter *adap,
struct cec_log_addrs *log_addrs, bool block);
Claim the CEC logical addresses. Should never be called if CEC_CAP_LOG_ADDRS Claim the CEC logical addresses. Should never be called if CEC_CAP_LOG_ADDRS
is set. If block is true, then wait until the logical addresses have been is set. If block is true, then wait until the logical addresses have been
......
...@@ -6,8 +6,6 @@ Digital TV Common functions ...@@ -6,8 +6,6 @@ Digital TV Common functions
.. kernel-doc:: drivers/media/dvb-core/dvb_math.h .. kernel-doc:: drivers/media/dvb-core/dvb_math.h
.. kernel-doc:: drivers/media/dvb-core/dvb_ringbuffer.h
.. kernel-doc:: drivers/media/dvb-core/dvbdev.h .. kernel-doc:: drivers/media/dvb-core/dvbdev.h
...@@ -18,6 +16,42 @@ Digital TV Common functions ...@@ -18,6 +16,42 @@ Digital TV Common functions
.. kernel-doc:: drivers/media/dvb-core/dvbdev.h .. kernel-doc:: drivers/media/dvb-core/dvbdev.h
:export: drivers/media/dvb-core/dvbdev.c :export: drivers/media/dvb-core/dvbdev.c
Digital TV Ring buffer
----------------------
Those routines implement ring buffers used to handle digital TV data and
copy it from/to userspace.
.. note::
1) For performance reasons read and write routines don't check buffer sizes
and/or number of bytes free/available. This has to be done before these
routines are called. For example:
.. code-block:: c
/* write @buflen: bytes */
free = dvb_ringbuffer_free(rbuf);
if (free >= buflen)
count = dvb_ringbuffer_write(rbuf, buffer, buflen);
else
/* do something */
/* read min. 1000, max. @bufsize: bytes */
avail = dvb_ringbuffer_avail(rbuf);
if (avail >= 1000)
count = dvb_ringbuffer_read(rbuf, buffer, min(avail, bufsize));
else
/* do something */
2) If there is exactly one reader and one writer, there is no need
to lock read or write operations.
Two or more readers must be locked against each other.
Flushing the buffer counts as a read operation.
Resetting the buffer counts as a read and write operation.
Two or more writers must be locked against each other.
.. kernel-doc:: drivers/media/dvb-core/dvb_ringbuffer.h
Digital TV Frontend kABI Digital TV Frontend kABI
...@@ -121,7 +155,7 @@ triggered by a hardware interrupt, it is recommended to use the Linux ...@@ -121,7 +155,7 @@ triggered by a hardware interrupt, it is recommended to use the Linux
bottom half mechanism or start a tasklet instead of making the callback bottom half mechanism or start a tasklet instead of making the callback
function call directly from a hardware interrupt. function call directly from a hardware interrupt.
This mechanism is implemented by :c:func:`dmx_ts_cb()` and :cpp:func:`dmx_section_cb()` This mechanism is implemented by :c:func:`dmx_ts_cb()` and :c:func:`dmx_section_cb()`
callbacks. callbacks.
.. kernel-doc:: drivers/media/dvb-core/demux.h .. kernel-doc:: drivers/media/dvb-core/demux.h
......
...@@ -34,7 +34,7 @@ pad to a sink pad. ...@@ -34,7 +34,7 @@ pad to a sink pad.
Media device Media device
^^^^^^^^^^^^ ^^^^^^^^^^^^
A media device is represented by a :c:type:`struct media_device <media_device>` A media device is represented by a struct :c:type:`media_device`
instance, defined in ``include/media/media-device.h``. instance, defined in ``include/media/media-device.h``.
Allocation of the structure is handled by the media device driver, usually by Allocation of the structure is handled by the media device driver, usually by
embedding the :c:type:`media_device` instance in a larger driver-specific embedding the :c:type:`media_device` instance in a larger driver-specific
...@@ -47,7 +47,7 @@ and unregistered by calling :c:func:`media_device_unregister()`. ...@@ -47,7 +47,7 @@ and unregistered by calling :c:func:`media_device_unregister()`.
Entities Entities
^^^^^^^^ ^^^^^^^^
Entities are represented by a :c:type:`struct media_entity <media_entity>` Entities are represented by a struct :c:type:`media_entity`
instance, defined in ``include/media/media-entity.h``. The structure is usually instance, defined in ``include/media/media-entity.h``. The structure is usually
embedded into a higher-level structure, such as embedded into a higher-level structure, such as
:c:type:`v4l2_subdev` or :c:type:`video_device` :c:type:`v4l2_subdev` or :c:type:`video_device`
...@@ -65,10 +65,10 @@ Interfaces ...@@ -65,10 +65,10 @@ Interfaces
^^^^^^^^^^ ^^^^^^^^^^
Interfaces are represented by a Interfaces are represented by a
:c:type:`struct media_interface <media_interface>` instance, defined in struct :c:type:`media_interface` instance, defined in
``include/media/media-entity.h``. Currently, only one type of interface is ``include/media/media-entity.h``. Currently, only one type of interface is
defined: a device node. Such interfaces are represented by a defined: a device node. Such interfaces are represented by a
:c:type:`struct media_intf_devnode <media_intf_devnode>`. struct :c:type:`media_intf_devnode`.
Drivers initialize and create device node interfaces by calling Drivers initialize and create device node interfaces by calling
:c:func:`media_devnode_create()` :c:func:`media_devnode_create()`
...@@ -77,7 +77,7 @@ and remove them by calling: ...@@ -77,7 +77,7 @@ and remove them by calling:
Pads Pads
^^^^ ^^^^
Pads are represented by a :c:type:`struct media_pad <media_pad>` instance, Pads are represented by a struct :c:type:`media_pad` instance,
defined in ``include/media/media-entity.h``. Each entity stores its pads in defined in ``include/media/media-entity.h``. Each entity stores its pads in
a pads array managed by the entity driver. Drivers usually embed the array in a pads array managed by the entity driver. Drivers usually embed the array in
a driver-specific structure. a driver-specific structure.
...@@ -85,8 +85,9 @@ a driver-specific structure. ...@@ -85,8 +85,9 @@ a driver-specific structure.
Pads are identified by their entity and their 0-based index in the pads Pads are identified by their entity and their 0-based index in the pads
array. array.
Both information are stored in the :c:type:`struct media_pad`, making the Both information are stored in the struct :c:type:`media_pad`,
:c:type:`media_pad` pointer the canonical way to store and pass link references. making the struct :c:type:`media_pad` pointer the canonical way
to store and pass link references.
Pads have flags that describe the pad capabilities and state. Pads have flags that describe the pad capabilities and state.
...@@ -101,7 +102,7 @@ Pads have flags that describe the pad capabilities and state. ...@@ -101,7 +102,7 @@ Pads have flags that describe the pad capabilities and state.
Links Links
^^^^^ ^^^^^
Links are represented by a :c:type:`struct media_link <media_link>` instance, Links are represented by a struct :c:type:`media_link` instance,
defined in ``include/media/media-entity.h``. There are two types of links: defined in ``include/media/media-entity.h``. There are two types of links:
**1. pad to pad links**: **1. pad to pad links**:
...@@ -184,7 +185,7 @@ Use count and power handling ...@@ -184,7 +185,7 @@ Use count and power handling
Due to the wide differences between drivers regarding power management Due to the wide differences between drivers regarding power management
needs, the media controller does not implement power management. However, needs, the media controller does not implement power management. However,
the :c:type:`struct media_entity <media_entity>` includes a ``use_count`` the struct :c:type:`media_entity` includes a ``use_count``
field that media drivers field that media drivers
can use to track the number of users of every entity for power management can use to track the number of users of every entity for power management
needs. needs.
...@@ -210,11 +211,11 @@ prevent link states from being modified during streaming by calling ...@@ -210,11 +211,11 @@ prevent link states from being modified during streaming by calling
The function will mark all entities connected to the given entity through The function will mark all entities connected to the given entity through
enabled links, either directly or indirectly, as streaming. enabled links, either directly or indirectly, as streaming.
The :c:type:`struct media_pipeline <media_pipeline>` instance pointed to by The struct :c:type:`media_pipeline` instance pointed to by
the pipe argument will be stored in every entity in the pipeline. the pipe argument will be stored in every entity in the pipeline.
Drivers should embed the :c:type:`struct media_pipeline <media_pipeline>` Drivers should embed the struct :c:type:`media_pipeline`
in higher-level pipeline structures and can then access the in higher-level pipeline structures and can then access the
pipeline through the :c:type:`struct media_entity <media_entity>` pipeline through the struct :c:type:`media_entity`
pipe field. pipe field.
Calls to :c:func:`media_entity_pipeline_start()` can be nested. Calls to :c:func:`media_entity_pipeline_start()` can be nested.
......
...@@ -56,7 +56,7 @@ You should also set these fields of :c:type:`video_device`: ...@@ -56,7 +56,7 @@ You should also set these fields of :c:type:`video_device`:
:c:type:`video_device`->vfl_dir fields are used to disable ops that do not :c:type:`video_device`->vfl_dir fields are used to disable ops that do not
match the type/dir combination. E.g. VBI ops are disabled for non-VBI nodes, match the type/dir combination. E.g. VBI ops are disabled for non-VBI nodes,
and output ops are disabled for a capture device. This makes it possible to and output ops are disabled for a capture device. This makes it possible to
provide just one :c:type:`v4l2_ioctl_ops struct` for both vbi and provide just one :c:type:`v4l2_ioctl_ops` struct for both vbi and
video nodes. video nodes.
- :c:type:`video_device`->lock: leave to ``NULL`` if you want to do all the - :c:type:`video_device`->lock: leave to ``NULL`` if you want to do all the
...@@ -166,14 +166,14 @@ something. ...@@ -166,14 +166,14 @@ something.
In the case of :ref:`videobuf2 <vb2_framework>` you will need to implement the In the case of :ref:`videobuf2 <vb2_framework>` you will need to implement the
``wait_prepare()`` and ``wait_finish()`` callbacks to unlock/lock if applicable. ``wait_prepare()`` and ``wait_finish()`` callbacks to unlock/lock if applicable.
If you use the ``queue->lock`` pointer, then you can use the helper functions If you use the ``queue->lock`` pointer, then you can use the helper functions
:c:func:`vb2_ops_wait_prepare` and :cpp:func:`vb2_ops_wait_finish`. :c:func:`vb2_ops_wait_prepare` and :c:func:`vb2_ops_wait_finish`.
The implementation of a hotplug disconnect should also take the lock from The implementation of a hotplug disconnect should also take the lock from
:c:type:`video_device` before calling v4l2_device_disconnect. If you are also :c:type:`video_device` before calling v4l2_device_disconnect. If you are also
using :c:type:`video_device`->queue->lock, then you have to first lock using :c:type:`video_device`->queue->lock, then you have to first lock
:c:type:`video_device`->queue->lock followed by :c:type:`video_device`->lock. :c:type:`video_device`->queue->lock followed by :c:type:`video_device`->lock.
That way you can be sure no ioctl is running when you call That way you can be sure no ioctl is running when you call
:c:type:`v4l2_device_disconnect`. :c:func:`v4l2_device_disconnect`.
Video device registration Video device registration
------------------------- -------------------------
...@@ -200,6 +200,7 @@ types exist: ...@@ -200,6 +200,7 @@ types exist:
- ``VFL_TYPE_VBI``: ``/dev/vbiX`` for vertical blank data (i.e. closed captions, teletext) - ``VFL_TYPE_VBI``: ``/dev/vbiX`` for vertical blank data (i.e. closed captions, teletext)
- ``VFL_TYPE_RADIO``: ``/dev/radioX`` for radio tuners - ``VFL_TYPE_RADIO``: ``/dev/radioX`` for radio tuners
- ``VFL_TYPE_SDR``: ``/dev/swradioX`` for Software Defined Radio tuners - ``VFL_TYPE_SDR``: ``/dev/swradioX`` for Software Defined Radio tuners
- ``VFL_TYPE_TOUCH``: ``/dev/v4l-touchX`` for touch sensors
The last argument gives you a certain amount of control over the device The last argument gives you a certain amount of control over the device
device node number used (i.e. the X in ``videoX``). Normally you will pass -1 device node number used (i.e. the X in ``videoX``). Normally you will pass -1
...@@ -262,6 +263,7 @@ file operations. ...@@ -262,6 +263,7 @@ file operations.
It is a bitmask and the following bits can be set: It is a bitmask and the following bits can be set:
.. tabularcolumns:: |p{5ex}|L|
===== ================================================================ ===== ================================================================
Mask Description Mask Description
...@@ -334,7 +336,7 @@ And this function: ...@@ -334,7 +336,7 @@ And this function:
returns the video_device belonging to the file struct. returns the video_device belonging to the file struct.
The :c:func:`video_devdata` function combines :cpp:func:`video_get_drvdata` The :c:func:`video_devdata` function combines :c:func:`video_get_drvdata`
with :c:func:`video_devdata`: with :c:func:`video_devdata`:
:c:func:`video_drvdata <video_drvdata>` :c:func:`video_drvdata <video_drvdata>`
......
...@@ -40,7 +40,7 @@ A good example of these ``replace``/``merge`` callbacks is in v4l2-event.c: ...@@ -40,7 +40,7 @@ A good example of these ``replace``/``merge`` callbacks is in v4l2-event.c:
In order to queue events to video device, drivers should call: In order to queue events to video device, drivers should call:
:c:func:`v4l2_event_queue <v4l2_event_queue>` :c:func:`v4l2_event_queue <v4l2_event_queue>`
(:c:type:`vdev <video_device>`, :ref:`ev <v4l2-event>`) (:c:type:`vdev <video_device>`, :c:type:`ev <v4l2_event>`)
The driver's only responsibility is to fill in the type and the data fields. The driver's only responsibility is to fill in the type and the data fields.
The other fields will be filled in by V4L2. The other fields will be filled in by V4L2.
...@@ -51,7 +51,7 @@ Event subscription ...@@ -51,7 +51,7 @@ Event subscription
Subscribing to an event is via: Subscribing to an event is via:
:c:func:`v4l2_event_subscribe <v4l2_event_subscribe>` :c:func:`v4l2_event_subscribe <v4l2_event_subscribe>`
(:c:type:`fh <v4l2_fh>`, :ref:`sub <v4l2-event-subscription>` , (:c:type:`fh <v4l2_fh>`, :c:type:`sub <v4l2_event_subscription>` ,
elems, :c:type:`ops <v4l2_subscribed_event_ops>`) elems, :c:type:`ops <v4l2_subscribed_event_ops>`)
...@@ -86,7 +86,7 @@ Unsubscribing an event ...@@ -86,7 +86,7 @@ Unsubscribing an event
Unsubscribing to an event is via: Unsubscribing to an event is via:
:c:func:`v4l2_event_unsubscribe <v4l2_event_unsubscribe>` :c:func:`v4l2_event_unsubscribe <v4l2_event_unsubscribe>`
(:c:type:`fh <v4l2_fh>`, :ref:`sub <v4l2-event-subscription>`) (:c:type:`fh <v4l2_fh>`, :c:type:`sub <v4l2_event_subscription>`)
This function is used to implement :c:type:`video_device`-> This function is used to implement :c:type:`video_device`->
:c:type:`ioctl_ops <v4l2_ioctl_ops>`-> ``vidioc_unsubscribe_event``. :c:type:`ioctl_ops <v4l2_ioctl_ops>`-> ``vidioc_unsubscribe_event``.
......
...@@ -21,8 +21,8 @@ function by the driver. ...@@ -21,8 +21,8 @@ function by the driver.
In many cases the struct :c:type:`v4l2_fh` will be embedded in a larger In many cases the struct :c:type:`v4l2_fh` will be embedded in a larger
structure. In that case you should call: structure. In that case you should call:
#) :c:func:`v4l2_fh_init` and :cpp:func:`v4l2_fh_add` in ``open()`` #) :c:func:`v4l2_fh_init` and :c:func:`v4l2_fh_add` in ``open()``
#) :c:func:`v4l2_fh_del` and :cpp:func:`v4l2_fh_exit` in ``release()`` #) :c:func:`v4l2_fh_del` and :c:func:`v4l2_fh_exit` in ``release()``
Drivers can extract their own file handle structure by using the container_of Drivers can extract their own file handle structure by using the container_of
macro. macro.
......
...@@ -27,7 +27,7 @@ methods. ...@@ -27,7 +27,7 @@ methods.
Bridges might also need to store per-subdev private data, such as a pointer to Bridges might also need to store per-subdev private data, such as a pointer to
bridge-specific per-subdev private data. The :c:type:`v4l2_subdev` structure bridge-specific per-subdev private data. The :c:type:`v4l2_subdev` structure
provides host private data for that purpose that can be accessed with provides host private data for that purpose that can be accessed with
:c:func:`v4l2_get_subdev_hostdata` and :cpp:func:`v4l2_set_subdev_hostdata`. :c:func:`v4l2_get_subdev_hostdata` and :c:func:`v4l2_set_subdev_hostdata`.
From the bridge driver perspective, you load the sub-device module and somehow From the bridge driver perspective, you load the sub-device module and somehow
obtain the :c:type:`v4l2_subdev` pointer. For i2c devices this is easy: you call obtain the :c:type:`v4l2_subdev` pointer. For i2c devices this is easy: you call
...@@ -412,19 +412,7 @@ later date. It differs between i2c drivers and as such can be confusing. ...@@ -412,19 +412,7 @@ later date. It differs between i2c drivers and as such can be confusing.
To see which chip variants are supported you can look in the i2c driver code To see which chip variants are supported you can look in the i2c driver code
for the i2c_device_id table. This lists all the possibilities. for the i2c_device_id table. This lists all the possibilities.
There are two more helper functions: There are one more helper function:
:c:func:`v4l2_i2c_new_subdev_cfg`: this function adds new irq and
platform_data arguments and has both 'addr' and 'probed_addrs' arguments:
if addr is not 0 then that will be used (non-probing variant), otherwise the
probed_addrs are probed.
For example: this will probe for address 0x10:
.. code-block:: c
struct v4l2_subdev *sd = v4l2_i2c_new_subdev_cfg(v4l2_dev, adapter,
"module_foo", "chipid", 0, NULL, 0, I2C_ADDRS(0x10));
:c:func:`v4l2_i2c_new_subdev_board` uses an :c:type:`i2c_board_info` struct :c:func:`v4l2_i2c_new_subdev_board` uses an :c:type:`i2c_board_info` struct
which is passed to the i2c driver and replaces the irq, platform_data and addr which is passed to the i2c driver and replaces the irq, platform_data and addr
...@@ -433,9 +421,10 @@ arguments. ...@@ -433,9 +421,10 @@ arguments.
If the subdev supports the s_config core ops, then that op is called with If the subdev supports the s_config core ops, then that op is called with
the irq and platform_data arguments after the subdev was setup. the irq and platform_data arguments after the subdev was setup.
The older :c:func:`v4l2_i2c_new_subdev` and The :c:func:`v4l2_i2c_new_subdev` function will call
:c:func:`v4l2_i2c_new_probed_subdev` functions will call ``s_config`` as :c:func:`v4l2_i2c_new_subdev_board`, internally filling a
well, but with irq set to 0 and platform_data set to ``NULL``. :c:type:`i2c_board_info` structure using the ``client_type`` and the
``addr`` to fill it.
V4L2 sub-device functions and data structures V4L2 sub-device functions and data structures
--------------------------------------------- ---------------------------------------------
......
...@@ -32,3 +32,4 @@ For more details see the file COPYING in the source distribution of Linux. ...@@ -32,3 +32,4 @@ For more details see the file COPYING in the source distribution of Linux.
kapi/dtv-core kapi/dtv-core
kapi/rc-core kapi/rc-core
kapi/mc-core kapi/mc-core
kapi/cec-core
...@@ -7,5 +7,5 @@ ignore ioctl __NET_GET_IF_OLD ...@@ -7,5 +7,5 @@ ignore ioctl __NET_GET_IF_OLD
ignore struct __dvb_net_if_old ignore struct __dvb_net_if_old
# Macros used at struct dvb_net_if # Macros used at struct dvb_net_if
replace define DVB_NET_FEEDTYPE_MPE dvb-net-if replace define DVB_NET_FEEDTYPE_MPE :c:type:`dvb_net_if`
replace define DVB_NET_FEEDTYPE_ULE dvb-net-if replace define DVB_NET_FEEDTYPE_ULE :c:type:`dvb_net_if`
...@@ -20,19 +20,22 @@ Synopsis ...@@ -20,19 +20,22 @@ Synopsis
#include <unistd.h> #include <unistd.h>
.. cpp:function:: int close( int fd ) .. c:function:: int close( int fd )
:name: cec-close
Arguments Arguments
========= =========
``fd`` ``fd``
File descriptor returned by :ref:`open() <func-open>`. File descriptor returned by :c:func:`open() <cec-open>`.
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
Closes the cec device. Resources associated with the file descriptor are Closes the cec device. Resources associated with the file descriptor are
......
...@@ -19,17 +19,18 @@ Synopsis ...@@ -19,17 +19,18 @@ Synopsis
#include <sys/ioctl.h> #include <sys/ioctl.h>
.. cpp:function:: int ioctl( int fd, int request, void *argp ) .. c:function:: int ioctl( int fd, int request, void *argp )
:name: cec-ioctl
Arguments Arguments
========= =========
``fd`` ``fd``
File descriptor returned by :ref:`open() <func-open>`. File descriptor returned by :c:func:`open() <cec-open>`.
``request`` ``request``
CEC ioctl request code as defined in the cec.h header file, for CEC ioctl request code as defined in the cec.h header file, for
example :ref:`CEC_ADAP_G_CAPS`. example :c:func:`CEC_ADAP_G_CAPS`.
``argp`` ``argp``
Pointer to a request-specific structure. Pointer to a request-specific structure.
...@@ -38,7 +39,9 @@ Arguments ...@@ -38,7 +39,9 @@ Arguments
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
The :c:func:`ioctl()` function manipulates cec device parameters. The The :c:func:`ioctl()` function manipulates cec device parameters. The
......
...@@ -19,7 +19,8 @@ Synopsis ...@@ -19,7 +19,8 @@ Synopsis
#include <fcntl.h> #include <fcntl.h>
.. cpp:function:: int open( const char *device_name, int flags ) .. c:function:: int open( const char *device_name, int flags )
:name: cec-open
Arguments Arguments
...@@ -45,7 +46,9 @@ Arguments ...@@ -45,7 +46,9 @@ Arguments
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
To open a cec device applications call :c:func:`open()` with the To open a cec device applications call :c:func:`open()` with the
......
...@@ -20,16 +20,28 @@ Synopsis ...@@ -20,16 +20,28 @@ Synopsis
#include <sys/poll.h> #include <sys/poll.h>
.. cpp:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout ) .. c:function:: int poll( struct pollfd *ufds, unsigned int nfds, int timeout )
:name: cec-poll
Arguments Arguments
========= =========
``ufds``
List of FD events to be watched
``nfds``
Number of FD efents at the \*ufds array
``timeout``
Timeout to wait for events
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
With the :c:func:`poll()` function applications can wait for CEC With the :c:func:`poll()` function applications can wait for CEC
...@@ -37,7 +49,7 @@ events. ...@@ -37,7 +49,7 @@ events.
On success :c:func:`poll()` returns the number of file descriptors On success :c:func:`poll()` returns the number of file descriptors
that have been selected (that is, file descriptors for which the that have been selected (that is, file descriptors for which the
``revents`` field of the respective :c:type:`struct pollfd` structure ``revents`` field of the respective struct :c:type:`pollfd`
is non-zero). CEC devices set the ``POLLIN`` and ``POLLRDNORM`` flags in is non-zero). CEC devices set the ``POLLIN`` and ``POLLRDNORM`` flags in
the ``revents`` field if there are messages in the receive queue. If the the ``revents`` field if there are messages in the receive queue. If the
transmit queue has room for new messages, the ``POLLOUT`` and transmit queue has room for new messages, the ``POLLOUT`` and
......
...@@ -3,7 +3,9 @@ ...@@ -3,7 +3,9 @@
Introduction Introduction
============ ============
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
HDMI connectors provide a single pin for use by the Consumer Electronics HDMI connectors provide a single pin for use by the Consumer Electronics
......
...@@ -14,7 +14,8 @@ CEC_ADAP_G_CAPS - Query device capabilities ...@@ -14,7 +14,8 @@ CEC_ADAP_G_CAPS - Query device capabilities
Synopsis Synopsis
======== ========
.. cpp:function:: int ioctl( int fd, int request, struct cec_caps *argp ) .. c:function:: int ioctl( int fd, CEC_ADAP_G_CAPS, struct cec_caps *argp )
:name: CEC_ADAP_G_CAPS
Arguments Arguments
========= =========
...@@ -22,25 +23,25 @@ Arguments ...@@ -22,25 +23,25 @@ Arguments
``fd`` ``fd``
File descriptor returned by :ref:`open() <cec-func-open>`. File descriptor returned by :ref:`open() <cec-func-open>`.
``request``
CEC_ADAP_G_CAPS
``argp`` ``argp``
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
All cec devices must support :ref:`ioctl CEC_ADAP_G_CAPS <CEC_ADAP_G_CAPS>`. To query All cec devices must support :ref:`ioctl CEC_ADAP_G_CAPS <CEC_ADAP_G_CAPS>`. To query
device information, applications call the ioctl with a pointer to a device information, applications call the ioctl with a pointer to a
struct :ref:`cec_caps <cec-caps>`. The driver fills the structure and struct :c:type:`cec_caps`. The driver fills the structure and
returns the information to the application. The ioctl never fails. returns the information to the application. The ioctl never fails.
.. tabularcolumns:: |p{1.2cm}|p{2.5cm}|p{13.8cm}|
.. _cec-caps: .. c:type:: cec_caps
.. flat-table:: struct cec_caps .. flat-table:: struct cec_caps
:header-rows: 0 :header-rows: 0
...@@ -84,6 +85,7 @@ returns the information to the application. The ioctl never fails. ...@@ -84,6 +85,7 @@ returns the information to the application. The ioctl never fails.
macro. macro.
.. tabularcolumns:: |p{4.4cm}|p{2.5cm}|p{10.6cm}|
.. _cec-capabilities: .. _cec-capabilities:
......
...@@ -17,33 +17,35 @@ CEC_ADAP_G_LOG_ADDRS, CEC_ADAP_S_LOG_ADDRS - Get or set the logical addresses ...@@ -17,33 +17,35 @@ CEC_ADAP_G_LOG_ADDRS, CEC_ADAP_S_LOG_ADDRS - Get or set the logical addresses
Synopsis Synopsis
======== ========
.. cpp:function:: int ioctl( int fd, int request, struct cec_log_addrs *argp ) .. c:function:: int ioctl( int fd, CEC_ADAP_G_LOG_ADDRS, struct cec_log_addrs *argp )
:name: CEC_ADAP_G_LOG_ADDRS
.. c:function:: int ioctl( int fd, CEC_ADAP_S_LOG_ADDRS, struct cec_log_addrs *argp )
:name: CEC_ADAP_S_LOG_ADDRS
Arguments Arguments
========= =========
``fd`` ``fd``
File descriptor returned by :ref:`open() <cec-func-open>`. File descriptor returned by :c:func:`open() <cec-open>`.
``request``
CEC_ADAP_G_LOG_ADDRS, CEC_ADAP_S_LOG_ADDRS
``argp`` ``argp``
Pointer to struct :c:type:`cec_log_addrs`.
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
To query the current CEC logical addresses, applications call To query the current CEC logical addresses, applications call
:ref:`ioctl CEC_ADAP_G_LOG_ADDRS <CEC_ADAP_G_LOG_ADDRS>` with a pointer to a :ref:`ioctl CEC_ADAP_G_LOG_ADDRS <CEC_ADAP_G_LOG_ADDRS>` with a pointer to a
:c:type:`struct cec_log_addrs` where the driver stores the logical addresses. struct :c:type:`cec_log_addrs` where the driver stores the logical addresses.
To set new logical addresses, applications fill in To set new logical addresses, applications fill in
:c:type:`struct cec_log_addrs` and call :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>` struct :c:type:`cec_log_addrs` and call :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>`
with a pointer to this struct. The :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>` with a pointer to this struct. The :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>`
is only available if ``CEC_CAP_LOG_ADDRS`` is set (the ``ENOTTY`` error code is is only available if ``CEC_CAP_LOG_ADDRS`` is set (the ``ENOTTY`` error code is
returned otherwise). The :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>` returned otherwise). The :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>`
...@@ -64,8 +66,11 @@ logical addresses are claimed or cleared. ...@@ -64,8 +66,11 @@ logical addresses are claimed or cleared.
Attempting to call :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>` when Attempting to call :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>` when
logical address types are already defined will return with error ``EBUSY``. logical address types are already defined will return with error ``EBUSY``.
.. c:type:: cec_log_addrs
.. _cec-log-addrs: .. tabularcolumns:: |p{1.0cm}|p{7.5cm}|p{8.0cm}|
.. cssclass:: longtable
.. flat-table:: struct cec_log_addrs .. flat-table:: struct cec_log_addrs
:header-rows: 0 :header-rows: 0
...@@ -220,6 +225,8 @@ logical address types are already defined will return with error ``EBUSY``. ...@@ -220,6 +225,8 @@ logical address types are already defined will return with error ``EBUSY``.
fallback to the Unregistered logical address. Note that if the Unregistered fallback to the Unregistered logical address. Note that if the Unregistered
logical address was explicitly requested, then this flag has no effect. logical address was explicitly requested, then this flag has no effect.
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
.. _cec-versions: .. _cec-versions:
.. flat-table:: CEC Versions .. flat-table:: CEC Versions
...@@ -253,6 +260,7 @@ logical address types are already defined will return with error ``EBUSY``. ...@@ -253,6 +260,7 @@ logical address types are already defined will return with error ``EBUSY``.
- CEC version according to the HDMI 2.0 standard. - CEC version according to the HDMI 2.0 standard.
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
.. _cec-prim-dev-types: .. _cec-prim-dev-types:
...@@ -319,6 +327,7 @@ logical address types are already defined will return with error ``EBUSY``. ...@@ -319,6 +327,7 @@ logical address types are already defined will return with error ``EBUSY``.
- Use for a video processor device. - Use for a video processor device.
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
.. _cec-log-addr-types: .. _cec-log-addr-types:
...@@ -388,6 +397,8 @@ logical address types are already defined will return with error ``EBUSY``. ...@@ -388,6 +397,8 @@ logical address types are already defined will return with error ``EBUSY``.
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
.. _cec-all-dev-types-flags: .. _cec-all-dev-types-flags:
.. flat-table:: CEC All Device Types Flags .. flat-table:: CEC All Device Types Flags
......
...@@ -17,24 +17,27 @@ CEC_ADAP_G_PHYS_ADDR, CEC_ADAP_S_PHYS_ADDR - Get or set the physical address ...@@ -17,24 +17,27 @@ CEC_ADAP_G_PHYS_ADDR, CEC_ADAP_S_PHYS_ADDR - Get or set the physical address
Synopsis Synopsis
======== ========
.. cpp:function:: int ioctl( int fd, int request, __u16 *argp ) .. c:function:: int ioctl( int fd, CEC_ADAP_G_PHYS_ADDR, __u16 *argp )
:name: CEC_ADAP_G_PHYS_ADDR
.. c:function:: int ioctl( int fd, CEC_ADAP_S_PHYS_ADDR, __u16 *argp )
:name: CEC_ADAP_S_PHYS_ADDR
Arguments Arguments
========= =========
``fd`` ``fd``
File descriptor returned by :ref:`open() <cec-func-open>`. File descriptor returned by :c:func:`open() <cec-open>`.
``request``
CEC_ADAP_G_PHYS_ADDR, CEC_ADAP_S_PHYS_ADDR
``argp`` ``argp``
Pointer to the CEC address.
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
To query the current physical address applications call To query the current physical address applications call
......
...@@ -15,8 +15,8 @@ CEC_DQEVENT - Dequeue a CEC event ...@@ -15,8 +15,8 @@ CEC_DQEVENT - Dequeue a CEC event
Synopsis Synopsis
======== ========
.. c:function:: int ioctl( int fd, int request, struct cec_event *argp ) .. c:function:: int ioctl( int fd, CEC_DQEVENT, struct cec_event *argp )
:name: CEC_DQEVENT :name: CEC_DQEVENT
Arguments Arguments
========= =========
...@@ -24,16 +24,15 @@ Arguments ...@@ -24,16 +24,15 @@ Arguments
``fd`` ``fd``
File descriptor returned by :ref:`open() <cec-func-open>`. File descriptor returned by :ref:`open() <cec-func-open>`.
``request``
CEC_DQEVENT
``argp`` ``argp``
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
CEC devices can send asynchronous events. These can be retrieved by CEC devices can send asynchronous events. These can be retrieved by
...@@ -50,8 +49,9 @@ two :ref:`CEC_EVENT_STATE_CHANGE <CEC-EVENT-STATE-CHANGE>` events with ...@@ -50,8 +49,9 @@ two :ref:`CEC_EVENT_STATE_CHANGE <CEC-EVENT-STATE-CHANGE>` events with
the same state). In that case the intermediate state changes were lost but the same state). In that case the intermediate state changes were lost but
it is guaranteed that the state did change in between the two events. it is guaranteed that the state did change in between the two events.
.. tabularcolumns:: |p{1.2cm}|p{2.9cm}|p{13.4cm}|
.. _cec-event-state-change_s: .. c:type:: cec_event_state_change
.. flat-table:: struct cec_event_state_change .. flat-table:: struct cec_event_state_change
:header-rows: 0 :header-rows: 0
...@@ -80,8 +80,9 @@ it is guaranteed that the state did change in between the two events. ...@@ -80,8 +80,9 @@ it is guaranteed that the state did change in between the two events.
has the unregistered logical address. In that case all other bits are 0. has the unregistered logical address. In that case all other bits are 0.
.. c:type:: cec_event_lost_msgs
.. _cec-event-lost-msgs_s: .. tabularcolumns:: |p{1.0cm}|p{2.0cm}|p{14.5cm}|
.. flat-table:: struct cec_event_lost_msgs .. flat-table:: struct cec_event_lost_msgs
:header-rows: 0 :header-rows: 0
...@@ -106,8 +107,9 @@ it is guaranteed that the state did change in between the two events. ...@@ -106,8 +107,9 @@ it is guaranteed that the state did change in between the two events.
this is more than enough. this is more than enough.
.. tabularcolumns:: |p{1.0cm}|p{4.2cm}|p{2.5cm}|p{8.8cm}|
.. _cec-event: .. c:type:: cec_event
.. flat-table:: struct cec_event .. flat-table:: struct cec_event
:header-rows: 0 :header-rows: 0
...@@ -121,11 +123,10 @@ it is guaranteed that the state did change in between the two events. ...@@ -121,11 +123,10 @@ it is guaranteed that the state did change in between the two events.
- ``ts`` - ``ts``
- Timestamp of the event in ns. - :cspan:`1` Timestamp of the event in ns.
The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access
the same clock from userspace use :c:func:`clock_gettime(2)`.
- The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access
the same clock from userspace use :c:func:`clock_gettime`.
- .. row 2 - .. row 2
...@@ -133,9 +134,7 @@ it is guaranteed that the state did change in between the two events. ...@@ -133,9 +134,7 @@ it is guaranteed that the state did change in between the two events.
- ``event`` - ``event``
- The CEC event type, see :ref:`cec-events`. - :cspan:`1` The CEC event type, see :ref:`cec-events`.
-
- .. row 3 - .. row 3
...@@ -143,9 +142,7 @@ it is guaranteed that the state did change in between the two events. ...@@ -143,9 +142,7 @@ it is guaranteed that the state did change in between the two events.
- ``flags`` - ``flags``
- Event flags, see :ref:`cec-event-flags`. - :cspan:`1` Event flags, see :ref:`cec-event-flags`.
-
- .. row 4 - .. row 4
...@@ -177,6 +174,7 @@ it is guaranteed that the state did change in between the two events. ...@@ -177,6 +174,7 @@ it is guaranteed that the state did change in between the two events.
event. event.
.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
.. _cec-events: .. _cec-events:
...@@ -206,6 +204,7 @@ it is guaranteed that the state did change in between the two events. ...@@ -206,6 +204,7 @@ it is guaranteed that the state did change in between the two events.
application didn't dequeue CEC messages fast enough. application didn't dequeue CEC messages fast enough.
.. tabularcolumns:: |p{6.0cm}|p{0.6cm}|p{10.9cm}|
.. _cec-event-flags: .. _cec-event-flags:
......
...@@ -13,24 +13,27 @@ CEC_G_MODE, CEC_S_MODE - Get or set exclusive use of the CEC adapter ...@@ -13,24 +13,27 @@ CEC_G_MODE, CEC_S_MODE - Get or set exclusive use of the CEC adapter
Synopsis Synopsis
======== ========
.. cpp:function:: int ioctl( int fd, int request, __u32 *argp ) .. c:function:: int ioctl( int fd, CEC_G_MODE, __u32 *argp )
:name: CEC_G_MODE
.. c:function:: int ioctl( int fd, CEC_S_MODE, __u32 *argp )
:name: CEC_S_MODE
Arguments Arguments
========= =========
``fd`` ``fd``
File descriptor returned by :ref:`open() <cec-func-open>`. File descriptor returned by :c:func:`open() <cec-open>`.
``request``
CEC_G_MODE, CEC_S_MODE
``argp`` ``argp``
Pointer to CEC mode.
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
By default any filehandle can use :ref:`CEC_TRANSMIT`, but in order to prevent By default any filehandle can use :ref:`CEC_TRANSMIT`, but in order to prevent
...@@ -71,6 +74,7 @@ always call :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>`. ...@@ -71,6 +74,7 @@ always call :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>`.
Available initiator modes are: Available initiator modes are:
.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
.. _cec-mode-initiator_e: .. _cec-mode-initiator_e:
...@@ -114,6 +118,7 @@ Available initiator modes are: ...@@ -114,6 +118,7 @@ Available initiator modes are:
Available follower modes are: Available follower modes are:
.. tabularcolumns:: |p{6.6cm}|p{0.9cm}|p{10.0cm}|
.. _cec-mode-follower_e: .. _cec-mode-follower_e:
...@@ -206,6 +211,7 @@ Available follower modes are: ...@@ -206,6 +211,7 @@ Available follower modes are:
Core message processing details: Core message processing details:
.. tabularcolumns:: |p{6.6cm}|p{10.9cm}|
.. _cec-core-processing: .. _cec-core-processing:
......
...@@ -16,28 +16,32 @@ CEC_RECEIVE, CEC_TRANSMIT - Receive or transmit a CEC message ...@@ -16,28 +16,32 @@ CEC_RECEIVE, CEC_TRANSMIT - Receive or transmit a CEC message
Synopsis Synopsis
======== ========
.. cpp:function:: int ioctl( int fd, int request, struct cec_msg *argp ) .. c:function:: int ioctl( int fd, CEC_RECEIVE, struct cec_msg *argp )
:name: CEC_RECEIVE
.. c:function:: int ioctl( int fd, CEC_TRANSMIT, struct cec_msg *argp )
:name: CEC_TRANSMIT
Arguments Arguments
========= =========
``fd`` ``fd``
File descriptor returned by :ref:`open() <cec-func-open>`. File descriptor returned by :c:func:`open() <cec-open>`.
``request``
CEC_RECEIVE, CEC_TRANSMIT
``argp`` ``argp``
Pointer to struct cec_msg.
Description Description
=========== ===========
.. note:: This documents the proposed CEC API. This API is not yet finalized .. note::
This documents the proposed CEC API. This API is not yet finalized
and is currently only available as a staging kernel module. and is currently only available as a staging kernel module.
To receive a CEC message the application has to fill in the To receive a CEC message the application has to fill in the
``timeout`` field of :c:type:`struct cec_msg` and pass it to :ref:`ioctl CEC_RECEIVE <CEC_RECEIVE>`. ``timeout`` field of struct :c:type:`cec_msg` and pass it to
:ref:`ioctl CEC_RECEIVE <CEC_RECEIVE>`.
If the file descriptor is in non-blocking mode and there are no received If the file descriptor is in non-blocking mode and there are no received
messages pending, then it will return -1 and set errno to the ``EAGAIN`` messages pending, then it will return -1 and set errno to the ``EAGAIN``
error code. If the file descriptor is in blocking mode and ``timeout`` error code. If the file descriptor is in blocking mode and ``timeout``
...@@ -51,9 +55,9 @@ A received message can be: ...@@ -51,9 +55,9 @@ A received message can be:
2. the result of an earlier non-blocking transmit (the ``sequence`` field will 2. the result of an earlier non-blocking transmit (the ``sequence`` field will
be non-zero). be non-zero).
To send a CEC message the application has to fill in the To send a CEC message the application has to fill in the struct
:c:type:`struct cec_msg` and pass it to :c:type:` cec_msg` and pass it to :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>`.
:ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>`. The :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>` is only available if The :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>` is only available if
``CEC_CAP_TRANSMIT`` is set. If there is no more room in the transmit ``CEC_CAP_TRANSMIT`` is set. If there is no more room in the transmit
queue, then it will return -1 and set errno to the ``EBUSY`` error code. queue, then it will return -1 and set errno to the ``EBUSY`` error code.
The transmit queue has enough room for 18 messages (about 1 second worth The transmit queue has enough room for 18 messages (about 1 second worth
...@@ -71,7 +75,11 @@ checked against the received messages to find the corresponding transmit ...@@ -71,7 +75,11 @@ checked against the received messages to find the corresponding transmit
result. result.
.. _cec-msg: .. tabularcolumns:: |p{1.0cm}|p{3.5cm}|p{13.0cm}|
.. c:type:: cec_msg
.. cssclass:: longtable
.. flat-table:: struct cec_msg .. flat-table:: struct cec_msg
:header-rows: 0 :header-rows: 0
...@@ -87,7 +95,7 @@ result. ...@@ -87,7 +95,7 @@ result.
- Timestamp in ns of when the last byte of the message was transmitted. - Timestamp in ns of when the last byte of the message was transmitted.
The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access
the same clock from userspace use :c:func:`clock_gettime(2)`. the same clock from userspace use :c:func:`clock_gettime`.
- .. row 2 - .. row 2
...@@ -97,7 +105,7 @@ result. ...@@ -97,7 +105,7 @@ result.
- Timestamp in ns of when the last byte of the message was received. - Timestamp in ns of when the last byte of the message was received.
The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access
the same clock from userspace use :c:func:`clock_gettime(2)`. the same clock from userspace use :c:func:`clock_gettime`.
- .. row 3 - .. row 3
...@@ -247,6 +255,7 @@ result. ...@@ -247,6 +255,7 @@ result.
valid if the :ref:`CEC_TX_STATUS_ERROR <CEC-TX-STATUS-ERROR>` status bit is set. valid if the :ref:`CEC_TX_STATUS_ERROR <CEC-TX-STATUS-ERROR>` status bit is set.
.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
.. _cec-tx-status: .. _cec-tx-status:
...@@ -315,6 +324,7 @@ result. ...@@ -315,6 +324,7 @@ result.
be set to explain which failures were seen. be set to explain which failures were seen.
.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
.. _cec-rx-status: .. _cec-rx-status:
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_BILINGUAL_CHANNEL_SELECT AUDIO_BILINGUAL_CHANNEL_SELECT
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_BILINGUAL_CHANNEL_SELECT, audio_channel_select_t) .. c:function:: int ioctl(int fd, AUDIO_BILINGUAL_CHANNEL_SELECT, struct *audio_channel_select)
:name: AUDIO_BILINGUAL_CHANNEL_SELECT
Arguments Arguments
...@@ -25,20 +27,13 @@ Arguments ...@@ -25,20 +27,13 @@ Arguments
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
-
- .. row 1
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_BILINGUAL_CHANNEL_SELECT for this command.
- .. row 3
- audio_channel_select_t ch - audio_channel_select_t ch
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_CHANNEL_SELECT AUDIO_CHANNEL_SELECT
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_CHANNEL_SELECT, audio_channel_select_t) .. c:function:: int ioctl(int fd, AUDIO_CHANNEL_SELECT, struct *audio_channel_select)
:name: AUDIO_CHANNEL_SELECT
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_CHANNEL_SELECT for this command.
- .. row 3
- audio_channel_select_t ch - audio_channel_select_t ch
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_CLEAR_BUFFER AUDIO_CLEAR_BUFFER
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_CLEAR_BUFFER) .. c:function:: int ioctl(int fd, AUDIO_CLEAR_BUFFER)
:name: AUDIO_CLEAR_BUFFER
Arguments Arguments
--------- ---------
...@@ -32,13 +33,6 @@ Arguments ...@@ -32,13 +33,6 @@ Arguments
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals AUDIO_CLEAR_BUFFER for this command.
Description Description
----------- -----------
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_CONTINUE AUDIO_CONTINUE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_CONTINUE) .. c:function:: int ioctl(int fd, AUDIO_CONTINUE)
:name: AUDIO_CONTINUE
Arguments Arguments
...@@ -32,13 +34,6 @@ Arguments ...@@ -32,13 +34,6 @@ Arguments
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals AUDIO_CONTINUE for this command.
Description Description
----------- -----------
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
DVB audio close() DVB audio close()
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int close(int fd) .. c:function:: int close(int fd)
:name: dvb-audio-close
Arguments Arguments
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
DVB audio open() DVB audio open()
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int open(const char *deviceName, int flags) .. c:function:: int open(const char *deviceName, int flags)
:name: dvb-audio-open
Arguments Arguments
...@@ -80,6 +82,8 @@ AUDIO_GET_STATUS. All other call will return with an error code. ...@@ -80,6 +82,8 @@ AUDIO_GET_STATUS. All other call will return with an error code.
Return Value Return Value
------------ ------------
.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
DVB audio write() DVB audio write()
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: size_t write(int fd, const void *buf, size_t count) .. c:function:: size_t write(int fd, const void *buf, size_t count)
:name: dvb-audio-write
Arguments Arguments
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_GET_CAPABILITIES AUDIO_GET_CAPABILITIES
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_GET_CAPABILITIES, unsigned int *cap) .. c:function:: int ioctl(int fd, AUDIO_GET_CAPABILITIES, unsigned int *cap)
:name: AUDIO_GET_CAPABILITIES
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_GET_CAPABILITIES for this command.
- .. row 3
- unsigned int \*cap - unsigned int \*cap
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_GET_PTS AUDIO_GET_PTS
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_GET_PTS, __u64 *pts) .. c:function:: int ioctl(int fd, AUDIO_GET_PTS, __u64 *pts)
:name: AUDIO_GET_PTS
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_GET_PTS for this command.
- .. row 3
- __u64 \*pts - __u64 \*pts
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_GET_STATUS AUDIO_GET_STATUS
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_GET_STATUS, struct audio_status *status) .. c:function:: int ioctl(int fd, AUDIO_GET_STATUS, struct audio_status *status)
:name: AUDIO_GET_STATUS
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_GET_STATUS for this command.
- .. row 3
- struct audio_status \*status - struct audio_status \*status
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_PAUSE AUDIO_PAUSE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_PAUSE) .. c:function:: int ioctl(int fd, AUDIO_PAUSE)
:name: AUDIO_PAUSE
Arguments Arguments
--------- ---------
...@@ -32,12 +33,6 @@ Arguments ...@@ -32,12 +33,6 @@ Arguments
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals AUDIO_PAUSE for this command.
Description Description
----------- -----------
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_PLAY AUDIO_PLAY
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_PLAY) .. c:function:: int ioctl(int fd, AUDIO_PLAY)
:name: AUDIO_PLAY
Arguments Arguments
...@@ -32,13 +34,6 @@ Arguments ...@@ -32,13 +34,6 @@ Arguments
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals AUDIO_PLAY for this command.
Description Description
----------- -----------
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_SELECT_SOURCE AUDIO_SELECT_SOURCE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_SELECT_SOURCE, audio_stream_source_t source) .. c:function:: int ioctl(int fd, AUDIO_SELECT_SOURCE, struct audio_stream_source *source)
:name: AUDIO_SELECT_SOURCE
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SELECT_SOURCE for this command.
- .. row 3
- audio_stream_source_t source - audio_stream_source_t source
......
...@@ -11,12 +11,14 @@ Name ...@@ -11,12 +11,14 @@ Name
AUDIO_SET_ATTRIBUTES AUDIO_SET_ATTRIBUTES
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = AUDIO_SET_ATTRIBUTES, audio_attributes_t attr ) .. c:function:: int ioctl(fd, AUDIO_SET_ATTRIBUTES, struct audio_attributes *attr )
:name: AUDIO_SET_ATTRIBUTES
Arguments Arguments
--------- ---------
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_ATTRIBUTES for this command.
- .. row 3
- audio_attributes_t attr - audio_attributes_t attr
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_SET_AV_SYNC AUDIO_SET_AV_SYNC
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_SET_AV_SYNC, boolean state) .. c:function:: int ioctl(int fd, AUDIO_SET_AV_SYNC, boolean state)
:name: AUDIO_SET_AV_SYNC
Arguments Arguments
...@@ -26,33 +28,21 @@ Arguments ...@@ -26,33 +28,21 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_AV_SYNC for this command.
- .. row 3
- boolean state - boolean state
- Tells the DVB subsystem if A/V synchronization shall be ON or OFF. - Tells the DVB subsystem if A/V synchronization shall be ON or OFF.
- .. row 4 TRUE: AV-sync ON
-
- TRUE AV-sync ON
- .. row 5
- FALSE: AV-sync OFF
- FALSE AV-sync OFF
Description Description
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_SET_BYPASS_MODE AUDIO_SET_BYPASS_MODE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_SET_BYPASS_MODE, boolean mode) .. c:function:: int ioctl(int fd, AUDIO_SET_BYPASS_MODE, boolean mode)
:name: AUDIO_SET_BYPASS_MODE
Arguments Arguments
--------- ---------
...@@ -26,34 +27,22 @@ Arguments ...@@ -26,34 +27,22 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_BYPASS_MODE for this command.
- .. row 3
- boolean mode - boolean mode
- Enables or disables the decoding of the current Audio stream in - Enables or disables the decoding of the current Audio stream in
the DVB subsystem. the DVB subsystem.
- .. row 4 TRUE: Bypass is disabled
-
- TRUE Bypass is disabled
- .. row 5
- FALSE: Bypass is enabled
- FALSE Bypass is enabled
Description Description
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_SET_EXT_ID AUDIO_SET_EXT_ID
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = AUDIO_SET_EXT_ID, int id) .. c:function:: int ioctl(fd, AUDIO_SET_EXT_ID, int id)
:name: AUDIO_SET_EXT_ID
Arguments Arguments
--------- ---------
...@@ -26,19 +27,13 @@ Arguments ...@@ -26,19 +27,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_EXT_ID for this command.
- .. row 3
- int id - int id
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_SET_ID AUDIO_SET_ID
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_SET_ID, int id) .. c:function:: int ioctl(int fd, AUDIO_SET_ID, int id)
:name: AUDIO_SET_ID
Arguments Arguments
--------- ---------
...@@ -26,19 +27,13 @@ Arguments ...@@ -26,19 +27,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_ID for this command.
- .. row 3
- int id - int id
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_SET_KARAOKE AUDIO_SET_KARAOKE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = AUDIO_SET_KARAOKE, audio_karaoke_t *karaoke) .. c:function:: int ioctl(fd, AUDIO_SET_KARAOKE, struct audio_karaoke *karaoke)
:name: AUDIO_SET_KARAOKE
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_KARAOKE for this command.
- .. row 3
- audio_karaoke_t \*karaoke - audio_karaoke_t \*karaoke
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_SET_MIXER AUDIO_SET_MIXER
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_SET_MIXER, audio_mixer_t *mix) .. c:function:: int ioctl(int fd, AUDIO_SET_MIXER, struct audio_mixer *mix)
:name: AUDIO_SET_MIXER
Arguments Arguments
--------- ---------
...@@ -26,19 +27,13 @@ Arguments ...@@ -26,19 +27,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_ID for this command.
- .. row 3
- audio_mixer_t \*mix - audio_mixer_t \*mix
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_SET_MUTE AUDIO_SET_MUTE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_SET_MUTE, boolean state) .. c:function:: int ioctl(int fd, AUDIO_SET_MUTE, boolean state)
:name: AUDIO_SET_MUTE
Arguments Arguments
...@@ -26,33 +28,21 @@ Arguments ...@@ -26,33 +28,21 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_MUTE for this command.
- .. row 3
- boolean state - boolean state
- Indicates if audio device shall mute or not. - Indicates if audio device shall mute or not.
- .. row 4 TRUE: Audio Mute
-
- TRUE Audio Mute
- .. row 5
- FALSE: Audio Un-mute
- FALSE Audio Un-mute
Description Description
......
...@@ -11,11 +11,13 @@ Name ...@@ -11,11 +11,13 @@ Name
AUDIO_SET_STREAMTYPE AUDIO_SET_STREAMTYPE
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = AUDIO_SET_STREAMTYPE, int type) .. c:function:: int ioctl(fd, AUDIO_SET_STREAMTYPE, int type)
:name: AUDIO_SET_STREAMTYPE
Arguments Arguments
...@@ -26,19 +28,13 @@ Arguments ...@@ -26,19 +28,13 @@ Arguments
:stub-columns: 0 :stub-columns: 0
- .. row 1 -
- int fd - int fd
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2 -
- int request
- Equals AUDIO_SET_STREAMTYPE for this command.
- .. row 3
- int type - int type
......
...@@ -11,12 +11,13 @@ Name ...@@ -11,12 +11,13 @@ Name
AUDIO_STOP AUDIO_STOP
.. attention:: This ioctl is deprecated
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(int fd, int request = AUDIO_STOP) .. c:function:: int ioctl(int fd, AUDIO_STOP)
:name: AUDIO_STOP
Arguments Arguments
--------- ---------
...@@ -32,12 +33,6 @@ Arguments ...@@ -32,12 +33,6 @@ Arguments
- File descriptor returned by a previous call to open(). - File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals AUDIO_STOP for this command.
Description Description
----------- -----------
......
...@@ -9,11 +9,7 @@ Audio Data Types ...@@ -9,11 +9,7 @@ Audio Data Types
This section describes the structures, data types and defines used when This section describes the structures, data types and defines used when
talking to the audio device. talking to the audio device.
.. c:type:: audio_stream_source
.. _audio-stream-source-t:
audio_stream_source_t
=====================
The audio stream source is set through the AUDIO_SELECT_SOURCE call The audio stream source is set through the AUDIO_SELECT_SOURCE call
and can take the following values, depending on whether we are replaying and can take the following values, depending on whether we are replaying
...@@ -33,10 +29,7 @@ AUDIO_SOURCE_MEMORY is selected the stream comes from the application ...@@ -33,10 +29,7 @@ AUDIO_SOURCE_MEMORY is selected the stream comes from the application
through the ``write()`` system call. through the ``write()`` system call.
.. _audio-play-state-t: .. c:type:: audio_play_state
audio_play_state_t
==================
The following values can be returned by the AUDIO_GET_STATUS call The following values can be returned by the AUDIO_GET_STATUS call
representing the state of audio playback. representing the state of audio playback.
...@@ -51,10 +44,7 @@ representing the state of audio playback. ...@@ -51,10 +44,7 @@ representing the state of audio playback.
} audio_play_state_t; } audio_play_state_t;
.. _audio-channel-select-t: .. c:type:: audio_channel_select
audio_channel_select_t
======================
The audio channel selected via AUDIO_CHANNEL_SELECT is determined by The audio channel selected via AUDIO_CHANNEL_SELECT is determined by
the following values. the following values.
...@@ -71,10 +61,7 @@ the following values. ...@@ -71,10 +61,7 @@ the following values.
} audio_channel_select_t; } audio_channel_select_t;
.. _audio-status: .. c:type:: audio_status
struct audio_status
===================
The AUDIO_GET_STATUS call returns the following structure informing The AUDIO_GET_STATUS call returns the following structure informing
about various states of the playback operation. about various states of the playback operation.
...@@ -93,10 +80,7 @@ about various states of the playback operation. ...@@ -93,10 +80,7 @@ about various states of the playback operation.
} audio_status_t; } audio_status_t;
.. _audio-mixer: .. c:type:: audio_mixer
struct audio_mixer
==================
The following structure is used by the AUDIO_SET_MIXER call to set the The following structure is used by the AUDIO_SET_MIXER call to set the
audio volume. audio volume.
...@@ -131,11 +115,7 @@ following bits set according to the hardwares capabilities. ...@@ -131,11 +115,7 @@ following bits set according to the hardwares capabilities.
#define AUDIO_CAP_SDDS 128 #define AUDIO_CAP_SDDS 128
#define AUDIO_CAP_AC3 256 #define AUDIO_CAP_AC3 256
.. c:type:: audio_karaoke
.. _audio-karaoke:
struct audio_karaoke
====================
The ioctl AUDIO_SET_KARAOKE uses the following format: The ioctl AUDIO_SET_KARAOKE uses the following format:
...@@ -155,10 +135,7 @@ into the left channel and Vocal2 into the right channel at 100% each. Ff ...@@ -155,10 +135,7 @@ into the left channel and Vocal2 into the right channel at 100% each. Ff
Melody is non-zero, the melody channel gets mixed into left and right. Melody is non-zero, the melody channel gets mixed into left and right.
.. _audio-attributes-t: .. c:type:: audio_attributes
audio attributes
================
The following attributes can be set by a call to AUDIO_SET_ATTRIBUTES: The following attributes can be set by a call to AUDIO_SET_ATTRIBUTES:
......
...@@ -15,28 +15,20 @@ DVB CA close() ...@@ -15,28 +15,20 @@ DVB CA close()
Synopsis Synopsis
-------- --------
.. cpp:function:: int close(int fd) .. c:function:: int close(int fd)
:name: dvb-ca-close
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
Description Description
----------- -----------
This system call closes a previously opened audio device. This system call closes a previously opened CA device.
Return Value Return Value
......
...@@ -15,48 +15,35 @@ DVB CA open() ...@@ -15,48 +15,35 @@ DVB CA open()
Synopsis Synopsis
-------- --------
.. cpp:function:: int open(const char *deviceName, int flags) .. c:function:: int open(const char *name, int flags)
:name: dvb-ca-open
Arguments Arguments
--------- ---------
``name``
Name of specific DVB CA device.
``flags``
A bit-wise OR of the following flags:
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
-
- O_RDONLY
- read-only access
- .. row 1 -
- O_RDWR
- const char \*deviceName - read/write access
- Name of specific video device.
- .. row 2 -
- O_NONBLOCK
- int flags - open in non-blocking mode
(blocking mode is the default)
- A bit-wise OR of the following flags:
- .. row 3
-
- O_RDONLY read-only access
- .. row 4
-
- O_RDWR read/write access
- .. row 5
-
- O_NONBLOCK open in non-blocking mode
- .. row 6
-
- (blocking mode is the default)
Description Description
...@@ -79,6 +66,8 @@ the device in this mode will fail, and an error code will be returned. ...@@ -79,6 +66,8 @@ the device in this mode will fail, and an error code will be returned.
Return Value Return Value
------------ ------------
.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
......
...@@ -15,40 +15,51 @@ CA_GET_CAP ...@@ -15,40 +15,51 @@ CA_GET_CAP
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_GET_CAP, ca_caps_t *) .. c:function:: int ioctl(fd, CA_GET_CAP, struct ca_caps *caps)
:name: CA_GET_CAP
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open(). ``caps``
Pointer to struct :c:type:`ca_caps`.
- .. row 2 .. c:type:: struct ca_caps
- int request .. flat-table:: struct ca_caps
:header-rows: 1
- Equals CA_GET_CAP for this command. :stub-columns: 0
- .. row 3
- ca_caps_t *
- Undocumented. -
- type
- name
- description
-
- unsigned int
- slot_num
- total number of CA card and module slots
-
- unsigned int
- slot_type
- bitmask with all supported slot types
-
- unsigned int
- descr_num
- total number of descrambler slots (keys)
-
- unsigned int
- descr_type
- bit mask with all supported descr types
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,40 +15,44 @@ CA_GET_DESCR_INFO ...@@ -15,40 +15,44 @@ CA_GET_DESCR_INFO
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_GET_DESCR_INFO, ca_descr_info_t *) .. c:function:: int ioctl(fd, CA_GET_DESCR_INFO, struct ca_descr_info *desc)
:name: CA_GET_DESCR_INFO
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd ``desc``
Pointer to struct :c:type:`ca_descr_info`.
- File descriptor returned by a previous call to open(). .. c:type:: struct ca_descr_info
- .. row 2 .. flat-table:: struct ca_descr_info
:header-rows: 1
- int request :stub-columns: 0
- Equals CA_GET_DESCR_INFO for this command.
- .. row 3
- ca_descr_info_t \* -
- type
- name
- description
- Undocumented. -
- unsigned int
- num
- number of available descramblers (keys)
-
- unsigned int
- type
- type of supported scrambling system. Valid values are:
``CA_ECD``, ``CA_NDS`` and ``CA_DSS``.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,40 +15,55 @@ CA_GET_MSG ...@@ -15,40 +15,55 @@ CA_GET_MSG
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_GET_MSG, ca_msg_t *) .. c:function:: int ioctl(fd, CA_GET_MSG, struct ca_msg *msg)
:name: CA_GET_MSG
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1 ``msg``
Pointer to struct :c:type:`ca_msg`.
- int fd
- File descriptor returned by a previous call to open(). .. c:type:: struct ca_msg
- .. row 2 .. flat-table:: struct ca_msg
:header-rows: 1
- int request :stub-columns: 0
- Equals CA_GET_MSG for this command. -
- type
- name
- description
-
- unsigned int
- index
-
- .. row 3 -
- unsigned int
- type
-
- ca_msg_t \* -
- unsigned int
- length
-
- Undocumented. -
- unsigned char
- msg[256]
-
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,40 +15,106 @@ CA_GET_SLOT_INFO ...@@ -15,40 +15,106 @@ CA_GET_SLOT_INFO
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_GET_SLOT_INFO, ca_slot_info_t *) .. c:function:: int ioctl(fd, CA_GET_SLOT_INFO, struct ca_slot_info *info)
:name: CA_GET_SLOT_INFO
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.
``info``
Pointer to struct c:type:`ca_slot_info`.
.. _ca_slot_info_type:
.. flat-table:: ca_slot_info types
:header-rows: 1
:stub-columns: 0 :stub-columns: 0
-
- type
- name
- description
-
- CA_CI
- 1
- CI high level interface
-
- CA_CI_LINK
- 2
- CI link layer level interface
-
- CA_CI_PHYS
- 4
- CI physical layer level interface
-
- CA_DESCR
- 8
- built-in descrambler
-
- CA_SC
- 128
- simple smart card interface
.. _ca_slot_info_flag:
.. flat-table:: ca_slot_info flags
:header-rows: 1
:stub-columns: 0
- .. row 1 -
- type
- name
- description
- int fd -
- CA_CI_MODULE_PRESENT
- 1
- module (or card) inserted
- File descriptor returned by a previous call to open(). -
- CA_CI_MODULE_READY
- 2
-
- .. row 2 .. c:type:: ca_slot_info
- int request .. flat-table:: struct ca_slot_info
:header-rows: 1
:stub-columns: 0
- Equals CA_GET_SLOT_INFO for this command. -
- type
- name
- description
- .. row 3 -
- int
- num
- slot number
- ca_slot_info_t \* -
- int
- type
- CA interface this slot supports, as defined at :ref:`ca_slot_info_type`.
- Undocumented. -
- unsigned int
- flags
- flags as defined at :ref:`ca_slot_info_flag`.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,34 +15,20 @@ CA_RESET ...@@ -15,34 +15,20 @@ CA_RESET
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_RESET) .. c:function:: int ioctl(fd, CA_RESET)
:name: CA_RESET
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals CA_RESET for this command.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,40 +15,24 @@ CA_SEND_MSG ...@@ -15,40 +15,24 @@ CA_SEND_MSG
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_SEND_MSG, ca_msg_t *) .. c:function:: int ioctl(fd, CA_SEND_MSG, struct ca_msg *msg)
:name: CA_SEND_MSG
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.
:stub-columns: 0
``msg``
- .. row 1 Pointer to struct :c:type:`ca_msg`.
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals CA_SEND_MSG for this command.
- .. row 3
- ca_msg_t \*
- Undocumented.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,40 +15,24 @@ CA_SET_DESCR ...@@ -15,40 +15,24 @@ CA_SET_DESCR
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_SET_DESCR, ca_descr_t *) .. c:function:: int ioctl(fd, CA_SET_DESCR, struct ca_descr *desc)
:name: CA_SET_DESCR
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <cec-open>`.
:stub-columns: 0
``msg``
- .. row 1 Pointer to struct :c:type:`ca_descr`.
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals CA_SET_DESCR for this command.
- .. row 3
- ca_descr_t \*
- Undocumented.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,40 +15,41 @@ CA_SET_PID ...@@ -15,40 +15,41 @@ CA_SET_PID
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = CA_SET_PID, ca_pid_t *) .. c:function:: int ioctl(fd, CA_SET_PID, struct ca_pid *pid)
:name: CA_SET_PID
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd ``pid``
Pointer to struct :c:type:`ca_pid`.
- File descriptor returned by a previous call to open(). .. c:type:: ca_pid
- .. row 2 .. flat-table:: struct ca_pid
:header-rows: 1
- int request :stub-columns: 0
- Equals CA_SET_PID for this command.
- .. row 3 -
- unsigned int
- pid
- Program ID
- ca_pid_t \* -
- int
- index
- PID index. Use -1 to disable.
- Undocumented.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -7,7 +7,7 @@ CA Data Types ...@@ -7,7 +7,7 @@ CA Data Types
************* *************
.. _ca-slot-info: .. c:type:: ca_slot_info
ca_slot_info_t ca_slot_info_t
============== ==============
...@@ -31,7 +31,7 @@ ca_slot_info_t ...@@ -31,7 +31,7 @@ ca_slot_info_t
} ca_slot_info_t; } ca_slot_info_t;
.. _ca-descr-info: .. c:type:: ca_descr_info
ca_descr_info_t ca_descr_info_t
=============== ===============
...@@ -48,7 +48,7 @@ ca_descr_info_t ...@@ -48,7 +48,7 @@ ca_descr_info_t
} ca_descr_info_t; } ca_descr_info_t;
.. _ca-caps: .. c:type:: ca_caps
ca_caps_t ca_caps_t
========= =========
...@@ -64,7 +64,7 @@ ca_caps_t ...@@ -64,7 +64,7 @@ ca_caps_t
} ca_cap_t; } ca_cap_t;
.. _ca-msg: .. c:type:: ca_msg
ca_msg_t ca_msg_t
======== ========
...@@ -81,7 +81,7 @@ ca_msg_t ...@@ -81,7 +81,7 @@ ca_msg_t
} ca_msg_t; } ca_msg_t;
.. _ca-descr: .. c:type:: ca_descr
ca_descr_t ca_descr_t
========== ==========
...@@ -96,7 +96,7 @@ ca_descr_t ...@@ -96,7 +96,7 @@ ca_descr_t
} ca_descr_t; } ca_descr_t;
.. _ca-pid: .. c:type:: ca_pid
ca-pid ca-pid
====== ======
......
...@@ -15,34 +15,18 @@ DMX_ADD_PID ...@@ -15,34 +15,18 @@ DMX_ADD_PID
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = DMX_ADD_PID, __u16 *) .. c:function:: int ioctl(fd, DMX_ADD_PID, __u16 *pid)
:name: DMX_ADD_PID
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
``pid``
- .. row 1 PID number to be filtered.
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_ADD_PID for this command.
- .. row 3
- __u16 *
- PID number to be filtered.
Description Description
......
...@@ -15,23 +15,15 @@ DVB demux close() ...@@ -15,23 +15,15 @@ DVB demux close()
Synopsis Synopsis
-------- --------
.. cpp:function:: int close(int fd) .. c:function:: int close(int fd)
:name: dvb-dmx-close
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
Description Description
----------- -----------
......
...@@ -15,43 +15,34 @@ DVB demux open() ...@@ -15,43 +15,34 @@ DVB demux open()
Synopsis Synopsis
-------- --------
.. cpp:function:: int open(const char *deviceName, int flags) .. c:function:: int open(const char *deviceName, int flags)
:name: dvb-dmx-open
Arguments Arguments
--------- ---------
``name``
Name of specific DVB demux device.
``flags``
A bit-wise OR of the following flags:
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
-
- O_RDONLY
- read-only access
- .. row 1 -
- O_RDWR
- const char \*deviceName - read/write access
- Name of demux device.
- .. row 2
- int flags
- A bit-wise OR of the following flags:
- .. row 3
-
- O_RDWR read/write access
- .. row 4
-
- O_NONBLOCK open in non-blocking mode
- .. row 5
- -
- (blocking mode is the default) - O_NONBLOCK
- open in non-blocking mode
(blocking mode is the default)
Description Description
......
...@@ -15,35 +15,20 @@ DVB demux read() ...@@ -15,35 +15,20 @@ DVB demux read()
Synopsis Synopsis
-------- --------
.. cpp:function:: size_t read(int fd, void *buf, size_t count) .. c:function:: size_t read(int fd, void *buf, size_t count)
:name: dvb-dmx-read
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2 ``buf``
Buffer to be filled
- void \*buf
- Pointer to the buffer to be used for returned filtered data.
- .. row 3
- size_t count
- Size of buf.
``count``
Max number of bytes to read
Description Description
----------- -----------
...@@ -53,10 +38,11 @@ data. The filtered data is transferred from the driver’s internal ...@@ -53,10 +38,11 @@ data. The filtered data is transferred from the driver’s internal
circular buffer to buf. The maximum amount of data to be transferred is circular buffer to buf. The maximum amount of data to be transferred is
implied by count. implied by count.
Return Value Return Value
------------ ------------
.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
......
...@@ -15,35 +15,20 @@ DVB demux write() ...@@ -15,35 +15,20 @@ DVB demux write()
Synopsis Synopsis
-------- --------
.. cpp:function:: ssize_t write(int fd, const void *buf, size_t count) .. c:function:: ssize_t write(int fd, const void *buf, size_t count)
:name: dvb-dmx-write
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by a previous call to :c:func:`open() <dvb-ca-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2 ``buf``
Buffer with data to be written
- void \*buf
- Pointer to the buffer containing the Transport Stream.
- .. row 3
- size_t count
- Size of buf.
``count``
Number of bytes at the buffer
Description Description
----------- -----------
...@@ -59,11 +44,12 @@ The amount of data to be transferred is implied by count. ...@@ -59,11 +44,12 @@ The amount of data to be transferred is implied by count.
Return Value Return Value
------------ ------------
.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
- .. row 1 - .. row 1
- ``EWOULDBLOCK`` - ``EWOULDBLOCK``
......
...@@ -15,41 +15,23 @@ DMX_GET_CAPS ...@@ -15,41 +15,23 @@ DMX_GET_CAPS
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = DMX_GET_CAPS, dmx_caps_t *) .. c:function:: int ioctl(fd, DMX_GET_CAPS, struct dmx_caps *caps)
:name: DMX_GET_CAPS
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request ``caps``
Pointer to struct :c:type:`dmx_caps`
- Equals DMX_GET_CAPS for this command.
- .. row 3
- dmx_caps_t *
- Undocumented.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
------------ ------------
......
...@@ -15,34 +15,18 @@ DMX_GET_EVENT ...@@ -15,34 +15,18 @@ DMX_GET_EVENT
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_GET_EVENT, struct dmx_event *ev) .. c:function:: int ioctl( int fd, DMX_GET_EVENT, struct dmx_event *ev)
:name: DMX_GET_EVENT
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_GET_EVENT for this command.
- .. row 3
- struct dmx_event \*ev
- Pointer to the location where the event is to be stored. ``ev``
Pointer to the location where the event is to be stored.
Description Description
......
...@@ -15,40 +15,23 @@ DMX_GET_PES_PIDS ...@@ -15,40 +15,23 @@ DMX_GET_PES_PIDS
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = DMX_GET_PES_PIDS, __u16[5]) .. c:function:: int ioctl(fd, DMX_GET_PES_PIDS, __u16 pids[5])
:name: DMX_GET_PES_PIDS
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_GET_PES_PIDS for this command.
- .. row 3
- __u16[5]
- Undocumented. ``pids``
Undocumented.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,34 +15,17 @@ DMX_GET_STC ...@@ -15,34 +15,17 @@ DMX_GET_STC
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_GET_STC, struct dmx_stc *stc) .. c:function:: int ioctl( int fd, DMX_GET_STC, struct dmx_stc *stc)
:name: DMX_GET_STC
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open(). ``stc``
Pointer to the location where the stc is to be stored.
- .. row 2
- int request
- Equals DMX_GET_STC for this command.
- .. row 3
- struct dmx_stc \*stc
- Pointer to the location where the stc is to be stored.
Description Description
...@@ -63,8 +46,6 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set ...@@ -63,8 +46,6 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set
appropriately. The generic error codes are described at the appropriately. The generic error codes are described at the
:ref:`Generic Error Codes <gen-errors>` chapter. :ref:`Generic Error Codes <gen-errors>` chapter.
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
:stub-columns: 0 :stub-columns: 0
......
...@@ -15,34 +15,18 @@ DMX_REMOVE_PID ...@@ -15,34 +15,18 @@ DMX_REMOVE_PID
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = DMX_REMOVE_PID, __u16 *) .. c:function:: int ioctl(fd, DMX_REMOVE_PID, __u16 *pid)
:name: DMX_REMOVE_PID
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
``pid``
- .. row 1 PID of the PES filter to be removed.
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_REMOVE_PID for this command.
- .. row 3
- __u16 *
- PID of the PES filter to be removed.
Description Description
......
...@@ -15,35 +15,18 @@ DMX_SET_BUFFER_SIZE ...@@ -15,35 +15,18 @@ DMX_SET_BUFFER_SIZE
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_SET_BUFFER_SIZE, unsigned long size) .. c:function:: int ioctl( int fd, DMX_SET_BUFFER_SIZE, unsigned long size)
:name: DMX_SET_BUFFER_SIZE
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_SET_BUFFER_SIZE for this command.
- .. row 3
- unsigned long size
- Size of circular buffer.
``size``
Unsigned long size
Description Description
----------- -----------
......
...@@ -15,34 +15,18 @@ DMX_SET_FILTER ...@@ -15,34 +15,18 @@ DMX_SET_FILTER
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_SET_FILTER, struct dmx_sct_filter_params *params) .. c:function:: int ioctl( int fd, DMX_SET_FILTER, struct dmx_sct_filter_params *params)
:name: DMX_SET_FILTER
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_SET_FILTER for this command.
- .. row 3
- struct dmx_sct_filter_params \*params ``params``
- Pointer to structure containing filter parameters. Pointer to structure containing filter parameters.
Description Description
......
...@@ -15,34 +15,19 @@ DMX_SET_PES_FILTER ...@@ -15,34 +15,19 @@ DMX_SET_PES_FILTER
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_SET_PES_FILTER, struct dmx_pes_filter_params *params) .. c:function:: int ioctl( int fd, DMX_SET_PES_FILTER, struct dmx_pes_filter_params *params)
:name: DMX_SET_PES_FILTER
Arguments Arguments
--------- ---------
.. flat-table::
:header-rows: 0
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open(). ``fd``
File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
- .. row 2 ``params``
Pointer to structure containing filter parameters.
- int request
- Equals DMX_SET_PES_FILTER for this command.
- .. row 3
- struct dmx_pes_filter_params \*params
- Pointer to structure containing filter parameters.
Description Description
...@@ -61,7 +46,7 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set ...@@ -61,7 +46,7 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set
appropriately. The generic error codes are described at the appropriately. The generic error codes are described at the
:ref:`Generic Error Codes <gen-errors>` chapter. :ref:`Generic Error Codes <gen-errors>` chapter.
.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
......
...@@ -15,40 +15,25 @@ DMX_SET_SOURCE ...@@ -15,40 +15,25 @@ DMX_SET_SOURCE
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl(fd, int request = DMX_SET_SOURCE, dmx_source_t *) .. c:function:: int ioctl(fd, DMX_SET_SOURCE, struct dmx_source *src)
:name: DMX_SET_SOURCE
Arguments Arguments
--------- ---------
.. flat-table::
:header-rows: 0
:stub-columns: 0
``fd``
File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
- .. row 1 ``src``
Undocumented.
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_SET_SOURCE for this command.
- .. row 3
- dmx_source_t *
- Undocumented.
Description Description
----------- -----------
This ioctl is undocumented. Documentation is welcome. .. note:: This ioctl is undocumented. Documentation is welcome.
Return Value Return Value
......
...@@ -15,29 +15,15 @@ DMX_START ...@@ -15,29 +15,15 @@ DMX_START
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_START) .. c:function:: int ioctl( int fd, DMX_START)
:name: DMX_START
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_START for this command.
Description Description
----------- -----------
...@@ -53,7 +39,7 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set ...@@ -53,7 +39,7 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set
appropriately. The generic error codes are described at the appropriately. The generic error codes are described at the
:ref:`Generic Error Codes <gen-errors>` chapter. :ref:`Generic Error Codes <gen-errors>` chapter.
.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
.. flat-table:: .. flat-table::
:header-rows: 0 :header-rows: 0
......
...@@ -15,29 +15,15 @@ DMX_STOP ...@@ -15,29 +15,15 @@ DMX_STOP
Synopsis Synopsis
-------- --------
.. cpp:function:: int ioctl( int fd, int request = DMX_STOP) .. c:function:: int ioctl( int fd, DMX_STOP)
:name: DMX_STOP
Arguments Arguments
--------- ---------
.. flat-table:: ``fd``
:header-rows: 0 File descriptor returned by :c:func:`open() <dvb-dmx-open>`.
:stub-columns: 0
- .. row 1
- int fd
- File descriptor returned by a previous call to open().
- .. row 2
- int request
- Equals DMX_STOP for this command.
Description Description
----------- -----------
......
...@@ -6,14 +6,12 @@ ...@@ -6,14 +6,12 @@
Demux Data Types Demux Data Types
**************** ****************
.. _dmx-output-t:
Output for the demux Output for the demux
==================== ====================
.. c:type:: dmx_output
.. _dmx-output: .. tabularcolumns:: |p{5.0cm}|p{12.5cm}|
.. flat-table:: enum dmx_output .. flat-table:: enum dmx_output
:header-rows: 1 :header-rows: 1
...@@ -65,12 +63,10 @@ Output for the demux ...@@ -65,12 +63,10 @@ Output for the demux
from the DMX device. from the DMX device.
.. _dmx-input-t:
dmx_input_t dmx_input_t
=========== ===========
.. c:type:: dmx_input
.. code-block:: c .. code-block:: c
...@@ -81,11 +77,11 @@ dmx_input_t ...@@ -81,11 +77,11 @@ dmx_input_t
} dmx_input_t; } dmx_input_t;
.. _dmx-pes-type-t:
dmx_pes_type_t dmx_pes_type_t
============== ==============
.. c:type:: dmx_pes_type
.. code-block:: c .. code-block:: c
...@@ -119,11 +115,10 @@ dmx_pes_type_t ...@@ -119,11 +115,10 @@ dmx_pes_type_t
} dmx_pes_type_t; } dmx_pes_type_t;
.. _dmx-filter:
struct dmx_filter struct dmx_filter
================= =================
.. c:type:: dmx_filter
.. code-block:: c .. code-block:: c
...@@ -135,7 +130,7 @@ struct dmx_filter ...@@ -135,7 +130,7 @@ struct dmx_filter
} dmx_filter_t; } dmx_filter_t;
.. _dmx-sct-filter-params: .. c:type:: dmx_sct_filter_params
struct dmx_sct_filter_params struct dmx_sct_filter_params
============================ ============================
...@@ -156,11 +151,10 @@ struct dmx_sct_filter_params ...@@ -156,11 +151,10 @@ struct dmx_sct_filter_params
}; };
.. _dmx-pes-filter-params:
struct dmx_pes_filter_params struct dmx_pes_filter_params
============================ ============================
.. c:type:: dmx_pes_filter_params
.. code-block:: c .. code-block:: c
...@@ -174,11 +168,10 @@ struct dmx_pes_filter_params ...@@ -174,11 +168,10 @@ struct dmx_pes_filter_params
}; };
.. _dmx-event:
struct dmx_event struct dmx_event
================ ================
.. c:type:: dmx_event
.. code-block:: c .. code-block:: c
...@@ -193,11 +186,10 @@ struct dmx_event ...@@ -193,11 +186,10 @@ struct dmx_event
}; };
.. _dmx-stc:
struct dmx_stc struct dmx_stc
============== ==============
.. c:type:: dmx_stc
.. code-block:: c .. code-block:: c
...@@ -208,11 +200,10 @@ struct dmx_stc ...@@ -208,11 +200,10 @@ struct dmx_stc
}; };
.. _dmx-caps:
struct dmx_caps struct dmx_caps
=============== ===============
.. c:type:: dmx_caps
.. code-block:: c .. code-block:: c
...@@ -222,15 +213,14 @@ struct dmx_caps ...@@ -222,15 +213,14 @@ struct dmx_caps
} dmx_caps_t; } dmx_caps_t;
.. _dmx-source-t: enum dmx_source
===============
enum dmx_source_t
=================
.. c:type:: dmx_source
.. code-block:: c .. code-block:: c
typedef enum { typedef enum dmx_source {
DMX_SOURCE_FRONT0 = 0, DMX_SOURCE_FRONT0 = 0,
DMX_SOURCE_FRONT1, DMX_SOURCE_FRONT1,
DMX_SOURCE_FRONT2, DMX_SOURCE_FRONT2,
......
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _dtv-fe-stats: .. c:type:: dtv_fe_stats
******************* *******************
struct dtv_fe_stats struct dtv_fe_stats
......
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _dtv-properties: .. c:type:: dtv_properties
********************* *********************
struct dtv_properties struct dtv_properties
......
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _dtv-property: .. c:type:: dtv_property
******************* *******************
struct dtv_property struct dtv_property
......
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _dtv-stats: .. c:type:: dtv_stats
**************** ****************
struct dtv_stats struct dtv_stats
......
...@@ -17,7 +17,9 @@ using :ref:`FE_READ_STATUS`. ...@@ -17,7 +17,9 @@ using :ref:`FE_READ_STATUS`.
Signal statistics are provided via Signal statistics are provided via
:ref:`FE_GET_PROPERTY`. :ref:`FE_GET_PROPERTY`.
.. note:: Most statistics require the demodulator to be fully locked .. note::
Most statistics require the demodulator to be fully locked
(e. g. with FE_HAS_LOCK bit set). See (e. g. with FE_HAS_LOCK bit set). See
:ref:`Frontend statistics indicators <frontend-stat-properties>` for :ref:`Frontend statistics indicators <frontend-stat-properties>` for
more details. more details.
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _dvb-frontend-event: .. c:type:: dvb_frontend_event
*************** ***************
frontend events frontend events
......
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _dvb-frontend-parameters: .. c:type:: dvb_frontend_parameters
******************* *******************
frontend parameters frontend parameters
...@@ -49,7 +49,7 @@ frontends the ``frequency`` specifies the absolute frequency and is ...@@ -49,7 +49,7 @@ frontends the ``frequency`` specifies the absolute frequency and is
given in Hz. given in Hz.
.. _dvb-qpsk-parameters: .. c:type:: dvb_qpsk_parameters
QPSK parameters QPSK parameters
=============== ===============
...@@ -66,7 +66,7 @@ structure: ...@@ -66,7 +66,7 @@ structure:
}; };
.. _dvb-qam-parameters: .. c:type:: dvb_qam_parameters
QAM parameters QAM parameters
============== ==============
...@@ -83,7 +83,7 @@ for cable QAM frontend you use the ``dvb_qam_parameters`` structure: ...@@ -83,7 +83,7 @@ for cable QAM frontend you use the ``dvb_qam_parameters`` structure:
}; };
.. _dvb-vsb-parameters: .. c:type:: dvb_vsb_parameters
VSB parameters VSB parameters
============== ==============
...@@ -98,7 +98,7 @@ ATSC frontends are supported by the ``dvb_vsb_parameters`` structure: ...@@ -98,7 +98,7 @@ ATSC frontends are supported by the ``dvb_vsb_parameters`` structure:
}; };
.. _dvb-ofdm-parameters: .. c:type:: dvb_ofdm_parameters
OFDM parameters OFDM parameters
=============== ===============
......
...@@ -8,7 +8,9 @@ ...@@ -8,7 +8,9 @@
Part II - Digital TV API Part II - Digital TV API
######################## ########################
.. note:: This API is also known as **DVB API**, although it is generic .. note::
This API is also known as **DVB API**, although it is generic
enough to support all digital TV standards. enough to support all digital TV standards.
**Version 5.10** **Version 5.10**
......
...@@ -20,8 +20,10 @@ Also, the union didn't have any space left to be expanded without ...@@ -20,8 +20,10 @@ Also, the union didn't have any space left to be expanded without
breaking userspace. So, the decision was to deprecate the legacy breaking userspace. So, the decision was to deprecate the legacy
union/struct based approach, in favor of a properties set approach. union/struct based approach, in favor of a properties set approach.
.. note:: On Linux DVB API version 3, setting a frontend were done via .. note::
:ref:`struct dvb_frontend_parameters <dvb-frontend-parameters>`.
On Linux DVB API version 3, setting a frontend were done via
struct :c:type:`dvb_frontend_parameters`.
This got replaced on version 5 (also called "S2API", as this API were This got replaced on version 5 (also called "S2API", as this API were
added originally_enabled to provide support for DVB-S2), because the added originally_enabled to provide support for DVB-S2), because the
old API has a very limited support to new standards and new hardware. old API has a very limited support to new standards and new hardware.
......
...@@ -9,7 +9,9 @@ Examples ...@@ -9,7 +9,9 @@ Examples
In this section we would like to present some examples for using the DVB In this section we would like to present some examples for using the DVB
API. API.
..note:: This section is out of date, and the code below won't even .. note::
This section is out of date, and the code below won't even
compile. Please refer to the compile. Please refer to the
`libdvbv5 <https://linuxtv.org/docs/libdvbv5/index.html>`__ for `libdvbv5 <https://linuxtv.org/docs/libdvbv5/index.html>`__ for
updated/recommended examples. updated/recommended examples.
......
.. -*- coding: utf-8; mode: rst -*- .. -*- coding: utf-8; mode: rst -*-
.. _fe-bandwidth-t:
****************** ******************
Frontend bandwidth Frontend bandwidth
****************** ******************
.. c:type:: fe_bandwidth
.. _fe-bandwidth:
.. flat-table:: enum fe_bandwidth .. flat-table:: enum fe_bandwidth
:header-rows: 1 :header-rows: 1
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment