projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b46998d
)
dma_buf: remove dmabuf sysfs teardown before release
author
Guangming Cao
<Guangming.Cao@mediatek.com>
Tue, 20 Jul 2021 10:31:58 +0000
(18:31 +0800)
committer
Christian König
<christian.koenig@amd.com>
Tue, 20 Jul 2021 10:59:55 +0000
(12:59 +0200)
Dmabuf sysfs stat is used for dmabuf info track.
But these file maybe still in use after buffer released,
should clear it before buffer release.
Signed-off-by: Guangming Cao <Guangming.Cao@mediatek.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Link:
https://patchwork.freedesktop.org/patch/msgid/20210720103158.83439-1-guangming.cao@mediatek.com
Signed-off-by: Christian König <christian.koenig@amd.com>
drivers/dma-buf/dma-buf.c
patch
|
blob
|
history
diff --git
a/drivers/dma-buf/dma-buf.c
b/drivers/dma-buf/dma-buf.c
index b1a6db71c656153c5ea96c331b5f4bdbd393487b..63d32261b63ff4ccc34a082aa5fe7ac5bad27052 100644
(file)
--- a/
drivers/dma-buf/dma-buf.c
+++ b/
drivers/dma-buf/dma-buf.c
@@
-76,12
+76,12
@@
static void dma_buf_release(struct dentry *dentry)
*/
BUG_ON(dmabuf->cb_shared.active || dmabuf->cb_excl.active);
+ dma_buf_stats_teardown(dmabuf);
dmabuf->ops->release(dmabuf);
if (dmabuf->resv == (struct dma_resv *)&dmabuf[1])
dma_resv_fini(dmabuf->resv);
- dma_buf_stats_teardown(dmabuf);
module_put(dmabuf->owner);
kfree(dmabuf->name);
kfree(dmabuf);