@@ -1935,13 +1935,12 @@ xfs_iunlink_update_dinode(
19351935}
19361936
19371937/* Set an in-core inode's unlinked pointer and return the old value. */
1938- STATIC int
1938+ static int
19391939xfs_iunlink_update_inode (
19401940 struct xfs_trans * tp ,
19411941 struct xfs_inode * ip ,
19421942 struct xfs_perag * pag ,
1943- xfs_agino_t next_agino ,
1944- xfs_agino_t * old_next_agino )
1943+ xfs_agino_t next_agino )
19451944{
19461945 struct xfs_mount * mp = tp -> t_mountp ;
19471946 struct xfs_dinode * dip ;
@@ -1971,8 +1970,6 @@ xfs_iunlink_update_inode(
19711970 * current pointer is the same as the new value, unless we're
19721971 * terminating the list.
19731972 */
1974- if (old_next_agino )
1975- * old_next_agino = old_value ;
19761973 if (old_value == next_agino ) {
19771974 if (next_agino != NULLAGINO ) {
19781975 xfs_inode_verifier_error (ip , - EFSCORRUPTED , __func__ ,
@@ -2026,17 +2023,13 @@ xfs_iunlink_insert_inode(
20262023 return error ;
20272024
20282025 if (next_agino != NULLAGINO ) {
2029- xfs_agino_t old_agino ;
2030-
20312026 /*
20322027 * There is already another inode in the bucket, so point this
20332028 * inode to the current head of the list.
20342029 */
2035- error = xfs_iunlink_update_inode (tp , ip , pag , next_agino ,
2036- & old_agino );
2030+ error = xfs_iunlink_update_inode (tp , ip , pag , next_agino );
20372031 if (error )
20382032 return error ;
2039- ASSERT (old_agino == NULLAGINO );
20402033 ip -> i_next_unlinked = next_agino ;
20412034 }
20422035
@@ -2088,7 +2081,6 @@ xfs_iunlink_remove_inode(
20882081 struct xfs_mount * mp = tp -> t_mountp ;
20892082 struct xfs_agi * agi = agibp -> b_addr ;
20902083 xfs_agino_t agino = XFS_INO_TO_AGINO (mp , ip -> i_ino );
2091- xfs_agino_t next_agino ;
20922084 xfs_agino_t head_agino ;
20932085 short bucket_index = agino % XFS_AGI_UNLINKED_BUCKETS ;
20942086 int error ;
@@ -2111,7 +2103,7 @@ xfs_iunlink_remove_inode(
21112103 * the old pointer value so that we can update whatever was previous
21122104 * to us in the list to point to whatever was next in the list.
21132105 */
2114- error = xfs_iunlink_update_inode (tp , ip , pag , NULLAGINO , & next_agino );
2106+ error = xfs_iunlink_update_inode (tp , ip , pag , NULLAGINO );
21152107 if (error )
21162108 return error ;
21172109
@@ -2132,7 +2124,7 @@ xfs_iunlink_remove_inode(
21322124 return - EFSCORRUPTED ;
21332125
21342126 error = xfs_iunlink_update_inode (tp , prev_ip , pag ,
2135- ip -> i_next_unlinked , NULL );
2127+ ip -> i_next_unlinked );
21362128 prev_ip -> i_next_unlinked = ip -> i_next_unlinked ;
21372129 } else {
21382130 /* Point the head of the list to the next unlinked inode. */
0 commit comments