NFS4.1: server gets drc mem fail should reply error at create_session
Subsystems (2)
PATCH 1/1 NFS4.1: server gets drc mem fail should reply error at create_session
When server gets drc mem fail, it should reply error to client.
Signed-off-by Mi Jinlong <[email protected]>
--- fs/nfsd/nfs4state.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
fs/nfsd/nfs4state.c +2 -0
@@ -745,6 +745,8 @@ static struct nfsd4_session *alloc_init_session(struct svc_rqst *rqstp, struct n*/ slotsize =nfsd4_sanitize_slot_size (fchan->maxresp_cached); numslots =nfsd4_get_drc_mem (slotsize, fchan->maxreqs); +if (numslots <1 ) +return NULL ; new =alloc_session (slotsize, numslots);if (!new) {
Signature · 1 line
1.7.0.1
Quoted 1 line · Mi Jinlong
When server gets drc mem fail, it should reply error to client.
Whoops, thanks--applying.
--b.
Quoted 24 lines
Signed-off-by Mi Jinlong <[email protected]>--- fs/nfsd/nfs4state.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)fs/nfsd/nfs4state.c +2
-0@@ -745,6 +745,8 @@ static struct nfsd4_session *alloc_init_session(struct svc_rqst *rqstp, struct n*/ slotsize =nfsd4_sanitize_slot_size (fchan->maxresp_cached); numslots =nfsd4_get_drc_mem (slotsize, fchan->maxreqs); +if (numslots <1 ) +return NULL ; new =alloc_session (slotsize, numslots);if (!new) {Signature · 1 line
1.7.0.1