€•¦TŒ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”Œ5/translations/zh_CN/networking/devlink/devlink-shared”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)�”}”(hhh]”hŒChinese (Traditional)”…”�”}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ5/translations/zh_TW/networking/devlink/devlink-shared”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒItalian”…”�”}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ5/translations/it_IT/networking/devlink/devlink-shared”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒJapanese”…”�”}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ5/translations/ja_JP/networking/devlink/devlink-shared”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒKorean”…”�”}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ5/translations/ko_KR/networking/devlink/devlink-shared”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒPortuguese (Brazilian)”…”�”}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ5/translations/pt_BR/networking/devlink/devlink-shared”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒSpanish”…”�”}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ5/translations/sp_SP/networking/devlink/devlink-shared”Œ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³ŒO/var/lib/git/docbuild/linux/Documentation/networking/devlink/devlink-shared.rst”h´KubhŒsection”“”)�”}”(hhh]”(hŒtitle”“”)�”}”(hŒDevlink Shared Instances”h]”hŒDevlink Shared Instances”…”�”}”(hhÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhhÊh²hh³hÇh´KubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒOverview”h]”hŒOverview”…”�”}”(hhàh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhhÝh²hh³hÇh´KubhŒ paragraph”“”)�”}”(hŒ‡Shared devlink instances allow multiple physical functions (PFs) on the same chip to share a devlink instance for chip-wide operations.”h]”hŒ‡Shared devlink instances allow multiple physical functions (PFs) on the same chip to share a devlink instance for chip-wide operations.”…”�”}”(hhðh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K hhÝh²hubhï)�”}”(hŒãMultiple PFs may reside on the same physical chip, running a single firmware. Some of the resources and configurations may be shared among these PFs. The shared devlink instance provides an object to pin configuration knobs on.”h]”hŒãMultiple PFs may reside on the same physical chip, running a single firmware. Some of the resources and configurations may be shared among these PFs. The shared devlink instance provides an object to pin configuration knobs on.”…”�”}”(hhþh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K hhÝh²hubhï)�”}”(hŒ$There are two possible usage models:”h]”hŒ$There are two possible usage models:”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KhhÝh²hubhŒenumerated_list”“”)�”}”(hhh]”(hŒ list_item”“”)�”}”(hŒ•The shared devlink instance is used alongside individual PF devlink instances, providing chip-wide configuration in addition to per-PF configuration.”h]”hï)�”}”(hŒ•The shared devlink instance is used alongside individual PF devlink instances, providing chip-wide configuration in addition to per-PF configuration.”h]”hŒ•The shared devlink instance is used alongside individual PF devlink instances, providing chip-wide configuration in addition to per-PF configuration.”…”�”}”(hj%h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´Khj!ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjh²hh³hÇh´Nubj )�”}”(hŒTThe shared devlink instance is the only devlink instance, without per-PF instances. ”h]”hï)�”}”(hŒSThe shared devlink instance is the only devlink instance, without per-PF instances.”h]”hŒSThe shared devlink instance is the only devlink instance, without per-PF instances.”…”�”}”(hj=h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´Khj9ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjh²hh³hÇh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œarabic”Œprefix”hŒsuffix”Œ.”uh1jhhÝh²hh³hÇh´Kubhï)�”}”(hŒ:It is up to the driver to decide which usage model to use.”h]”hŒ:It is up to the driver to decide which usage model to use.”…”�”}”(hj\h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KhhÝh²hubhï)�”}”(hŒAThe shared devlink instance is not backed by any struct *device*.”h]”(hŒ8The shared devlink instance is not backed by any struct ”…”�”}”(hjjh²hh³Nh´NubhŒemphasis”“”)�”}”(hŒ*device*”h]”hŒdevice”…”�”}”(hjth²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jrhjjubhŒ.”…”�”}”(hjjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KhhÝh²hubeh}”(h]”Œoverview”ah ]”h"]”Œoverview”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´KubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒImplementation”h]”hŒImplementation”…”�”}”(hj—h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj”h²hh³hÇh´KubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ Architecture”h]”hŒ Architecture”…”�”}”(hj¨h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj¥h²hh³hÇh´K!ubhï)�”}”(hŒThe implementation uses:”h]”hŒThe implementation uses:”…”�”}”(hj¶h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K#hj¥h²hubhŒ bullet_list”“”)�”}”(hhh]”(j )�”}”(hŒS**Chip identification**: PFs are grouped by chip using a driver-specific identifier”h]”hï)�”}”(hjËh]”(hŒstrong”“”)�”}”(hŒ**Chip identification**”h]”hŒChip identification”…”�”}”(hjÒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjÍubhŒ<: PFs are grouped by chip using a driver-specific identifier”…”�”}”(hjÍh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K%hjÉubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÆh²hh³hÇh´Nubj )�”}”(hŒX**Shared instance management**: Global list of shared instances with reference counting ”h]”hï)�”}”(hŒW**Shared instance management**: Global list of shared instances with reference counting”h]”(jÑ)�”}”(hŒ**Shared instance management**”h]”hŒShared instance management”…”�”}”(hjøh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjôubhŒ9: Global list of shared instances with reference counting”…”�”}”(hjôh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K&hjðubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÆh²hh³hÇh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ*”uh1jÄh³hÇh´K%hj¥h²hubeh}”(h]”Œ architecture”ah ]”h"]”Œ architecture”ah$]”h&]”uh1hÈhj”h²hh³hÇh´K!ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ API Functions”h]”hŒ API Functions”…”�”}”(hj)h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj&h²hh³hÇh´K)ubhï)�”}”(hŒKThe following functions are provided for managing shared devlink instances:”h]”hŒKThe following functions are provided for managing shared devlink instances:”…”�”}”(hj7h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K+hj&h²hubjÅ)�”}”(hhh]”(j )�”}”(hŒX``devlink_shd_get()``: Get or create a shared devlink instance identified by a string ID”h]”hï)�”}”(hjJh]”(hŒliteral”“”)�”}”(hŒ``devlink_shd_get()``”h]”hŒdevlink_shd_get()”…”�”}”(hjQh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjLubhŒC: Get or create a shared devlink instance identified by a string ID”…”�”}”(hjLh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K-hjHubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjEh²hh³hÇh´Nubj )�”}”(hŒG``devlink_shd_put()``: Release a reference on a shared devlink instance”h]”hï)�”}”(hjqh]”(jP)�”}”(hŒ``devlink_shd_put()``”h]”hŒdevlink_shd_put()”…”�”}”(hjvh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjsubhŒ2: Release a reference on a shared devlink instance”…”�”}”(hjsh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K.hjoubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjEh²hh³hÇh´Nubj )�”}”(hŒJ``devlink_shd_get_priv()``: Get private data from shared devlink instance ”h]”hï)�”}”(hŒI``devlink_shd_get_priv()``: Get private data from shared devlink instance”h]”(jP)�”}”(hŒ``devlink_shd_get_priv()``”h]”hŒdevlink_shd_get_priv()”…”�”}”(hjœh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhj˜ubhŒ/: Get private data from shared devlink instance”…”�”}”(hj˜h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K/hj”ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjEh²hh³hÇh´Nubeh}”(h]”h ]”h"]”h$]”h&]”jjuh1jÄh³hÇh´K-hj&h²hubeh}”(h]”Œ api-functions”ah ]”h"]”Œ api functions”ah$]”h&]”uh1hÈhj”h²hh³hÇh´K)ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒInitialization Flow”h]”hŒInitialization Flow”…”�”}”(hjËh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjÈh²hh³hÇh´K2ubj)�”}”(hhh]”(j )�”}”(hŒ4**PF calls shared devlink init** during driver probe”h]”hï)�”}”(hjÞh]”(jÑ)�”}”(hŒ **PF calls shared devlink init**”h]”hŒPF calls shared devlink init”…”�”}”(hjãh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjàubhŒ during driver probe”…”�”}”(hjàh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K4hjÜubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÙh²hh³hÇh´Nubj )�”}”(hŒQ**Chip identification** using driver-specific method to determine device identity”h]”hï)�”}”(hjh]”(jÑ)�”}”(hŒ**Chip identification**”h]”hŒChip identification”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjubhŒ: using driver-specific method to determine device identity”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K5hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÙh²hh³hÇh´Nubj )�”}”(hX**Get or create shared instance** using ``devlink_shd_get()``: * The function looks up existing instance by identifier * If none exists, creates new instance: - Allocates and registers devlink instance - Adds to global shared instances list - Increments reference count ”h]”(hï)�”}”(hŒ>**Get or create shared instance** using ``devlink_shd_get()``:”h]”(jÑ)�”}”(hŒ!**Get or create shared instance**”h]”hŒGet or create shared instance”…”�”}”(hj.h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhj*ubhŒ using ”…”�”}”(hj*h²hh³Nh´NubjP)�”}”(hŒ``devlink_shd_get()``”h]”hŒdevlink_shd_get()”…”�”}”(hj@h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhj*ubhŒ:”…”�”}”(hj*h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K6hj&ubjÅ)�”}”(hhh]”(j )�”}”(hŒ5The function looks up existing instance by identifier”h]”hï)�”}”(hj]h]”hŒ5The function looks up existing instance by identifier”…”�”}”(hj_h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K8hj[ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjXubj )�”}”(hŒ•If none exists, creates new instance: - Allocates and registers devlink instance - Adds to global shared instances list - Increments reference count ”h]”hï)�”}”(hŒ”If none exists, creates new instance: - Allocates and registers devlink instance - Adds to global shared instances list - Increments reference count”h]”hŒ”If none exists, creates new instance: - Allocates and registers devlink instance - Adds to global shared instances list - Increments reference count”…”�”}”(hjvh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K9hjrubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjXubeh}”(h]”h ]”h"]”h$]”h&]”jjuh1jÄh³hÇh´K8hj&ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhjÙh²hh³Nh´Nubj )�”}”(hŒ‹**Set nested devlink instance** for the PF devlink instance using ``devl_nested_devlink_set()`` before registering the PF devlink instance ”h]”hï)�”}”(hŒŠ**Set nested devlink instance** for the PF devlink instance using ``devl_nested_devlink_set()`` before registering the PF devlink instance”h]”(jÑ)�”}”(hŒ**Set nested devlink instance**”h]”hŒSet nested devlink instance”…”�”}”(hjžh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjšubhŒ# for the PF devlink instance using ”…”�”}”(hjšh²hh³Nh´NubjP)�”}”(hŒ``devl_nested_devlink_set()``”h]”hŒdevl_nested_devlink_set()”…”�”}”(hj°h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjšubhŒ+ before registering the PF devlink instance”…”�”}”(hjšh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K>hj–ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÙh²hh³hÇh´Nubeh}”(h]”h ]”h"]”h$]”h&]”jWjXjYhjZj[uh1jhjÈh²hh³hÇh´K4ubeh}”(h]”Œinitialization-flow”ah ]”h"]”Œinitialization flow”ah$]”h&]”uh1hÈhj”h²hh³hÇh´K2ubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒ Cleanup Flow”h]”hŒ Cleanup Flow”…”�”}”(hjßh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjÜh²hh³hÇh´KBubj)�”}”(hhh]”(j )�”}”(hŒ**Cleanup** when PF is removed”h]”hï)�”}”(hjòh]”(jÑ)�”}”(hŒ **Cleanup**”h]”hŒCleanup”…”�”}”(hj÷h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjôubhŒ when PF is removed”…”�”}”(hjôh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KDhjðubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjíh²hh³hÇh´Nubj )�”}”(hŒP**Call** ``devlink_shd_put()`` to release reference (decrements reference count)”h]”hï)�”}”(hjh]”(jÑ)�”}”(hŒ**Call**”h]”hŒCall”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjubhŒ ”…”�”}”(hjh²hh³Nh´NubjP)�”}”(hŒ``devlink_shd_put()``”h]”hŒdevlink_shd_put()”…”�”}”(hj.h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjubhŒ2 to release reference (decrements reference count)”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KEhjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjíh²hh³hÇh´Nubj )�”}”(hŒg**Shared instance is automatically destroyed** when the last PF removes (reference count reaches zero) ”h]”hï)�”}”(hŒf**Shared instance is automatically destroyed** when the last PF removes (reference count reaches zero)”h]”(jÑ)�”}”(hŒ.**Shared instance is automatically destroyed**”h]”hŒ*Shared instance is automatically destroyed”…”�”}”(hjTh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjPubhŒ8 when the last PF removes (reference count reaches zero)”…”�”}”(hjPh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KFhjLubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjíh²hh³hÇh´Nubeh}”(h]”h ]”h"]”h$]”h&]”jWjXjYhjZj[uh1jhjÜh²hh³hÇh´KDubeh}”(h]”Œ cleanup-flow”ah ]”h"]”Œ cleanup flow”ah$]”h&]”uh1hÈhj”h²hh³hÇh´KBubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒChip Identification”h]”hŒChip Identification”…”�”}”(hjƒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj€h²hh³hÇh´KIubhï)�”}”(hŒÙPFs belonging to the same chip are identified using a driver-specific method. The driver is free to choose any identifier that is suitable for determining whether two PFs are part of the same device. Examples include:”h]”hŒÙPFs belonging to the same chip are identified using a driver-specific method. The driver is free to choose any identifier that is suitable for determining whether two PFs are part of the same device. Examples include:”…”�”}”(hj‘h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KKhj€h²hubjÅ)�”}”(hhh]”(j )�”}”(hŒ0**PCI VPD serial numbers**: Extract from PCI VPD”h]”hï)�”}”(hj¤h]”(jÑ)�”}”(hŒ**PCI VPD serial numbers**”h]”hŒPCI VPD serial numbers”…”�”}”(hj©h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhj¦ubhŒ: Extract from PCI VPD”…”�”}”(hj¦h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KOhj¢ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjŸh²hh³hÇh´Nubj )�”}”(hŒA**Device tree properties**: Read chip identifier from device tree”h]”hï)�”}”(hjÉh]”(jÑ)�”}”(hŒ**Device tree properties**”h]”hŒDevice tree properties”…”�”}”(hjÎh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjËubhŒ': Read chip identifier from device tree”…”�”}”(hjËh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KPhjÇubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjŸh²hh³hÇh´Nubj )�”}”(hŒW**Other hardware-specific identifiers**: Any unique identifier that groups PFs by chip ”h]”hï)�”}”(hŒV**Other hardware-specific identifiers**: Any unique identifier that groups PFs by chip”h]”(jÑ)�”}”(hŒ'**Other hardware-specific identifiers**”h]”hŒ#Other hardware-specific identifiers”…”�”}”(hjôh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÐhjðubhŒ/: Any unique identifier that groups PFs by chip”…”�”}”(hjðh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KQhjìubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjŸh²hh³hÇh´Nubeh}”(h]”h ]”h"]”h$]”h&]”jjuh1jÄh³hÇh´KOhj€h²hubeh}”(h]”Œchip-identification”ah ]”h"]”Œchip identification”ah$]”h&]”uh1hÈhj”h²hh³hÇh´KIubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒLocking”h]”hŒLocking”…”�”}”(hj#h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj h²hh³hÇh´KTubhï)�”}”(hŒeA global mutex (``shd_mutex``) protects the shared instances list during registration/deregistration.”h]”(hŒA global mutex (”…”�”}”(hj1h²hh³Nh´NubjP)�”}”(hŒ ``shd_mutex``”h]”hŒ shd_mutex”…”�”}”(hj9h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhj1ubhŒH) protects the shared instances list during registration/deregistration.”…”�”}”(hj1h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KVhj h²hubhï)�”}”(hŒ’Similarly to other nested devlink instance relationships, devlink lock of the shared instance should be always taken after the devlink lock of PF.”h]”hŒ’Similarly to other nested devlink instance relationships, devlink lock of the shared instance should be always taken after the devlink lock of PF.”…”�”}”(hjQh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´KXhj h²hubeh}”(h]”Œlocking”ah ]”h"]”Œlocking”ah$]”h&]”uh1hÈhj”h²hh³hÇh´KTubhÉ)�”}”(hhh]”(hÎ)�”}”(hŒReference Counting”h]”hŒReference Counting”…”�”}”(hjjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjgh²hh³hÇh´K\ubhï)�”}”(hX(Each shared devlink instance maintains a reference count (``refcount_t refcount``). The reference count is incremented when ``devlink_shd_get()`` is called and decremented when ``devlink_shd_put()`` is called. When the reference count reaches zero, the shared instance is automatically destroyed.”h]”(hŒ:Each shared devlink instance maintains a reference count (”…”�”}”(hjxh²hh³Nh´NubjP)�”}”(hŒ``refcount_t refcount``”h]”hŒrefcount_t refcount”…”�”}”(hj€h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjxubhŒ+). The reference count is incremented when ”…”�”}”(hjxh²hh³Nh´NubjP)�”}”(hŒ``devlink_shd_get()``”h]”hŒdevlink_shd_get()”…”�”}”(hj’h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjxubhŒ is called and decremented when ”…”�”}”(hjxh²hh³Nh´NubjP)�”}”(hŒ``devlink_shd_put()``”h]”hŒdevlink_shd_put()”…”�”}”(hj¤h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jOhjxubhŒb is called. When the reference count reaches zero, the shared instance is automatically destroyed.”…”�”}”(hjxh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hîh³hÇh´K^hjgh²hubeh}”(h]”Œreference-counting”ah ]”h"]”Œreference counting”ah$]”h&]”uh1hÈhj”h²hh³hÇh´K\ubeh}”(h]”Œimplementation”ah ]”h"]”Œimplementation”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´Kubeh}”(h]”Œdevlink-shared-instances”ah ]”h"]”Œdevlink shared instances”ah$]”h&]”uh1hÈhhh²hh³hÇh´Kubeh}”(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”}”Œnameids”}”(jÑjÎj‘jŽjÉjÆj#j jÅjÂjÙjÖj}jzjjjdjajÁj¾uŒ nametypes”}”(jщj‘‰jɉj#‰jʼnjÙ‰j}‰j‰jd‰jÁ‰uh}”(jÎhÊjŽhÝjÆj”j j¥jÂj&jÖjÈjzjÜjj€jaj j¾jguŒ 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”]”Œ transformer”NŒ include_log”]”Œ decoration”Nh²hub.