1. 29 2月, 2016 4 次提交
  2. 26 2月, 2016 1 次提交
    • T
      ALSA: hda - Loop interrupt handling until really cleared · 473f4145
      Takashi Iwai 提交于
      Currently the interrupt handler of HD-audio driver assumes that no irq
      update is needed while processing the irq.  But in reality, it has
      been confirmed that the HW irq is issued even during the irq
      handling.  Since we clear the irq status at the beginning, process the
      interrupt, then exits from the handler, the lately issued interrupt is
      left untouched without being properly processed.
      
      This patch changes the interrupt handler code to loop over the
      check-and-process.  The handler tries repeatedly as long as the IRQ
      status are turned on, and either stream or CORB/RIRB is handled.
      
      For checking the stream handling, snd_hdac_bus_handle_stream_irq()
      returns a value indicating the stream indices bits.  Other than that,
      the change is only in the irq handler itself.
      Reported-by: NLibin Yang <libin.yang@linux.intel.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      473f4145
  3. 25 2月, 2016 3 次提交
  4. 23 2月, 2016 1 次提交
    • T
      ALSA: hda - Apply clock gate workaround to Skylake, too · 7e31a015
      Takashi Iwai 提交于
      Some Skylake machines show the codec probe errors in certain
      situations, e.g. HP Z240 desktop fails to probe the onboard Realtek
      codec at reloading the snd-hda-intel module like:
        snd_hda_intel 0000:00:1f.3: spurious response 0x200:0x2, last cmd=0x000000
        snd_hda_intel 0000:00:1f.3: azx_get_response timeout, switching to polling mode: lastcmd=0x000f0000
        snd_hda_intel 0000:00:1f.3: No response from codec, disabling MSI: last cmd=0x000f0000
        snd_hda_intel 0000:00:1f.3: Codec #0 probe error; disabling it...
        hdaudio hdaudioC0D2: no AFG or MFG node found
        snd_hda_intel 0000:00:1f.3: no codecs initialized
      
      Also, HP G470 G3 suffers from the similar problem, as reported in
      bugzilla below.  On this machine, the codec probe error appears even
      at a fresh boot.
      
      As Libin suggested, the same workaround used for Broxton in the commit
      [6639484d: ALSA: hda - disable dynamic clock gating on Broxton
       before reset] can be applied for Skylake in order to fix this problem.
      The Intel HW team also confirmed that this is needed for SKL.
      
      This patch makes the workaround applied to both SKL and BXT
      platforms.  The referred macros are moved and one superfluous macro
      (IS_BROXTON()) is another one (IS_BXT()) as well.
      
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=112731Suggested-by: NLibin Yang <libin.yang@linux.intel.com>
      Cc: <stable@vger.kernel.org> # v4.4+
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      7e31a015
  5. 18 2月, 2016 1 次提交
    • T
      ALSA: pcm: Fix rwsem deadlock for non-atomic PCM stream · 67ec1072
      Takashi Iwai 提交于
      A non-atomic PCM stream may take snd_pcm_link_rwsem rw semaphore twice
      in the same code path, e.g. one in snd_pcm_action_nonatomic() and
      another in snd_pcm_stream_lock().  Usually this is OK, but when a
      write lock is issued between these two read locks, the problem
      happens: the write lock is blocked due to the first reade lock, and
      the second read lock is also blocked by the write lock.  This
      eventually deadlocks.
      
      The reason is the way rwsem manages waiters; it's queued like FIFO, so
      even if the writer itself doesn't take the lock yet, it blocks all the
      waiters (including reads) queued after it.
      
      As a workaround, in this patch, we replace the standard down_write()
      with an spinning loop.  This is far from optimal, but it's good
      enough, as the spinning time is supposed to be relatively short for
      normal PCM operations, and the code paths requiring the write lock
      aren't called so often.
      Reported-by: NVinod Koul <vinod.koul@intel.com>
      Tested-by: NRamesh Babu <ramesh.babu@intel.com>
      Cc: <stable@vger.kernel.org> # v3.18+
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      67ec1072
  6. 16 2月, 2016 1 次提交
  7. 15 2月, 2016 2 次提交
    • T
      ALSA: hda - Cancel probe work instead of flush at remove · 0b8c8219
      Takashi Iwai 提交于
      The commit [991f86d7: ALSA: hda - Flush the pending probe work at
      remove] introduced the sync of async probe work at remove for fixing
      the race.  However, this may lead to another hangup when the module
      removal is performed quickly before starting the probe work, because
      it issues flush_work() and it's blocked forever.
      
      The workaround is to use cancel_work_sync() instead of flush_work()
      there.
      
      Fixes: 991f86d7 ('ALSA: hda - Flush the pending probe work at remove')
      Cc: <stable@vger.kernel.org> # v3.17+
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      0b8c8219
    • T
      ALSA: seq: Fix leak of pool buffer at concurrent writes · d99a36f4
      Takashi Iwai 提交于
      When multiple concurrent writes happen on the ALSA sequencer device
      right after the open, it may try to allocate vmalloc buffer for each
      write and leak some of them.  It's because the presence check and the
      assignment of the buffer is done outside the spinlock for the pool.
      
      The fix is to move the check and the assignment into the spinlock.
      
      (The current implementation is suboptimal, as there can be multiple
       unnecessary vmallocs because the allocation is done before the check
       in the spinlock.  But the pool size is already checked beforehand, so
       this isn't a big problem; that is, the only possible path is the
       multiple writes before any pool assignment, and practically seen, the
       current coverage should be "good enough".)
      
      The issue was triggered by syzkaller fuzzer.
      
      BugLink: http://lkml.kernel.org/r/CACT4Y+bSzazpXNvtAr=WXaL8hptqjHwqEyFA+VN2AWEx=aurkg@mail.gmail.comReported-by: NDmitry Vyukov <dvyukov@google.com>
      Tested-by: NDmitry Vyukov <dvyukov@google.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      d99a36f4
  8. 13 2月, 2016 1 次提交
  9. 12 2月, 2016 1 次提交
    • T
      Merge tag 'asoc-fix-v4.5-rc4' of... · 86c2ee16
      Takashi Iwai 提交于
      Merge tag 'asoc-fix-v4.5-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
      
      ASoC: Fixes for v4.5
      
      A rather large batch of fixes here, almost all in the Intel driver.
      The changes that got merged in this merge window for Skylake were rather
      large and as well as issues that you'd expect in a large block of new
      code there were some problems created for older processors which needed
      fixing up.  Things are largely settling down now hopefully.
      86c2ee16
  10. 11 2月, 2016 9 次提交
  11. 10 2月, 2016 1 次提交
  12. 09 2月, 2016 5 次提交
  13. 08 2月, 2016 8 次提交
  14. 07 2月, 2016 2 次提交
    • T
      ALSA: hda - Fix speaker output from VAIO AiO machines · c44d9b11
      Takashi Iwai 提交于
      Some Sony VAIO AiO models (VGC-JS4EF and VGC-JS25G, both with PCI SSID
      104d:9044) need the same quirk to make the speaker working properly.
      
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=112031
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      c44d9b11
    • L
      Merge tag 'usb-4.5-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · 46df55ce
      Linus Torvalds 提交于
      Pull USB fixes from Greg KH:
       "Here are some USB fixes for 4.5-rc3.
      
        The usual, xhci fixes for reported issues, combined with some small
        gadget driver fixes, and a MAINTAINERS file update.  All have been in
        linux-next with no reported issues"
      
      * tag 'usb-4.5-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
        xhci: harden xhci_find_next_ext_cap against device removal
        xhci: Fix list corruption in urb dequeue at host removal
        usb: host: xhci-plat: fix NULL pointer in probe for device tree case
        usb: xhci-mtk: fix AHB bus hang up caused by roothubs polling
        usb: xhci-mtk: fix bpkts value of LS/HS periodic eps not behind TT
        usb: xhci: apply XHCI_PME_STUCK_QUIRK to Intel Broxton-M platforms
        usb: xhci: set SSIC port unused only if xhci_suspend succeeds
        usb: xhci: add a quirk bit for ssic port unused
        usb: xhci: handle both SSIC ports in PME stuck quirk
        usb: dwc3: gadget: set the OTG flag in dwc3 gadget driver.
        Revert "xhci: don't finish a TD if we get a short-transfer event mid TD"
        MAINTAINERS: fix my email address
        usb: dwc2: Fix probe problem on bcm2835
        Revert "usb: dwc2: Move reset into dwc2_get_hwparams()"
        usb: musb: ux500: Fix NULL pointer dereference at system PM
        usb: phy: mxs: declare variable with initialized value
        usb: phy: msm: fix error handling in probe.
      46df55ce