<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<p><br>
</p>
<div class="moz-cite-prefix">On 31-08-2023 14:35, Tejas Upadhyay
wrote:<br>
</div>
<blockquote type="cite" cite="mid:20230831090536.2949934-5-tejas.upadhyay@intel.com">
<pre class="moz-quote-pre" wrap="">Enable accounting of indirect client memory usage.
Signed-off-by: Tejas Upadhyay <a class="moz-txt-link-rfc2396E" href="mailto:tejas.upadhyay@intel.com"><tejas.upadhyay@intel.com></a>
---
drivers/gpu/drm/xe/xe_vm.c | 1 +
drivers/gpu/drm/xe/xe_vm_types.h | 2 ++
2 files changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/xe/xe_vm.c b/drivers/gpu/drm/xe/xe_vm.c
index 9cbf2f63d641..f5f832c8ed42 100644
--- a/drivers/gpu/drm/xe/xe_vm.c
+++ b/drivers/gpu/drm/xe/xe_vm.c
@@ -2057,6 +2057,7 @@ int xe_vm_create_ioctl(struct drm_device *dev, void *data,
}
args->vm_id = id;
+ vm->xef = xef;</pre>
</blockquote>
shouldn't it be applicable only if <code style="padding: 0px; tab-size: 8; white-space: pre-wrap;" class="hljs diff language-diff">CONFIG_PROC_FS is enabled ? </code>
<blockquote type="cite" cite="mid:20230831090536.2949934-5-tejas.upadhyay@intel.com">
<pre class="moz-quote-pre" wrap="">
#if IS_ENABLED(CONFIG_DRM_XE_DEBUG_MEM)
/* Warning: Security issue - never enable by default */
diff --git a/drivers/gpu/drm/xe/xe_vm_types.h b/drivers/gpu/drm/xe/xe_vm_types.h
index fd2178dbde3a..db8523d81d0f 100644
--- a/drivers/gpu/drm/xe/xe_vm_types.h
+++ b/drivers/gpu/drm/xe/xe_vm_types.h
@@ -336,6 +336,8 @@ struct xe_vm {
/** @batch_invalidate_tlb: Always invalidate TLB before batch start */
bool batch_invalidate_tlb;
+ /** @xef: XE file handle for tracking this VM's drm client */
+ struct xe_file *xef;</pre>
</blockquote>
Same comment as above.<br>
<blockquote type="cite" cite="mid:20230831090536.2949934-5-tejas.upadhyay@intel.com">
<pre class="moz-quote-pre" wrap="">
};
/** struct xe_vma_op_map - VMA map operation */
</pre>
</blockquote>
</body>
</html>