1. 31 10月, 2011 1 次提交
  2. 21 10月, 2011 1 次提交
  3. 20 10月, 2011 4 次提交
  4. 19 10月, 2011 17 次提交
  5. 27 9月, 2011 1 次提交
  6. 14 9月, 2011 2 次提交
    • S
      nfs: Do not allow multiple mounts on same mountpoint when using -o noac · fb2088cc
      Sachin Prabhu 提交于
      Do not allow multiple mounts on same mountpoint when using -o noac
      
      When you normally attempt to mount a share twice on the same mountpoint,
      a check in do_add_mount causes it to return an error
      
      # mount localhost:/nfsv3 /mnt
      # mount localhost:/nfsv3 /mnt
      mount.nfs: /mnt is already mounted or busy
      
      However when using the option 'noac', the user is able to mount the same
      share on the same mountpoint multiple times. This happens because a
      share mounted with the noac option is automatically assigned the 'sync'
      flag MS_SYNCHRONOUS in nfs_initialise_sb(). This flag is set after the
      check for already existing superblocks is done in sget(). The check for
      the mount flags in nfs_compare_mount_options() does not take into
      account the 'sync' flag applied later on in the code path. This means
      that when using 'noac', a new superblock structure is assigned for every
      new mount of the same share and multiple shares on the same mountpoint
      are allowed.
      
      ie.
      # mount -onoac localhost:/nfsv3 /mnt
      can be run multiple times.
      
      The patch checks for noac and assigns the sync flag before sget() is
      called to obtain an already existing superblock structure.
      Signed-off-by: NSachin Prabhu <sprabhu@redhat.com>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      fb2088cc
    • T
      NFS: Fix a typo in nfs_flush_multi · f13c3620
      Trond Myklebust 提交于
      Fix a typo which causes an Oops in the RPC layer, when using wsize < 4k.
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      Tested-by: NSricharan R <r.sricharan@ti.com>
      f13c3620
  7. 25 8月, 2011 4 次提交
  8. 12 8月, 2011 1 次提交
  9. 11 8月, 2011 1 次提交
  10. 04 8月, 2011 5 次提交
    • T
      NFSv4.1: Return NFS4ERR_BADSESSION to callbacks during session resets · 910ac68a
      Trond Myklebust 提交于
      If the client is in the process of resetting the session when it receives
      a callback, then returning NFS4ERR_DELAY may cause a deadlock with the
      DESTROY_SESSION call.
      
      Basically, if the client returns NFS4ERR_DELAY in response to the
      CB_SEQUENCE call, then the server is entitled to believe that the
      client is busy because it is already processing that call. In that
      case, the server is perfectly entitled to respond with a
      NFS4ERR_BACK_CHAN_BUSY to any DESTROY_SESSION call.
      
      Fix this by having the client reply with a NFS4ERR_BADSESSION in
      response to the callback if it is resetting the session.
      
      Cc: stable@kernel.org [2.6.38+]
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      910ac68a
    • T
      NFSv4.1: Fix the callback 'highest_used_slotid' behaviour · 55a67399
      Trond Myklebust 提交于
      Currently, there is no guarantee that we will call nfs4_cb_take_slot() even
      though nfs4_callback_compound() will consistently call
      nfs4_cb_free_slot() provided the cb_process_state has set the 'clp' field.
      The result is that we can trigger the BUG_ON() upon the next call to
      nfs4_cb_take_slot().
      
      This patch fixes the above problem by using the slot id that was taken in
      the CB_SEQUENCE operation as a flag for whether or not we need to call
      nfs4_cb_free_slot().
      It also fixes an atomicity problem: we need to set tbl->highest_used_slotid
      atomically with the check for NFS4_SESSION_DRAINING, otherwise we end up
      racing with the various tests in nfs4_begin_drain_session().
      
      Cc: stable@kernel.org [2.6.38+]
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      55a67399
    • B
      pnfs-obj: Fix the comp_index != 0 case · 9af7db32
      Boaz Harrosh 提交于
      There were bugs in the case of partial layout where olo_comp_index
      is not zero. This used to work and was tested but one of the later
      cleanup SQUASHMEs broke it and was not tested since.
      
      Also add a dprint that specify those received layout parameters.
      Everything else was already printed.
      
      [Needed in v3.0]
      CC: Stable Tree <stable@kernel.org>
      Signed-off-by: NBoaz Harrosh <bharrosh@panasas.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      9af7db32
    • B
      pnfs-obj: Bug when we are running out of bio · 20618b21
      Boaz Harrosh 提交于
      When we have a situation that the number of pages we want
      to encode is bigger then the size of the bio. (Which can
      currently happen only when all IO is going to a single device
      .e.g group_width==1) then the IO is submitted short and we
      report back only the amount of bytes we actually wrote/read
      and all is fine. BUT ...
      
      There was a bug that the current length counter was advanced
      before the fail to add the extra page, and we come to a situation
      that the CDB length was one-page longer then the actual bio size,
      which is of course rejected by the osd-target.
      
      While here also fix the bio size calculation, in the case
      that we received more then one group of devices.
      
      CC: Stable Tree <stable@kernel.org>
      Signed-off-by: NBoaz Harrosh <bharrosh@panasas.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      20618b21
    • H
      nfs: add missing prefetch.h include · 88c9e421
      Heiko Carstens 提交于
      Fix this compile error on s390:
      
        CC [M]  fs/nfs/blocklayout/blocklayout.o
      fs/nfs/blocklayout/blocklayout.c: In function 'bl_end_io_read':
      fs/nfs/blocklayout/blocklayout.c:201:4: error: implicit declaration of function 'prefetchw'
      
      Introduced with 9549ec01 "pnfsblock: bl_read_pagelist".
      
      Cc: Fred Isaman <iisaman@citi.umich.edu>
      Signed-off-by: NHeiko Carstens <heiko.carstens@de.ibm.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      88c9e421
  11. 01 8月, 2011 3 次提交