Merge remote-tracking branch 'selinux/next'
[deliverable/linux.git] / Documentation / media / uapi / dvb / ca-fopen.rst
1 .. -*- coding: utf-8; mode: rst -*-
2
3 .. _ca_fopen:
4
5 =============
6 DVB CA open()
7 =============
8
9 Name
10 ----
11
12 DVB CA open()
13
14
15 Synopsis
16 --------
17
18 .. c:function:: int open(const char *name, int flags)
19 :name: dvb-ca-open
20
21
22 Arguments
23 ---------
24
25 ``name``
26 Name of specific DVB CA device.
27
28 ``flags``
29 A bit-wise OR of the following flags:
30
31 .. flat-table::
32 :header-rows: 0
33 :stub-columns: 0
34
35 -
36 - O_RDONLY
37 - read-only access
38
39 -
40 - O_RDWR
41 - read/write access
42
43 -
44 - O_NONBLOCK
45 - open in non-blocking mode
46 (blocking mode is the default)
47
48
49 Description
50 -----------
51
52 This system call opens a named ca device (e.g. /dev/ost/ca) for
53 subsequent use.
54
55 When an open() call has succeeded, the device will be ready for use. The
56 significance of blocking or non-blocking mode is described in the
57 documentation for functions where there is a difference. It does not
58 affect the semantics of the open() call itself. A device opened in
59 blocking mode can later be put into non-blocking mode (and vice versa)
60 using the F_SETFL command of the fcntl system call. This is a standard
61 system call, documented in the Linux manual page for fcntl. Only one
62 user can open the CA Device in O_RDWR mode. All other attempts to open
63 the device in this mode will fail, and an error code will be returned.
64
65
66 Return Value
67 ------------
68
69 .. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
70
71 .. flat-table::
72 :header-rows: 0
73 :stub-columns: 0
74
75
76 - .. row 1
77
78 - ``ENODEV``
79
80 - Device driver not loaded/available.
81
82 - .. row 2
83
84 - ``EINTERNAL``
85
86 - Internal error.
87
88 - .. row 3
89
90 - ``EBUSY``
91
92 - Device or resource busy.
93
94 - .. row 4
95
96 - ``EINVAL``
97
98 - Invalid argument.
This page took 0.032739 seconds and 5 git commands to generate.