nfsd: fix the check for confirmed openowner in nfs4_preprocess_stateid_op

commit ebe9cb3bb1 upstream.

If we find a non-confirmed openowner we jump to exit the function, but do
not set an error value.  Fix this by factoring out a helper to do the
check and properly set the error from nfsd4_validate_stateid.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
[ luis: backported to 3.16:
  - return status immediately in nfsd4_validate_stateid() ]
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
This commit is contained in:
Christoph Hellwig 2015-04-28 15:41:15 +02:00 • committed by Luis Henriques
commit 27f6d3e540