Lines Matching refs:sdp
55 struct gfs2_sbd *sdp; /* incore superblock */ member
85 static unsigned int gl_hash(const struct gfs2_sbd *sdp, in gl_hash() argument
92 h = jhash(&sdp, sizeof(struct gfs2_sbd *), h); in gl_hash()
122 struct gfs2_sbd *sdp = gl->gl_sbd; in gfs2_glock_free() local
125 if (atomic_dec_and_test(&sdp->sd_glock_disposal)) in gfs2_glock_free()
126 wake_up(&sdp->sd_glock_wait); in gfs2_glock_free()
195 struct gfs2_sbd *sdp = gl->gl_sbd; in gfs2_glock_put() local
211 sdp->sd_lockstruct.ls_ops->lm_put_lock(gl); in gfs2_glock_put()
223 const struct gfs2_sbd *sdp, in search_bucket() argument
232 if (gl->gl_sbd != sdp) in search_bucket()
509 struct gfs2_sbd *sdp = gl->gl_sbd; in do_xmote() local
536 if (sdp->sd_lockstruct.ls_ops->lm_lock) { in do_xmote()
538 ret = sdp->sd_lockstruct.ls_ops->lm_lock(gl, target, lck_flags); in do_xmote()
631 struct gfs2_sbd *sdp = gl->gl_sbd; in delete_work_func() local
640 inode = gfs2_ilookup(sdp->sd_vfs, no_addr, 1); in delete_work_func()
642 inode = gfs2_lookup_by_inum(sdp, no_addr, NULL, GFS2_BLKST_UNLINKED); in delete_work_func()
702 int gfs2_glock_get(struct gfs2_sbd *sdp, u64 number, in gfs2_glock_get() argument
706 struct super_block *s = sdp->sd_vfs; in gfs2_glock_get()
709 unsigned int hash = gl_hash(sdp, &name); in gfs2_glock_get()
714 gl = search_bucket(hash, sdp, &name); in gfs2_glock_get()
741 atomic_inc(&sdp->sd_glock_disposal); in gfs2_glock_get()
742 gl->gl_sbd = sdp; in gfs2_glock_get()
754 gl->gl_stats = this_cpu_ptr(sdp->sd_lkstats)->lkstats[glops->go_type]; in gfs2_glock_get()
775 tmp = search_bucket(hash, sdp, &name); in gfs2_glock_get()
780 atomic_dec(&sdp->sd_glock_disposal); in gfs2_glock_get()
931 struct gfs2_sbd *sdp = gl->gl_sbd; in add_to_queue() local
978 if (sdp->sd_lockstruct.ls_ops->lm_cancel) in add_to_queue()
979 sdp->sd_lockstruct.ls_ops->lm_cancel(gl); in add_to_queue()
1009 struct gfs2_sbd *sdp = gl->gl_sbd; in gfs2_glock_nq() local
1012 if (unlikely(test_bit(SDF_SHUTDOWN, &sdp->sd_flags))) in gfs2_glock_nq()
1128 int gfs2_glock_nq_num(struct gfs2_sbd *sdp, u64 number, in gfs2_glock_nq_num() argument
1135 error = gfs2_glock_get(sdp, number, glops, CREATE, &gl); in gfs2_glock_nq_num()
1464 static void examine_bucket(glock_examiner examiner, const struct gfs2_sbd *sdp, in examine_bucket() argument
1473 if ((gl->gl_sbd == sdp) && lockref_get_not_dead(&gl->gl_lockref)) in examine_bucket()
1480 static void glock_hash_walk(glock_examiner examiner, const struct gfs2_sbd *sdp) in glock_hash_walk() argument
1485 examine_bucket(examiner, sdp, x); in glock_hash_walk()
1530 void gfs2_glock_thaw(struct gfs2_sbd *sdp) in gfs2_glock_thaw() argument
1532 glock_hash_walk(thaw_glock, sdp); in gfs2_glock_thaw()
1555 void gfs2_gl_hash_clear(struct gfs2_sbd *sdp) in gfs2_gl_hash_clear() argument
1557 set_bit(SDF_SKIP_DLM_UNLOCK, &sdp->sd_flags); in gfs2_gl_hash_clear()
1559 glock_hash_walk(clear_glock, sdp); in gfs2_gl_hash_clear()
1561 wait_event(sdp->sd_glock_wait, atomic_read(&sdp->sd_glock_disposal) == 0); in gfs2_gl_hash_clear()
1562 glock_hash_walk(dump_glock_func, sdp); in gfs2_gl_hash_clear()
1779 struct gfs2_sbd *sdp = gi->sdp; in gfs2_sbstats_seq_show() local
1792 const struct gfs2_pcpu_lkstats *lkstats = per_cpu_ptr(sdp->sd_lkstats, i); in gfs2_sbstats_seq_show()
1874 } while (gi->sdp != gi->gl->gl_sbd || in gfs2_glock_iter_next()
1989 gi->sdp = inode->i_private; in gfs2_glocks_open()
2004 gi->sdp = inode->i_private; in gfs2_glstats_open()
2019 gi->sdp = inode->i_private; in gfs2_sbstats_open()
2048 int gfs2_create_debugfs_file(struct gfs2_sbd *sdp) in gfs2_create_debugfs_file() argument
2052 dent = debugfs_create_dir(sdp->sd_table_name, gfs2_root); in gfs2_create_debugfs_file()
2055 sdp->debugfs_dir = dent; in gfs2_create_debugfs_file()
2059 sdp->debugfs_dir, sdp, in gfs2_create_debugfs_file()
2063 sdp->debugfs_dentry_glocks = dent; in gfs2_create_debugfs_file()
2067 sdp->debugfs_dir, sdp, in gfs2_create_debugfs_file()
2071 sdp->debugfs_dentry_glstats = dent; in gfs2_create_debugfs_file()
2075 sdp->debugfs_dir, sdp, in gfs2_create_debugfs_file()
2079 sdp->debugfs_dentry_sbstats = dent; in gfs2_create_debugfs_file()
2083 gfs2_delete_debugfs_file(sdp); in gfs2_create_debugfs_file()
2087 void gfs2_delete_debugfs_file(struct gfs2_sbd *sdp) in gfs2_delete_debugfs_file() argument
2089 if (sdp->debugfs_dir) { in gfs2_delete_debugfs_file()
2090 if (sdp->debugfs_dentry_glocks) { in gfs2_delete_debugfs_file()
2091 debugfs_remove(sdp->debugfs_dentry_glocks); in gfs2_delete_debugfs_file()
2092 sdp->debugfs_dentry_glocks = NULL; in gfs2_delete_debugfs_file()
2094 if (sdp->debugfs_dentry_glstats) { in gfs2_delete_debugfs_file()
2095 debugfs_remove(sdp->debugfs_dentry_glstats); in gfs2_delete_debugfs_file()
2096 sdp->debugfs_dentry_glstats = NULL; in gfs2_delete_debugfs_file()
2098 if (sdp->debugfs_dentry_sbstats) { in gfs2_delete_debugfs_file()
2099 debugfs_remove(sdp->debugfs_dentry_sbstats); in gfs2_delete_debugfs_file()
2100 sdp->debugfs_dentry_sbstats = NULL; in gfs2_delete_debugfs_file()
2102 debugfs_remove(sdp->debugfs_dir); in gfs2_delete_debugfs_file()
2103 sdp->debugfs_dir = NULL; in gfs2_delete_debugfs_file()