92 code =
xfs_ialloc(tp, dp, mode, nlink, rdev, prid, okalloc,
93 &ialloc_context, &ip);
104 if (!ialloc_context && !ip) {
115 if (ialloc_context) {
128 log_res = xfs_trans_get_log_res(tp);
129 log_count = xfs_trans_get_log_count(tp);
139 dqinfo = (
void *)tp->t_dqinfo;
148 if (committed !=
NULL) {
157 xfs_buf_relse(ialloc_context);
159 tp->t_dqinfo = dqinfo;
178 tp->t_dqinfo = dqinfo;
179 tp->t_flags |= tflags;
183 xfs_buf_relse(ialloc_context);
195 code =
xfs_ialloc(tp, dp, mode, nlink, rdev, prid,
196 okalloc, &ialloc_context, &ip);
207 ASSERT(!ialloc_context && ip);
210 if (committed !=
NULL)
234 ASSERT (ip->i_d.di_nlink > 0);
240 if (ip->i_d.di_nlink == 0) {
266 ASSERT(xfs_isilocked(ip, XFS_ILOCK_EXCL));
267 ASSERT(ip->i_d.di_version == 1);
269 ip->i_d.di_version = 2;
270 ip->i_d.di_onlink = 0;
271 memset(&(ip->i_d.di_pad[0]), 0,
sizeof(ip->i_d.di_pad));
273 if (!xfs_sb_version_hasnlink(&mp->m_sb)) {
274 spin_lock(&mp->m_sb_lock);
275 if (!xfs_sb_version_hasnlink(&mp->m_sb)) {
276 xfs_sb_version_addnlink(&mp->m_sb);
277 spin_unlock(&mp->m_sb_lock);
280 spin_unlock(&mp->m_sb_lock);
296 ASSERT(ip->i_d.di_nlink > 0);
299 if ((ip->i_d.di_version == 1) &&