1169
1169
return (cmount->get_client())->ll_get_inode(vino);
1174
* Populates the client cache with the requested inode, and its
1177
extern "C" int ceph_ll_lookup_inode(
1178
struct ceph_mount_info *cmount,
1179
struct inodeno_t ino,
1182
int r = (cmount->get_client())->lookup_ino(ino, inode);
1187
assert(*inode != NULL);
1190
// Request the parent inode, so that we can look up the name
1192
r = (cmount->get_client())->lookup_parent(*inode, &parent);
1193
if (r && r != -EINVAL) {
1195
(cmount->get_client())->ll_forget(*inode, 1);
1197
} else if (r == -EINVAL) {
1198
// EINVAL indicates node without parents (root), drop out now
1199
// and don't try to look up the non-existent dentry.
1202
assert(parent != NULL);
1204
// Finally, get the name (dentry) of the requested inode
1205
r = (cmount->get_client())->lookup_name(*inode, parent);
1208
(cmount->get_client())->ll_forget(parent, 1);
1209
(cmount->get_client())->ll_forget(*inode, 1);
1213
(cmount->get_client())->ll_forget(parent, 1);
1172
1217
extern "C" int ceph_ll_lookup(class ceph_mount_info *cmount,
1173
1218
struct Inode *parent, const char *name,
1174
1219
struct stat *attr, Inode **out,