Lines Matching defs:mdsc
42 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dentry->d_sb);
54 atomic64_inc(&mdsc->metric.total_dentries);
314 struct ceph_mds_client *mdsc = fsc->mdsc;
353 __ceph_touch_fmode(ci, mdsc, CEPH_FILE_MODE_WR);
396 req = ceph_mdsc_create_request(mdsc, op, USE_AUTH_MDS);
444 err = ceph_mdsc_do_request(mdsc, NULL, req);
775 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dir->i_sb);
813 __ceph_touch_fmode(ci, mdsc, CEPH_FILE_MODE_RD);
825 req = ceph_mdsc_create_request(mdsc, op, USE_ANY_MDS);
839 err = ceph_mdsc_do_request(mdsc, NULL, req);
887 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dir->i_sb);
906 req = ceph_mdsc_create_request(mdsc, CEPH_MDS_OP_MKNOD, USE_AUTH_MDS);
935 err = ceph_mdsc_do_request(mdsc, dir, req);
995 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dir->i_sb);
1014 req = ceph_mdsc_create_request(mdsc, CEPH_MDS_OP_SYMLINK, USE_AUTH_MDS);
1051 err = ceph_mdsc_do_request(mdsc, dir, req);
1066 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dir->i_sb);
1101 req = ceph_mdsc_create_request(mdsc, op, USE_AUTH_MDS);
1127 err = ceph_mdsc_do_request(mdsc, dir, req);
1146 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dir->i_sb);
1166 req = ceph_mdsc_create_request(mdsc, CEPH_MDS_OP_LINK, USE_AUTH_MDS);
1187 err = ceph_mdsc_do_request(mdsc, dir, req);
1198 static void ceph_async_unlink_cb(struct ceph_mds_client *mdsc,
1294 struct ceph_mds_client *mdsc = fsc->mdsc;
1313 req = ceph_mdsc_create_request(mdsc, op, USE_AUTH_MDS);
1347 err = ceph_mdsc_submit_request(mdsc, dir, req);
1372 err = ceph_mdsc_do_request(mdsc, dir, req);
1386 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(old_dir->i_sb);
1418 req = ceph_mdsc_create_request(mdsc, op, USE_AUTH_MDS);
1439 err = ceph_mdsc_do_request(mdsc, old_dir, req);
1453 * Move dentry to tail of mdsc->dentry_leases list when lease is updated.
1462 struct ceph_mds_client *mdsc;
1472 mdsc = ceph_sb_to_client(dn->d_sb)->mdsc;
1473 spin_lock(&mdsc->dentry_list_lock);
1474 list_move_tail(&di->lease_list, &mdsc->dentry_leases);
1475 spin_unlock(&mdsc->dentry_list_lock);
1478 static void __dentry_dir_lease_touch(struct ceph_mds_client* mdsc,
1484 list_move_tail(&di->lease_list, &mdsc->dentry_dir_leases);
1488 * When dir lease is used, add dentry to tail of mdsc->dentry_dir_leases
1496 struct ceph_mds_client *mdsc;
1519 mdsc = ceph_sb_to_client(dn->d_sb)->mdsc;
1520 spin_lock(&mdsc->dentry_list_lock);
1521 __dentry_dir_lease_touch(mdsc, di),
1522 spin_unlock(&mdsc->dentry_list_lock);
1527 struct ceph_mds_client *mdsc;
1533 mdsc = ceph_sb_to_client(di->dentry->d_sb)->mdsc;
1534 spin_lock(&mdsc->dentry_list_lock);
1536 spin_unlock(&mdsc->dentry_list_lock);
1554 __dentry_leases_walk(struct ceph_mds_client *mdsc,
1565 list = lwc->dir_lease ? &mdsc->dentry_dir_leases : &mdsc->dentry_leases;
1566 spin_lock(&mdsc->dentry_list_lock);
1587 __dentry_dir_lease_touch(mdsc, di);
1611 spin_unlock(&mdsc->dentry_list_lock);
1622 spin_lock(&mdsc->dentry_list_lock);
1625 &mdsc->dentry_leases);
1627 __dentry_dir_lease_touch(mdsc, di);
1629 spin_unlock(&mdsc->dentry_list_lock);
1681 int ceph_trim_dentries(struct ceph_mds_client *mdsc)
1687 spin_lock(&mdsc->caps_list_lock);
1688 if (mdsc->caps_use_max > 0 &&
1689 mdsc->caps_use_count > mdsc->caps_use_max)
1690 count = mdsc->caps_use_count - mdsc->caps_use_max;
1693 spin_unlock(&mdsc->caps_list_lock);
1697 freed = __dentry_leases_walk(mdsc, &lwc, __dentry_lease_check);
1706 lwc.dir_lease_ttl = mdsc->fsc->mount_options->caps_wanted_delay_max * HZ;
1707 freed +=__dentry_leases_walk(mdsc, &lwc, __dir_lease_check);
1832 struct ceph_mds_client *mdsc)
1841 __ceph_touch_fmode(ci, mdsc, CEPH_FILE_MODE_RD);
1869 struct ceph_mds_client *mdsc;
1891 mdsc = ceph_sb_to_client(dir->i_sb)->mdsc;
1904 if (valid || dir_lease_is_valid(dir, dentry, mdsc)) {
1920 percpu_counter_inc(&mdsc->metric.d_lease_mis);
1924 req = ceph_mdsc_create_request(mdsc, op, USE_ANY_MDS);
1936 err = ceph_mdsc_do_request(mdsc, NULL, req);
1955 percpu_counter_inc(&mdsc->metric.d_lease_hit);
2002 atomic64_dec(&fsc->mdsc->metric.total_dentries);