xref: /OK3568_Linux_fs/kernel/Documentation/userspace-api/media/dvb/audio-set-id.rst (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
2*4882a593Smuzhiyun.. c:namespace:: DTV.audio
3*4882a593Smuzhiyun
4*4882a593Smuzhiyun.. _AUDIO_SET_ID:
5*4882a593Smuzhiyun
6*4882a593Smuzhiyun============
7*4882a593SmuzhiyunAUDIO_SET_ID
8*4882a593Smuzhiyun============
9*4882a593Smuzhiyun
10*4882a593SmuzhiyunName
11*4882a593Smuzhiyun----
12*4882a593Smuzhiyun
13*4882a593SmuzhiyunAUDIO_SET_ID
14*4882a593Smuzhiyun
15*4882a593Smuzhiyun.. attention:: This ioctl is deprecated
16*4882a593Smuzhiyun
17*4882a593SmuzhiyunSynopsis
18*4882a593Smuzhiyun--------
19*4882a593Smuzhiyun
20*4882a593Smuzhiyun.. c:macro:: AUDIO_SET_ID
21*4882a593Smuzhiyun
22*4882a593Smuzhiyun``int ioctl(int fd, AUDIO_SET_ID, int id)``
23*4882a593Smuzhiyun
24*4882a593SmuzhiyunArguments
25*4882a593Smuzhiyun---------
26*4882a593Smuzhiyun
27*4882a593Smuzhiyun.. flat-table::
28*4882a593Smuzhiyun    :header-rows:  0
29*4882a593Smuzhiyun    :stub-columns: 0
30*4882a593Smuzhiyun
31*4882a593Smuzhiyun    -
32*4882a593Smuzhiyun
33*4882a593Smuzhiyun       -  int fd
34*4882a593Smuzhiyun
35*4882a593Smuzhiyun       -  File descriptor returned by a previous call to open().
36*4882a593Smuzhiyun
37*4882a593Smuzhiyun    -
38*4882a593Smuzhiyun
39*4882a593Smuzhiyun       -  int id
40*4882a593Smuzhiyun
41*4882a593Smuzhiyun       -  audio sub-stream id
42*4882a593Smuzhiyun
43*4882a593SmuzhiyunDescription
44*4882a593Smuzhiyun-----------
45*4882a593Smuzhiyun
46*4882a593SmuzhiyunThis ioctl selects which sub-stream is to be decoded if a program or
47*4882a593Smuzhiyunsystem stream is sent to the video device. If no audio stream type is
48*4882a593Smuzhiyunset the id has to be in [0xC0,0xDF] for MPEG sound, in [0x80,0x87] for
49*4882a593SmuzhiyunAC3 and in [0xA0,0xA7] for LPCM. More specifications may follow for
50*4882a593Smuzhiyunother stream types. If the stream type is set the id just specifies the
51*4882a593Smuzhiyunsubstream id of the audio stream and only the first 5 bits are
52*4882a593Smuzhiyunrecognized.
53*4882a593Smuzhiyun
54*4882a593SmuzhiyunReturn Value
55*4882a593Smuzhiyun------------
56*4882a593Smuzhiyun
57*4882a593SmuzhiyunOn success 0 is returned, on error -1 and the ``errno`` variable is set
58*4882a593Smuzhiyunappropriately. The generic error codes are described at the
59*4882a593Smuzhiyun:ref:`Generic Error Codes <gen-errors>` chapter.
60