Whamcloud - gitweb
LU-10769 osd-zfs: fix deadlock on osd_object::oo_guard
[fs/lustre-release.git] / lustre / osd-zfs / osd_internal.h
index 5d423cc..4877600 100644 (file)
@@ -97,6 +97,8 @@
 
 #define OSD_GRANT_FOR_LOCAL_OIDS (2ULL << 20) /* 2MB for last_rcvd, ... */
 
+extern struct dt_body_operations osd_body_scrub_ops;
+
 /**
  * Iterator's in-memory data structure for quota file.
  */
@@ -253,6 +255,8 @@ struct osd_thread_info {
        struct osd_idmap_cache *oti_ins_cache;
        int                    oti_ins_cache_size;
        int                    oti_ins_cache_used;
+       /* inc by osd_trans_create and dec by osd_trans_stop */
+       int                    oti_ins_cache_depth;
        struct lu_buf          oti_xattr_lbuf;
        zap_cursor_t           oti_zc;
        zap_cursor_t           oti_zc2;
@@ -605,7 +609,6 @@ int __osd_attr_init(const struct lu_env *env, struct osd_device *osd,
                    struct lu_attr *la, uint64_t parent, nvlist_t *);
 int osd_find_new_dnode(const struct lu_env *env, dmu_tx_t *tx,
                       uint64_t oid, dnode_t **dnp);
-int osd_object_init0(const struct lu_env *env, struct osd_object *obj);
 
 /* osd_oi.c */
 int osd_oi_init(const struct lu_env *env, struct osd_device *o);
@@ -669,6 +672,7 @@ int osd_scrub_setup(const struct lu_env *env, struct osd_device *dev);
 void osd_scrub_cleanup(const struct lu_env *env, struct osd_device *dev);
 int osd_scrub_start(const struct lu_env *env, struct osd_device *dev,
                    __u32 flags);
+void osd_scrub_stop(struct osd_device *dev);
 int osd_oii_insert(const struct lu_env *env, struct osd_device *dev,
                   const struct lu_fid *fid, uint64_t oid, bool insert);
 int osd_oii_lookup(struct osd_device *dev, const struct lu_fid *fid,