Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

nfsd: when CB_SEQUENCE gets ESERVERFAULT don't increment seq_nr

ESERVERFAULT means that the server sent a successful and legitimate
reply, but the session info didn't match what was expected. Don't
increment the seq_nr in that case.

Signed-off-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>

authored by

Jeff Layton and committed by
Chuck Lever
bf36c149 f049911b

+6 -1
+6 -1
fs/nfsd/nfs4callback.c
··· 1363 1363 ret = true; 1364 1364 break; 1365 1365 case -ESERVERFAULT: 1366 - ++session->se_cb_seq_nr[cb->cb_held_slot]; 1366 + /* 1367 + * Call succeeded, but the session, slot index, or slot 1368 + * sequence number in the response do not match the same 1369 + * in the server's call. The sequence information is thus 1370 + * untrustworthy. 1371 + */ 1367 1372 nfsd4_mark_cb_fault(cb->cb_clp); 1368 1373 break; 1369 1374 case 1: