sphinx.addnodesdocument)}( rawsourcechildren]( translations LanguagesNode)}(hhh](h pending_xref)}(hhh]docutils.nodesTextChinese (Simplified)}parenthsba attributes}(ids]classes]names]dupnames]backrefs] refdomainstdreftypedoc reftarget'/translations/zh_CN/gpu/drm-usage-statsmodnameN classnameN refexplicitutagnamehhh ubh)}(hhh]hChinese (Traditional)}hh2sbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget'/translations/zh_TW/gpu/drm-usage-statsmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hItalian}hhFsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget'/translations/it_IT/gpu/drm-usage-statsmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hJapanese}hhZsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget'/translations/ja_JP/gpu/drm-usage-statsmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hKorean}hhnsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget'/translations/ko_KR/gpu/drm-usage-statsmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hSpanish}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget'/translations/sp_SP/gpu/drm-usage-statsmodnameN classnameN refexplicituh1hhh ubeh}(h]h ]h"]h$]h&]current_languageEnglishuh1h hh _documenthsourceNlineNubhtarget)}(h.. _drm-client-usage-stats:h]h}(h]h ]h"]h$]h&]refiddrm-client-usage-statsuh1hhKhhhhhA/var/lib/git/docbuild/linux/Documentation/gpu/drm-usage-stats.rstubhsection)}(hhh](htitle)}(hDRM client usage statsh]hDRM client usage stats}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhhhhhKubh paragraph)}(hDRM drivers can choose to export partly standardised text output via the `fops->show_fdinfo()` as part of the driver specific file operations registered in the `struct drm_driver` object registered with the DRM core.h](hIDRM drivers can choose to export partly standardised text output via the }(hhhhhNhNubhtitle_reference)}(h`fops->show_fdinfo()`h]hfops->show_fdinfo()}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhubhB as part of the driver specific file operations registered in the }(hhhhhNhNubh)}(h`struct drm_driver`h]hstruct drm_driver}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhubh% object registered with the DRM core.}(hhhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKhhhhubh)}(h|One purpose of this output is to enable writing as generic as practically feasible `top(1)` like userspace monitoring tools.h](hSOne purpose of this output is to enable writing as generic as practically feasible }(hhhhhNhNubh)}(h`top(1)`h]htop(1)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhubh! like userspace monitoring tools.}(hhhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhK hhhhubh)}(hGiven the differences between various DRM drivers the specification of the output is split between common and driver specific parts. Having said that, wherever possible effort should still be made to standardise as much as possible.h]hGiven the differences between various DRM drivers the specification of the output is split between common and driver specific parts. Having said that, wherever possible effort should still be made to standardise as much as possible.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhhhhubh)}(hhh](h)}(hFile format specificationh]hFile format specification}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj)hhhhhKubh bullet_list)}(hhh](h list_item)}(h;File shall contain one key value pair per one line of text.h]h)}(hjCh]h;File shall contain one key value pair per one line of text.}(hjEhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjAubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubj@)}(h>Colon character (`:`) must be used to delimit keys and values.h]h)}(hjZh](hColon character (}(hj\hhhNhNubh)}(h`:`h]h:}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhj\ubh*) must be used to delimit keys and values.}(hj\hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKhjXubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubj@)}(h4All standardised keys shall be prefixed with `drm-`.h]h)}(hjh](h-All standardised keys shall be prefixed with }(hjhhhNhNubh)}(h`drm-`h]hdrm-}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubj@)}(hDriver-specific keys shall be prefixed with `driver_name-`, where driver_name should ideally be the same as the `name` field in `struct drm_driver`, although this is not mandatory.h]h)}(hDriver-specific keys shall be prefixed with `driver_name-`, where driver_name should ideally be the same as the `name` field in `struct drm_driver`, although this is not mandatory.h](h,Driver-specific keys shall be prefixed with }(hjhhhNhNubh)}(h`driver_name-`h]h driver_name-}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubh6, where driver_name should ideally be the same as the }(hjhhhNhNubh)}(h`name`h]hname}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubh field in }(hjhhhNhNubh)}(h`struct drm_driver`h]hstruct drm_driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubh!, although this is not mandatory.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubj@)}(hbWhitespace between the delimiter and first non-whitespace character shall be ignored when parsing.h]h)}(hbWhitespace between the delimiter and first non-whitespace character shall be ignored when parsing.h]hbWhitespace between the delimiter and first non-whitespace character shall be ignored when parsing.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubj@)}(h6Keys are not allowed to contain whitespace characters.h]h)}(hjh]h6Keys are not allowed to contain whitespace characters.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubj@)}(hubah}(h]h ]h"]h$]h&]uh1j?hj<hhhhhNubeh}(h]h ]h"]h$]h&]bullet-uh1j:hhhKhj)hhubh)}(hhh](h)}(h Key typesh]h Key types}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^hhhhhK#ubhenumerated_list)}(hhh](j@)}(hMandatory, fully standardised.h]h)}(hjvh]hMandatory, fully standardised.}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK%hjtubah}(h]h ]h"]h$]h&]uh1j?hjqhhhhhNubj@)}(hOptional, fully standardised.h]h)}(hjh]hOptional, fully standardised.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK&hjubah}(h]h ]h"]h$]h&]uh1j?hjqhhhhhNubj@)}(hDriver specific. h]h)}(hDriver specific.h]hDriver specific.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK'hjubah}(h]h ]h"]h$]h&]uh1j?hjqhhhhhNubeh}(h]h ]h"]h$]h&]enumtypearabicprefixhsuffix.uh1johj^hhhhhK%ubeh}(h] key-typesah ]h"] key typesah$]h&]uh1hhj)hhhhhK#ubh)}(hhh](h)}(h Data typesh]h Data types}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhK*ubj;)}(hhh](j@)}(h= - Unsigned integer without defining the maximum value.h]h)}(hjh]h= - Unsigned integer without defining the maximum value.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK,hjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubj@)}(hP - String excluding any above defined reserved characters or whitespace.h]h)}(hjh]hP - String excluding any above defined reserved characters or whitespace.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK-hjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubj@)}(h - String. h]h)}(h - String.h]h - String.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK.hjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubeh}(h]h ]h"]h$]h&]j\j]uh1j:hhhK,hjhhubeh}(h] data-typesah ]h"] data typesah$]h&]uh1hhj)hhhhhK*ubh)}(hhh](h)}(h!Mandatory fully standardised keysh]h!Mandatory fully standardised keys}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5hhhhhK1ubj;)}(hhh]j@)}(hdrm-driver: h]h)}(hdrm-driver: h]hdrm-driver: }(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK3hjIubah}(h]h ]h"]h$]h&]uh1j?hjFhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhK3hj5hhubh)}(hnString shall contain the name this driver registered as via the respective `struct drm_driver` data structure.h](hKString shall contain the name this driver registered as via the respective }(hjghhhNhNubh)}(h`struct drm_driver`h]hstruct drm_driver}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1hhjgubh data structure.}(hjghhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhK5hj5hhubeh}(h]!mandatory-fully-standardised-keysah ]h"]!mandatory fully standardised keysah$]h&]uh1hhj)hhhhhK1ubh)}(hhh](h)}(h Optional fully standardised keysh]h Optional fully standardised keys}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhK9ubh)}(hhh](h)}(hIdentificationh]hIdentification}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhK h]h)}(hdrm-pdev: h]hdrm-pdev: }(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK>hjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhK>hjhhubh)}(hSFor PCI devices this should contain the PCI slot address of the device in question.h]hSFor PCI devices this should contain the PCI slot address of the device in question.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK@hjhhubj;)}(hhh]j@)}(hdrm-client-id: h]h)}(hdrm-client-id: h]hdrm-client-id: }(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKChjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKChjhhubh)}(hUnique value relating to the open DRM file descriptor used to distinguish duplicated and shared file descriptors. Conceptually the value should map 1:1 to the in kernel representation of `struct drm_file` instances.h](hUnique value relating to the open DRM file descriptor used to distinguish duplicated and shared file descriptors. Conceptually the value should map 1:1 to the in kernel representation of }(hjhhhNhNubh)}(h`struct drm_file`h]hstruct drm_file}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubh instances.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKEhjhhubh)}(hUniqueness of the value shall be either globally unique, or unique within the scope of each device, in which case `drm-pdev` shall be present as well.h](hrUniqueness of the value shall be either globally unique, or unique within the scope of each device, in which case }(hj!hhhNhNubh)}(h `drm-pdev`h]hdrm-pdev}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!ubh shall be present as well.}(hj!hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKIhjhhubh)}(hUserspace should make sure to not double account any usage statistics by using the above described criteria in order to associate data to individual clients.h]hUserspace should make sure to not double account any usage statistics by using the above described criteria in order to associate data to individual clients.}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKLhjhhubj;)}(hhh]j@)}(hdrm-client-name: h]h)}(hdrm-client-name: h]hdrm-client-name: }(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKOhjRubah}(h]h ]h"]h$]h&]uh1j?hjOhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKOhjhhubh)}(hCString optionally set by userspace using DRM_IOCTL_SET_CLIENT_NAME.h]hCString optionally set by userspace using DRM_IOCTL_SET_CLIENT_NAME.}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKQhjhhubeh}(h]identificationah ]h"]identificationah$]h&]uh1hhjhhhhhK: ns h]h)}(hdrm-engine-: nsh]hdrm-engine-: ns}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKWhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKWhjhhubh)}(hGPUs usually contain multiple execution engines. Each shall be given a stable and unique name (keystr), with possible values documented in the driver specific documentation.h]hGPUs usually contain multiple execution engines. Each shall be given a stable and unique name (keystr), with possible values documented in the driver specific documentation.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKYhjhhubh)}(hValue shall be in specified time units which the respective GPU engine spent busy executing workloads belonging to this client.h]hValue shall be in specified time units which the respective GPU engine spent busy executing workloads belonging to this client.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK]hjhhubh)}(hX_Values are not required to be constantly monotonic if it makes the driver implementation easier, but are required to catch up with the previously reported larger value within a reasonable period. Upon observing a value lower than what was previously read, userspace is expected to stay with that larger previous value until a monotonic update is seen.h]hX_Values are not required to be constantly monotonic if it makes the driver implementation easier, but are required to catch up with the previously reported larger value within a reasonable period. Upon observing a value lower than what was previously read, userspace is expected to stay with that larger previous value until a monotonic update is seen.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK`hjhhubj;)}(hhh]j@)}(h%drm-engine-capacity-: h]h)}(h$drm-engine-capacity-: h]h$drm-engine-capacity-: }(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKfhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKfhjhhubh)}(hEngine identifier string must be the same as the one specified in the drm-engine- tag and shall contain a greater than zero number in case the exported engine corresponds to a group of identical hardware engines.h]hEngine identifier string must be the same as the one specified in the drm-engine- tag and shall contain a greater than zero number in case the exported engine corresponds to a group of identical hardware engines.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhhjhhubh)}(h]In the absence of this tag parser shall assume capacity of one. Zero capacity is not allowed.h]h]In the absence of this tag parser shall assume capacity of one. Zero capacity is not allowed.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKlhjhhubj;)}(hhh]j@)}(hdrm-cycles-: h]h)}(hdrm-cycles-: h]hdrm-cycles-: }(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKohj"ubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKohjhhubh)}(hEngine identifier string must be the same as the one specified in the drm-engine- tag and shall contain the number of busy cycles for the given engine.h]hEngine identifier string must be the same as the one specified in the drm-engine- tag and shall contain the number of busy cycles for the given engine.}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKqhjhhubh)}(hX_Values are not required to be constantly monotonic if it makes the driver implementation easier, but are required to catch up with the previously reported larger value within a reasonable period. Upon observing a value lower than what was previously read, userspace is expected to stay with that larger previous value until a monotonic update is seen.h]hX_Values are not required to be constantly monotonic if it makes the driver implementation easier, but are required to catch up with the previously reported larger value within a reasonable period. Upon observing a value lower than what was previously read, userspace is expected to stay with that larger previous value until a monotonic update is seen.}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKuhjhhubj;)}(hhh]j@)}(h"drm-total-cycles-: h]h)}(h!drm-total-cycles-: h]h!drm-total-cycles-: }(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK{hj_ubah}(h]h ]h"]h$]h&]uh1j?hj\hhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhK{hjhhubh)}(hEngine identifier string must be the same as the one specified in the drm-cycles- tag and shall contain the total number cycles for the given engine.h]hEngine identifier string must be the same as the one specified in the drm-cycles- tag and shall contain the total number cycles for the given engine.}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK}hjhhubh)}(hXThis is a timestamp in GPU unspecified unit that matches the update rate of drm-cycles-. For drivers that implement this interface, the engine utilization can be calculated entirely on the GPU clock domain, without considering the CPU sleep time between 2 samples.h]hXThis is a timestamp in GPU unspecified unit that matches the update rate of drm-cycles-. For drivers that implement this interface, the engine utilization can be calculated entirely on the GPU clock domain, without considering the CPU sleep time between 2 samples.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hMA driver may implement either this key or drm-maxfreq-, but not both.h]hMA driver may implement either this key or drm-maxfreq-, but not both.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h*drm-maxfreq-: [Hz|MHz|KHz] h]h)}(h)drm-maxfreq-: [Hz|MHz|KHz]h]h)drm-maxfreq-: [Hz|MHz|KHz]}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(hXEngine identifier string must be the same as the one specified in the drm-engine- tag and shall contain the maximum frequency for the given engine. Taken together with drm-cycles-, this can be used to calculate percentage utilization of the engine, whereas drm-engine- only reflects time active without considering what frequency the engine is operating as a percentage of its maximum frequency.h]hXEngine identifier string must be the same as the one specified in the drm-engine- tag and shall contain the maximum frequency for the given engine. Taken together with drm-cycles-, this can be used to calculate percentage utilization of the engine, whereas drm-engine- only reflects time active without considering what frequency the engine is operating as a percentage of its maximum frequency.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hRA driver may implement either this key or drm-total-cycles-, but not both.h]hRA driver may implement either this key or drm-total-cycles-, but not both.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubeh}(h] utilizationah ]h"] utilizationah$]h&]uh1hhjhhhhhKUubh)}(hhh](h)}(hMemoryh]hMemory}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubh)}(hEach possible memory type which can be used to store buffer objects by the GPU in question shall be given a stable and unique name to be used as the "" string.h]hEach possible memory type which can be used to store buffer objects by the GPU in question shall be given a stable and unique name to be used as the “” string.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hFThe region name "memory" is reserved to refer to normal system memory.h]hJThe region name “memory” is reserved to refer to normal system memory.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hThe value shall reflect the amount of storage currently consumed by the buffer objects belong to this client, in the respective memory region.h]hThe value shall reflect the amount of storage currently consumed by the buffer objects belong to this client, in the respective memory region.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hkDefault unit shall be bytes with optional unit specifiers of 'KiB' or 'MiB' indicating kibi- or mebi-bytes.h]hsDefault unit shall be bytes with optional unit specifiers of ‘KiB’ or ‘MiB’ indicating kibi- or mebi-bytes.}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h%drm-total-: [KiB|MiB] h]h)}(h$drm-total-: [KiB|MiB]h]h$drm-total-: [KiB|MiB]}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhj8ubah}(h]h ]h"]h$]h&]uh1j?hj5hhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(hXmThe total size of all requested buffers, including both shared and private memory. The backing store for the buffers does not need to be currently instantiated to count under this category. To avoid double-counting, if a buffer has multiple regions where it can be allocated to, the implementation should consistently select a single region for accounting purposes.h]hXmThe total size of all requested buffers, including both shared and private memory. The backing store for the buffers does not need to be currently instantiated to count under this category. To avoid double-counting, if a buffer has multiple regions where it can be allocated to, the implementation should consistently select a single region for accounting purposes.}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h&drm-shared-: [KiB|MiB] h]h)}(h%drm-shared-: [KiB|MiB]h]h%drm-shared-: [KiB|MiB]}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjgubah}(h]h ]h"]h$]h&]uh1j?hjdhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(hThe total size of buffers that are shared with another file (i.e., have more than one handle). The same requirement to avoid double-counting that applies to drm-total- also applies here.h]hThe total size of buffers that are shared with another file (i.e., have more than one handle). The same requirement to avoid double-counting that applies to drm-total- also applies here.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h(drm-resident-: [KiB|MiB] h]h)}(h'drm-resident-: [KiB|MiB]h]h'drm-resident-: [KiB|MiB]}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(h}The total size of buffers that are resident (i.e., have their backing store present or instantiated) in the specified region.h]h}The total size of buffers that are resident (i.e., have their backing store present or instantiated) in the specified region.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h&drm-memory-: [KiB|MiB] h]h)}(h%drm-memory-: [KiB|MiB]h]h%drm-memory-: [KiB|MiB]}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(h_This key is deprecated and is only printed by amdgpu; it is an alias for drm-resident-.h]h_This key is deprecated and is only printed by amdgpu; it is an alias for drm-resident-.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h)drm-purgeable-: [KiB|MiB] h]h)}(h(drm-purgeable-: [KiB|MiB]h]h(drm-purgeable-: [KiB|MiB]}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(h:The total size of buffers that are resident and purgeable.h]h:The total size of buffers that are resident and purgeable.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hFor example, drivers that implement functionality similar to 'madvise' can count buffers that have instantiated backing stores but have been marked with an equivalent of MADV_DONTNEED.h]hFor example, drivers that implement functionality similar to ‘madvise’ can count buffers that have instantiated backing stores but have been marked with an equivalent of MADV_DONTNEED.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubj;)}(hhh]j@)}(h&drm-active-: [KiB|MiB] h]h)}(h%drm-active-: [KiB|MiB]h]h%drm-active-: [KiB|MiB]}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhj1ubah}(h]h ]h"]h$]h&]uh1j?hj.hhhhhNubah}(h]h ]h"]h$]h&]j\j]uh1j:hhhKhjhhubh)}(hAThe total size of buffers that are active on one or more engines.h]hAThe total size of buffers that are active on one or more engines.}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hOne practical example of this could be the presence of unsignaled fences in a GEM buffer reservation object. Therefore, the active category is a subset of the resident category.h]hOne practical example of this could be the presence of unsignaled fences in a GEM buffer reservation object. Therefore, the active category is a subset of the resident category.}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjhhubeh}(h]memoryah ]h"]memoryah$]h&]uh1hhjhhhhhKubeh}(h] optional-fully-standardised-keysah ]h"] optional fully standardised keysah$]h&]uh1hhj)hhhhhK9ubeh}(h]file-format-specificationah ]h"]file format specificationah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(hImplementation Detailsh]hImplementation Details}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubh)}(hX'Drivers should use drm_show_fdinfo() in their `struct file_operations`, and implement &drm_driver.show_fdinfo if they wish to provide any stats which are not provided by drm_show_fdinfo(). But even driver specific stats should be documented above and where possible, aligned with other drivers.h](h.Drivers should use drm_show_fdinfo() in their }(hjhhhNhNubh)}(h`struct file_operations`h]hstruct file_operations}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjubh, and implement &drm_driver.show_fdinfo if they wish to provide any stats which are not provided by drm_show_fdinfo(). But even driver specific stats should be documented above and where possible, aligned with other drivers.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhKhjhhubh)}(hhh](h)}(hDriver specific implementationsh]hDriver specific implementations}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubj;)}(hhh](j@)}(h:ref:`i915-usage-stats`h]h)}(hjh]h)}(hjh]hinline)}(hjh]hi915-usage-stats}(hjhhhNhNubah}(h]h ](xrefstdstd-refeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocgpu/drm-usage-stats refdomainjreftyperef refexplicitrefwarn reftargeti915-usage-statsuh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubj@)}(h:ref:`panfrost-usage-stats`h]h)}(hjh]h)}(hjh]j)}(hjh]hpanfrost-usage-stats}(hj hhhNhNubah}(h]h ](jstdstd-refeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftyperef refexplicitrefwarnjpanfrost-usage-statsuh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubj@)}(h:ref:`panthor-usage-stats`h]h)}(hj3h]h)}(hj3h]j)}(hj3h]hpanthor-usage-stats}(hj;hhhNhNubah}(h]h ](jstdstd-refeh"]h$]h&]uh1jhj8ubah}(h]h ]h"]h$]h&]refdocj refdomainjEreftyperef refexplicitrefwarnjpanthor-usage-statsuh1hhhhKhj5ubah}(h]h ]h"]h$]h&]uh1hhhhKhj1ubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubj@)}(h:ref:`xe-usage-stats`h]h)}(hjeh]h)}(hjeh]j)}(hjeh]hxe-usage-stats}(hjmhhhNhNubah}(h]h ](jstdstd-refeh"]h$]h&]uh1jhjjubah}(h]h ]h"]h$]h&]refdocj refdomainjwreftyperef refexplicitrefwarnjxe-usage-statsuh1hhhhKhjgubah}(h]h ]h"]h$]h&]uh1hhhhKhjcubah}(h]h ]h"]h$]h&]uh1j?hjhhhhhNubeh}(h]h ]h"]h$]h&]j\*uh1j:hhhKhjhhubeh}(h]driver-specific-implementationsah ]h"]driver specific implementationsah$]h&]uh1hhjhhhhhKubeh}(h]implementation-detailsah ]h"]implementation detailsah$]h&]uh1hhhhhhhhKubeh}(h](hid1eh ]h"](drm client usage statsdrm-client-usage-statseh$]h&]uh1hhhhhhhhKexpect_referenced_by_name}jhsexpect_referenced_by_id}hhsubeh}(h]h ]h"]h$]h&]sourcehuh1hcurrent_sourceN current_lineNsettingsdocutils.frontendValues)}(hN generatorN datestampN source_linkN source_urlN toc_backlinksentryfootnote_backlinksK sectnum_xformKstrip_commentsNstrip_elements_with_classesN strip_classesN report_levelK halt_levelKexit_status_levelKdebugNwarning_streamN tracebackinput_encoding utf-8-siginput_encoding_error_handlerstrictoutput_encodingutf-8output_encoding_error_handlerjerror_encodingutf-8error_encoding_error_handlerbackslashreplace language_codeenrecord_dependenciesNconfigN id_prefixhauto_id_prefixid dump_settingsNdump_internalsNdump_transformsNdump_pseudo_xmlNexpose_internalsNstrict_visitorN_disable_configN_sourceh _destinationN _config_files]7/var/lib/git/docbuild/linux/Documentation/docutils.confafile_insertion_enabled raw_enabledKline_length_limitM'pep_referencesN pep_base_urlhttps://peps.python.org/pep_file_url_templatepep-%04drfc_referencesN rfc_base_url&https://datatracker.ietf.org/doc/html/ tab_widthKtrim_footnote_reference_spacesyntax_highlightlong smart_quotessmartquotes_locales]character_level_inline_markupdoctitle_xform docinfo_xformKsectsubtitle_xform image_loadinglinkembed_stylesheetcloak_email_addressessection_self_linkenvNubreporterNindirect_targets]substitution_defs}substitution_names}refnames}refids}h]hasnameids}(jhjjjj}jjj2j/jjjxjujjjjjpjmjjjju nametypes}(jjjjj2jjxjjjpjjuh}(hhjhj}j)jj^j/jjj5jujjjjjjmjjjjju footnote_refs} citation_refs} autofootnotes]autofootnote_refs]symbol_footnotes]symbol_footnote_refs] footnotes] citations]autofootnote_startKsymbol_footnote_startK id_counter collectionsCounter}jKsRparse_messages]transform_messages]hsystem_message)}(hhh]h)}(hhh]h