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