1. 06 Apr, 2012 5 commits
  2. 05 Apr, 2012 20 commits
    • Linus Torvalds's avatar
      Merge branch 'akpm' (Andrew's patch-bomb) · 5d32c88f
      Linus Torvalds authored
      Merge batch of fixes from Andrew Morton:
       "The simple_open() cleanup was held back while I wanted for laggards to
        merge things.
      
        I still need to send a few checkpoint/restore patches.  I've been
        wobbly about merging them because I'm wobbly about the overall
        prospects for success of the project.  But after speaking with Pavel
        at the LSF conference, it sounds like they're further toward
        completion than I feared - apparently davem is at the "has stopped
        complaining" stage regarding the net changes.  So I need to go back
        and re-review those patchs and their (lengthy) discussion."
      
      * emailed from Andrew Morton <akpm@linux-foundation.org>: (16 patches)
        memcg swap: use mem_cgroup_uncharge_swap fix
        backlight: add driver for DA9052/53 PMIC v1
        C6X: use set_current_blocked() and block_sigmask()
        MAINTAINERS: add entry for sparse checker
        MAINTAINERS: fix REMOTEPROC F: typo
        alpha: use set_current_blocked() and block_sigmask()
        simple_open: automatically convert to simple_open()
        scripts/coccinelle/api/simple_open.cocci: semantic patch for simple_open()
        libfs: add simple_open()
        hugetlbfs: remove unregister_filesystem() when initializing module
        drivers/rtc/rtc-88pm860x.c: fix rtc irq enable callback
        fs/xattr.c:setxattr(): improve handling of allocation failures
        fs/xattr.c:listxattr(): fall back to vmalloc() if kmalloc() failed
        fs/xattr.c: suppress page allocation failure warnings from sys_listxattr()
        sysrq: use SEND_SIG_FORCED instead of force_sig()
        proc: fix mount -t proc -o AAA
      5d32c88f
    • Michal Hocko's avatar
      memcg swap: use mem_cgroup_uncharge_swap fix · dac23b0d
      Michal Hocko authored
      Although mem_cgroup_uncharge_swap has an empty placeholder for
      !CONFIG_CGROUP_MEM_RES_CTLR_SWAP the definition is placed in the
      CONFIG_SWAP ifdef block so we are missing the same definition for
      !CONFIG_SWAP which implies !CONFIG_CGROUP_MEM_RES_CTLR_SWAP.
      
      This has not been an issue before, because mem_cgroup_uncharge_swap was
      not called from !CONFIG_SWAP context.  But Hugh Dickins has a cleanup
      patch to call __mem_cgroup_commit_charge_swapin which is defined also
      for !CONFIG_SWAP.
      
      Let's move both the empty definition and declaration outside of the
      CONFIG_SWAP block to avoid the following compilation error:
      
        mm/memcontrol.c: In function '__mem_cgroup_commit_charge_swapin':
        mm/memcontrol.c:2837: error: implicit declaration of function 'mem_cgroup_uncharge_swap'
      
      if CONFIG_SWAP is disabled.
      Reported-by: default avatarDavid Rientjes <rientjes@google.com>
      Signed-off-by: default avatarMichal Hocko <mhocko@suse.cz>
      Cc: Hugh Dickins <hughd@google.com>
      Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
      Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp>
      Cc: Johannes Weiner <hannes@cmpxchg.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      dac23b0d
    • Ashish Jangam's avatar
      backlight: add driver for DA9052/53 PMIC v1 · 6ede3d83
      Ashish Jangam authored
      DA9052/53 PMIC has capability to supply power for upto 3 banks of 6
      white serial LEDS.  It can also control intensity of independent banks
      and to drive these banks boost converter will provide up to 24V and
      forward current of max 50mA.
      
      This patch allows to control intensity of the individual WLEDs bank
      through DA9052/53 PMIC.
      
      This patch is functionally tested on Samsung SMDKV6410.
      Signed-off-by: default avatarDavid Dajun Chen <dchen@diasemi.com>
      Signed-off-by: default avatarAshish Jangam <ashish.jangam@kpitcummins.com>
      Cc: Richard Purdie <rpurdie@rpsys.net>
      Cc: Samuel Ortiz <sameo@linux.intel.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6ede3d83
    • Matt Fleming's avatar
      C6X: use set_current_blocked() and block_sigmask() · 6e61ee3b
      Matt Fleming authored
      As described in e6fa16ab ("signal: sigprocmask() should do
      retarget_shared_pending()") the modification of current->blocked is
      incorrect as we need to check whether the signal we're about to block is
      pending in the shared queue.
      
      Also, use the new helper function introduced in commit 5e6292c0
      ("signal: add block_sigmask() for adding sigmask to current->blocked")
      which centralises the code for updating current->blocked after
      successfully delivering a signal and reduces the amount of duplicate
      code across architectures.  In the past some architectures got this code
      wrong, so using this helper function should stop that from happening
      again.
      Acked-by: default avatarMark Salter <msalter@redhat.com>
      Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
      Acked-by: default avatarOleg Nesterov <oleg@redhat.com>
      Signed-off-by: default avatarMatt Fleming <matt.fleming@intel.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6e61ee3b
    • Christopher Li's avatar
    • Joe Perches's avatar
      MAINTAINERS: fix REMOTEPROC F: typo · 6fc26488
      Joe Perches authored
      remoteproc.txt should have been .h
      Signed-off-by: default avatarJoe Perches <joe@perches.com>
      Cc: Ohad Ben-Cohen <ohad@wizery.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6fc26488
    • Matt Fleming's avatar
      alpha: use set_current_blocked() and block_sigmask() · 2561b069
      Matt Fleming authored
      As described in e6fa16ab ("signal: sigprocmask() should do
      retarget_shared_pending()") the modification of current->blocked is
      incorrect as we need to check for shared signals we're about to block.
      
      Also, use the new helper function introduced in commit 5e6292c0
      ("signal: add block_sigmask() for adding sigmask to current->blocked")
      which centralises the code for updating current->blocked after
      successfully delivering a signal and reduces the amount of duplicate
      code across architectures.  In the past some architectures got this code
      wrong, so using this helper function should stop that from happening
      again.
      
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Matt Turner <mattst88@gmail.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Acked-by: default avatarOleg Nesterov <oleg@redhat.com>
      Signed-off-by: default avatarMatt Fleming <matt.fleming@intel.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      2561b069
    • Stephen Boyd's avatar
      simple_open: automatically convert to simple_open() · 234e3405
      Stephen Boyd authored
      Many users of debugfs copy the implementation of default_open() when
      they want to support a custom read/write function op.  This leads to a
      proliferation of the default_open() implementation across the entire
      tree.
      
      Now that the common implementation has been consolidated into libfs we
      can replace all the users of this function with simple_open().
      
      This replacement was done with the following semantic patch:
      
      <smpl>
      @ open @
      identifier open_f != simple_open;
      identifier i, f;
      @@
      -int open_f(struct inode *i, struct file *f)
      -{
      (
      -if (i->i_private)
      -f->private_data = i->i_private;
      |
      -f->private_data = i->i_private;
      )
      -return 0;
      -}
      
      @ has_open depends on open @
      identifier fops;
      identifier open.open_f;
      @@
      struct file_operations fops = {
      ...
      -.open = open_f,
      +.open = simple_open,
      ...
      };
      </smpl>
      
      [akpm@linux-foundation.org: checkpatch fixes]
      Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: Julia Lawall <Julia.Lawall@lip6.fr>
      Acked-by: default avatarIngo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      234e3405
    • Julia Lawall's avatar
      scripts/coccinelle/api/simple_open.cocci: semantic patch for simple_open() · 9b3ae64b
      Julia Lawall authored
      Find instances of an open-coded simple_open() and replace them with
      calls to simple_open().
      Signed-off-by: default avatarJulia Lawall <Julia.Lawall@lip6.fr>
      Reported-by: default avatarStephen Boyd <sboyd@codeaurora.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      9b3ae64b
    • Stephen Boyd's avatar
      libfs: add simple_open() · 20955e89
      Stephen Boyd authored
      debugfs and a few other drivers use an open-coded version of
      simple_open() to pass a pointer from the file to the read/write file
      ops.  Add support for this simple case to libfs so that we can remove
      the many duplicate copies of this simple function.
      Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: Julia Lawall <Julia.Lawall@lip6.fr>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      20955e89
    • Hillf Danton's avatar
      hugetlbfs: remove unregister_filesystem() when initializing module · 7563ec4c
      Hillf Danton authored
      It was introduced by d1d5e05f ("hugetlbfs: return error code when
      initializing module") but as Al pointed out, is a bad idea.
      
      Quoted comments from Al:
       "Note that unregister_filesystem() in module init is *always* wrong;
        it's not an issue here (it's done too early to care about and
        realistically the box is not going anywhere - it'll panic when attempt
        to exec /sbin/init fails, if not earlier), but it's a damn bad
        example.
      
        Consider a normal fs module.  Somebody loads it and in parallel with
        that we get a mount attempt on that fs type.  It comes between
        register and failure exits that causes unregister; at that point we
        are screwed since grabbing a reference to module as done by mount is
        enough to prevent exit, but not to prevent the failure of init.  As
        the result, module will get freed when init fails, mounted fs of that
        type be damned."
      
      So remove it.
      Signed-off-by: default avatarHillf Danton <dhillf@gmail.com>
      Cc: David Rientjes <rientjes@google.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      7563ec4c
    • Jett.Zhou's avatar
      drivers/rtc/rtc-88pm860x.c: fix rtc irq enable callback · fd835d1f
      Jett.Zhou authored
      According to 88pm860x spec, rtc alarm irq enable control is bit3 for
      RTC_ALARM_EN, so fix it.
      Signed-off-by: default avatarJett.Zhou <jtzhou@marvell.com>
      Cc: Axel Lin <axel.lin@gmail.com>
      Cc: Haojian Zhuang <haojian.zhuang@marvell.com>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      fd835d1f
    • Andrew Morton's avatar
      fs/xattr.c:setxattr(): improve handling of allocation failures · 44c82498
      Andrew Morton authored
      This allocation can be as large as 64k.
      
       - Add __GFP_NOWARN so the a falied kmalloc() is silent
      
       - Fall back to vmalloc() if the kmalloc() failed
      
      Cc: Dave Chinner <david@fromorbit.com>
      Cc: Dave Jones <davej@codemonkey.org.uk>
      Cc: David Rientjes <rientjes@google.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      44c82498
    • Andrew Morton's avatar
      fs/xattr.c:listxattr(): fall back to vmalloc() if kmalloc() failed · 0d08d7b7
      Andrew Morton authored
      This allocation can be as large as 64k.  As David points out, "falling
      back to vmalloc here is much better solution than failing to retreive
      the attribute - it will work no matter how fragmented memory gets.  That
      means we don't get incomplete backups occurring after days or months of
      uptime and successful backups".
      
      Cc: Dave Chinner <david@fromorbit.com>
      Cc: Dave Jones <davej@codemonkey.org.uk>
      Cc: David Rientjes <rientjes@google.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      0d08d7b7
    • Dave Jones's avatar
      fs/xattr.c: suppress page allocation failure warnings from sys_listxattr() · 703bf2d1
      Dave Jones authored
      This size is user controllable, up to a maximum of XATTR_LIST_MAX (64k).
      So it's trivial for someone to trigger a stream of order:4 page
      allocation errors.
      Signed-off-by: default avatarDave Jones <davej@redhat.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: Dave Chinner <david@fromorbit.com>
      Acked-by: default avatarDavid Rientjes <rientjes@google.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      703bf2d1
    • Anton Vorontsov's avatar
      sysrq: use SEND_SIG_FORCED instead of force_sig() · b82c3287
      Anton Vorontsov authored
      Change send_sig_all() to use do_send_sig_info(SEND_SIG_FORCED) instead
      of force_sig(SIGKILL).  With the recent changes we do not need force_ to
      kill the CLONE_NEWPID tasks.
      
      And this is more correct.  force_sig() can race with the exiting thread,
      while do_send_sig_info(group => true) kill the whole process.
      
      Some more notes from Oleg Nesterov:
      
      > Just one note. This change makes no difference for sysrq_handle_kill().
      > But it obviously changes the behaviour sysrq_handle_term(). I think
      > this is fine, if you want to really kill the task which blocks/ignores
      > SIGTERM you can use sysrq_handle_kill().
      >
      > Even ignoring the reasons why force_sig() is simply wrong here,
      > force_sig(SIGTERM) looks strange. The task won't be killed if it has
      > a handler, but SIG_IGN can't help. However if it has the handler
      > but blocks SIGTERM temporary (this is very common) it will be killed.
      
      Also,
      
      > force_sig() can't kill the process if the main thread has already
      > exited. IOW, it is trivial to create the process which can't be
      > killed by sysrq.
      
      So, this patch fixes the issue.
      Suggested-by: default avatarOleg Nesterov <oleg@redhat.com>
      Acked-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      Acked-by: default avatarOleg Nesterov <oleg@redhat.com>
      Signed-off-by: default avatarAnton Vorontsov <anton.vorontsov@linaro.org>
      Cc: Alan Cox <alan@linux.intel.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      b82c3287
    • Vasiliy Kulikov's avatar
      proc: fix mount -t proc -o AAA · 99663be7
      Vasiliy Kulikov authored
      The proc_parse_options() call from proc_mount() runs only once at boot
      time.  So on any later mount attempt, any mount options are ignored
      because ->s_root is already initialized.
      
      As a consequence, "mount -o <options>" will ignore the options.  The
      only way to change mount options is "mount -o remount,<options>".
      
      To fix this, parse the mount options unconditionally.
      Signed-off-by: default avatarVasiliy Kulikov <segoon@openwall.com>
      Reported-by: default avatarArkadiusz Miskiewicz <a.miskiewicz@gmail.com>
      Tested-by: default avatarArkadiusz Miskiewicz <a.miskiewicz@gmail.com>
      Cc: Alexey Dobriyan <adobriyan@gmail.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: Valdis Kletnieks <Valdis.Kletnieks@vt.edu>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      99663be7
    • Linus Torvalds's avatar
      Merge git://git.samba.org/sfrench/cifs-2.6 · 43f63c87
      Linus Torvalds authored
      Pull CIFS fixes from Steve French.
      
      * git://git.samba.org/sfrench/cifs-2.6:
        Fix UNC parsing on mount
        Remove unnecessary check for NULL in password parser
        CIFS: Fix VFS lock usage for oplocked files
        Revert "CIFS: Fix VFS lock usage for oplocked files"
        cifs: writing past end of struct in cifs_convert_address()
        cifs: silence compiler warnings showing up with gcc-4.7.0
        CIFS: Fix VFS lock usage for oplocked files
      43f63c87
    • Linus Torvalds's avatar
      Merge tag 'for_linus-3.4-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb · 6c216ec6
      Linus Torvalds authored
      Pull KGDB/KDB regression fixes from Jason Wessel:
       - Fix a Smatch warning that appeared in the 3.4 merge window
       - Fix kgdb test suite with SMP for all archs without HW single stepping
       - Fix kgdb sw breakpoints with CONFIG_DEBUG_RODATA=y limitations on x86
       - Fix oops on kgdb test suite with CONFIG_DEBUG_RODATA
       - Fix kgdb test suite with SMP for all archs with HW single stepping
      
      * tag 'for_linus-3.4-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb:
        x86,kgdb: Fix DEBUG_RODATA limitation using text_poke()
        kgdb,debug_core: pass the breakpoint struct instead of address and memory
        kgdbts: (2 of 2) fix single step awareness to work correctly with SMP
        kgdbts: (1 of 2) fix single step awareness to work correctly with SMP
        kgdbts: Fix kernel oops with CONFIG_DEBUG_RODATA
        kdb: Fix smatch warning on dbg_io_ops->is_console
      6c216ec6
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.linaro.org/people/mszyprowski/linux-dma-mapping · 58bca4a8
      Linus Torvalds authored
      Pull DMA mapping branch from Marek Szyprowski:
       "Short summary for the whole series:
      
        A few limitations have been identified in the current dma-mapping
        design and its implementations for various architectures.  There exist
        more than one function for allocating and freeing the buffers:
        currently these 3 are used dma_{alloc, free}_coherent,
        dma_{alloc,free}_writecombine, dma_{alloc,free}_noncoherent.
      
        For most of the systems these calls are almost equivalent and can be
        interchanged.  For others, especially the truly non-coherent ones
        (like ARM), the difference can be easily noticed in overall driver
        performance.  Sadly not all architectures provide implementations for
        all of them, so the drivers might need to be adapted and cannot be
        easily shared between different architectures.  The provided patches
        unify all these functions and hide the differences under the already
        existing dma attributes concept.  The thread with more references is
        available here:
      
          http://www.spinics.net/lists/linux-sh/msg09777.html
      
        These patches are also a prerequisite for unifying DMA-mapping
        implementation on ARM architecture with the common one provided by
        dma_map_ops structure and extending it with IOMMU support.  More
        information is available in the following thread:
      
          http://thread.gmane.org/gmane.linux.kernel.cross-arch/12819
      
        More works on dma-mapping framework are planned, especially in the
        area of buffer sharing and managing the shared mappings (together with
        the recently introduced dma_buf interface: commit d15bd7ee
        "dma-buf: Introduce dma buffer sharing mechanism").
      
        The patches in the current set introduce a new alloc/free methods
        (with support for memory attributes) in dma_map_ops structure, which
        will later replace dma_alloc_coherent and dma_alloc_writecombine
        functions."
      
      People finally started piping up with support for merging this, so I'm
      merging it as the last of the pending stuff from the merge window.
      Looks like pohmelfs is going to wait for 3.5 and more external support
      for merging.
      
      * 'for-linus' of git://git.linaro.org/people/mszyprowski/linux-dma-mapping:
        common: DMA-mapping: add NON-CONSISTENT attribute
        common: DMA-mapping: add WRITE_COMBINE attribute
        common: dma-mapping: introduce mmap method
        common: dma-mapping: remove old alloc_coherent and free_coherent methods
        Hexagon: adapt for dma_map_ops changes
        Unicore32: adapt for dma_map_ops changes
        Microblaze: adapt for dma_map_ops changes
        SH: adapt for dma_map_ops changes
        Alpha: adapt for dma_map_ops changes
        SPARC: adapt for dma_map_ops changes
        PowerPC: adapt for dma_map_ops changes
        MIPS: adapt for dma_map_ops changes
        X86 & IA64: adapt for dma_map_ops changes
        common: dma-mapping: introduce generic alloc() and free() methods
      58bca4a8
  3. 04 Apr, 2012 15 commits
    • Linus Torvalds's avatar
      Merge tag 'pm-for-3.4-part-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 64ebe987
      Linus Torvalds authored
      Pull more power management updates from Rafael Wysocki:
       - Patch series that hopefully fixes races between the freezer and
         request_firmware() and request_firmware_nowait() for good, with two
         cleanups from Stephen Boyd on top.
       - Runtime PM fix from Alan Stern preventing tasks from getting stuck
         indefinitely in the runtime PM wait queue.
       - Device PM QoS update from MyungJoo Ham introducing a new variant of
         pm_qos_update_request() allowing the callers to specify a timeout.
      
      * tag 'pm-for-3.4-part-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        PM / QoS: add pm_qos_update_request_timeout() API
        firmware_class: Move request_firmware_nowait() to workqueues
        firmware_class: Reorganize fw_create_instance()
        PM / Sleep: Mitigate race between the freezer and request_firmware()
        PM / Sleep: Move disabling of usermode helpers to the freezer
        PM / Hibernate: Disable usermode helpers right before freezing tasks
        firmware_class: Do not warn that system is not ready from async loads
        firmware_class: Split _request_firmware() into three functions, v2
        firmware_class: Rework usermodehelper check
        PM / Runtime: don't forget to wake up waitqueue on failure
      64ebe987
    • Linus Torvalds's avatar
      Merge branch 'selinux' ("struct common_audit_data" sanitizer) · a5149bf3
      Linus Torvalds authored
      Merge common_audit_data cleanup patches from Eric Paris.
      
      This is really too late, but it's a long-overdue cleanup of the costly
      wrapper functions for the security layer.
      
      The "struct common_audit_data" is used all over in critical paths,
      allocated and initialized on the stack.  And used to be much too large,
      causing not only unnecessarily big stack frames but the clearing of the
      (mostly useless) data was also very visible in profiles.
      
      As a particular example, in one microbenchmark for just doing "stat()"
      over files a lot, selinux_inode_permission() used 7% of the CPU time.
      That's despite the fact that it doesn't actually *do* anything: it is
      just a helper wrapper function in the selinux security layer.
      
      This patch-series shrinks "struct common_audit_data" sufficiently that
      code generation for these kinds of wrapper functions is improved
      noticeably, and we spend much less time just initializing data that we
      will never use.
      
      The functions still get called all the time, and it still shows up at
      3.5+% in my microbenchmark, but it's quite a bit lower down the list,
      and much less noticeable.
      
      * Emailed patches from Eric Paris <eparis@redhat.com>:
        lsm_audit: don't specify the audit pre/post callbacks in 'struct common_audit_data'
        SELinux: do not allocate stack space for AVC data unless needed
        SELinux: remove avd from slow_avc_audit()
        SELinux: remove avd from selinux_audit_data
        LSM: shrink the common_audit_data data union
        LSM: shrink sizeof LSM specific portion of common_audit_data
      a5149bf3
    • Linus Torvalds's avatar
      Merge tag 'regmap-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap · 3ff8f932
      Linus Torvalds authored
      Pull a single regmap fix from Mark Brown:
       "A simple bug that's been lurking for a while but not terribly visible
        since a high proportion of chips have no register 0 so the normal
        failure is that we end up doing a bit of extra I/O."
      
      * tag 'regmap-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap:
        regmap: rbtree: Fix register default look-up in sync
      3ff8f932
    • Linus Torvalds's avatar
      Merge tag 'regulator-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator · 4a1e8ebc
      Linus Torvalds authored
      Pull regulator fixes from Mark Brown:
       "A bunch of smallish fixes that came up during the merge window as
        things got more testing - even more fixes from Axel, a fix for error
        handling in more complex systems using -EPROBE_DEFER and a couple of
        small fixes for the new dummy regulators."
      
      * tag 'regulator-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
        regulator: Remove non-existent parameter from fixed-helper.c kernel doc
        regulator: Fix setting new voltage in s5m8767_set_voltage
        regulator: fix sysfs name collision between dummy and fixed dummy regulator
        regulator: Fix deadlock on removal of regulators with supplies
        regulator: Fix comments in include/linux/regulator/machine.h
        regulator: Only update [LDOx|DCx]_HIB_MODE bits in wm8350_[ldo|dcdc]_set_suspend_disable
        regulator: Fix setting low power mode for wm831x aldo
        regulator: Return microamps in wm8350_isink_get_current
        regulator: wm8350: Fix the logic to choose best current limit setting
        regulator: wm831x-isink: Fix the logic to choose best current limit setting
        regulator: wm831x-dcdc: Fix the logic to choose best current limit setting
        regulator: anatop: patching to device-tree property "reg".
        regulator: Do proper shift to set correct bit for DC[2|5]_HIB_MODE setting
        regulator: Fix restoring pmic.dcdcx_hib_mode settings in wm8350_dcdc_set_suspend_enable
        regulator: Fix unbalanced lock/unlock in mc13892_regulator_probe error path
        regulator: Fix set and get current limit for wm831x_buckv
        regulator: tps6586x: Fix list minimal voltage setting for LDO0
      4a1e8ebc
    • Linus Torvalds's avatar
      Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 66cfb327
      Linus Torvalds authored
      Pull perf fixes from Ingo Molnar.
      
      * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        perf/x86/p4: Add format attributes
        tracing, sched, vfs: Fix 'old_pid' usage in trace_sched_process_exec()
      66cfb327
    • Linus Torvalds's avatar
      Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 67422598
      Linus Torvalds authored
      Pull x86 fixes from Ingo Molnar.
      
      * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86, kvm: Call restore_sched_clock_state() only after %gs is initialized
        x86: Use -mno-avx when available
        x86: Remove the ancient and deprecated disable_hlt() and enable_hlt() facility
        x86: Preserve lazy irq disable semantics in fixup_irqs()
      67422598
    • Linus Torvalds's avatar
      Merge tag 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging · 20d9d9a0
      Linus Torvalds authored
      Pull hwmon patches from Guenter Roeck:
       - Fix crash in ad7314 driver
       - Add support for AMD Trinity CPUs to k10temp driver
       - Fix __initdata/__initconst mixup in w83627ehf driver
       - Fix runtime warnings in acpi_power_meter and max6639 drivers
       - Fix build warnings in adm1031, f75375s, sht15, and gpio-fan drivers
      
      * tag 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging:
        hwmon: (ad7314) Adds missing spi_dev initialization
        hwmon: (k10temp) Add support for AMD Trinity CPUs
        hwmon: (w83627ehf) mark const init data with __initconst instead of __initdata
        hwmon: (acpi_power_meter) fix lockdep spew due to non-static lock class
        hwmon: (adm1031) Fix compiler warning
        hwmon: (f75375s) Fix warning message seen in some configurations
        hwmon: (max6639) Convert to dev_pm_ops
        hwmon: (sht15) Fix Kconfig dependencies
        hwmon: (gpio-fan) Fix Kconfig dependencies
      20d9d9a0
    • Linus Torvalds's avatar
      Merge tag 'mce-fix-for-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp · 7114a72f
      Linus Torvalds authored
      Pull MCE fixlet from Borislav Petkov:
       "One fix which makes MCE decoding much more "liberal" wrt families."
      
      * tag 'mce-fix-for-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp:
        MCE, AMD: Drop too granulary family model checks
      7114a72f
    • Linus Torvalds's avatar
      Merge tag 'md-3.4-fixes' of git://neil.brown.name/md · 36bbffc0
      Linus Torvalds authored
      Pull assorted md fixes from Neil Brown:
       - some RAID levels didn't clear up properly if md_integrity_register
        failed
       - a 'check' of RAID5/RAID6 doesn't actually read any data since a
         recent patch - so fix that (and mark for -stable)
       - a couple of other minor bugs.
      
      * tag 'md-3.4-fixes' of git://neil.brown.name/md:
        md/raid1,raid10: don't compare excess byte during consistency check.
        md/raid5: Fix a bug about judging if the operation is syncing or replacing
        md/raid1:Remove unnecessary rcu_dereference(conf->mirrors[i].rdev).
        md: Avoid OOPS when reshaping raid1 to raid0
        md/raid5: fix handling of bad blocks during recovery.
        md/raid1: If md_integrity_register() failed,run() must free the mem
        md/raid0: If md_integrity_register() fails, raid0_run() must free the mem.
        md/linear: If md_integrity_register() fails, linear_run() must free the mem.
      36bbffc0
    • Linus Torvalds's avatar
      Merge branch 'fixes' of git://git.linaro.org/people/rmk/linux-arm · 20a2a811
      Linus Torvalds authored
      Pull ARM fixes from Russell King:
       "Nothing too big here, just small fixes."
      
      * 'fixes' of git://git.linaro.org/people/rmk/linux-arm:
        ARM: fix more fallout from 9f97da78 (Disintegrate asm/system.h for ARM)
        ARM: fix bios32.c build warning
        ARM: 7337/1: ptrace: fix ptrace_read_user for !CONFIG_MMU platforms
        ARM: fix missing bug.h include in arch/arm/kernel/insn.c
        ARM: sa11x0: fix build errors from DMA engine API updates
      20a2a811
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc · a92bc5a6
      Linus Torvalds authored
      Pull Sparc fixes from David Miller:
       "One build regression and one serial probe regression fix on sparc."
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc:
        serial/sunzilog: fix keyboard on SUN SPARCstation
        sparc: pgtable_64: change include order
      a92bc5a6
    • Paul Gortmaker's avatar
      avr32: fix nop compile fails from system.h split up · 167d8215
      Paul Gortmaker authored
      To fix:
      
        In file included from kernel/exit.c:61:
        arch/avr32/include/asm/mmu_context.h: In function 'enable_mmu':
        arch/avr32/include/asm/mmu_context.h:135: error: implicit declaration of function 'nop'
      
      It needs an include of the new file created in commit ae473946
      ("Disintegrate asm/system.h for AVR32"), but since that file only
      contains "nop", and since other arch already have precedent of putting
      nop in asm/barrier.h we should just delete the new file and put nop in
      barrier.h
      Suggested-and-acked-by: default avatarDavid Howells <dhowells@redhat.com>
      Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
      Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
      Signed-off-by: default avatarPaul Gortmaker <paul.gortmaker@windriver.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      167d8215
    • Linus Torvalds's avatar
      Revert "nouveau/bios: Fix tracking of BIOS image data" · f3718a81
      Linus Torvalds authored
      This reverts commit d06221c0.
      
      It turns out to trigger the "BUG_ON(!PageCompound(page))" in kfree(),
      apparently because the code ends up trying to free somethng that was
      never kmalloced in the first place.
      
      BenH points out that the patch was untested and wasn't meant to go into
      the upstream kernel that quickly in the first place.
      
      Backtrace:
        bios_shadow
        bios_shadow_prom
        nv_mask
        init_io
        bios_shadow
        nouveau_bios_init
        NVReadVgaCrtc
        NVSetOwner
        nouveau_card_init
        nouveau_load
      Reported-by: default avatarMeelis Roos <mroos@linux.ee>
      Requested-by: default avatarDave Airlie <airlied@gmail.com>
      Acked-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      f3718a81
    • Borislav Petkov's avatar
      MCE, AMD: Drop too granulary family model checks · ec3e82d6
      Borislav Petkov authored
      MCA details seldom change inbetween the models of a family so don't
      be too conservative and enable decoding on everything starting from
      K8 onwards. Minor adjustments can come in later but most importantly,
      we have some decoding infrastructure in place for upcoming models by
      default.
      Signed-off-by: default avatarBorislav Petkov <borislav.petkov@amd.com>
      ec3e82d6
    • Sam Ravnborg's avatar
      serial/sunzilog: fix keyboard on SUN SPARCstation · ca6f327d
      Sam Ravnborg authored
      The keyboard on my SUN SPARCstation 5 no longer worked.
      
          The culprint was: d4e33fac
          ("serial: Kill off NO_IRQ")
      
      Fix up logic for no irq / irq so the keyboard works again.
      Signed-off-by: default avatarSam Ravnborg <sam@ravnborg.org>
      Cc: Alan Cox <alan@linux.intel.com>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ca6f327d