mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Illumos 6171 - dsl_prop_unregister() slows down dataset eviction.
6171 dsl_prop_unregister() slows down dataset eviction. Reviewed by: Matthew Ahrens <mahrens@delphix.com> Reviewed by: Prakash Surya <prakash.surya@delphix.com> Approved by: Dan McDonald <danmcd@omniti.com> References: https://www.illumos.org/issues/6171 https://github.com/illumos/illumos-gate/commit/03bad06 Porting notes: - Conflicts -3558fd7Prototype/structure update for Linux -2cf7f52Linux compat 2.6.39: mount_nodev() -13fe019Illumos #3464 -241b541Illumos 5959 - clean up per-dataset feature count code - dsl_prop_unregister() preserved until out of tree consumers like Lustre can transition to dsl_prop_unregister_all(). - Fixing 'space or tab at end of line' in include/sys/dsl_dataset.h Ported-by: kernelOfTruth kerneloftruth@gmail.com Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
This commit is contained in:
committed by
Brian Behlendorf
parent
5a28a9737a
commit
0eb21616fa
+12
-2
@@ -41,10 +41,17 @@ struct dsl_dir;
|
||||
/* The callback func may not call into the DMU or DSL! */
|
||||
typedef void (dsl_prop_changed_cb_t)(void *arg, uint64_t newval);
|
||||
|
||||
typedef struct dsl_prop_record {
|
||||
list_node_t pr_node; /* link on dd_props */
|
||||
const char *pr_propname;
|
||||
list_t pr_cbs;
|
||||
} dsl_prop_record_t;
|
||||
|
||||
typedef struct dsl_prop_cb_record {
|
||||
list_node_t cbr_node; /* link on dd_prop_cbs */
|
||||
list_node_t cbr_pr_node; /* link on pr_cbs */
|
||||
list_node_t cbr_ds_node; /* link on ds_prop_cbs */
|
||||
dsl_prop_record_t *cbr_pr;
|
||||
struct dsl_dataset *cbr_ds;
|
||||
const char *cbr_propname;
|
||||
dsl_prop_changed_cb_t *cbr_func;
|
||||
void *cbr_arg;
|
||||
} dsl_prop_cb_record_t;
|
||||
@@ -54,10 +61,13 @@ typedef struct dsl_props_arg {
|
||||
zprop_source_t pa_source;
|
||||
} dsl_props_arg_t;
|
||||
|
||||
void dsl_prop_init(dsl_dir_t *dd);
|
||||
void dsl_prop_fini(dsl_dir_t *dd);
|
||||
int dsl_prop_register(struct dsl_dataset *ds, const char *propname,
|
||||
dsl_prop_changed_cb_t *callback, void *cbarg);
|
||||
int dsl_prop_unregister(struct dsl_dataset *ds, const char *propname,
|
||||
dsl_prop_changed_cb_t *callback, void *cbarg);
|
||||
void dsl_prop_unregister_all(struct dsl_dataset *ds, void *cbarg);
|
||||
void dsl_prop_notify_all(struct dsl_dir *dd);
|
||||
boolean_t dsl_prop_hascb(struct dsl_dataset *ds);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user