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>`.
34 .. note:: This documents the proposed CEC API. This API is not yet finalized
35 and is currently only available as a staging kernel module.
37 All cec devices must support :ref:`ioctl CEC_ADAP_G_CAPS <CEC_ADAP_G_CAPS>`. To query
38 device information, applications call the ioctl with a pointer to a
39 struct :ref:`cec_caps <cec-caps>`. The driver fills the structure and
40 returns the information to the application. The ioctl never fails.
45 .. flat-table:: struct cec_caps
57 - The name of the cec adapter driver.
65 - The name of this CEC adapter. The combination ``driver`` and
66 ``name`` must be unique.
74 - The capabilities of the CEC adapter, see
75 :ref:`cec-capabilities`.
83 - CEC Framework API version, formatted with the ``KERNEL_VERSION()``
90 .. flat-table:: CEC Capabilities Flags
96 - .. _`CEC-CAP-PHYS-ADDR`:
98 - ``CEC_CAP_PHYS_ADDR``
102 - Userspace has to configure the physical address by calling
103 :ref:`ioctl CEC_ADAP_S_PHYS_ADDR <CEC_ADAP_S_PHYS_ADDR>`. If
104 this capability isn't set, then setting the physical address is
105 handled by the kernel whenever the EDID is set (for an HDMI
106 receiver) or read (for an HDMI transmitter).
108 - .. _`CEC-CAP-LOG-ADDRS`:
110 - ``CEC_CAP_LOG_ADDRS``
114 - Userspace has to configure the logical addresses by calling
115 :ref:`ioctl CEC_ADAP_S_LOG_ADDRS <CEC_ADAP_S_LOG_ADDRS>`. If
116 this capability isn't set, then the kernel will have configured
119 - .. _`CEC-CAP-TRANSMIT`:
121 - ``CEC_CAP_TRANSMIT``
125 - Userspace can transmit CEC messages by calling
126 :ref:`ioctl CEC_TRANSMIT <CEC_TRANSMIT>`. This implies that
127 userspace can be a follower as well, since being able to transmit
128 messages is a prerequisite of becoming a follower. If this
129 capability isn't set, then the kernel will handle all CEC
130 transmits and process all CEC messages it receives.
132 - .. _`CEC-CAP-PASSTHROUGH`:
134 - ``CEC_CAP_PASSTHROUGH``
138 - Userspace can use the passthrough mode by calling
139 :ref:`ioctl CEC_S_MODE <CEC_S_MODE>`.
147 - This adapter supports the remote control protocol.
149 - .. _`CEC-CAP-MONITOR-ALL`:
151 - ``CEC_CAP_MONITOR_ALL``
155 - The CEC hardware can monitor all messages, not just directed and
163 On success 0 is returned, on error -1 and the ``errno`` variable is set
164 appropriately. The generic error codes are described at the
165 :ref:`Generic Error Codes <gen-errors>` chapter.