--- sys/fs/nfs/nfs_commonkrpc.c.slotpos	2022-08-25 15:56:35.061725000 -0700
+++ sys/fs/nfs/nfs_commonkrpc.c	2022-08-25 16:04:49.447571000 -0700
@@ -1082,12 +1082,12 @@ printf("Disable slot=%d\n", nd->nd_slotid);
 						    }
 						    slot = nd->nd_slotid;
 						}
+						freeslot = slot;
 					} else if (slot != 0) {
 						printf("newnfs_request: Bad "
 						    "session slot=%d\n", slot);
 						slot = 0;
 					}
-					freeslot = slot;
 					if (retseq != sep->nfsess_slotseq[slot])
 						printf("retseq diff 0x%x\n",
 						    retseq);
@@ -1172,6 +1172,9 @@ printf("nfs_commonkrpc: initiate recovery\n");
 						*tl++ = txdr_unsigned(slotseq);
 						*tl++ = txdr_unsigned(slotpos);
 						*tl = txdr_unsigned(maxslot);
+						if ((nd->nd_flag &
+						    ND_HASSLOTID) != 0)
+							nd->nd_slotid = slotpos;
 					}
 					if (reterr == NFSERR_BADSESSION ||
 					    reterr == 0) {
