NFSD: don't report compiled-out versions as present
Subsystems (2)
PATCH 1/1 NFSD: don't report compiled-out versions as present
The /proc/fs/nfsd/versions file calls nfsd_vers() to check whether the particular nfsd version is present/available. The problem is that once I turn off e.g. NFSD-V4 this call returns -1 which is true from the callers POV which is wrong.
The proposal is to report false in that case.
Patch is against git://linux-nfs.org/~bfields/linux:master
---
fs/nfsd/nfssvc.c +1 -1
@@ -120,7 +120,7 @@ u32 nfsd_supported_minorversion;int nfsd_vers (int vers,enum vers_op change) {if (vers <NFSD_MINVERS || vers >=NFSD_NRVERS ) -return -1 ; +return 0 ;switch (change) {case NFSD_SET : nfsd_versions[vers] = nfsd_version[vers];
Quoted 8 lines · Pavel Emelyanov
The
/proc/fs/nfsd/versionsfile callsnfsd_vers()to check whether the particular nfsd version is present/available. The problem is that once I turn off e.g. NFSD-V4 this call returns -1 which is true from the callers POV which is wrong.The proposal is to report false in that case.
Patch is against
git://linux-nfs.org/~bfields/linux:master
Thanks, applying for 2.6.35 and -stable; looks like this exists since 6658d3a7bbfd1768a7b599def47939417f0ee8ef?
--b.
Quoted 19 lines
Signed-off-by Pavel Emelyanov <[email protected]>---
fs/nfsd/nfssvc.c +1
-1@@ -120,7 +120,7 @@ u32 nfsd_supported_minorversion;int nfsd_vers (int vers,enum vers_op change) {if (vers <NFSD_MINVERS || vers >=NFSD_NRVERS ) -return -1 ; +return 0 ;switch (change) {case NFSD_SET : nfsd_versions[vers] = nfsd_version[vers];
Neil Brown
Acked-byQuoted 6 lines · On Fri, 14 May 2010 15:03:40 -0400 "J. Bruce Fields" <[email protected]>…
Quoted 5 lines · Pavel Emelyanov
The
/proc/fs/nfsd/versionsfile callsnfsd_vers()to check whether the particular nfsd version is present/available. The problem is that once I turn off e.g. NFSD-V4 this call returns -1 which is true from the callers POV which is wrong.
Quoted 6 lines
Quoted 3 lines
The proposal is to report false in that case.
Patch is against
git://linux-nfs.org/~bfields/linux:masterThanks, applying for 2.6.35 and -stable; looks like this exists since
6658d3a7bbfd1768a7b599def47939417f0ee8ef?
Ouch-yes :-(
NeilBrown
Quoted 26 lines
--b.
Quoted 11 lines
Signed-off-by Pavel Emelyanov <[email protected]>---
fs/nfsd/nfssvc.c +0
-0fs/nfsd/nfssvc.c u32 nfsd_supported_minorversion; · line 126
Quoted 8 lines
fs/nfsd/nfssvc.c +1
-1@@ -120,7 +120,7 @@ u32 nfsd_supported_minorversion;int nfsd_vers (int vers,enum vers_op change) {if (vers <NFSD_MINVERS || vers >=NFSD_NRVERS ) -return -1 ; +return 0 ;switch (change) {case NFSD_SET : nfsd_versions[vers] = nfsd_version[vers];--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html