File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -1523,6 +1523,17 @@ static const struct rpc_call_ops nfs_commit_ops = {
15231523 .rpc_release = nfs_commit_release ,
15241524};
15251525
1526+ static int nfs_generic_commit_list (struct inode * inode , struct list_head * head ,
1527+ int how )
1528+ {
1529+ int status ;
1530+
1531+ status = pnfs_commit_list (inode , head , how );
1532+ if (status == PNFS_NOT_ATTEMPTED )
1533+ status = nfs_commit_list (inode , head , how );
1534+ return status ;
1535+ }
1536+
15261537int nfs_commit_inode (struct inode * inode , int how )
15271538{
15281539 LIST_HEAD (head );
@@ -1536,9 +1547,7 @@ int nfs_commit_inode(struct inode *inode, int how)
15361547 if (res ) {
15371548 int error ;
15381549
1539- error = pnfs_commit_list (inode , & head , how );
1540- if (error == PNFS_NOT_ATTEMPTED )
1541- error = nfs_commit_list (inode , & head , how );
1550+ error = nfs_generic_commit_list (inode , & head , how );
15421551 if (error < 0 )
15431552 return error ;
15441553 if (!may_wait )
You can’t perform that action at this time.
0 commit comments