ahrens commented on this pull request.


> @@ -2940,7 +2916,8 @@ dbuf_rele_and_unlock(dmu_buf_impl_t *db, void *tag)
                                    db->db.db_size, db);
                                mutex_exit(&db->db_mtx);
 
-                               if (db->db_caching_status == DB_DBUF_CACHE) {
+                               if (db->db_caching_status == DB_DBUF_CACHE &&
+                                   !evicting) {
                                        dbuf_evict_notify();

That makes sense.  I think in practice it isn't a big deal either way, because 
we go through dbuf_rele_and_unlock(evicting=FALSE) so often (e.g. nearly every 
call into the ZPL/ZVOL is going to do this).  And when evicting=TRUE, we 
typically are either already in the dbuf_evict_thread, or we are called from 
dbuf_rele_unlock(evicting=FALSE), so we checked (and signaled if necessary) 
just a few nanoseconds ago.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openzfs/openzfs/pull/645#discussion_r193504160
------------------------------------------
openzfs: openzfs-developer
Permalink: 
https://openzfs.topicbox.com/groups/developer/Tb73a3d2cba6f4c23-M328b039d99b9da86515a6cb2
Delivery options: https://openzfs.topicbox.com/groups

Reply via email to