pastebin - collaborative debugging tool
nrubsig.kpaste.net RSS


long path fix+misc
Posted by Anonymous on Sat 16th Mar 2024 13:13
raw | new post
view followups (newest first): long path fix+misc by Anonymous

  1. diff --git a/cygwin/README.bintarball.txt b/cygwin/README.bintarball.txt
  2. index 26cc9c3..a5ea187 100644
  3. --- a/cygwin/README.bintarball.txt
  4. +++ b/cygwin/README.bintarball.txt
  5. @@ -62,7 +62,7 @@ NFSv4.1 client and filesystem driver for Windows 10/11
  6.  # 3. Requirements:
  7.  #
  8.  - Windows 10 or Windows 11
  9. -- Cygwin 3.5.0
  10. +- Cygwin 3.5.1 (or 3.6.x-devel)
  11.      - Packages (required):
  12.          cygwin
  13.          cygwin-devel
  14. diff --git a/daemon/lookup.c b/daemon/lookup.c
  15. index e15046a..044efc0 100644
  16. --- a/daemon/lookup.c
  17. +++ b/daemon/lookup.c
  18. @@ -290,12 +290,15 @@ out:
  19.  static uint32_t max_lookup_components(
  20.      IN const nfs41_session *session)
  21.  {
  22. -#define ROUNDUPDIV(x, y) (((x)+((y)-1))/(y))
  23.      const uint32_t comps = min(
  24.          session->fore_chan_attrs.ca_maxoperations,
  25.          MAX_LOOKUP_COMPONENTS);
  26.  
  27. -    return ROUNDUPDIV(comps-4, 3);
  28. +    /*
  29. +     * Make sure we round this value down, otherwise the NFS server
  30. +     * will not send all requests back
  31. +     */
  32. +    return ((comps-4) / 3);
  33.  }
  34.  
  35.  static uint32_t get_component_array(
  36. diff --git a/daemon/nfs41_ops.c b/daemon/nfs41_ops.c
  37. index 5d0bb20..1fc0c57 100644
  38. --- a/daemon/nfs41_ops.c
  39. +++ b/daemon/nfs41_ops.c
  40. @@ -166,6 +166,13 @@ int nfs41_create_session(nfs41_client *clnt, nfs41_session *session, bool_t try_
  41.      reply.csr_fore_chan_attrs = &session->fore_chan_attrs;
  42.      reply.csr_back_chan_attrs = &session->back_chan_attrs;
  43.  
  44. +    DPRINTF(0, ("nfs41_create_session: "
  45. +        "Requested req.csa_fore_chan_attrs."
  46. +        "(ca_maxoperations=%d,ca_maxrequests=%d)\n",
  47. +        (int)req.csa_fore_chan_attrs.ca_maxoperations,
  48. +        (int)req.csa_fore_chan_attrs.ca_maxrequests));
  49. +
  50. +
  51.      status = compound_encode_send_decode(session, &compound, try_recovery);
  52.      if (status)
  53.          goto out;
  54. @@ -173,6 +180,18 @@ int nfs41_create_session(nfs41_client *clnt, nfs41_session *session, bool_t try_
  55.      if (compound_error(status = compound.res.status))
  56.          goto out;
  57.  
  58. +    DPRINTF(0, ("nfs41_create_session: "
  59. +        "Response from server: session->fore_chan_attrs->"
  60. +        "(ca_maxoperations=%d,ca_maxrequests=%d)\n",
  61. +        (int)session->fore_chan_attrs.ca_maxoperations,
  62. +        (int)session->fore_chan_attrs.ca_maxrequests));
  63. +
  64. +    if (session->fore_chan_attrs.ca_maxoperations < 64) {
  65. +        eprintf("WARNING: Server returned ca_maxoperations(=%d)"
  66. +        " < 64, this will lead to bad performance\n",
  67. +        session->fore_chan_attrs.ca_maxoperations);
  68. +    }
  69. +
  70.      print_hexbuf(1, (unsigned char *)"session id: ", session->session_id, NFS4_SESSIONID_SIZE);
  71.      // check that csa_sequence is same as csr_sequence
  72.      if (reply.csr_sequence != clnt->seq_id) {

Submit a correction or amendment below (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.

Syntax highlighting:

To highlight particular lines, prefix each line with {%HIGHLIGHT}




All content is user-submitted.
The administrators of this site (kpaste.net) are not responsible for their content.
Abuse reports should be emailed to us at