1. 15 Jan, 2015 3 commits
  2. 14 Jan, 2015 7 commits
    • Johan Hovold's avatar
      gpio: unregister gpiochip device before removing it · 01cca93a
      Johan Hovold authored
      Unregister gpiochip device (used to export information through sysfs)
      before removing it internally. This way removal will reverse addition.
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      01cca93a
    • Johan Hovold's avatar
      gpio: fix sleep-while-atomic in gpiochip_remove · 6798acaa
      Johan Hovold authored
      Move direct and indirect calls to gpiochip_remove_pin_ranges outside of
      spin lock as they can end up taking a mutex in pinctrl_remove_gpio_range.
      
      Note that the pin ranges are already added outside of the lock.
      
      Fixes: 9ef0d6f7 ("gpiolib: call pin removal in chip removal function")
      Fixes: f23f1516 ("gpiolib: provide provision to register pin ranges")
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      6798acaa
    • Johan Hovold's avatar
      gpio: fix memory leak and sleep-while-atomic · 00acc3dc
      Johan Hovold authored
      Fix memory leak and sleep-while-atomic in gpiochip_remove.
      
      The memory leak was introduced by afa82fab ("gpio / ACPI: Move event
      handling registration to gpiolib irqchip helpers") that moved the
      release of acpi interrupt resources to gpiochip_irqchip_remove, but by
      then the resources are no longer accessible as the acpi_gpio_chip has
      already been freed by acpi_gpiochip_remove.
      
      Note that this also fixes a few potential sleep-while-atomics, which has
      been around since 14250520 ("gpio: add IRQ chip helpers in gpiolib")
      when the call to gpiochip_irqchip_remove while holding a spinlock was
      added (a couple of irq-domain paths can end up grabbing mutexes).
      
      Fixes: afa82fab ("gpio / ACPI: Move event handling registration to
      gpiolib irqchip helpers")
      Fixes: 14250520 ("gpio: add IRQ chip helpers in gpiolib")
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      00acc3dc
    • Johan Hovold's avatar
      gpio: clean up gpiochip_add error handling · 05aa5203
      Johan Hovold authored
      Clean up gpiochip_add error handling.
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      05aa5203
    • Johan Hovold's avatar
      gpio: fix gpio-chip list corruption · 225fce83
      Johan Hovold authored
      Fix potential corruption of gpio-chip list due to failure to remove the
      chip from the list before returning in gpiochip_add error path.
      
      The chip could be long gone when the global list is next traversed,
      something which could lead to a null-pointer dereference. In the best
      case (chip not deallocated) we are just leaking the gpio range.
      
      Fixes: 14e85c0e ("gpio: remove gpio_descs global array")
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      225fce83
    • Johan Hovold's avatar
      gpio: fix memory and reference leaks in gpiochip_add error path · 5539b3c9
      Johan Hovold authored
      Memory allocated and references taken by of_gpiochip_add and
      acpi_gpiochip_add were never released on errors in gpiochip_add (e.g.
      failure to find free gpio range).
      
      Fixes: 391c970c ("of/gpio: add default of_xlate function if device
      has a node pointer")
      Fixes: 664e3e5a ("gpio / ACPI: register to ACPI events
      automatically")
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      5539b3c9
    • Aaron Lu's avatar
      gpio: crystalcove: use handle_nested_irq · e733a2fb
      Aaron Lu authored
      The CrystalCove GPIO chip has can_sleep set so its demultiplexed irqs
      will have IRQ_NESTED_THREAD flag set, thus we should use the nested
      version handle_nested_irq in CrystalCove's irq handler instead of
      handle_generic_irq, or the following warning will be hit and the
      functionality is lost:
      
      [ 4089.639554] Hardware name: ASUSTeK COMPUTER INC. T100TA/T100TA, BIOS T100TA.313 08/13/2014
      [ 4089.639564]  00000002 00000000 c24fbdf4 c16e0257 c24fbe38 c24fbe28 c105390c c18ec480
      [ 4089.639596]  c24fbe54 00000048 c18f8e3b 00000295 c10a60fc 00000295 c10a60fc f4464540
      [ 4089.639626]  f446459c c278ad40 c24fbe40 c1053974 00000009 c24fbe38 c18ec480 c24fbe54
      [ 4089.639656] Call Trace:
      [ 4089.639685]  [<c16e0257>] dump_stack+0x41/0x52
      [ 4089.639707]  [<c105390c>] warn_slowpath_common+0x8c/0xc0
      [ 4089.639727]  [<c10a60fc>] ? irq_nested_primary_handler+0x2c/0x30
      [ 4089.639744]  [<c10a60fc>] ? irq_nested_primary_handler+0x2c/0x30
      [ 4089.639763]  [<c1053974>] warn_slowpath_fmt+0x34/0x40
      [ 4089.639781]  [<c10a60fc>] irq_nested_primary_handler+0x2c/0x30
      [ 4089.639800]  [<c10a5c56>] handle_irq_event_percpu+0x76/0x190
      [ 4089.639818]  [<c1461570>] ? regmap_format_10_14_write+0x30/0x30
      [ 4089.639836]  [<c1464f4c>] ? _regmap_bus_raw_write+0x4c/0x70
      [ 4089.639854]  [<c10a5da1>] handle_irq_event+0x31/0x50
      [ 4089.639872]  [<c10a83eb>] handle_simple_irq+0x4b/0x70
      [ 4089.639889]  [<c10a5384>] generic_handle_irq+0x24/0x40
      [ 4089.639908]  [<c1366d87>] crystalcove_gpio_irq_handler+0xa7/0xc0
      [ 4089.639927]  [<c10a85a7>] handle_nested_irq+0x77/0x190
      [ 4089.639947]  [<c1469801>] regmap_irq_thread+0x1b1/0x360
      [ 4089.639966]  [<c10a6ae8>] irq_thread_fn+0x18/0x30
      [ 4089.639983]  [<c10a6906>] irq_thread+0xf6/0x110
      [ 4089.640001]  [<c10a6ad0>] ? irq_finalize_oneshot.part.30+0x1b0/0x1b0
      [ 4089.640019]  [<c10a6b50>] ? irq_forced_thread_fn+0x50/0x50
      [ 4089.640037]  [<c10a6810>] ? irq_thread_check_affinity+0xc0/0xc0
      [ 4089.640054]  [<c106f389>] kthread+0xa9/0xc0
      [ 4089.640074]  [<c16e6401>] ret_from_kernel_thread+0x21/0x30
      [ 4089.640091]  [<c106f2e0>] ? kthread_create_on_node+0x110/0x110
      [ 4089.640105] ---[ end trace dca7946ad31eba7d ]---
      
      Buglink: https://bugzilla.kernel.org/show_bug.cgi?id=90521Reported-and-tested-by: default avatarBrian Loften <bloften80@gmail.com>
      Cc: Stable <stable@vger.kernel.org>
      Signed-off-by: default avatarAaron Lu <aaron.lu@intel.com>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      e733a2fb
  3. 11 Jan, 2015 9 commits
  4. 10 Jan, 2015 10 commits
    • Linus Torvalds's avatar
      Merge tag 'vfio-v3.19-rc4' of git://github.com/awilliam/linux-vfio · 4850d37d
      Linus Torvalds authored
      Pull VFIO fix from Alex Williamson:
       "Fix PCI header check in vfio_pci_probe() (Wei Yang)"
      
      * tag 'vfio-v3.19-rc4' of git://github.com/awilliam/linux-vfio:
        vfio-pci: Fix the check on pci device type in vfio_pci_probe()
      4850d37d
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · aff8ad59
      Linus Torvalds authored
      Pull SCSI fix from James Bottomley:
       "Just one fix: a qlogic busy wait regression"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        qla2xxx: fix busy wait regression
      aff8ad59
    • Linus Torvalds's avatar
      Merge tag 'sound-3.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound · eb749269
      Linus Torvalds authored
      Pull sound fixes from Takashi Iwai:
       "All a few small regression or stable fixes: a Nvidia HDMI ID addition,
        a regression fix for CAIAQ stream count, a typo fix for GPIO setup
        with STAC/IDT HD-audio codecs, and a Fireworks big-endian fix"
      
      * tag 'sound-3.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
        ALSA: fireworks: fix an endianness bug for transaction length
        ALSA: hda - Add new GPU codec ID 0x10de0072 to snd-hda
        ALSA: hda - Fix wrong gpio_dir & gpio_mask hint setups for IDT/STAC codecs
        ALSA: snd-usb-caiaq: fix stream count check
      eb749269
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid · 28023d2a
      Linus Torvalds authored
      Pull HID updates from Jiri Kosina:
      
       - bounds checking fixes in logitech and roccat drivers, from Peter Wu
         and Dan Carpenter
      
       - double-kfree fix in i2c-hid driver on bus shutdown, from Mika
         Westerberg
      
       - a couple of various small driver fixes
      
       - a few device id additions
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
        HID: roccat: potential out of bounds in pyra_sysfs_write_settings()
        HID: Add a new id 0x501a for Genius MousePen i608X
        HID: logitech-hidpp: prefix the name with "Logitech"
        HID: logitech-hidpp: avoid unintended fall-through
        HID: Allow HID_BATTERY_STRENGTH to be enabled
        HID: i2c-hid: Do not free buffers in i2c_hid_stop()
        HID: add battery quirk for USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_ISO keyboard
        HID: logitech-hidpp: check WTP report length
        HID: logitech-dj: check report length
      28023d2a
    • Linus Torvalds's avatar
      Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux · 1dd34daa
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "I'm briefly working between holidays and LCA, so this is close to a
        couple of weeks of fixes,
      
        Two sets of amdkfd fixes, this is a new feature this kernel, and this
        pull fixes a few issues since it got merged, ordering when built-in to
        kernel and also the iommu vs gpu ordering patch, it also reworks the
        ioctl before the initial release.
      
        Otherwise:
         - radeon: some misc fixes all over, hdmi, 4k, dpm
         - nouveau: mcp77 init fixes, oops fix, bug on fix, msi fix
         - i915: power fixes, revert VGACNTR patch
      
        Probably be quiteer next week since I'll be at LCA anyways"
      
      * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux: (33 commits)
        drm/amdkfd: rewrite kfd_ioctl() according to drm_ioctl()
        drm/amdkfd: reformat IOCTL definitions to drm-style
        drm/amdkfd: Do copy_to/from_user in general kfd_ioctl()
        drm/radeon: integer underflow in radeon_cp_dispatch_texture()
        drm/radeon: adjust default bapm settings for KV
        drm/radeon: properly filter DP1.2 4k modes on non-DP1.2 hw
        drm/radeon: fix sad_count check for dce3
        drm/radeon: KV has three PPLLs (v2)
        drm/amdkfd: unmap VMID<-->PASID when relesing VMID (non-HWS)
        drm/radeon: Init amdkfd only if it was compiled
        amdkfd: actually allocate longs for the pasid bitmask
        drm/nouveau/nouveau: Do not BUG_ON(!spin_is_locked()) on UP
        drm/nv4c/mc: disable msi
        drm/nouveau/fb/ram/mcp77: enable NISO poller
        drm/nouveau/fb/ram/mcp77: use carveout reg to determine size
        drm/nouveau/fb/ram/mcp77: subclass nouveau_ram
        drm/nouveau: wake up the card if necessary during gem callbacks
        drm/nouveau/device: Add support for GK208B, resolves bug 86935
        drm/nouveau: fix missing return statement in nouveau_ttm_tt_unpopulate
        drm/nouveau/bios: fix oops on pre-nv50 chipsets
        ...
      1dd34daa
    • Linus Torvalds's avatar
      Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux · d80b34c9
      Linus Torvalds authored
      Pull arm64 fixes from Will Deacon:
       "Here is a handful of minor arm64 fixes discovered and fixed over the
        Christmas break.  The main part is adding some missing #includes that
        we seem to be getting transitively but have started causing problems
        in -next.
      
         - Fix early mapping fixmap corruption by EFI runtime services
         - Fix __NR_compat_syscalls off-by-one
         - Add missing sanity checks for some 32-bit registers
         - Add some missing #includes which we get transitively
         - Remove unused prepare_to_copy() macro"
      
      * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
        arm64/efi: add missing call to early_ioremap_reset()
        arm64: fix missing asm/io.h include in kernel/smp_spin_table.c
        arm64: fix missing asm/alternative.h include in kernel/module.c
        arm64: fix missing linux/bug.h include in asm/arch_timer.h
        arm64: fix missing asm/pgtable-hwdef.h include in asm/processor.h
        arm64: sanity checks: add missing AArch32 registers
        arm64: Remove unused prepare_to_copy()
        arm64: Correct __NR_compat_syscalls for bpf
      d80b34c9
    • Linus Torvalds's avatar
      Merge tag 'for_linus-3.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb · aa929135
      Linus Torvalds authored
      Pull kgdb/kdb fixes from Jason Wessel:
       "These have been around since 3.17 and in kgdb-next for the last 9
        weeks and some will go back to -stable.
      
        Summary of changes:
      
        Cleanups
         - kdb: Remove unused command flags, repeat flags and KDB_REPEAT_NONE
      
        Fixes
         - kgdb/kdb: Allow access on a single core, if a CPU round up is
           deemed impossible, which will allow inspection of the now "trashed"
           kernel
         - kdb: Add enable mask for the command groups
         - kdb: access controls to restrict sensitive commands"
      
      * tag 'for_linus-3.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb:
        kernel/debug/debug_core.c: Logging clean-up
        kgdb: timeout if secondary CPUs ignore the roundup
        kdb: Allow access to sensitive commands to be restricted by default
        kdb: Add enable mask for groups of commands
        kdb: Categorize kdb commands (similar to SysRq categorization)
        kdb: Remove KDB_REPEAT_NONE flag
        kdb: Use KDB_REPEAT_* values as flags
        kdb: Rename kdb_register_repeat() to kdb_register_flags()
        kdb: Rename kdb_repeat_t to kdb_cmdflags_t, cmd_repeat to cmd_flags
        kdb: Remove currently unused kdbtab_t->cmd_flags
      aa929135
    • Linus Torvalds's avatar
      Merge branch 'for-3.19' of git://linux-nfs.org/~bfields/linux · dc9319f5
      Linus Torvalds authored
      Pull two nfsd bugfixes from Bruce Fields.
      
      * 'for-3.19' of git://linux-nfs.org/~bfields/linux:
        rpc: fix xdr_truncate_encode to handle buffer ending on page boundary
        nfsd: fix fi_delegees leak when fi_had_conflict returns true
      dc9319f5
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client · 20ebb345
      Linus Torvalds authored
      Pull two Ceph fixes from Sage Weil:
       "These are both pretty trivial: a sparse warning fix and size_t printk
        thing"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
        libceph: fix sparse endianness warnings
        ceph: use %zu for len in ceph_fill_inline_data()
      20ebb345
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs · 03c751a5
      Linus Torvalds authored
      Pull btrfs fixes from Chris Mason:
       "None of these are huge, but my commit does fix a regression from 3.18
        that could cause lost files during log replay.
      
        This also adds Dave Sterba to the list of Btrfs maintainers.  It
        doesn't mean we're doing things differently, but Dave has really been
        helping with the maintainer workload for years"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
        Btrfs: don't delay inode ref updates during log replay
        Btrfs: correctly get tree level in tree_backref_for_extent
        Btrfs: call inode_dec_link_count() on mkdir error path
        Btrfs: abort transaction if we don't find the block group
        Btrfs, scrub: uninitialized variable in scrub_extent_for_parity()
        Btrfs: add more maintainers
      03c751a5
  5. 09 Jan, 2015 11 commits