1. 22 Jun, 2015 3 commits
  2. 19 Jun, 2015 3 commits
  3. 04 Jun, 2015 7 commits
    • Chuck Lever's avatar
      rpcrdma: Merge svcrdma and xprtrdma modules into one · ffe1f0df
      Chuck Lever authored
      Bi-directional RPC support means code in svcrdma.ko invokes a bit of
      code in xprtrdma.ko, and vice versa. To avoid loader/linker loops,
      merge the server and client side modules together into a single
      module.
      
      When backchannel capabilities are added, the combined module will
      register all needed transport capabilities so that Upper Layer
      consumers automatically have everything needed to create a
      bi-directional transport connection.
      
      Module aliases are added for backwards compatibility with user
      space, which still may expect svcrdma.ko or xprtrdma.ko to be
      present.
      
      This commit reverts commit 2e8c12e1 ("xprtrdma: add separate
      Kconfig options for NFSoRDMA client and server support") and
      provides a single CONFIG option for enabling the new module.
      Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      ffe1f0df
    • Chuck Lever's avatar
      svcrdma: Add a separate "max data segs macro for svcrdma · 0380a3f3
      Chuck Lever authored
      The server and client maximum are architecturally independent.
      Allow changing one without affecting the other.
      Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      0380a3f3
    • Chuck Lever's avatar
      svcrdma: Replace GFP_KERNEL in a loop with GFP_NOFAIL · b7e0b9a9
      Chuck Lever authored
      At the 2015 LSF/MM, it was requested that memory allocation
      call sites that request GFP_KERNEL allocations in a loop should be
      annotated with __GFP_NOFAIL.
      Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      b7e0b9a9
    • Chuck Lever's avatar
      svcrdma: Keep rpcrdma_msg fields in network byte-order · 30b7e246
      Chuck Lever authored
      Fields in struct rpcrdma_msg are __be32. Don't byte-swap these
      fields when decoding RPC calls and then swap them back for the
      reply. For the most part, they can be left alone.
      Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      30b7e246
    • Chuck Lever's avatar
      svcrdma: Fix byte-swapping in svc_rdma_sendto.c · 70747c25
      Chuck Lever authored
      In send_write_chunks(), we have:
      
      	for (xdr_off = rqstp->rq_res.head[0].iov_len, chunk_no = 0;
      	     xfer_len && chunk_no < arg_ary->wc_nchunks;
      	     chunk_no++) {
      		 . . .
      	}
      
      Note that arg_ary->wc_nchunk is in network byte-order. For the
      comparison to work correctly, both have to be in native byte-order.
      
      In send_reply_chunks, we have:
      
      	write_len = min(xfer_len, htonl(ch->rs_length));
      
      xfer_len is in native byte-order, and ch->rs_length is in
      network byte-order. be32_to_cpu() is the correct byte swap
      for ch->rs_length.
      
      As an additional clean up, replace ntohl() with be32_to_cpu() in
      a few other places.
      
      This appears to address a problem with large rsize hangs while
      using PHYSICAL memory registration. I suspect that is the only
      registration mode that uses more than one chunk element.
      
      BugLink: https://bugzilla.linux-nfs.org/show_bug.cgi?id=248Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      70747c25
    • Kinglong Mee's avatar
      nfsd: Update callback sequnce id only CB_SEQUENCE success · 276f03e3
      Kinglong Mee authored
      When testing pnfs layout, nfsd got error NFS4ERR_SEQ_MISORDERED.
      It is caused by nfs return NFS4ERR_DELAY before validate_seqid(),
      don't update the sequnce id, but nfsd updates the sequnce id !!!
      
      According to RFC5661 20.9.3,
      " If CB_SEQUENCE returns an error, then the state of the slot
      (sequence ID, cached reply) MUST NOT change. "
      Signed-off-by: default avatarKinglong Mee <kinglongmee@gmail.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      276f03e3
    • Kinglong Mee's avatar
      nfsd: Reset cb_status in nfsd4_cb_prepare() at retrying · 4399396e
      Kinglong Mee authored
      nfsd enters a infinite loop and prints message every 10 seconds:
      
      May 31 18:33:52 test-server kernel: Error sending entire callback!
      May 31 18:34:01 test-server kernel: Error sending entire callback!
      
      This is caused by a cb_layoutreturn getting error -10008
      (NFS4ERR_DELAY), the client crashing, and then nfsd entering the
      infinite loop:
      
        bc_sendto --> call_timeout --> nfsd4_cb_done --> nfsd4_cb_layout_done
        with error -10008 --> rpc_delay(task, HZ/100) --> bc_sendto ...
      
      Reproduced using xfstests 074 with nfs client's kdump on,
      CONFIG_DEFAULT_HUNG_TASK_TIMEOUT set, and client's blkmapd down:
      
      1. nfs client's write operation will get the layout of file,
         and then send getdeviceinfo,
      2. but layout segment is not recorded by client because blkmapd is down,
      3. client writes data by sending WRITE to server,
      4. nfs server recalls the layout of the file before WRITE,
      5. network error causes the client reset the session and return NFS4ERR_DELAY,
      6. so client's WRITE operation is waiting the reply.
         If the task hangs 120s, the client will crash.
      7. so that, the next bc_sendto will fail with TIMEOUT,
         and cb_status is NFS4ERR_DELAY.
      Signed-off-by: default avatarKinglong Mee <kinglongmee@gmail.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
      4399396e
  4. 03 Jun, 2015 2 commits
  5. 01 Jun, 2015 1 commit
  6. 29 May, 2015 4 commits
  7. 07 May, 2015 1 commit
  8. 04 May, 2015 12 commits
  9. 03 May, 2015 7 commits