| 17796 | } |
| 17797 | |
| 17798 | int Client::fdescribe_layout(int fd, file_layout_t *lp) |
| 17799 | { |
| 17800 | RWRef_t mref_reader(mount_state, CLIENT_MOUNTING); |
| 17801 | if (!mref_reader.is_state_satisfied()) |
| 17802 | return -ENOTCONN; |
| 17803 | |
| 17804 | std::scoped_lock lock(client_lock); |
| 17805 | |
| 17806 | Fh *f = get_filehandle(fd); |
| 17807 | if (!f) |
| 17808 | return -EBADF; |
| 17809 | Inode *in = f->inode.get(); |
| 17810 | |
| 17811 | *lp = in->layout; |
| 17812 | |
| 17813 | ldout(cct, 3) << __func__ << "(" << fd << ") = 0" << dendl; |
| 17814 | return 0; |
| 17815 | } |
| 17816 | |
| 17817 | int64_t Client::get_default_pool_id() |
| 17818 | { |
no test coverage detected