Re: [PATCH Version 2 1/1] NFSv4.1 set the cl_hostname for data servers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Feb 16, 2012, at 5:00 PM, Adamson, Dros wrote:

> 
> On Feb 16, 2012, at 4:29 PM, Myklebust, Trond wrote:
> 
>> On Thu, 2012-02-16 at 16:10 -0500, andros@xxxxxxxxxx wrote:
>>> From: Andy Adamson <andros@xxxxxxxxxx>
>>> 
>>> Used by /proc/fs/nfsfs/servers
>>> 
>>> Signed-off-by: Andy Adamson <andros@xxxxxxxxxx>
>>> ---
>>> fs/nfs/client.c            |    3 ++-
>>> fs/nfs/internal.h          |    3 ++-
>>> fs/nfs/nfs4filelayoutdev.c |   11 ++++++++++-
>>> 3 files changed, 14 insertions(+), 3 deletions(-)
>>> 
>>> diff --git a/fs/nfs/client.c b/fs/nfs/client.c
>>> index d0f850f..c625284 100644
>>> --- a/fs/nfs/client.c
>>> +++ b/fs/nfs/client.c
>>> @@ -1443,7 +1443,7 @@ error:
>>> */
>>> struct nfs_client *nfs4_set_ds_client(struct nfs_client* mds_clp,
>>> 		const struct sockaddr *ds_addr,
>>> -		int ds_addrlen, int ds_proto)
>>> +		int ds_addrlen, int ds_proto, char *ds_hostname)
>> 
>> Can you make this (and the other instances below) 'const char *', so
>> that we avoid any confusion? Otherwise it looks more or less OK...
>> 
>> Note that we should consider splitting da->da_remotestr into a
>> hostname/port part at some point so that we avoid the copy below.
> 
> da_remotestr (and ds_remotestr) were meant to be for display only (and iirc they can actually be NULL).

^^ dprintk() display, that is.

> 
> The right way to do this is from the actual sin_addr (da_addr).
> 
> -dros

Attachment: smime.p7s
Description: S/MIME cryptographic signature


[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux