€•=Œsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ@/translations/zh_CN/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ@/translations/zh_TW/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ@/translations/it_IT/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ@/translations/ja_JP/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ@/translations/ko_KR/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒPortuguese (Brazilian)”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ@/translations/pt_BR/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ@/translations/sp_SP/userspace-api/media/mediactl/media-func-open”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ8SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later”h]”hŒ8SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later”…””}”hh·sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1hµhhh²hh³ŒZ/var/lib/git/docbuild/linux/Documentation/userspace-api/media/mediactl/media-func-open.rst”h´KubhŒtarget”“”)”}”(hŒ.. _media-func-open:”h]”h}”(h]”h ]”h"]”h$]”h&]”Œrefid”Œmedia-func-open”uh1hÈh´Khhh²hh³hÇubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒ media open()”h]”hŒ media open()”…””}”(hhÝh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÛhhØh²hh³hÇh´Kubh×)”}”(hhh]”(hÜ)”}”(hŒName”h]”hŒName”…””}”(hhîh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÛhhëh²hh³hÇh´K ubhŒ paragraph”“”)”}”(hŒ media-open - Open a media device”h]”hŒ media-open - Open a media device”…””}”(hhþh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K hhëh²hubeh}”(h]”Œname”ah ]”h"]”Œname”ah$]”h&]”uh1hÖhhØh²hh³hÇh´K ubh×)”}”(hhh]”(hÜ)”}”(hŒSynopsis”h]”hŒSynopsis”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÛhjh²hh³hÇh´KubhŒ literal_block”“”)”}”(hŒ#include ”h]”hŒ#include ”…””}”hj'sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆŒforce”‰Œlanguage”Œc”Œhighlight_args”}”uh1j%h³hÇh´Khjh²hubhŒindex”“”)”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œentries”]”(Œsingle”ŒMC.open (C function)”Œ c.MC.open”hNt”auh1j:hjh²hh³Nh´NubhŒdesc”“”)”}”(hhh]”(hŒdesc_signature”“”)”}”(hŒ.int open( const char *device_name, int flags )”h]”hŒdesc_signature_line”“”)”}”(hŒ,int open(const char *device_name, int flags)”h]”(hŒdesc_sig_keyword_type”“”)”}”(hŒint”h]”hŒint”…””}”(hj^h²hh³Nh´Nubah}”(h]”h ]”Œkt”ah"]”h$]”h&]”uh1j\hjXh²hh³hÇh´KubhŒdesc_sig_space”“”)”}”(hŒ ”h]”hŒ ”…””}”(hjoh²hh³Nh´Nubah}”(h]”h ]”Œw”ah"]”h$]”h&]”uh1jmhjXh²hh³hÇh´KubhŒ desc_name”“”)”}”(hŒopen”h]”hŒ desc_sig_name”“”)”}”(hŒopen”h]”hŒopen”…””}”(hj†h²hh³Nh´Nubah}”(h]”h ]”Œn”ah"]”h$]”h&]”uh1j„hj€ubah}”(h]”h ]”(Œsig-name”Œdescname”eh"]”h$]”h&]”hÅhÆuh1j~hjXh²hh³hÇh´KubhŒdesc_parameterlist”“”)”}”(hŒ$(const char *device_name, int flags)”h]”(hŒdesc_parameter”“”)”}”(hŒconst char *device_name”h]”(hŒdesc_sig_keyword”“”)”}”(hŒconst”h]”hŒconst”…””}”(hj«h²hh³Nh´Nubah}”(h]”h ]”Œk”ah"]”h$]”h&]”uh1j©hj¥ubjn)”}”(hŒ ”h]”hŒ ”…””}”(hjºh²hh³Nh´Nubah}”(h]”h ]”jzah"]”h$]”h&]”uh1jmhj¥ubj])”}”(hŒchar”h]”hŒchar”…””}”(hjÈh²hh³Nh´Nubah}”(h]”h ]”jiah"]”h$]”h&]”uh1j\hj¥ubjn)”}”(hŒ ”h]”hŒ ”…””}”(hjÖh²hh³Nh´Nubah}”(h]”h ]”jzah"]”h$]”h&]”uh1jmhj¥ubhŒdesc_sig_punctuation”“”)”}”(hŒ*”h]”hŒ*”…””}”(hjæh²hh³Nh´Nubah}”(h]”h ]”Œp”ah"]”h$]”h&]”uh1jähj¥ubj…)”}”(hŒ device_name”h]”hŒ device_name”…””}”(hjõh²hh³Nh´Nubah}”(h]”h ]”j‘ah"]”h$]”h&]”uh1j„hj¥ubeh}”(h]”h ]”h"]”h$]”h&]”Œnoemph”ˆhÅhÆuh1j£hjŸubj¤)”}”(hŒ int flags”h]”(j])”}”(hŒint”h]”hŒint”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”jiah"]”h$]”h&]”uh1j\hj ubjn)”}”(hŒ ”h]”hŒ ”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”jzah"]”h$]”h&]”uh1jmhj ubj…)”}”(hŒflags”h]”hŒflags”…””}”(hj*h²hh³Nh´Nubah}”(h]”h ]”j‘ah"]”h$]”h&]”uh1j„hj ubeh}”(h]”h ]”h"]”h$]”h&]”Œnoemph”ˆhÅhÆuh1j£hjŸubeh}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1jhjXh²hh³hÇh´Kubeh}”(h]”h ]”h"]”h$]”h&]”hÅhÆŒ add_permalink”ˆuh1jVŒsphinx_line_type”Œ declarator”hjRh²hh³hÇh´Kubah}”(h]”jIah ]”(Œsig”Œ sig-object”eh"]”h$]”h&]”Œ is_multiline”ˆŒ _toc_parts”)Œ _toc_name”huh1jPh³hÇh´KhjMh²hubhŒ desc_content”“”)”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”uh1jYhjMh²hh³hÇh´Kubeh}”(h]”h ]”(j7Œfunction”eh"]”h$]”h&]”Œdomain”j7Œobjtype”jgŒdesctype”jgŒnoindex”‰Œ noindexentry”‰Œnocontentsentry”‰uh1jKh²hhjh³Nh´Nubeh}”(h]”Œsynopsis”ah ]”h"]”Œsynopsis”ah$]”h&]”uh1hÖhhØh²hh³hÇh´Kubh×)”}”(hhh]”(hÜ)”}”(hŒ Arguments”h]”hŒ Arguments”…””}”(hj|h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÛhjyh²hh³hÇh´KubhŒdefinition_list”“”)”}”(hhh]”(hŒdefinition_list_item”“”)”}”(hŒ%``device_name`` Device to be opened. ”h]”(hŒterm”“”)”}”(hŒ``device_name``”h]”hŒliteral”“”)”}”(hj™h]”hŒ device_name”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j›hj—ubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´Khj‘ubhŒ definition”“”)”}”(hhh]”hý)”}”(hŒDevice to be opened.”h]”hŒDevice to be opened.”…””}”(hjµh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´Khj²ubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hj‘ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´KhjŒubj)”}”(hŒi``flags`` Open flags. Access mode must be either ``O_RDONLY`` or ``O_RDWR``. Other flags have no effect. ”h]”(j–)”}”(hŒ ``flags``”h]”jœ)”}”(hjÕh]”hŒflags”…””}”(hj×h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j›hjÓubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´K hjÏubj±)”}”(hhh]”hý)”}”(hŒ^Open flags. Access mode must be either ``O_RDONLY`` or ``O_RDWR``. Other flags have no effect.”h]”(hŒ'Open flags. Access mode must be either ”…””}”(hjíh²hh³Nh´Nubjœ)”}”(hŒ ``O_RDONLY``”h]”hŒO_RDONLY”…””}”(hjõh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j›hjíubhŒ or ”…””}”(hjíh²hh³Nh´Nubjœ)”}”(hŒ ``O_RDWR``”h]”hŒO_RDWR”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j›hjíubhŒ. Other flags have no effect.”…””}”(hjíh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´Khjêubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hjÏubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´K hjŒh²hubeh}”(h]”h ]”h"]”h$]”h&]”uh1jŠhjyh²hh³hÇh´Nubeh}”(h]”Œ arguments”ah ]”h"]”Œ arguments”ah$]”h&]”uh1hÖhhØh²hh³hÇh´Kubh×)”}”(hhh]”(hÜ)”}”(hŒ Description”h]”hŒ Description”…””}”(hj<h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÛhj9h²hh³hÇh´K#ubhý)”}”(hŒ¤To open a media device applications call :c:func:`open()` with the desired device name. The function has no side effects; the device configuration remain unchanged.”h]”(hŒ)To open a media device applications call ”…””}”(hjJh²hh³Nh´Nubh)”}”(hŒ:c:func:`open()`”h]”jœ)”}”(hjTh]”hŒopen()”…””}”(hjVh²hh³Nh´Nubah}”(h]”h ]”(Œxref”j7Œc-func”eh"]”h$]”h&]”uh1j›hjRubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”Œ,userspace-api/media/mediactl/media-func-open”Œ refdomain”j7Œreftype”Œfunc”Œ refexplicit”‰Œrefwarn”‰Œ c:parent_key”Œsphinx.domains.c”Œ LookupKey”“”)”}”Œdata”]”jsŒ ASTIdentifier”“”)”}”Œ identifier”ŒMC”sbN†”asbŒ reftarget”Œopen”uh1hh³hÇh´K%hjJubhŒk with the desired device name. The function has no side effects; the device configuration remain unchanged.”…””}”(hjJh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K%hj9h²hubhý)”}”(hŒŽWhen the device is opened in read-only mode, attempts to modify its configuration will result in an error, and ``errno`` will be set to EBADF.”h]”(hŒoWhen the device is opened in read-only mode, attempts to modify its configuration will result in an error, and ”…””}”(hjh²hh³Nh´Nubjœ)”}”(hŒ ``errno``”h]”hŒerrno”…””}”(hj•h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j›hjubhŒ will be set to EBADF.”…””}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K)hj9h²hubeh}”(h]”Œ description”ah ]”h"]”Œ description”ah$]”h&]”uh1hÖhhØh²hh³hÇh´K#ubh×)”}”(hhh]”(hÜ)”}”(hŒ Return Value”h]”hŒ Return Value”…””}”(hj¸h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÛhjµh²hh³hÇh´K.ubhý)”}”(hŒ”:c:func:`open()` returns the new file descriptor on success. On error, -1 is returned, and ``errno`` is set appropriately. Possible error codes are:”h]”(h)”}”(hŒ:c:func:`open()`”h]”jœ)”}”(hjÌh]”hŒopen()”…””}”(hjÎh²hh³Nh´Nubah}”(h]”h ]”(j`j7Œc-func”eh"]”h$]”h&]”uh1j›hjÊubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”jlŒ refdomain”j7Œreftype”Œfunc”Œ refexplicit”‰Œrefwarn”‰jrjvjŒopen”uh1hh³hÇh´K0hjÆubhŒK returns the new file descriptor on success. On error, -1 is returned, and ”…””}”(hjÆh²hh³Nh´Nubjœ)”}”(hŒ ``errno``”h]”hŒerrno”…””}”(hjíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j›hjÆubhŒ0 is set appropriately. Possible error codes are:”…””}”(hjÆh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K0hjµh²hubj‹)”}”(hhh]”(j)”}”(hŒ8EACCES The requested access to the file is not allowed. ”h]”(j–)”}”(hŒEACCES”h]”hŒEACCES”…””}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´K5hjubj±)”}”(hhh]”hý)”}”(hŒ0The requested access to the file is not allowed.”h]”hŒ0The requested access to the file is not allowed.”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K5hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´K5hjubj)”}”(hŒAEMFILE The process already has the maximum number of files open. ”h]”(j–)”}”(hŒEMFILE”h]”hŒEMFILE”…””}”(hj;h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´K8hj7ubj±)”}”(hhh]”hý)”}”(hŒ9The process already has the maximum number of files open.”h]”hŒ9The process already has the maximum number of files open.”…””}”(hjLh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K8hjIubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hj7ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´K8hjh²hubj)”}”(hŒLENFILE The system limit on the total number of open files has been reached. ”h]”(j–)”}”(hŒENFILE”h]”hŒENFILE”…””}”(hjjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´K;hjfubj±)”}”(hhh]”hý)”}”(hŒDThe system limit on the total number of open files has been reached.”h]”hŒDThe system limit on the total number of open files has been reached.”…””}”(hj{h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K;hjxubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hjfubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´K;hjh²hubj)”}”(hŒ1ENOMEM Insufficient kernel memory was available. ”h]”(j–)”}”(hŒENOMEM”h]”hŒENOMEM”…””}”(hj™h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´K>hj•ubj±)”}”(hhh]”hý)”}”(hŒ)Insufficient kernel memory was available.”h]”hŒ)Insufficient kernel memory was available.”…””}”(hjªh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´K>hj§ubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hj•ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´K>hjh²hubj)”}”(hŒAENXIO No device corresponding to this device special file exists.”h]”(j–)”}”(hŒENXIO”h]”hŒENXIO”…””}”(hjÈh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j•h³hÇh´K@hjÄubj±)”}”(hhh]”hý)”}”(hŒ;No device corresponding to this device special file exists.”h]”hŒ;No device corresponding to this device special file exists.”…””}”(hjÙh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hüh³hÇh´KAhjÖubah}”(h]”h ]”h"]”h$]”h&]”uh1j°hjÄubeh}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÇh´K@hjh²hubeh}”(h]”h ]”h"]”h$]”h&]”uh1jŠhjµh²hh³hÇh´Nubeh}”(h]”Œ return-value”ah ]”h"]”Œ return value”ah$]”h&]”uh1hÖhhØh²hh³hÇh´K.ubeh}”(h]”(Œ media-open”hÕeh ]”h"]”(Œ media open()”Œmedia-func-open”eh$]”h&]”uh1hÖhhh²hh³hÇh´KŒexpect_referenced_by_name”}”jhÊsŒexpect_referenced_by_id”}”hÕhÊsubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”hÇuh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(hÛNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j1Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”hÇŒ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”hÕ]”hÊasŒnameids”}”(jhÕjjjjjvjsj6j3j²j¯jþjûuŒ nametypes”}”(jˆj‰j‰jv‰j6‰j²‰jþ‰uh}”(hÕhØjhØjhëjsjjIjRj3jyj¯j9jûjµuŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”hŒsystem_message”“”)”}”(hhh]”hý)”}”(hhh]”hŒ5Hyperlink target "media-func-open" is not referenced.”…””}”hj›sbah}”(h]”h ]”h"]”h$]”h&]”uh1hühj˜ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”ŒINFO”Œsource”hÇŒline”Kuh1j–ubaŒ transformer”NŒ include_log”]”Œ decoration”Nh²hub.