1. 20 Oct, 2017 3 commits
  2. 19 Oct, 2017 5 commits
  3. 18 Oct, 2017 9 commits
    • Linus Torvalds's avatar
      Merge tag 'xfs-4.14-fixes-6' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux · 73d3393a
      Linus Torvalds authored
      Pull xfs fixes from Darrick Wong:
      
       - fix some more CONFIG_XFS_RT related build problems
      
       - fix data loss when writeback at eof races eofblocks gc and loses
      
       - invalidate page cache after fs finishes a dio write
      
       - remove dirty page state when invalidating pages so releasepage does
         the right thing when handed a dirty page
      
      * tag 'xfs-4.14-fixes-6' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux:
        xfs: move two more RT specific functions into CONFIG_XFS_RT
        xfs: trim writepage mapping to within eof
        fs: invalidate page cache after end_io() in dio completion
        xfs: cancel dirty pages on invalidation
      73d3393a
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.dk/linux-block · 020b3023
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
       "Three small fixes:
      
         - A fix for skd, it was using kfree() to free a structure allocate
           with kmem_cache_alloc().
      
         - Stable fix for nbd, fixing a regression using the normal ioctl
           based tools.
      
         - Fix for a previous fix in this series, that fixed up
           inconsistencies between buffered and direct IO"
      
      * 'for-linus' of git://git.kernel.dk/linux-block:
        fs: Avoid invalidation in interrupt context in dio_complete()
        nbd: don't set the device size until we're connected
        skd: Use kmem_cache_free
      020b3023
    • Linus Torvalds's avatar
      Merge tag 'enforcement-4.14-rc6' of... · 3e0cc09a
      Linus Torvalds authored
      Merge tag 'enforcement-4.14-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
      
      Pull enforcement policy update from Greg KH:
       "Documentation: Add a file explaining the requested Linux kernel
        license enforcement policy
      
        Here's a new file to the kernel's Documentation directory. It adds a
        short document describing the views of how the Linux kernel community
        feels about enforcing the license of the kernel.
      
        The patch has been reviewed by a large number of kernel developers
        already, as seen by their acks on the patch, and their agreement of
        the statement with their names on it. The location of the file was
        also agreed upon by the Documentation maintainer, so all should be
        good there.
      
        For some background information about this statement, see this article
        written by some of the kernel developers involved in drafting it:
      
      	http://kroah.com/log/blog/2017/10/16/linux-kernel-community-enforcement-statement/
      
        and this article that answers a number of questions that came up in
        the discussion of this statement with the kernel developer community:
      
      	http://kroah.com/log/blog/2017/10/16/linux-kernel-community-enforcement-statement-faq/
      
        If anyone has any further questions about it, please let me, and the
        TAB members, know and we will be glad to help answer them"
      
      * tag 'enforcement-4.14-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
        Documentation: Add a file explaining the Linux kernel license enforcement policy
      3e0cc09a
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux · 96b0e525
      Linus Torvalds authored
      Pull s390 fixes from Martin Schwidefsky:
       "Two bug fixes:
      
         - A fix for cputime accounting vs CPU hotplug
      
         - Add two options to zfcpdump_defconfig to make SCSI dump work again"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux:
        s390: fix zfcpdump-config
        s390/cputime: fix guest/irq/softirq times after CPU hotplug
      96b0e525
    • Linus Torvalds's avatar
      Merge tag 'trace-v4.14-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace · 503f7e29
      Linus Torvalds authored
      Pull tracing fix from Steven Rostedt:
       "Testing a new trace event format, I triggered a bug by doing:
      
          # modprobe trace-events-sample
          # echo 1 > /sys/kernel/debug/tracing/events/sample-trace/enable
          # rmmod trace-events-sample
      
        This would cause an oops. The issue is that I added another trace
        event sample that reused a reg function of another trace event to
        create a thread to call the tracepoints. The problem was that the reg
        function couldn't handle nested calls (reg; reg; unreg; unreg;) and
        created two threads (instead of one) and only removed one on exit.
      
        This isn't a critical bug as the bug is only in sample code. But
        sample code should be free of known bugs to prevent others from
        copying it. This is why this is also marked for stable"
      
      * tag 'trace-v4.14-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
        tracing/samples: Fix creation and deletion of simple_thread_fn creation
      503f7e29
    • Takashi Iwai's avatar
      ALSA: hda - Fix incorrect TLV callback check introduced during set_fs() removal · a91d6612
      Takashi Iwai authored
      The commit 99b5c5bb ("ALSA: hda - Remove the use of set_fs()")
      converted the get_kctl_0dB_offset() call for killing set_fs() usage in
      HD-audio codec code.  The conversion assumed that the TLV callback
      used in HD-audio code is only snd_hda_mixer_amp() and applies the TLV
      calculation locally.
      
      Although this assumption is correct, and all slave kctls are actually
      with that callback, the current code is still utterly buggy; it
      doesn't hit this condition and falls back to the next check.  It's
      because the function gets called after adding slave kctls to vmaster.
      By assigning a slave kctl, the slave kctl object is faked inside
      vmaster code, and the whole kctl ops are overridden.  Thus the
      callback op points to a different value from what we've assumed.
      
      More badly, as reported by the KERNEXEC and UDEREF features of PaX,
      the code flow turns into the unexpected pitfall.  The next fallback
      check is SNDRV_CTL_ELEM_ACCESS_TLV_READ access bit, and this always
      hits for each kctl with TLV.  Then it evaluates the callback function
      pointer wrongly as if it were a TLV array.  Although currently its
      side-effect is fairly limited, this incorrect reference may lead to an
      unpleasant result.
      
      For addressing the regression, this patch introduces a new helper to
      vmaster code, snd_ctl_apply_vmaster_slaves().  This works similarly
      like the existing map_slaves() in hda_codec.c: it loops over the slave
      list of the given master, and applies the given function to each
      slave.  Then the initializer function receives the right kctl object
      and we can compare the correct pointer instead of the faked one.
      
      Also, for catching the similar breakage in future, give an error
      message when the unexpected TLV callback is found and bail out
      immediately.
      
      Fixes: 99b5c5bb ("ALSA: hda - Remove the use of set_fs()")
      Reported-by: default avatarPaX Team <pageexec@freemail.hu>
      Cc: <stable@vger.kernel.org> # v4.13
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      a91d6612
    • Takashi Iwai's avatar
      ALSA: hda: Remove superfluous '-' added by printk conversion · 6bf88a34
      Takashi Iwai authored
      While converting the error messages to the standard macros in the
      commit 4e76a883 ("ALSA: hda - Replace with standard printk"), a
      superfluous '-' slipped in the code mistakenly.  Its influence is
      almost negligible, merely shows a dB value as negative integer instead
      of positive integer (or vice versa) in the rare error message.
      So let's kill this embarrassing byte to show more correct value.
      
      Fixes: 4e76a883 ("ALSA: hda - Replace with standard printk")
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      6bf88a34
    • Takashi Iwai's avatar
      ALSA: hda: Abort capability probe at invalid register read · 098a0a62
      Takashi Iwai authored
      The loop in snd_hdac_bus_parse_capabilities() may go to nirvana when
      it hits an invalid register value read:
      
       BUG: unable to handle kernel paging request at ffffad5dc41f3fff
       IP: pci_azx_readl+0x5/0x10 [snd_hda_intel]
       Call Trace:
        snd_hdac_bus_parse_capabilities+0x3c/0x1f0 [snd_hda_core]
        azx_probe_continue+0x7d5/0x940 [snd_hda_intel]
        .....
      
      This happened on a new Intel machine, and we need to check the value
      and abort the loop accordingly.
      
      [Note: the fixes tag below indicates only the commit where this patch
       can be applied; the original problem was introduced even before that
       commit]
      
      Fixes: 6720b384 ("ALSA: hda - move bus_parse_capabilities to core")
      Cc: <stable@vger.kernel.org>
      Acked-by: default avatarVinod Koul <vinod.koul@intel.com>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      098a0a62
    • Ben Hutchings's avatar
      ALSA: seq: Enable 'use' locking in all configurations · 8009d506
      Ben Hutchings authored
      The 'use' locking macros are no-ops if neither SMP or SND_DEBUG is
      enabled.  This might once have been OK in non-preemptible
      configurations, but even in that case snd_seq_read() may sleep while
      relying on a 'use' lock.  So always use the proper implementations.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarBen Hutchings <ben.hutchings@codethink.co.uk>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      8009d506
  4. 17 Oct, 2017 4 commits
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · ebe6e90c
      Linus Torvalds authored
      Pull SCSI fixes from James Bottomley:
       "Four mostly error leg fixes and one more important regression in a
        prior commit (the qla2xxx one)"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        scsi: fc: check for rport presence in fc_block_scsi_eh
        scsi: qla2xxx: Fix uninitialized work element
        scsi: libiscsi: fix shifting of DID_REQUEUE host byte
        scsi: libfc: fix a deadlock in fc_rport_work
        scsi: fixup kernel warning during rmmod()
      ebe6e90c
    • Steven Rostedt (VMware)'s avatar
      tracing/samples: Fix creation and deletion of simple_thread_fn creation · 6575257c
      Steven Rostedt (VMware) authored
      Commit 7496946a ("tracing: Add samples of DECLARE_EVENT_CLASS() and
      DEFINE_EVENT()") added template examples for all the events. It created a
      DEFINE_EVENT_FN() example which reused the foo_bar_reg and foo_bar_unreg
      functions.
      
      Enabling both the TRACE_EVENT_FN() and DEFINE_EVENT_FN() example trace
      events caused the foo_bar_reg to be called twice, creating the test thread
      twice. The foo_bar_unreg would remove it only once, even if it was called
      multiple times, leaving a thread existing when the module is unloaded,
      causing an oops.
      
      Add a ref count and allow foo_bar_reg() and foo_bar_unreg() be called by
      multiple trace events.
      
      Cc: stable@vger.kernel.org
      Fixes: 7496946a ("tracing: Add samples of DECLARE_EVENT_CLASS() and DEFINE_EVENT()")
      Signed-off-by: default avatarSteven Rostedt (VMware) <rostedt@goodmis.org>
      6575257c
    • Lukas Czerner's avatar
      fs: Avoid invalidation in interrupt context in dio_complete() · ffe51f01
      Lukas Czerner authored
      Currently we try to defer completion of async DIO to the process context
      in case there are any mapped pages associated with the inode so that we
      can invalidate the pages when the IO completes. However the check is racy
      and the pages can be mapped afterwards. If this happens we might end up
      calling invalidate_inode_pages2_range() in dio_complete() in interrupt
      context which could sleep. This can be reproduced by generic/451.
      
      Fix this by passing the information whether we can or can't invalidate
      to the dio_complete(). Thanks Eryu Guan for reporting this and Jan Kara
      for suggesting a fix.
      
      Fixes: 332391a9 ("fs: Fix page cache inconsistency when mixing buffered and AIO DIO")
      Reported-by: default avatarEryu Guan <eguan@redhat.com>
      Reviewed-by: default avatarJan Kara <jack@suse.cz>
      Tested-by: default avatarEryu Guan <eguan@redhat.com>
      Signed-off-by: default avatarLukas Czerner <lczerner@redhat.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      ffe51f01
    • Linus Torvalds's avatar
      Merge tag 'media/v4.14-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media · 3728e6a2
      Linus Torvalds authored
      Pull media fixes from Mauro Carvalho Chehab:
       "Core fixes:
         - cec: Respond to unregistered initiators, when applicable
         - dvb_frontend: only use kref after initialized
      
        Driver-specific fixes:
         - qcom, camss: Make function vfe_set_selection static
         - qcom: VIDEO_QCOM_CAMSS should depend on HAS_DMA
         - s5p-cec: add NACK detection support
         - media: staging/imx: Fix uninitialized variable warning
         - dib3000mc: i2c transfers over usb cannot be done from stack
         - venus: init registered list on streamoff"
      
      * tag 'media/v4.14-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media:
        media: dvb_frontend: only use kref after initialized
        media: platform: VIDEO_QCOM_CAMSS should depend on HAS_DMA
        media: cec: Respond to unregistered initiators, when applicable
        media: s5p-cec: add NACK detection support
        media: staging/imx: Fix uninitialized variable warning
        media: qcom: camss: Make function vfe_set_selection static
        media: venus: init registered list on streamoff
        media: dvb: i2c transfers over usb cannot be done from stack
      3728e6a2
  5. 16 Oct, 2017 9 commits
  6. 15 Oct, 2017 3 commits
    • Linus Torvalds's avatar
      Merge tag 'char-misc-4.14-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc · ae7df8f9
      Linus Torvalds authored
      Pull char/misc driver fixes from Greg KH:
       "Here are 4 patches to resolve some char/misc driver issues found these
        past weeks.
      
        One of them is a mei bugfix and another is a new mei device id. There
        is also a hyper-v fix for a reported issue, and a binder issue fix for
        a problem reported by a few people.
      
        All of these have been in my tree for a while, I don't know if
        linux-next is really testing much this month. But 0-day is happy with
        them :)"
      
      * tag 'char-misc-4.14-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
        binder: fix use-after-free in binder_transaction()
        Drivers: hv: vmbus: Fix bugs in rescind handling
        mei: me: add gemini lake devices id
        mei: always use domain runtime pm callbacks.
      ae7df8f9
    • Linus Torvalds's avatar
      Merge tag 'usb-4.14-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · 7a263b16
      Linus Torvalds authored
      Pull USB fixes from Greg KH:
       "Here are a handful of USB driver fixes for 4.14-rc5.
      
        There is the "usual" usb-serial fixes and device ids, USB gadget
        fixes, and some more fixes found by the fuzz testing that is happening
        on the USB layer right now.
      
        All of these have been in my tree this week with no reported issues"
      
      * tag 'usb-4.14-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
        usb: usbtest: fix NULL pointer dereference
        usb: gadget: configfs: Fix memory leak of interface directory data
        usb: gadget: composite: Fix use-after-free in usb_composite_overwrite_options
        usb: misc: usbtest: Fix overflow in usbtest_do_ioctl()
        usb: renesas_usbhs: Fix DMAC sequence for receiving zero-length packet
        USB: dummy-hcd: Fix deadlock caused by disconnect detection
        usb: phy: tegra: Fix phy suspend for UDC
        USB: serial: console: fix use-after-free after failed setup
        USB: serial: console: fix use-after-free on disconnect
        USB: serial: qcserial: add Dell DW5818, DW5819
        USB: serial: cp210x: add support for ELV TFD500
        USB: serial: cp210x: fix partnum regression
        USB: serial: option: add support for TP-Link LTE module
        USB: serial: ftdi_sio: add id for Cypress WICED dev board
      7a263b16
    • Linus Torvalds's avatar
      Merge tag 'dmaengine-fix-4.14-rc5' of git://git.infradead.org/users/vkoul/slave-dma · 7a23c5ab
      Linus Torvalds authored
      Pull dmaengine fixes from Vinod Koul:
       "Here are fixes for this round
      
         - fix spinlock usage amd fifo response for altera driver
      
         - fix ti crossbar race condition
      
         - fix edma memcpy align"
      
      * tag 'dmaengine-fix-4.14-rc5' of git://git.infradead.org/users/vkoul/slave-dma:
        dmaengine: altera: fix spinlock usage
        dmaengine: altera: fix response FIFO emptying
        dmaengine: ti-dma-crossbar: Fix possible race condition with dma_inuse
        dmaengine: edma: Align the memcpy acnt array size with the transfer
      7a23c5ab
  7. 14 Oct, 2017 7 commits