summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLucas De Marchi <lucas.demarchi@intel.com>2024-07-30 20:35:02 -0700
committerLucas De Marchi <lucas.demarchi@intel.com>2024-08-09 07:11:54 -0700
commit965de1e69e91e331eee9d9f53e46b4652ba157c1 (patch)
treeecec8020e5ed29dee7c9e31d51afc74ac64cda51
parent0dabf88262c0349d261248638064b97da35369f8 (diff)
lib/igt_drm_fdinfo: Improve fdinfo parse documentation
Be explicit on what we are parsing: key-values for the current process, likely to be used by the same process causing workloads, or by key-values for a random process, likely to be used when analyzing all the clients. Reviewed-by: Jonathan Cavitt <jonathan.cavitt@intel.com> Link: https://lore.kernel.org/r/20240731033504.1426640-2-lucas.demarchi@intel.com Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
-rw-r--r--lib/igt_drm_fdinfo.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/igt_drm_fdinfo.h b/lib/igt_drm_fdinfo.h
index 35f43305b..168b3c44c 100644
--- a/lib/igt_drm_fdinfo.h
+++ b/lib/igt_drm_fdinfo.h
@@ -74,7 +74,9 @@ struct drm_client_fdinfo {
};
/**
- * igt_parse_drm_fdinfo: Parses the drm fdinfo file
+ * igt_parse_drm_fdinfo: Parse the drm fdinfo file for this process
+ *
+ * Parse /proc/self/fdinfo/<drm_fd> collecting all key-values
*
* @drm_fd: DRM file descriptor
* @info: Structure to populate with read data. Must be zeroed.
@@ -92,10 +94,12 @@ igt_parse_drm_fdinfo(int drm_fd, struct drm_client_fdinfo *info,
const char **region_map, unsigned int region_entries);
/**
- * __igt_parse_drm_fdinfo: Parses the drm fdinfo file
+ * __igt_parse_drm_fdinfo: Parse the drm fdinfo file for a process
+ *
+ * Parse /proc/<pid>/fdinfo/<fd> collecting all key-values.
*
- * @dir: File descriptor pointing to /proc/pid/fdinfo directory
- * @fd: String representation of the file descriptor number to parse.
+ * @dir: File descriptor pointing to /proc/<pid>/fdinfo directory
+ * @fd: String representation of the file descriptor number (<fd>) to parse.
* @info: Structure to populate with read data. Must be zeroed.
* @name_map: Optional array of strings representing engine names
* @map_entries: Number of strings in the names array