1. 30 5月, 2012 1 次提交
  2. 14 2月, 2012 1 次提交
  3. 04 1月, 2012 4 次提交
  4. 02 11月, 2011 3 次提交
  5. 26 7月, 2011 1 次提交
  6. 20 7月, 2011 1 次提交
  7. 26 5月, 2011 3 次提交
  8. 31 3月, 2011 1 次提交
  9. 23 2月, 2011 1 次提交
  10. 07 3月, 2011 1 次提交
    • T
      ocfs2: Remove EXIT from masklog. · c1e8d35e
      Tao Ma 提交于
      mlog_exit is used to record the exit status of a function.
      But because it is added in so many functions, if we enable it,
      the system logs get filled up quickly and cause too much I/O.
      So actually no one can open it for a production system or even
      for a test.
      
      This patch just try to remove it or change it. So:
      1. if all the error paths already use mlog_errno, it is just removed.
         Otherwise, it will be replaced by mlog_errno.
      2. if it is used to print some return value, it is replaced with
         mlog(0,...).
      mlog_exit_ptr is changed to mlog(0.
      All those mlog(0,...) will be replaced with trace events later.
      Signed-off-by: NTao Ma <boyu.mt@taobao.com>
      c1e8d35e
  11. 21 2月, 2011 1 次提交
    • T
      ocfs2: Remove ENTRY from masklog. · ef6b689b
      Tao Ma 提交于
      ENTRY is used to record the entry of a function.
      But because it is added in so many functions, if we enable it,
      the system logs get filled up quickly and cause too much I/O.
      So actually no one can open it for a production system or even
      for a test.
      
      So for mlog_entry_void, we just remove it.
      for mlog_entry(...), we replace it with mlog(0,...), and they
      will be replace by trace event later.
      Signed-off-by: NTao Ma <boyu.mt@taobao.com>
      ef6b689b
  12. 02 2月, 2011 1 次提交
    • E
      fs/vfs/security: pass last path component to LSM on inode creation · 2a7dba39
      Eric Paris 提交于
      SELinux would like to implement a new labeling behavior of newly created
      inodes.  We currently label new inodes based on the parent and the creating
      process.  This new behavior would also take into account the name of the
      new object when deciding the new label.  This is not the (supposed) full path,
      just the last component of the path.
      
      This is very useful because creating /etc/shadow is different than creating
      /etc/passwd but the kernel hooks are unable to differentiate these
      operations.  We currently require that userspace realize it is doing some
      difficult operation like that and than userspace jumps through SELinux hoops
      to get things set up correctly.  This patch does not implement new
      behavior, that is obviously contained in a seperate SELinux patch, but it
      does pass the needed name down to the correct LSM hook.  If no such name
      exists it is fine to pass NULL.
      Signed-off-by: NEric Paris <eparis@redhat.com>
      2a7dba39
  13. 13 1月, 2011 1 次提交
  14. 07 1月, 2011 1 次提交
    • N
      fs: dcache reduce branches in lookup path · fb045adb
      Nick Piggin 提交于
      Reduce some branches and memory accesses in dcache lookup by adding dentry
      flags to indicate common d_ops are set, rather than having to check them.
      This saves a pointer memory access (dentry->d_op) in common path lookup
      situations, and saves another pointer load and branch in cases where we
      have d_op but not the particular operation.
      
      Patched with:
      
      git grep -E '[.>]([[:space:]])*d_op([[:space:]])*=' | xargs sed -e 's/\([^\t ]*\)->d_op = \(.*\);/d_set_d_op(\1, \2);/' -e 's/\([^\t ]*\)\.d_op = \(.*\);/d_set_d_op(\&\1, \2);/' -i
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      fb045adb
  15. 23 12月, 2010 1 次提交
  16. 26 10月, 2010 1 次提交
  17. 11 9月, 2010 1 次提交
    • G
      Track negative entries v3 · 5e98d492
      Goldwyn Rodrigues 提交于
      Track negative dentries by recording the generation number of the parent
      directory in d_fsdata. The generation number for the parent directory is
      recorded in the inode_info, which increments every time the lock on the
      directory is dropped.
      
      If the generation number of the parent directory and the negative dentry
      matches, there is no need to perform the revalidate, else a revalidate
      is forced. This improves performance in situations where nodes look for
      the same non-existent file multiple times.
      
      Thanks Mark for explaining the DLM sequence.
      Signed-off-by: NGoldwyn Rodrigues <rgoldwyn@suse.de>
      Signed-off-by: NJoel Becker <joel.becker@oracle.com>
      5e98d492
  18. 08 9月, 2010 3 次提交
    • M
      ocfs2: Fix orphan add in ocfs2_create_inode_in_orphan · 97b8f4a9
      Mark Fasheh 提交于
      ocfs2_create_inode_in_orphan() is used by reflink to create the newly
      reflinked inode simultaneously in the orphan dir. This allows us to easily
      handle partially-reflinked files during recovery cleanup.
      
      We have a problem though - the orphan dir stringifies inode # to determine
      a unique name under which the orphan entry dirent can be created. Since
      ocfs2_create_inode_in_orphan() needs the space allocated in the orphan dir
      before it can allocate the inode, we currently call into the orphan code:
      
             /*
              * We give the orphan dir the root blkno to fake an orphan name,
              * and allocate enough space for our insertion.
              */
             status = ocfs2_prepare_orphan_dir(osb, &orphan_dir,
                                               osb->root_blkno,
                                               orphan_name, &orphan_insert);
      
      Using osb->root_blkno might work fine on unindexed directories, but the
      orphan dir can have an index.  When it has that index, the above code fails
      to allocate the proper index entry.  Later, when we try to remove the file
      from the orphan dir (using the actual inode #), the reflink operation will
      fail.
      
      To fix this, I created a function ocfs2_alloc_orphaned_file() which uses the
      newly split out orphan and inode alloc code to figure out what the inode
      block number will be (once allocated) and then prepare the orphan dir from
      that data.
      Signed-off-by: NMark Fasheh <mfasheh@suse.com>
      Signed-off-by: NTao Ma <tao.ma@oracle.com>
      97b8f4a9
    • M
      ocfs2: split out ocfs2_prepare_orphan_dir() into locking and prep functions · dd43bcde
      Mark Fasheh 提交于
      We do this because ocfs2_create_inode_in_orphan() wants to order locking of
      the orphan dir with respect to locking of the inode allocator *before*
      making any changes to the directory.
      Signed-off-by: NMark Fasheh <mfasheh@suse.com>
      Signed-off-by: NTao Ma <tao.ma@oracle.com>
      dd43bcde
    • M
      ocfs2: split out inode alloc code from ocfs2_mknod_locked · 021960ca
      Mark Fasheh 提交于
      Do this by splitting the bulk of the function away from the inode allocation
      code at the very tom of ocfs2_mknod_locked(). Existing callers don't need to
      change and won't see any difference. The new function created,
      __ocfs2_mknod_locked() will be used shortly.
      Signed-off-by: NMark Fasheh <mfasheh@suse.com>
      Signed-off-by: NTao Ma <tao.ma@oracle.com>
      021960ca
  19. 22 5月, 2010 1 次提交
  20. 11 5月, 2010 1 次提交
  21. 06 5月, 2010 1 次提交
    • J
      ocfs2: Make ocfs2_journal_dirty() void. · ec20cec7
      Joel Becker 提交于
      jbd[2]_journal_dirty_metadata() only returns 0.  It's been returning 0
      since before the kernel moved to git.  There is no point in checking
      this error.
      
      ocfs2_journal_dirty() has been faithfully returning the status since the
      beginning.  All over ocfs2, we have blocks of code checking this can't
      fail status.  In the past few years, we've tried to avoid adding these
      checks, because they are pointless.  But anyone who looks at our code
      assumes they are needed.
      
      Finally, ocfs2_journal_dirty() is made a void function.  All error
      checking is removed from other files.  We'll BUG_ON() the status of
      jbd2_journal_dirty_metadata() just in case they change it someday.  They
      won't.
      Signed-off-by: NJoel Becker <joel.becker@oracle.com>
      ec20cec7
  22. 24 4月, 2010 4 次提交
  23. 24 3月, 2010 1 次提交
  24. 26 3月, 2010 1 次提交
  25. 06 5月, 2010 1 次提交
  26. 05 3月, 2010 3 次提交
    • C
      dquot: cleanup dquot initialize routine · 871a2931
      Christoph Hellwig 提交于
      Get rid of the initialize dquot operation - it is now always called from
      the filesystem and if a filesystem really needs it's own (which none
      currently does) it can just call into it's own routine directly.
      
      Rename the now static low-level dquot_initialize helper to __dquot_initialize
      and vfs_dq_init to dquot_initialize to have a consistent namespace.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NJan Kara <jack@suse.cz>
      871a2931
    • C
      dquot: move dquot initialization responsibility into the filesystem · 907f4554
      Christoph Hellwig 提交于
      Currently various places in the VFS call vfs_dq_init directly.  This means
      we tie the quota code into the VFS.  Get rid of that and make the
      filesystem responsible for the initialization.   For most metadata operations
      this is a straight forward move into the methods, but for truncate and
      open it's a bit more complicated.
      
      For truncate we currently only call vfs_dq_init for the sys_truncate case
      because open already takes care of it for ftruncate and open(O_TRUNC) - the
      new code causes an additional vfs_dq_init for those which is harmless.
      
      For open the initialization is moved from do_filp_open into the open method,
      which means it happens slightly earlier now, and only for regular files.
      The latter is fine because we don't need to initialize it for operations
      on special files, and we already do it as part of the namespace operations
      for directories.
      
      Add a dquot_file_open helper that filesystems that support generic quotas
      can use to fill in ->open.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NJan Kara <jack@suse.cz>
      907f4554
    • C
      dquot: cleanup inode allocation / freeing routines · 63936dda
      Christoph Hellwig 提交于
      Get rid of the alloc_inode and free_inode dquot operations - they are
      always called from the filesystem and if a filesystem really needs
      their own (which none currently does) it can just call into it's
      own routine directly.
      
      Also get rid of the vfs_dq_alloc/vfs_dq_free wrappers and always
      call the lowlevel dquot_alloc_inode / dqout_free_inode routines
      directly, which now lose the number argument which is always 1.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NJan Kara <jack@suse.cz>
      63936dda