€•/Œ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/bpf/fs_kfuncs”Œ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/bpf/fs_kfuncs”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ!/translations/it_IT/bpf/fs_kfuncs”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ!/translations/ja_JP/bpf/fs_kfuncs”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ!/translations/ko_KR/bpf/fs_kfuncs”Œ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/bpf/fs_kfuncs”Œ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Œ SPDX-License-Identifier: GPL-2.0”h]”hŒ SPDX-License-Identifier: GPL-2.0”…””}”hh£sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1h¡hhhžhhŸŒ;/var/lib/git/docbuild/linux/Documentation/bpf/fs_kfuncs.rst”h KubhŒtarget”“”)”}”(hŒ.. _fs_kfuncs-header-label:”h]”h}”(h]”h ]”h"]”h$]”h&]”Œrefid”Œfs-kfuncs-header-label”uh1h´h KhhhžhhŸh³ubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒBPF filesystem kfuncs”h]”hŒBPF filesystem kfuncs”…””}”(hhÉhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÇhhÄhžhhŸh³h KubhŒ paragraph”“”)”}”(hŒwBPF LSM programs need to access filesystem data from LSM hooks. The following BPF kfuncs can be used to get these data.”h]”hŒwBPF LSM programs need to access filesystem data from LSM hooks. The following BPF kfuncs can be used to get these data.”…””}”(hhÙhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h K hhÄhžhubhŒ block_quote”“”)”}”(hŒ<* ``bpf_get_file_xattr()`` * ``bpf_get_fsverity_digest()`` ”h]”hŒ bullet_list”“”)”}”(hhh]”(hŒ list_item”“”)”}”(hŒ``bpf_get_file_xattr()`` ”h]”hØ)”}”(hŒ``bpf_get_file_xattr()``”h]”hŒliteral”“”)”}”(hhúh]”hŒbpf_get_file_xattr()”…””}”(hhþhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hühhøubah}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h K hhôubah}”(h]”h ]”h"]”h$]”h&]”uh1hòhhïubhó)”}”(hŒ``bpf_get_fsverity_digest()`` ”h]”hØ)”}”(hŒ``bpf_get_fsverity_digest()``”h]”hý)”}”(hjh]”hŒbpf_get_fsverity_digest()”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hühjubah}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h Khjubah}”(h]”h ]”h"]”h$]”h&]”uh1hòhhïubeh}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ*”uh1híhŸh³h K hhéubah}”(h]”h ]”h"]”h$]”h&]”uh1hçhŸh³h K hhÄhžhubhØ)”}”(hŒ=To avoid recursions, these kfuncs follow the following rules:”h]”hŒ=To avoid recursions, these kfuncs follow the following rules:”…””}”(hjFhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h KhhÄhžhubhŒenumerated_list”“”)”}”(hhh]”(hó)”}”(hŒ6These kfuncs are only permitted from BPF LSM function.”h]”hØ)”}”(hj[h]”hŒ6These kfuncs are only permitted from BPF LSM function.”…””}”(hj]hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h KhjYubah}”(h]”h ]”h"]”h$]”h&]”uh1hòhjVhžhhŸh³h Nubhó)”}”(hŒËThese kfuncs should not call into other LSM hooks, i.e. security_*(). For example, ``bpf_get_file_xattr()`` does not use ``vfs_getxattr()``, because the latter calls LSM hook ``security_inode_getxattr``.”h]”hØ)”}”(hŒËThese kfuncs should not call into other LSM hooks, i.e. security_*(). For example, ``bpf_get_file_xattr()`` does not use ``vfs_getxattr()``, because the latter calls LSM hook ``security_inode_getxattr``.”h]”(hŒSThese kfuncs should not call into other LSM hooks, i.e. security_*(). For example, ”…””}”(hjthžhhŸNh Nubhý)”}”(hŒ``bpf_get_file_xattr()``”h]”hŒbpf_get_file_xattr()”…””}”(hj|hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hühjtubhŒ does not use ”…””}”(hjthžhhŸNh Nubhý)”}”(hŒ``vfs_getxattr()``”h]”hŒvfs_getxattr()”…””}”(hjŽhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hühjtubhŒ$, because the latter calls LSM hook ”…””}”(hjthžhhŸNh Nubhý)”}”(hŒ``security_inode_getxattr``”h]”hŒsecurity_inode_getxattr”…””}”(hj hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hühjtubhŒ.”…””}”(hjthžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h Khjpubah}”(h]”h ]”h"]”h$]”h&]”uh1hòhjVhžhhŸh³h Nubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œarabic”Œprefix”hŒsuffix”Œ.”uh1jThhÄhžhhŸh³h Kubeh}”(h]”(Œbpf-filesystem-kfuncs”hÁeh ]”h"]”(Œbpf filesystem kfuncs”Œfs_kfuncs-header-label”eh$]”h&]”uh1hÂhhhžhhŸh³h KŒexpect_referenced_by_name”}”jÏh¶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”jùŒ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”}”(jÏhÁjÎjËuŒ nametypes”}”(jψjΉuh}”(hÁhÄjËhÄ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Œ