forked from Archive/PX4-Autopilot
NFS fixes
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@4649 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
parent
d045038299
commit
01de46fb3f
|
@ -1223,7 +1223,7 @@ int cmd_nfsmount(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv)
|
|||
FAR char *address;
|
||||
FAR char *target;
|
||||
FAR char *protocol = NULL;
|
||||
struct sockaddr_in *sin = NULL;
|
||||
struct sockaddr_in sin;
|
||||
bool badarg = false;
|
||||
#ifdef CONFIG_NET_IPv6
|
||||
struct in6_addr inaddr;
|
||||
|
@ -1341,10 +1341,11 @@ int cmd_nfsmount(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv)
|
|||
data.version = 3;
|
||||
data.proto = (tcp) ? 6 : 17;
|
||||
data.sotype = (tcp) ? 0 : 1;
|
||||
sin->sin_family = 2;
|
||||
sin->sin_port = htons(2049);
|
||||
sin->sin_addr = inaddr;
|
||||
data.addr = (struct sockaddr *)sin;
|
||||
sin.sin_family = 2;
|
||||
sin.sin_port = htons(2049);
|
||||
sin.sin_addr = inaddr;
|
||||
data.addr = (struct sockaddr *)&sin;
|
||||
data.addrlen = sizeof(struct sockaddr);
|
||||
data.flags = 0x00000200;
|
||||
data.retrans = 3;
|
||||
data.acregmin = 3;
|
||||
|
|
|
@ -346,31 +346,30 @@ struct nfsrv_descript
|
|||
|
||||
struct nfs_args
|
||||
{
|
||||
uint8_t version; /* args structure version number */
|
||||
struct sockaddr *addr; /* file server address */
|
||||
//int addrlen; /* length of address */
|
||||
uint8_t sotype; /* Socket type */
|
||||
uint8_t proto; /* and Protocol */
|
||||
nfsfh_t fh; /* File handle to be mounted */
|
||||
int fhsize; /* Size, in bytes, of fh */
|
||||
int flags; /* flags */
|
||||
int wsize; /* write size in bytes */
|
||||
int rsize; /* read size in bytes */
|
||||
int readdirsize; /* readdir size in bytes */
|
||||
int timeo; /* initial timeout in .1 secs */
|
||||
int retrans; /* times to retry send */
|
||||
int maxgrouplist; /* Max. size of group list */
|
||||
int readahead; /* # of blocks to readahead */
|
||||
int leaseterm; /* Term (sec) of lease */
|
||||
int deadthresh; /* Retrans threshold */
|
||||
//char *hostname; /* server's name */
|
||||
int acregmin; /* cache attrs for reg files min time */
|
||||
int acregmax; /* cache attrs for reg files max time */
|
||||
int acdirmin; /* cache attrs for dirs min time */
|
||||
int acdirmax; /* cache attrs for dirs max time */
|
||||
uint8_t version; /* args structure version number */
|
||||
struct sockaddr *addr; /* file server address */
|
||||
uint8_t addrlen; /* length of address */
|
||||
uint8_t sotype; /* Socket type */
|
||||
uint8_t proto; /* and Protocol */
|
||||
nfsfh_t fh; /* File handle to be mounted */
|
||||
int fhsize; /* Size, in bytes, of fh */
|
||||
int flags; /* flags */
|
||||
int wsize; /* write size in bytes */
|
||||
int rsize; /* read size in bytes */
|
||||
int readdirsize; /* readdir size in bytes */
|
||||
int timeo; /* initial timeout in .1 secs */
|
||||
int retrans; /* times to retry send */
|
||||
int maxgrouplist; /* Max. size of group list */
|
||||
int readahead; /* # of blocks to readahead */
|
||||
int leaseterm; /* Term (sec) of lease */
|
||||
int deadthresh; /* Retrans threshold */
|
||||
//char *hostname; /* server's name */
|
||||
int acregmin; /* cache attrs for reg files min time */
|
||||
int acregmax; /* cache attrs for reg files max time */
|
||||
int acdirmin; /* cache attrs for dirs min time */
|
||||
int acdirmax; /* cache attrs for dirs max time */
|
||||
};
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
****************************************************************************/
|
||||
|
|
Loading…
Reference in New Issue