11 Jul, 2012

2 commits


08 Jul, 2012

4 commits

  • Linus Torvalds
     
  • Pull security docs update from James Morris.

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
    security: Minor improvements to no_new_privs documentation

    Linus Torvalds
     
  • We already use them for openat() and friends, but fchdir() also wants to
    be able to use O_PATH file descriptors. This should make it comparable
    to the O_SEARCH of Solaris. In particular, O_PATH allows you to access
    (not-quite-open) a directory you don't have read persmission to, only
    execute permission.

    Noticed during development of multithread support for ksh93.

    Reported-by: ольга крыжановская
    Cc: Al Viro
    Cc: stable@kernel.org # O_PATH introduced in 3.0+
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • Pull ARM fixes from Russell King:
    "Last merge window, we had some updates from Al cleaning up the signal
    restart handling. These have caused some problems on ARM, and while
    Al has some fixes, we have some concerns with Al's patches but we've
    been unsuccesful with discussing this.

    We have got to the point where we need to do something, and we've
    decided that the best solution is to revert the appropriate commits
    until Al is able to reply to us.

    Also included here are four patches to fix warnings that I've noticed
    in my build system, and one fix for kprobes test code."

    * 'fixes' of git://git.linaro.org/people/rmk/linux-arm:
    ARM: fix warning caused by wrongly typed arm_dma_limit
    ARM: fix warnings about atomic64_read
    ARM: 7440/1: kprobes: only test 'sub pc, pc, #1b-2b+8-2' on ARMv6
    ARM: 7441/1: perf: return -EOPNOTSUPP if requested mode exclusion is unavailable
    ARM: 7443/1: Revert "new way of handling ERESTART_RESTARTBLOCK"
    ARM: 7442/1: Revert "remove unused restart trampoline"
    ARM: fix set_domain() macro
    ARM: fix mach-versatile/pci.c warning

    Linus Torvalds
     

07 Jul, 2012

11 commits

  • The documentation didn't actually mention how to enable no_new_privs.
    This also adds a note about possible interactions between
    no_new_privs and LSMs (i.e. why teaching systemd to set no_new_privs
    is not necessarily a good idea), and it references the new docs
    from include/linux/prctl.h.

    Suggested-by: Rob Landley
    Signed-off-by: Andy Lutomirski
    Acked-by: Kees Cook
    Signed-off-by: James Morris

    Andy Lutomirski
     
  • Pull eCryptfs fixes from Tyler Hicks:
    "Fixes an incorrect access mode check when preparing to open a file in
    the lower filesystem. This isn't an urgent fix, but it is simple and
    the check was obviously incorrect.

    Also fixes a couple important bugs in the eCryptfs miscdev interface.
    These changes are low risk due to the small number of users that use
    the miscdev interface. I was able to keep the changes minimal and I
    have some cleaner, more complete changes queued up for the next merge
    window that will build on these patches."

    * tag 'ecryptfs-3.5-rc6-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs:
    eCryptfs: Gracefully refuse miscdev file ops on inherited/passed files
    eCryptfs: Fix lockdep warning in miscdev operations
    eCryptfs: Properly check for O_RDONLY flag before doing privileged open

    Linus Torvalds
     
  • Pull target fixes from Nicholas Bellinger:
    "Two minor target fixes. There is really nothing exciting and/or
    controversial this time around.

    There's one fix from MDR for a RCU debug warning message within tcm_fc
    code (CC'ed to stable), and a small AC fix for qla_target.c based upon
    a recent Coverity static report.

    Also, there is one other outstanding virtio-scsi LUN scanning bugfix
    that has been uncovered with the in-flight tcm_vhost driver over the
    last days, and that needs to make it into 3.5 final too. This patch
    has been posted to linux-scsi again here:

    http://marc.info/?l=linux-scsi&m=134160609212542&w=2

    and I've asked James to include it in his next PULL request."

    * git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending:
    qla2xxx: print the right array elements in qlt_async_event
    tcm_fc: Resolve suspicious RCU usage warnings

    Linus Torvalds
     
  • File operations on /dev/ecryptfs would BUG() when the operations were
    performed by processes other than the process that originally opened the
    file. This could happen with open files inherited after fork() or file
    descriptors passed through IPC mechanisms. Rather than calling BUG(), an
    error code can be safely returned in most situations.

    In ecryptfs_miscdev_release(), eCryptfs still needs to handle the
    release even if the last file reference is being held by a process that
    didn't originally open the file. ecryptfs_find_daemon_by_euid() will not
    be successful, so a pointer to the daemon is stored in the file's
    private_data. The private_data pointer is initialized when the miscdev
    file is opened and only used when the file is released.

    https://launchpad.net/bugs/994247

    Signed-off-by: Tyler Hicks
    Reported-by: Sasha Levin
    Tested-by: Sasha Levin

    Tyler Hicks
     
  • Based upon Alan's patch from Coverity scan id 793583, these debug
    messages in qlt_async_event() should be starting from byte 0, which is
    always the Asynchronous Event Status Code from the parent switch statement.

    Also, rename reason_code -> login_code following the language used in
    2500 FW spec for Port Database Changed (0x8014) -> Port Database Changed
    Event Mailbox Register for mailbox[2].

    Signed-off-by: Alan Cox
    Cc: Chad Dupuis
    Cc: Giridhar Malavali
    Signed-off-by: Nicholas Bellinger

    Alan Cox
     
  • Use rcu_dereference_protected to tell rcu that the ft_lport_lock
    is held during ft_lport_create. This resolved "suspicious RCU usage"
    warnings when debugging options are turned on.

    Signed-off-by: Mark Rustad
    Tested-by: Ross Brattain
    Cc:
    Signed-off-by: Nicholas Bellinger

    Mark Rustad
     
  • Pull two MTD fixes from David Woodhouse:
    - Fix a logic error in OLPC CAFÉ NAND ready() function.
    - Fix regression due to bitflip handling changes.

    * tag 'for-linus-20120706' of git://git.infradead.org/linux-mtd:
    mtd: cafe_nand: fix an & vs | mistake
    mtd: nand: initialize bitflip_threshold prior to BBT scanning

    Linus Torvalds
     
  • Otherwise the code races with munmap (causing a use-after-free
    of the vma) or with close (causing a use-after-free of the struct
    file).

    The bug was introduced by commit 90ed52ebe481 ("[PATCH] holepunch: fix
    mmap_sem i_mutex deadlock")

    Cc: Hugh Dickins
    Cc: Miklos Szeredi
    Cc: Badari Pulavarty
    Cc: Nick Piggin
    Cc: stable@vger.kernel.org
    Signed-off-by: Andy Lutomirski
    Signed-off-by: Linus Torvalds

    Andy Lutomirski
     
  • Pull ocfs2 fixes from Joel Becker.

    * 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2:
    aio: make kiocb->private NUll in init_sync_kiocb()
    ocfs2: Fix bogus error message from ocfs2_global_read_info
    ocfs2: for SEEK_DATA/SEEK_HOLE, return internal error unchanged if ocfs2_get_clusters_nocache() or ocfs2_inode_lock() call failed.
    ocfs2: use spinlock irqsave for downconvert lock.patch
    ocfs2: Misplaced parens in unlikley
    ocfs2: clear unaligned io flag when dio fails

    Linus Torvalds
     
  • Pull cifs fixes from Steve French.

    * git://git.samba.org/sfrench/cifs-2.6:
    cifs: when server doesn't set CAP_LARGE_READ_X, cap default rsize at MaxBufferSize
    cifs: fix parsing of password mount option

    Linus Torvalds
     
  • Pull input layer fixes from Dmitry Torokhov:
    "Two fixes for regressions in Wacom driver and fixes for drivers using
    threaded IRQ framework without specifying IRQF_ONESHOT."

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
    Input: request threaded-only IRQs with IRQF_ONESHOT
    Input: wacom - don't retrieve touch_max when it is predefined
    Input: wacom - fix retrieving touch_max bug
    Input: fix input.h kernel-doc warning

    Linus Torvalds
     

06 Jul, 2012

6 commits

  • The intent here was clearly to set result to true if the 0x40000000 flag
    was set. But instead there was a | vs & typo and we always set result
    to true.

    Artem: check the spec at
    wiki.laptop.org/images/5/5c/88ALP01_Datasheet_July_2007.pdf
    and this fix looks correct.

    Signed-off-by: Dan Carpenter
    Cc: stable@vger.kernel.org
    Signed-off-by: Artem Bityutskiy
    Signed-off-by: David Woodhouse

    Dan Carpenter
     
  • Pull ARM SoC fixes from Arnd Bergmann:
    "Small fixes on multiple ARM platforms
    - A build regression from a previous fix on dove and mv78xx0
    - Two fixes for recently (3.5-rc1) changed mmp/pxa code
    - multiple omap2+ bug fixes
    - two trivial fixes for i.MX
    - one v3.5 regression for mxs"

    * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
    ARM: apx4devkit: fix FEC enabling PHY clock
    ARM: OMAP2+: hwmod data: Fix wrong McBSP clock alias on OMAP4
    ARM: OMAP4: hwmod data: temporarily comment out data for the usb_host_fs and aess IP blocks
    ARM: Orion: Fix WDT compile for Dove and MV78xx0
    ARM: mmp: remove mach/gpio-pxa.h
    ARM: imx: assert SCC gate stays enabled
    ARM: OMAP4: TWL6030: ensure sys_nirq1 is mux'd and wakeup enabled
    ARM: OMAP2: Overo: init I2C before MMC to fix MMC suspend/resume failure
    ARM: imx27_visstrim_m10: Do not include
    ARM: pxa: hx4700: Fix basic suspend/resume

    Linus Torvalds
     
  • Pull KVM fix from Marcelo Tosatti:
    "Memory leak and oops on the x86 mmu code, and sanitization of the
    KVM_IRQFD ioctl."

    * git://git.kernel.org/pub/scm/virt/kvm/kvm:
    KVM: MMU: fix shrinking page from the empty mmu
    KVM: fix fault page leak
    KVM: Sanitize KVM_IRQFD flags
    KVM: Add missing KVM_IRQFD API documentation
    KVM: Pass kvm_irqfd to functions

    Linus Torvalds
     
  • Pull leds fix from Bryan Wu:
    "Fix for heartbeat led trigger driver"

    * 'fixes-for-3.5' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds:
    leds: heartbeat: fix bug on panic

    Linus Torvalds
     
  • Pull btrfs updates from Chris Mason:
    "I held off on my rc5 pull because I hit an oops during log recovery
    after a crash. I wanted to make sure it wasn't a regression because
    we have some logging fixes in here.

    It turns out that a commit during the merge window just made it much
    more likely to trigger directory logging instead of full commits,
    which exposed an old bug.

    The new backref walking code got some additional fixes. This should
    be the final set of them.

    Josef fixed up a corner where our O_DIRECT writes and buffered reads
    could expose old file contents (not stale, just not the most recent).
    He and Liu Bo fixed crashes during tree log recover as well.

    Ilya fixed errors while we resume disk balancing operations on
    readonly mounts."

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
    Btrfs: run delayed directory updates during log replay
    Btrfs: hold a ref on the inode during writepages
    Btrfs: fix tree log remove space corner case
    Btrfs: fix wrong check during log recovery
    Btrfs: use _IOR for BTRFS_IOC_SUBVOL_GETFLAGS
    Btrfs: resume balance on rw (re)mounts properly
    Btrfs: restore restriper state on all mounts
    Btrfs: fix dio write vs buffered read race
    Btrfs: don't count I/O statistic read errors for missing devices
    Btrfs: resolve tree mod log locking issue in btrfs_next_leaf
    Btrfs: fix tree mod log rewind of ADD operations
    Btrfs: leave critical region in btrfs_find_all_roots as soon as possible
    Btrfs: always put insert_ptr modifications into the tree mod log
    Btrfs: fix tree mod log for root replacements at leaf level
    Btrfs: support root level changes in __resolve_indirect_ref
    Btrfs: avoid waiting for delayed refs when we must not

    Linus Torvalds
     
  • Pull DT fixes from Rob Herring:
    "Mainly some documentation updates and 2 fixes:

    - An export symbol fix for of_platform_populate from Stephen W.
    - A fix for the order compatible entries are matched to ensure the
    first compatible string is matched when there are multiple matches."

    Normally these would go through Grant Likely (thus the "fixes-for-grant"
    branch name), but Grant is in the middle of moving to Scotland, and is
    practically offline until sometime in August. So pull directly from Rob.

    * 'fixes-for-grant' of git://sources.calxeda.com/kernel/linux:
    of: match by compatible property first
    dt: mc13xxx.txt: Fix gpio number assignment
    dt: fsl-fec.txt: Fix gpio number assignment
    dt: fsl-mma8450.txt: Add missing 'reg' description
    dt: fsl-imx-esdhc.txt: Fix gpio number assignment
    dt: fsl-imx-cspi.txt: Fix comment about GPIOs used for chip selects
    of: Add Avionic Design vendor prefix
    of: export of_platform_populate()

    Linus Torvalds
     

05 Jul, 2012

14 commits

  • arch/arm/mm/init.c: In function 'arm_memblock_init':
    arch/arm/mm/init.c:380: warning: comparison of distinct pointer types lacks a cast

    by fixing the typecast in its definition when DMA_ZONE is disabled.
    This was missed in 4986e5c7c (ARM: mm: fix type of the arm_dma_limit
    global variable).

    Signed-off-by: Russell King

    Russell King
     
  • Fix:
    net/netfilter/xt_connbytes.c: In function 'connbytes_mt':
    net/netfilter/xt_connbytes.c:43: warning: passing argument 1 of 'atomic64_read' discards qualifiers from pointer target type
    ...

    by adding the missing const.

    Signed-off-by: Russell King

    Russell King
     
  • 'sub pc, pc, #1b-2b+8-2' results in address == '10'.

    sub pc, pc, #const (== ADR pc, #const) performs an interworking branch
    (BXWritePC()) on ARMv7+ and a simple branch (BranchWritePC()) on earlier
    versions.

    In ARM state, BXWritePC() is UNPREDICTABLE when address == '10'.

    In ARM state on ARMv6+, BranchWritePC() ignores address. Before
    ARMv6, BranchWritePC() is UNPREDICTABLE if address != '00'

    So the instruction is UNPREDICTABLE both before and after v6.

    Acked-by: Jon Medhurst
    Signed-off-by: Rabin Vincent
    Signed-off-by: Russell King

    Rabin Vincent
     
  • …/git/tmlind/linux-omap into fixes

    PM related fixes for omaps mostly to get suspend/resume
    working again.

    * tag 'omap-fixes-for-v3.5-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
    ARM: OMAP2+: hwmod data: Fix wrong McBSP clock alias on OMAP4
    ARM: OMAP4: hwmod data: temporarily comment out data for the usb_host_fs and aess IP blocks
    ARM: OMAP4: TWL6030: ensure sys_nirq1 is mux'd and wakeup enabled
    ARM: OMAP2: Overo: init I2C before MMC to fix MMC suspend/resume failure

    Signed-off-by: Arnd Bergmann <arnd@arndb.de>

    Arnd Bergmann
     
  • * 'mxs/fixes-for-3.5' of git://git.linaro.org/people/shawnguo/linux-2.6:
    ARM: apx4devkit: fix FEC enabling PHY clock

    Signed-off-by: Arnd Bergmann

    Arnd Bergmann
     
  • We currently return -EPERM if the user requests mode exclusion that is
    not supported by the CPU. This looks pretty confusing from userspace
    and is inconsistent with other architectures (ppc, x86).

    This patch returns -EOPNOTSUPP instead.

    Signed-off-by: Will Deacon
    Signed-off-by: Russell King

    Will Deacon
     
  • This reverts commit 6b5c8045ecc7e726cdaa2a9d9c8e5008050e1252.

    Conflicts:

    arch/arm/kernel/ptrace.c

    The new syscall restarting code can lead to problems if we take an
    interrupt in userspace just before restarting the svc instruction. If
    a signal is delivered when returning from the interrupt, the
    TIF_SYSCALL_RESTARTSYS will remain set and cause any syscalls executed
    from the signal handler to be treated as a restart of the previously
    interrupted system call. This includes the final sigreturn call, meaning
    that we may fail to exit from the signal context. Furthermore, if a
    system call made from the signal handler requires a restart via the
    restart_block, it is possible to clear the thread flag and fail to
    restart the originally interrupted system call.

    The right solution to this problem is to perform the restarting in the
    kernel, avoiding the possibility of handling a further signal before the
    restart is complete. Since we're almost at -rc6, let's revert the new
    method for now and aim for in-kernel restarting at a later date.

    Acked-by: Catalin Marinas
    Signed-off-by: Will Deacon
    Signed-off-by: Russell King

    Will Deacon
     
  • This reverts commit fa18484d0947b976a769d15c83c50617493c81c1.

    We need the restart trampoline back so that we can revert a related
    problematic patch 6b5c8045ecc7e726cdaa2a9d9c8e5008050e1252 ("arm: new
    way of handling ERESTART_RESTARTBLOCK").

    Acked-by: Catalin Marinas
    Signed-off-by: Will Deacon
    Signed-off-by: Russell King

    Will Deacon
     
  • Avoid polluting drivers with a set_domain() macro, which interferes with
    structure member names:

    drivers/net/wireless/ath/ath9k/dfs_pattern_detector.c:294:33: error: macro "set_domain" passed 2 arguments, but takes just 1

    Signed-off-by: Russell King

    Russell King
     
  • Ocfs2 uses kiocb.*private as a flag of unsigned long size. In
    commit a11f7e6 ocfs2: serialize unaligned aio, the unaligned
    io flag is involved in it to serialize the unaligned aio. As
    *private is not initialized in init_sync_kiocb() of do_sync_write(),
    this unaligned io flag may be unexpectly set in an aligned dio.
    And this will cause OCFS2_I(inode)->ip_unaligned_aio decreased
    to -1 in ocfs2_dio_end_io(), thus the following unaligned dio
    will hang forever at ocfs2_aiodio_wait() in ocfs2_file_aio_write().

    Signed-off-by: Junxiao Bi
    Cc: stable@vger.kernel.org
    Acked-by: Jeff Moyer
    Signed-off-by: Joel Becker

    Junxiao Bi
     
  • …git/pjw/omap-pending into fixes

    A few more OMAP fixes for 3.5-rc. These fix some bugs with power
    management and McBSP.

    Tony Lindgren
     
  • Ethernet stopped to work after mxs clk framework change.

    Signed-off-by: Lauri Hintsala
    Signed-off-by: Shawn Guo

    Lauri Hintsala
     
  • Since commit 1c6c69525b ("genirq: Reject bogus threaded irq requests")
    threaded IRQs without a primary handler need to be requested with
    IRQF_ONESHOT, otherwise the request will fail. This patch adds the
    IRQF_ONESHOT to input drivers where it is missing. Not modified by
    this patch are those drivers where the requested IRQ will always be a
    nested IRQ (e.g. because it's part of an MFD), since for this special
    case IRQF_ONESHOT is not required to be specified when requesting the
    IRQ.

    Signed-off-by: Lars-Peter Clausen
    Signed-off-by: Dmitry Torokhov

    Lars-Peter Clausen
     
  • arch/arm/mach-versatile/pci.c: In function 'versatile_map_irq':
    arch/arm/mach-versatile/pci.c:342: warning: unused variable 'devslot'

    Signed-off-by: Russell King

    Russell King
     

04 Jul, 2012

3 commits

  • The commit 503d0ea24d1d3dd3db95e5e0edd693da7a2a23eb
    ARM: OMAP4: hwmod data: Add aliases for McBSP fclk clocks

    added a wrong "prcm_clk" alias for PRCM clock whereas the McBSP
    driver and previous OMAPs are using "prcm_fck".

    It thus lead to the following warning.

    [ 47.409729] omap-mcbsp: clks: could not clk_get() prcm_fck

    Fix that by changing the opt_clk role to prcm_fck.

    Reported-by: Misael Lopez Cruz
    Signed-off-by: Benoit Cousson
    Cc: Peter Ujfalusi
    Tested-by: Sebastien Guiriec
    Signed-off-by: Paul Walmsley

    Benoit Cousson
     
  • The OMAP4 usb_host_fs (OHCI) and AESS IP blocks require some special
    programming for them to enter idle. Without this programming, they
    will prevent the rest of the chip from entering full chip idle.

    To implement the idle programming cleanly, this will take some
    coordination between maintainers. This is likely to take some time,
    so it is probably best to leave this for 3.6 or 3.7. So, in the
    meantime, prevent these IP blocks from being registered.

    Later, once the appropriate support is available, this patch can be
    reverted.

    This second version comments out the IP block data since Benoît didn't
    like removing it.

    Signed-off-by: Paul Walmsley
    Cc: Benoît Cousson

    Paul Walmsley
     
  • From Haojian Zhuang :

    * 'fixes' of git://github.com/hzhuang1/linux:
    ARM: mmp: remove mach/gpio-pxa.h

    Signed-off-by: Arnd Bergmann

    Arnd Bergmann