Back to home page

OSCL-LXR

 
 

    


0001 .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
0002 .. c:namespace:: DTV.video
0003 
0004 .. _video_fopen:
0005 
0006 ================
0007 dvb video open()
0008 ================
0009 
0010 Name
0011 ----
0012 
0013 dvb video open()
0014 
0015 .. attention:: This ioctl is deprecated.
0016 
0017 Synopsis
0018 --------
0019 
0020 .. c:function:: int open(const char *deviceName, int flags)
0021 
0022 Arguments
0023 ---------
0024 
0025 .. flat-table::
0026     :header-rows:  0
0027     :stub-columns: 0
0028 
0029     -  .. row 1
0030 
0031        -  const char \*deviceName
0032 
0033        -  Name of specific video device.
0034 
0035     -  .. row 2
0036 
0037        -  int flags
0038 
0039        -  A bit-wise OR of the following flags:
0040 
0041     -  .. row 3
0042 
0043        -
0044        -  O_RDONLY read-only access
0045 
0046     -  .. row 4
0047 
0048        -
0049        -  O_RDWR read/write access
0050 
0051     -  .. row 5
0052 
0053        -
0054        -  O_NONBLOCK open in non-blocking mode
0055 
0056     -  .. row 6
0057 
0058        -
0059        -  (blocking mode is the default)
0060 
0061 Description
0062 -----------
0063 
0064 This system call opens a named video device (e.g.
0065 /dev/dvb/adapter0/video0) for subsequent use.
0066 
0067 When an open() call has succeeded, the device will be ready for use. The
0068 significance of blocking or non-blocking mode is described in the
0069 documentation for functions where there is a difference. It does not
0070 affect the semantics of the open() call itself. A device opened in
0071 blocking mode can later be put into non-blocking mode (and vice versa)
0072 using the F_SETFL command of the fcntl system call. This is a standard
0073 system call, documented in the Linux manual page for fcntl. Only one
0074 user can open the Video Device in O_RDWR mode. All other attempts to
0075 open the device in this mode will fail, and an error-code will be
0076 returned. If the Video Device is opened in O_RDONLY mode, the only
0077 ioctl call that can be used is VIDEO_GET_STATUS. All other call will
0078 return an error code.
0079 
0080 Return Value
0081 ------------
0082 
0083 .. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
0084 
0085 .. flat-table::
0086     :header-rows:  0
0087     :stub-columns: 0
0088 
0089     -  .. row 1
0090 
0091        -  ``ENODEV``
0092 
0093        -  Device driver not loaded/available.
0094 
0095     -  .. row 2
0096 
0097        -  ``EINTERNAL``
0098 
0099        -  Internal error.
0100 
0101     -  .. row 3
0102 
0103        -  ``EBUSY``
0104 
0105        -  Device or resource busy.
0106 
0107     -  .. row 4
0108 
0109        -  ``EINVAL``
0110 
0111        -  Invalid argument.