Skip to content
  1. Dec 01, 2016
  2. Nov 30, 2016
    • Linus Torvalds's avatar
      Merge tag 'arc-4.9-final' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc · ded6e842
      Linus Torvalds authored
      Pull ARC fixes from Vineet Gupta:
      
       - fix PAE40 crash [Yuriy]
      
       - disable IO-Coherency by default
      
       - use a different inline asm constraint for Zero Overhead loops
      
      * tag 'arc-4.9-final' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc:
        ARC: mm: PAE40: Fix crash at munmap
        ARC: mm: IOC: Don't enable IOC by default
        ARC: Don't use "+l" inline asm constraint
      ded6e842
    • Linus Torvalds's avatar
      Re-enable CONFIG_MODVERSIONS in a slightly weaker form · faaae2a5
      Linus Torvalds authored
      
      
      This enables CONFIG_MODVERSIONS again, but allows for missing symbol CRC
      information in order to work around the issue that newer binutils
      versions seem to occasionally drop the CRC on the floor.  binutils 2.26
      seems to work fine, while binutils 2.27 seems to break MODVERSIONS of
      symbols that have been defined in assembler files.
      
      [ We've had random missing CRC's before - it may be an old problem that
        just is now reliably triggered with the weak asm symbols and a new
        version of binutils ]
      
      Some day I really do want to remove MODVERSIONS entirely.  Sadly, today
      does not appear to be that day: Debian people apparently do want the
      option to enable MODVERSIONS to make it easier to have external modules
      across kernel versions, and this seems to be a fairly minimal fix for
      the annoying problem.
      
      Cc: Ben Hutchings <ben@decadent.org.uk>
      Acked-by: default avatarMichal Marek <mmarek@suse.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      faaae2a5
    • Linus Torvalds's avatar
      Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 · 22d3d4fb
      Linus Torvalds authored
      Pull CIFS fixes from Steve French:
       "A few misc important cifs fixes, including a fix for a 4.9 regression
        in posix_acl xattr handling"
      
      * 'for-next' of git://git.samba.org/sfrench/cifs-2.6:
        CIFS: iterate over posix acl xattr entry correctly in ACL_to_cifs_posix()
        Call echo service immediately after socket reconnect
        CIFS: Fix BUG() in calc_seckey()
      22d3d4fb
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · ab59d1f4
      Linus Torvalds authored
      Pull SCSI fixes from James Bottomley:
       "Four small fixes.
      
        The be2iscsi is a potential device overrun in consistent memory, which
        could have nasty consequences if the consistent allocations are
        packed.
      
        The hpsa one fixes a regression where older controllers can now get a
        numbering clash between the first internal disk and the controller.
      
        The libfc one is a regression in timespec conversions which causes a
        user visible issue in a command line tool and the mpt3sas one fixes a
        regression where the controller could remain permanently blocked after
        an ATA pass through command followed by a reset"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        scsi: be2iscsi: allocate enough memory in beiscsi_boot_get_sinfo()
        scsi: mpt3sas: Unblock device after controller reset
        scsi: hpsa: use bus '3' for legacy HBA devices
        scsi: libfc: fix seconds_since_last_reset miscalculation
      ab59d1f4
    • Yuriy Kolerov's avatar
      ARC: mm: PAE40: Fix crash at munmap · 6a8b2ca7
      Yuriy Kolerov authored
      commit 1c3c9093 broke PAE40. Macro pfn_pte(pfn, prot) creates paddr
      from pfn, but the page shift was getting truncated to 32 bits since we lost
      the proper cast to 64 bits (for PAE400
      
      Instead of reverting that commit, use a better helper which is 32/64 bits
      safe just like ARM implementation.
      
      Fixes: 1c3c9093
      
       ("ARC: mm: fix build breakage with STRICT_MM_TYPECHECKS")
      Cc: <stable@vger.kernel.org>   #4.4+
      Signed-off-by: default avatarYuriy Kolerov <yuriy.kolerov@synopsys.com>
      [vgupta: massaged changelog]
      Signed-off-by: default avatarVineet Gupta <vgupta@synopsys.com>
      6a8b2ca7
    • Aaron Lu's avatar
      mremap: move_ptes: check pte dirty after its removal · a2ce2666
      Aaron Lu authored
      Linus found there still is a race in mremap after commit 5d190420
      
      
      ("mremap: fix race between mremap() and page cleanning").
      
      As described by Linus:
       "the issue is that another thread might make the pte be dirty (in the
        hardware walker, so no locking of ours will make any difference)
        *after* we checked whether it was dirty, but *before* we removed it
        from the page tables"
      
      Fix it by moving the check after we removed it from the page table.
      
      Suggested-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: default avatarAaron Lu <aaron.lu@intel.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      a2ce2666
  3. Nov 29, 2016
    • Eryu Guan's avatar
      CIFS: iterate over posix acl xattr entry correctly in ACL_to_cifs_posix() · ae9ebe7c
      Eryu Guan authored
      Commit 2211d5ba
      
       ("posix_acl: xattr representation cleanups")
      removes the typedefs and the zero-length a_entries array in struct
      posix_acl_xattr_header, and uses bare struct posix_acl_xattr_header
      and struct posix_acl_xattr_entry directly.
      
      But it failed to iterate over posix acl slots when converting posix
      acls to CIFS format, which results in several test failures in
      xfstests (generic/053 generic/105) when testing against a samba v1
      server, starting from v4.9-rc1 kernel. e.g.
      
        [root@localhost xfstests]# diff -u tests/generic/105.out /root/xfstests/results//generic/105.out.bad
        --- tests/generic/105.out       2016-09-19 16:33:28.577962575 +0800
        +++ /root/xfstests/results//generic/105.out.bad 2016-10-22 15:41:15.201931110 +0800
        @@ -1,3 +1,4 @@
         QA output created by 105
         -rw-r--r-- root
        +setfacl: subdir: Invalid argument
         -rw-r--r-- root
      
      Fix it by introducing a new "ace" var, like what
      cifs_copy_posix_acl() does, and iterating posix acl xattr entries
      over it in the for loop.
      
      Signed-off-by: default avatarEryu Guan <guaneryu@gmail.com>
      Signed-off-by: default avatarSteve French <smfrench@gmail.com>
      ae9ebe7c
    • Sachin Prabhu's avatar
      Call echo service immediately after socket reconnect · b8c60012
      Sachin Prabhu authored
      Commit 4fcd1813
      
       ("Fix reconnect to not defer smb3 session reconnect
      long after socket reconnect") changes the behaviour of the SMB2 echo
      service and causes it to renegotiate after a socket reconnect. However
      under default settings, the echo service could take up to 120 seconds to
      be scheduled.
      
      The patch forces the echo service to be called immediately resulting a
      negotiate call being made immediately on reconnect.
      
      Signed-off-by: default avatarSachin Prabhu <sprabhu@redhat.com>
      Reviewed-by: default avatarPavel Shilovsky <pshilov@microsoft.com>
      Signed-off-by: default avatarSteve French <smfrench@gmail.com>
      b8c60012
    • Sachin Prabhu's avatar
      CIFS: Fix BUG() in calc_seckey() · 5f4b5569
      Sachin Prabhu authored
      
      
      Andy Lutromirski's new virtually mapped kernel stack allocations moves
      kernel stacks the vmalloc area. This triggers the bug
       kernel BUG at ./include/linux/scatterlist.h:140!
      at calc_seckey()->sg_init()
      
      Signed-off-by: default avatarSachin Prabhu <sprabhu@redhat.com>
      Signed-off-by: default avatarSteve French <smfrench@gmail.com>
      Reviewed-by: default avatarJeff Layton <jlayton@redhat.com>
      5f4b5569
    • Linus Torvalds's avatar
      Merge branch 'for-4.9-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata · 88abd824
      Linus Torvalds authored
      Pull libata fixes from Tejun Heo:
       "The recent changes in ahci MSI handling need one more fix.  Hopefully,
        this restores parity with before.
      
        The other two are minor fixes with both low impact and risk"
      
      * 'for-4.9-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata:
        ahci: always fall back to single-MSI mode
        libata-scsi: Fixup ata_gen_passthru_sense()
        mvsas: fix error return code in mvs_task_prep()
      88abd824
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc · 96e52d3a
      Linus Torvalds authored
      Pull sparc fixes from David Miller:
       "Two ugly build warning fixes"
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc:
        dbri: Fix compiler warning
        qlogicpti: Fix compiler warnings
      96e52d3a
    • Tushar Dave's avatar
      dbri: Fix compiler warning · 16f46050
      Tushar Dave authored
      
      
      dbri uses 'u32' for dma handle while invoking kernel DMA APIs,
      instead of using dma_addr_t. This hasn't caused any 'incompatible
      pointer type' warning on SPARC because until now dma_addr_t is of
      type u32. However, recent changes in SPARC ATU (iommu) enabled 64bit
      DMA and therefore dma_addr_t became of type u64. This makes
      'incompatible pointer type' warnings inevitable.
      
      e.g.
      sound/sparc/dbri.c: In function ‘snd_dbri_create’:
      sound/sparc/dbri.c:2538: warning: passing argument 3 of ‘dma_zalloc_coherent’ from incompatible pointer type
      ./include/linux/dma-mapping.h:608: note: expected ‘dma_addr_t *’ but argument is of type ‘u32 *’
      
      For the record, dbri(sbus) driver never executes on sun4v. Therefore
      even though 64bit DMA is enabled on SPARC, dbri continues to use
      legacy iommu that guarantees DMA address is always in 32bit range.
      
      This patch resolves above compiler warning.
      
      Signed-off-by: default avatarTushar Dave <tushar.n.dave@oracle.com>
      Reviewed-by: default avatarthomas tai <thomas.tai@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      16f46050
    • Tushar Dave's avatar
      qlogicpti: Fix compiler warnings · e58566b1
      Tushar Dave authored
      
      
      qlogicpti uses '__u32' for dma handle while invoking kernel DMA APIs,
      instead of using dma_addr_t. This hasn't caused any 'incompatible
      pointer type' warning on SPARC because until now dma_addr_t is of
      type u32. However, recent changes in SPARC ATU (iommu) enabled 64bit
      DMA and therefore dma_addr_t became of type u64. This makes
      'incompatible pointer type' warnings inevitable.
      
      e.g.
      drivers/scsi/qlogicpti.c: In function ‘qpti_map_queues’:
      drivers/scsi/qlogicpti.c:813: warning: passing argument 3 of ‘dma_alloc_coherent’ from incompatible pointer type
      ./include/linux/dma-mapping.h:445: note: expected ‘dma_addr_t *’ but argument is of type ‘__u32 *’
      drivers/scsi/qlogicpti.c:822: warning: passing argument 3 of ‘dma_alloc_coherent’ from incompatible pointer type
      ./include/linux/dma-mapping.h:445: note: expected ‘dma_addr_t *’ but argument is of type ‘__u32 *’
      
      For the record, qlogicpti never executes on sun4v. Therefore even
      though 64bit DMA is enabled on SPARC, qlogicpti continues to use
      legacy iommu that guarantees DMA address is always in 32bit range.
      
      This patch resolves aforementioned compiler warnings.
      
      Signed-off-by: default avatarTushar Dave <tushar.n.dave@oracle.com>
      Reviewed-by: default avatarthomas tai <thomas.tai@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e58566b1
    • Vineet Gupta's avatar
      ARC: mm: IOC: Don't enable IOC by default · 23cb1f64
      Vineet Gupta authored
      
      
      Signed-off-by: default avatarVineet Gupta <vgupta@synopsys.com>
      23cb1f64
    • Vineet Gupta's avatar
      ARC: Don't use "+l" inline asm constraint · 3c7c7a2f
      Vineet Gupta authored
      
      
      Apparenty this is coming in the way of gcc fix which inhibits the usage
      of LP_COUNT as a gpr.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarVineet Gupta <vgupta@synopsys.com>
      3c7c7a2f
  4. Nov 28, 2016
  5. Nov 27, 2016
  6. Nov 26, 2016
    • Jon Paul Maloy's avatar
      tipc: resolve connection flow control compatibility problem · 6998cc6e
      Jon Paul Maloy authored
      In commit 10724cc7
      
       ("tipc: redesign connection-level flow control")
      we replaced the previous message based flow control with one based on
      1k blocks. In order to ensure backwards compatibility the mechanism
      falls back to using message as base unit when it senses that the peer
      doesn't support the new algorithm. The default flow control window,
      i.e., how many units can be sent before the sender blocks and waits
      for an acknowledge (aka advertisement) is 512. This was tested against
      the previous version, which uses an acknowledge frequency of on ack per
      256 received message, and found to work fine.
      
      However, we missed the fact that versions older than Linux 3.15 use an
      acknowledge frequency of 512, which is exactly the limit where a 4.6+
      sender will stop and wait for acknowledge. This would also work fine if
      it weren't for the fact that if the first sent message on a 4.6+ server
      side is an empty SYNACK, this one is also is counted as a sent message,
      while it is not counted as a received message on a legacy 3.15-receiver.
      This leads to the sender always being one step ahead of the receiver, a
      scenario causing the sender to block after 512 sent messages, while the
      receiver only has registered 511 read messages. Hence, the legacy
      receiver is not trigged to send an acknowledge, with a permanently
      blocked sender as result.
      
      We solve this deadlock by simply allowing the sender to send one more
      message before it blocks, i.e., by a making minimal change to the
      condition used for determining connection congestion.
      
      Signed-off-by: default avatarJon Maloy <jon.maloy@ericsson.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6998cc6e
    • Arnd Bergmann's avatar
      mvpp2: use correct size for memset · e8f967c3
      Arnd Bergmann authored
      gcc-7 detects a short memset in mvpp2, introduced in the original
      merge of the driver:
      
      drivers/net/ethernet/marvell/mvpp2.c: In function 'mvpp2_cls_init':
      drivers/net/ethernet/marvell/mvpp2.c:3296:2: error: 'memset' used with length equal to number of elements without multiplication by element size [-Werror=memset-elt-size]
      
      The result seems to be that we write uninitialized data into the
      flow table registers, although we did not get any warning about
      that uninitialized data usage.
      
      Using sizeof() lets us initialize then entire array instead.
      
      Fixes: 3f518509
      
       ("ethernet: Add new driver for Marvell Armada 375 network unit")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e8f967c3
    • Geliang Tang's avatar
      net/mlx5: drop duplicate header delay.h · 5e7dfeb7
      Geliang Tang authored
      
      
      Drop duplicate header delay.h from mlx5/core/main.c.
      
      Signed-off-by: default avatarGeliang Tang <geliangtang@gmail.com>
      Acked-by: default avatarMatan Barak <matanb@mellanox.com>
      Acked-by: default avatarSaeed Mahameed <saeedm@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5e7dfeb7
    • Geliang Tang's avatar
      net: ieee802154: drop duplicate header delay.h · 8f8a8b13
      Geliang Tang authored
      
      
      Drop duplicate header delay.h from adf7242.c.
      
      Signed-off-by: default avatarGeliang Tang <geliangtang@gmail.com>
      Acked-by: default avatarStefan Schmidt <stefan@osg.samsung.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      8f8a8b13
    • Geliang Tang's avatar
      ibmvnic: drop duplicate header seq_file.h · 4ee12efa
      Geliang Tang authored
      
      
      Drop duplicate header seq_file.h from ibmvnic.c.
      
      Signed-off-by: default avatarGeliang Tang <geliangtang@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4ee12efa
    • Dan Carpenter's avatar
      fsl/fman: fix a leak in tgec_free() · 1f1e70ef
      Dan Carpenter authored
      We set "tgec->cfg" to NULL before passing it to kfree().  There is no
      need to set it to NULL at all.  Let's just delete it.
      
      Fixes: 57ba4c9b
      
       ("fsl/fman: Add FMan MAC support")
      Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1f1e70ef
    • Miroslav Lichvar's avatar
      net: ethtool: don't require CAP_NET_ADMIN for ETHTOOL_GLINKSETTINGS · 8006f6bf
      Miroslav Lichvar authored
      
      
      The ETHTOOL_GLINKSETTINGS command is deprecating the ETHTOOL_GSET
      command and likewise it shouldn't require the CAP_NET_ADMIN capability.
      
      Signed-off-by: default avatarMiroslav Lichvar <mlichvar@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      8006f6bf
    • Jon Paul Maloy's avatar
      tipc: improve sanity check for received domain records · d876a4d2
      Jon Paul Maloy authored
      In commit 35c55c98
      
       ("tipc: add neighbor monitoring framework") we
      added a data area to the link monitor STATE messages under the
      assumption that previous versions did not use any such data area.
      
      For versions older than Linux 4.3 this assumption is not correct. In
      those version, all STATE messages sent out from a node inadvertently
      contain a 16 byte data area containing a string; -a leftover from
      previous RESET messages which were using this during the setup phase.
      This string serves no purpose in STATE messages, and should no be there.
      
      Unfortunately, this data area is delivered to the link monitor
      framework, where a sanity check catches that it is not a correct domain
      record, and drops it. It also issues a rate limited warning about the
      event.
      
      Since such events occur much more frequently than anticipated, we now
      choose to remove the warning in order to not fill the kernel log with
      useless contents. We also make the sanity check stricter, to further
      reduce the risk that such data is inavertently admitted.
      
      Signed-off-by: default avatarJon Maloy <jon.maloy@ericsson.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d876a4d2
    • Jon Paul Maloy's avatar
      tipc: fix compatibility bug in link monitoring · f7967556
      Jon Paul Maloy authored
      commit 81729810
      
       ("tipc: fix link priority propagation") introduced a
      compatibility problem between TIPC versions newer than Linux 4.6 and
      those older than Linux 4.4. In versions later than 4.4, link STATE
      messages only contain a non-zero link priority value when the sender
      wants the receiver to change its priority. This has the effect that the
      receiver resets itself in order to apply the new priority. This works
      well, and is consistent with the said commit.
      
      However, in versions older than 4.4 a valid link priority is present in
      all sent link STATE messages, leading to cyclic link establishment and
      reset on the 4.6+ node.
      
      We fix this by adding a test that the received value should not only
      be valid, but also differ from the current value in order to cause the
      receiving link endpoint to reset.
      
      Reported-by: default avatarAmar Nv <amar.nv005@gmail.com>
      Signed-off-by: default avatarJon Maloy <jon.maloy@ericsson.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f7967556
    • Andrew Lunn's avatar
      net: ethernet: mvneta: Remove IFF_UNICAST_FLT which is not implemented · 97db8afa
      Andrew Lunn authored
      
      
      The mvneta driver advertises it supports IFF_UNICAST_FLT. However, it
      actually does not. The hardware probably does support it, but there is
      no code to configure the filter. As a quick and simple fix, remove the
      flag. This will cause the core to fall back to promiscuous mode.
      
      Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
      Fixes: b50b72de
      
       ("net: mvneta: enable features before registering the driver")
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      97db8afa
    • Linus Torvalds's avatar
      Merge branch 'parisc-4.9-4' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux · 3ad0e83c
      Linus Torvalds authored
      Pull parisc fixes from Helge Deller:
       "On parisc we were still seeing occasional random segmentation faults
        and memory corruption on SMP machines. Dave Anglin then looked again
        at the TLB related code and found two issues in the PCI DMA and
        generic TLB flush functions.
      
        Then, in our startup code we had some timing of the cache and TLB
        functions to calculate a threshold when to use a complete TLB/cache
        flush or just to flush a specific range. This code produced a race
        with newly started CPUs and thus lead to occasional kernel crashes
        (due to stale TLB/cache entries). The patch by Dave fixes this issue
        by flushing the local caches before starting secondary CPUs and by
        removing the race.
      
        The last problem fixed by this series is that we quite often suffered
        from hung tasks and self-detected stalls on the CPUs. It was somehow
        clear that this was related to the (in v4.7) newly introduced cr16
        clocksource and the own implementation of sched_clock(). I replaced
        the open-coded sched_clock() function and switched to the generic
        sched_clock() implementation which seems to have fixed this isse as
        well.
      
        All patches have been sucessfully tested on a variety of machines,
        including our debian buildd servers.
      
        All patches (beside the small pr_cont fix) are tagged for stable
        releases"
      
      * 'parisc-4.9-4' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
        parisc: Also flush data TLB in flush_icache_page_asm
        parisc: Fix race in pci-dma.c
        parisc: Switch to generic sched_clock implementation
        parisc: Fix races in parisc_setup_cache_timing()
        parisc: Fix printk continuations in system detection
      3ad0e83c
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security · 86b01b54
      Linus Torvalds authored
      Pull keys fixes from James Morris:
       "From David:
      
         - Fix mpi_powm()'s handling of a number with a zero exponent
           [CVE-2016-8650].
      
           Integrate my and Andrey's patches for mpi_powm() and use
           mpi_resize() instead of RESIZE_IF_NEEDED() - the latter adds a
           duplicate check into the execution path of a trivial case we
           don't normally expect to be taken.
      
         - Fix double free in X.509 error handling"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
        mpi: Fix NULL ptr dereference in mpi_powm() [ver #3]
        X.509: Fix double free in x509_cert_parse() [ver #3]
      86b01b54