NFS: Fix port initialisation in nfs_remount()
The recent changeset 53a0b9c4c9
(NFS: Replace
nfs_parse_ip_address() with rpc_pton()) broke nfs_remount, since the call
to rpc_pton() will zero out the port number in data->nfs_server.address.
This is actually due to a bug in nfs_remount: it should be looking at the
port number in nfs_server.port instead...
This fixes bug
http://bugzilla.kernel.org/show_bug.cgi?id=14276
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
f5855fecda
commit
bcd2ea17da
@ -1846,9 +1846,10 @@ nfs_compare_remount_data(struct nfs_server *nfss,
|
||||
data->acdirmin != nfss->acdirmin / HZ ||
|
||||
data->acdirmax != nfss->acdirmax / HZ ||
|
||||
data->timeo != (10U * nfss->client->cl_timeout->to_initval / HZ) ||
|
||||
data->nfs_server.port != nfss->port ||
|
||||
data->nfs_server.addrlen != nfss->nfs_client->cl_addrlen ||
|
||||
memcmp(&data->nfs_server.address, &nfss->nfs_client->cl_addr,
|
||||
data->nfs_server.addrlen) != 0)
|
||||
!rpc_cmp_addr(&data->nfs_server.address,
|
||||
&nfss->nfs_client->cl_addr))
|
||||
return -EINVAL;
|
||||
|
||||
return 0;
|
||||
@ -1891,6 +1892,7 @@ nfs_remount(struct super_block *sb, int *flags, char *raw_data)
|
||||
data->acdirmin = nfss->acdirmin / HZ;
|
||||
data->acdirmax = nfss->acdirmax / HZ;
|
||||
data->timeo = 10U * nfss->client->cl_timeout->to_initval / HZ;
|
||||
data->nfs_server.port = nfss->port;
|
||||
data->nfs_server.addrlen = nfss->nfs_client->cl_addrlen;
|
||||
memcpy(&data->nfs_server.address, &nfss->nfs_client->cl_addr,
|
||||
data->nfs_server.addrlen);
|
||||
|
Loading…
Reference in New Issue
Block a user