1. 15 3月, 2011 6 次提交
  2. 14 3月, 2011 8 次提交
    • A
      exportfs: Return the minimum required handle size · 5fe0c237
      Aneesh Kumar K.V 提交于
      The exportfs encode handle function should return the minimum required
      handle size. This helps user to find out the handle size by passing 0
      handle size in the first step and then redoing to the call again with
      the returned handle size value.
      Acked-by: NSerge Hallyn <serue@us.ibm.com>
      Signed-off-by: NAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      5fe0c237
    • A
      clean statfs-like syscalls up · c8b91acc
      Al Viro 提交于
      New helpers: user_statfs() and fd_statfs(), taking userland pathname and
      descriptor resp. and filling struct kstatfs.  Syscalls of statfs family
      (native, compat and foreign - osf and hpux on alpha and parisc resp.)
      switched to those.  Removes some boilerplate code, simplifies cleanup
      on errors...
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      c8b91acc
    • A
      open-style analog of vfs_path_lookup() · 73d049a4
      Al Viro 提交于
      new function: file_open_root(dentry, mnt, name, flags) opens the file
      vfs_path_lookup would arrive to.
      
      Note that name can be empty; in that case the usual requirement that
      dentry should be a directory is lifted.
      
      open-coded equivalents switched to it, may_open() got down exactly
      one caller and became static.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      73d049a4
    • A
      reduce vfs_path_lookup() to do_path_lookup() · 5b6ca027
      Al Viro 提交于
      New lookup flag: LOOKUP_ROOT.  nd->root is set (and held) by caller,
      path_init() starts walking from that place and all pathname resolution
      machinery never drops nd->root if that flag is set.  That turns
      vfs_path_lookup() into a special case of do_path_lookup() *and*
      gets us down to 3 callers of link_path_walk(), making it finally
      feasible to rip the handling of trailing symlink out of link_path_walk().
      That will not only simply the living hell out of it, but make life
      much simpler for unionfs merge.  Trailing symlink handling will
      become iterative, which is a good thing for stack footprint in
      a lot of situations as well.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      5b6ca027
    • A
      get rid of nd->file · 70e9b357
      Al Viro 提交于
      Don't stash the struct file * used as starting point of walk in nameidata;
      pass file ** to path_init() instead.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      70e9b357
    • A
      switch do_filp_open() to struct open_flags · 47c805dc
      Al Viro 提交于
      take calculation of open_flags by open(2) arguments into new helper
      in fs/open.c, move filp_open() over there, have it and do_sys_open()
      use that helper, switch exec.c callers of do_filp_open() to explicit
      (and constant) struct open_flags.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      47c805dc
    • A
      untangle the "need_reval_dot" mess · 16c2cd71
      Al Viro 提交于
      instead of ad-hackery around need_reval_dot(), do the following:
      set a flag (LOOKUP_JUMPED) in the beginning of path, on absolute
      symlink traversal, on ".." and on procfs-style symlinks.  Clear on
      normal components, leave unchanged on ".".  Non-nested callers of
      link_path_walk() call handle_reval_path(), which checks that flag
      is set and that fs does want the final revalidate thing, then does
      ->d_revalidate().  In link_path_walk() all the return_reval stuff
      is gone.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      16c2cd71
    • A
      kill path_lookup() · c9c6cac0
      Al Viro 提交于
      all remaining callers pass LOOKUP_PARENT to it, so
      flags argument can die; renamed to kern_path_parent()
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      c9c6cac0
  3. 12 3月, 2011 2 次提交
    • T
      NFSv4/4.1: Fix nfs4_schedule_state_recovery abuses · 0400a6b0
      Trond Myklebust 提交于
      nfs4_schedule_state_recovery() should only be used when we need to force
      the state manager to check the lease. If we just want to start the
      state manager in order to handle a state recovery situation, we should be
      using nfs4_schedule_state_manager().
      
      This patch fixes the abuses of nfs4_schedule_state_recovery() by replacing
      its use with a set of helper functions that do the right thing.
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      0400a6b0
    • L
      plist: Shrink struct plist_head · bf6a9b83
      Lai Jiangshan 提交于
      struct plist_head is used in struct task_struct as well as struct
      rtmutex. If we can make it smaller, it will also make these structures
      smaller as well.
      
      The field prio_list in struct plist_head is seldom used and we can get
      its information from the plist_nodes. Removing this field will decrease
      the size of plist_head by half.
      Signed-off-by: NLai Jiangshan <laijs@cn.fujitsu.com>
      LKML-Reference: <4D107982.9090700@cn.fujitsu.com>
      Signed-off-by: NSteven Rostedt <rostedt@goodmis.org>
      bf6a9b83
  4. 11 3月, 2011 9 次提交
  5. 10 3月, 2011 3 次提交
  6. 09 3月, 2011 1 次提交
  7. 08 3月, 2011 2 次提交
    • S
      debugobjects: Add hint for better object identification · 99777288
      Stanislaw Gruszka 提交于
      In complex subsystems like mac80211 structures can contain several
      timers and work structs, so identifying a specific instance from the
      call trace and object type output of debugobjects can be hard.
      
      Allow the subsystems which support debugobjects to provide a hint
      function. This function returns a pointer to a kernel address
      (preferrably the objects callback function) which is printed along
      with the debugobjects type.
      
      Add hint methods for timer_list, work_struct and hrtimer.
      
      [ tglx: Massaged changelog, made it compile ]
      Signed-off-by: NStanislaw Gruszka <sgruszka@redhat.com>
      LKML-Reference: <20110307085809.GA9334@redhat.com>
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      99777288
    • A
      unfuck proc_sysctl ->d_compare() · dfef6dcd
      Al Viro 提交于
      a) struct inode is not going to be freed under ->d_compare();
      however, the thing PROC_I(inode)->sysctl points to just might.
      Fortunately, it's enough to make freeing that sucker delayed,
      provided that we don't step on its ->unregistering, clear
      the pointer to it in PROC_I(inode) before dropping the reference
      and check if it's NULL in ->d_compare().
      
      b) I'm not sure that we *can* walk into NULL inode here (we recheck
      dentry->seq between verifying that it's still hashed / fetching
      dentry->d_inode and passing it to ->d_compare() and there's no
      negative hashed dentries in /proc/sys/*), but if we can walk into
      that, we really should not have ->d_compare() return 0 on it!
      Said that, I really suspect that this check can be simply killed.
      Nick?
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      dfef6dcd
  8. 05 3月, 2011 5 次提交
  9. 03 3月, 2011 2 次提交
    • T
      blktrace: Remove blk_fill_rwbs_rq. · 2d3a8497
      Tao Ma 提交于
      If we enable trace events to trace block actions, We use
      blk_fill_rwbs_rq to analyze the corresponding actions
      in request's cmd_flags, but we only choose the minor 2 bits
      from it, so most of other flags(e.g, REQ_SYNC) are missing.
      For example, with a sync write we get:
      write_test-2409  [001]   160.013869: block_rq_insert: 3,64 W 0 () 258135 + =
      8 [write_test]
      
      Since now we have integrated the flags of both bio and request,
      it is safe to pass rq->cmd_flags directly to blk_fill_rwbs and
      blk_fill_rwbs_rq isn't needed any more.
      
      With this patch, after a sync write we get:
      write_test-2417  [000]   226.603878: block_rq_insert: 3,64 WS 0 () 258135 +=
       8 [write_test]
      Signed-off-by: NTao Ma <boyu.mt@taobao.com>
      Acked-by: NJeff Moyer <jmoyer@redhat.com>
      Signed-off-by: NJens Axboe <jaxboe@fusionio.com>
      2d3a8497
    • A
      RxRPC: Fix v1 keys · f009918a
      Anton Blanchard 提交于
      commit 33941284 (RxRPC: Allow key payloads to be passed in XDR form)
      broke klog for me. I notice the v1 key struct had a kif_version field
      added:
      
      -struct rxkad_key {
      -       u16     security_index;         /* RxRPC header security index */
      -       u16     ticket_len;             /* length of ticket[] */
      -       u32     expiry;                 /* time at which expires */
      -       u32     kvno;                   /* key version number */
      -       u8      session_key[8];         /* DES session key */
      -       u8      ticket[0];              /* the encrypted ticket */
      -};
      
      +struct rxrpc_key_data_v1 {
      +       u32             kif_version;            /* 1 */
      +       u16             security_index;
      +       u16             ticket_length;
      +       u32             expiry;                 /* time_t */
      +       u32             kvno;
      +       u8              session_key[8];
      +       u8              ticket[0];
      +};
      
      However the code in rxrpc_instantiate strips it away:
      
      	data += sizeof(kver);
      	datalen -= sizeof(kver);
      
      Removing kif_version fixes my problem.
      Signed-off-by: NAnton Blanchard <anton@samba.org>
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f009918a
  10. 02 3月, 2011 2 次提交
    • T
      block: add @force_kblockd to __blk_run_queue() · 1654e741
      Tejun Heo 提交于
      __blk_run_queue() automatically either calls q->request_fn() directly
      or schedules kblockd depending on whether the function is recursed.
      blk-flush implementation needs to be able to explicitly choose
      kblockd.  Add @force_kblockd.
      
      All the current users are converted to specify %false for the
      parameter and this patch doesn't introduce any behavior change.
      
      stable: This is prerequisite for fixing ide oops caused by the new
              blk-flush implementation.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Cc: Jan Beulich <JBeulich@novell.com>
      Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
      Cc: stable@kernel.org
      Signed-off-by: NJens Axboe <jaxboe@fusionio.com>
      1654e741
    • M
      mfd: Don't suspend WM8994 if the CODEC is not suspended · 77bd70e9
      Mark Brown 提交于
      ASoC supports keeping the audio subsysetm active over suspend in order
      to support use cases such as audio passthrough from a cellular modem
      with the main CPU suspended. Ensure that we don't power down the CODEC
      when this is happening by checking to see if VMID is up and skipping
      suspend and resume when it is. If the CODEC has suspended then it'll
      turn VMID off before the core suspend() gets called.
      Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
      Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
      77bd70e9