diff options
author | Tim Schumacher <[email protected]> | 2018-09-26 19:29:26 +0200 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2018-09-26 10:29:26 -0700 |
commit | c13060e4787e9578dafad85a47c62457424bec9c (patch) | |
tree | bf05ff868e01b6d607a234026a659ff4b5e1a789 /module/zfs/dbuf.c | |
parent | 7a23c81342df05ace730bd303b4a73854dba43dd (diff) |
Linux 4.19-rc3+ compat: Remove refcount_t compat
torvalds/linux@59b57717f ("blkcg: delay blkg destruction until
after writeback has finished") added a refcount_t to the blkcg
structure. Due to the refcount_t compatibility code, zfs_refcount_t
was used by mistake.
Resolve this by removing the compatibility code and replacing the
occurrences of refcount_t with zfs_refcount_t.
Reviewed-by: Franz Pletz <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Tim Schumacher <[email protected]>
Closes #7885
Closes #7932
Diffstat (limited to 'module/zfs/dbuf.c')
-rw-r--r-- | module/zfs/dbuf.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/module/zfs/dbuf.c b/module/zfs/dbuf.c index f7376875a..db7df6023 100644 --- a/module/zfs/dbuf.c +++ b/module/zfs/dbuf.c @@ -223,7 +223,7 @@ static boolean_t dbuf_evict_thread_exit; */ typedef struct dbuf_cache { multilist_t *cache; - refcount_t size; + zfs_refcount_t size; } dbuf_cache_t; dbuf_cache_t dbuf_caches[DB_CACHE_MAX]; @@ -2784,7 +2784,7 @@ dbuf_create(dnode_t *dn, uint8_t level, uint64_t blkid, ASSERT(dn->dn_object == DMU_META_DNODE_OBJECT || refcount_count(&dn->dn_holds) > 0); - (void) refcount_add(&dn->dn_holds, db); + (void) zfs_refcount_add(&dn->dn_holds, db); atomic_inc_32(&dn->dn_dbufs_count); dprintf_dbuf(db, "db=%p\n", db); @@ -3183,7 +3183,7 @@ dbuf_hold_impl_arg(struct dbuf_hold_arg *dh) } dh->dh_db->db_caching_status = DB_NO_CACHE; } - (void) refcount_add(&dh->dh_db->db_holds, dh->dh_tag); + (void) zfs_refcount_add(&dh->dh_db->db_holds, dh->dh_tag); DBUF_VERIFY(dh->dh_db); mutex_exit(&dh->dh_db->db_mtx); @@ -3308,7 +3308,7 @@ dbuf_rm_spill(dnode_t *dn, dmu_tx_t *tx) void dbuf_add_ref(dmu_buf_impl_t *db, void *tag) { - int64_t holds = refcount_add(&db->db_holds, tag); + int64_t holds = zfs_refcount_add(&db->db_holds, tag); VERIFY3S(holds, >, 1); } @@ -3328,7 +3328,7 @@ dbuf_try_add_ref(dmu_buf_t *db_fake, objset_t *os, uint64_t obj, uint64_t blkid, if (found_db != NULL) { if (db == found_db && dbuf_refcount(db) > db->db_dirtycnt) { - (void) refcount_add(&db->db_holds, tag); + (void) zfs_refcount_add(&db->db_holds, tag); result = B_TRUE; } mutex_exit(&found_db->db_mtx); |