1 .. -*- coding: utf-8; mode: rst -*-
12 CEC_ADAP_G_CAPS - Query device capabilities
17 .. cpp:function:: int ioctl( int fd, int request, struct cec_caps *argp )
23 File descriptor returned by :ref:`open() <cec-func-open>`.
36 This documents the proposed CEC API. This API is not yet finalized
37 and is currently only available as a staging kernel module.
39 All cec devices must support :ref:`ioctl CEC_ADAP_G_CAPS <CEC_ADAP_G_CAPS>`. To query
40 device information, applications call the ioctl with a pointer to a
41 struct :ref:`cec_caps <cec-caps>`. The driver fills the structure and
42 returns the information to the application. The ioctl never fails.
47 .. tabularcolumns:: |p{1.0cm}|p{1.0cm}|p{15.5cm}|
49 .. flat-table:: struct cec_caps
61 - The name of the cec adapter driver.
69 - The name of this CEC adapter. The combination ``driver`` and
70 ``name`` must be unique.
78 - The capabilities of the CEC adapter, see
79 :ref:`cec-capabilities`.
87 - CEC Framework API version, formatted with the ``KERNEL_VERSION()``
94 .. tabularcolumns:: |p{4.4cm}|p{1.5cm}|p{11.6cm}|
96 .. flat-table:: CEC Capabilities Flags
102 - .. _`CEC-CAP-PHYS-ADDR`:
104 - ``CEC_CAP_PHYS_ADDR``
108 - Userspace has to configure the physical address by calling
109 :ref:`ioctl CEC_ADAP_S_PHYS_ADDR <CEC_ADAP_S_PHYS_ADDR>`. If
110 this capability isn't set, then setting the physical address is
111 handled by the kernel whenever the EDID is set (for an HDMI
112 receiver) or read (for an HDMI transmitter).
114 - .. _`CEC-CAP-LOG-ADDRS`:
116 - ``CEC_CAP_LOG_ADDRS``
120 - Userspace has to configure the logical addresses by calling
121 :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>`. If
122 this capability isn't set, then the kernel will have configured
125 - .. _`CEC-CAP-TRANSMIT`:
127 - ``CEC_CAP_TRANSMIT``
131 - Userspace can transmit CEC messages by calling
132 :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>`. This implies that
133 userspace can be a follower as well, since being able to transmit
134 messages is a prerequisite of becoming a follower. If this
135 capability isn't set, then the kernel will handle all CEC
136 transmits and process all CEC messages it receives.
138 - .. _`CEC-CAP-PASSTHROUGH`:
140 - ``CEC_CAP_PASSTHROUGH``
144 - Userspace can use the passthrough mode by calling
145 :ref:`ioctl CEC_S_MODE <CEC_S_MODE>`.
153 - This adapter supports the remote control protocol.
155 - .. _`CEC-CAP-MONITOR-ALL`:
157 - ``CEC_CAP_MONITOR_ALL``
161 - The CEC hardware can monitor all messages, not just directed and
169 On success 0 is returned, on error -1 and the ``errno`` variable is set
170 appropriately. The generic error codes are described at the
171 :ref:`Generic Error Codes <gen-errors>` chapter.