FreeBSD Bugzilla – Attachment 160132 Details for
Bug 202358
[patch] [zfs] fix possible assert fail in sa_handle_get_from_db()
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
proposed patch
file_202358.txt (text/plain), 1.18 KB, created by
Andriy Gapon
on 2015-08-20 08:08:42 UTC
(
hide
)
Description:
proposed patch
Filename:
MIME Type:
Creator:
Andriy Gapon
Created:
2015-08-20 08:08:42 UTC
Size:
1.18 KB
patch
obsolete
>diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c >index cc7c925ea8c5d..375a188a79032 100644 >--- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c >+++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c >@@ -211,6 +211,7 @@ sa_cache_constructor(void *buf, void *unused, int kmflag) > { > sa_handle_t *hdl = buf; > >+ hdl->sa_dbu.dbu_evict_func = NULL; > mutex_init(&hdl->sa_lock, NULL, MUTEX_DEFAULT, NULL); > return (0); > } >@@ -220,7 +221,8 @@ static void > sa_cache_destructor(void *buf, void *unused) > { > sa_handle_t *hdl = buf; >- hdl->sa_dbu.dbu_evict_func = NULL; >+ >+ ASSERT3P(hdl->sa_dbu.dbu_evict_func, ==, NULL); > mutex_destroy(&hdl->sa_lock); > } > >@@ -1360,6 +1362,7 @@ sa_handle_destroy(sa_handle_t *hdl) > dmu_buf_rele((dmu_buf_t *)hdl->sa_spill, NULL); > mutex_exit(&hdl->sa_lock); > >+ hdl->sa_dbu.dbu_evict_func = NULL; > kmem_cache_free(sa_cache, hdl); > } > >@@ -1401,6 +1404,7 @@ sa_handle_get_from_db(objset_t *os, dmu_buf_t *db, void *userp, > } > > if (winner != NULL) { >+ handle->sa_dbu.dbu_evict_func = NULL; > kmem_cache_free(sa_cache, handle); > handle = winner; > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 202358
:
159915
|
160132