1. 10 3月, 2017 2 次提交
    • N
      powerpc/64s: fix handling of non-synchronous machine checks · 1363875b
      Nicholas Piggin 提交于
      A synchronous machine check is an exception raised by the attempt to
      execute the current instruction. If the error can't be corrected, it
      can make sense to SIGBUS the currently running process.
      
      In other cases, the error condition is not related to the current
      instruction, so killing the current process is not the right thing to
      do.
      
      Today, all machine checks are MCE_SEV_ERROR_SYNC, so this has no
      practical change. It will be used to handle POWER9 asynchronous
      machine checks.
      Signed-off-by: NNicholas Piggin <npiggin@gmail.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      1363875b
    • L
      powerpc/pmac: Fix crash in dma-mapping.h with NULL dma_ops · 46f401c4
      Larry Finger 提交于
      Commit 5657933d ("treewide: Move dma_ops from struct dev_archdata
      into struct device") introduced a crash for macio devices, an example
      backtrace being:
      
        kernel BUG at ./include/linux/dma-mapping.h:465!
        Oops: Exception in kernel mode, sig: 5 [#1]
        ...
        NIP [c031ddb0] dmam_alloc_coherent+0x74/0x140
        LR [c031de70] dmam_alloc_coherent+0x134/0x140
        Call Trace:
         dmam_alloc_coherent+0x134/0x140 (unreliable)
         pata_macio_port_start+0x3c/0x8c
         ata_host_start.part.5+0xfc/0x208
         ata_host_activate+0x128/0x154
         pata_macio_common_init+0x2f0/0x538
         pata_macio_attach+0xd8/0x180
         macio_device_probe+0x5c/0xec
         driver_probe_device+0x21c/0x314
         __driver_attach+0xcc/0xd0
         bus_for_each_dev+0x68/0xb4
         bus_add_driver+0x1dc/0x244
         driver_register+0x88/0x130
         pata_macio_init+0x5c/0x88
         do_one_initcall+0x40/0x170
         kernel_init_freeable+0x134/0x1d0
         kernel_init+0x18/0x110
         ret_from_kernel_thread+0x5c/0x64
      
      This was caused by the device having NULL dma_ops, triggering the
      BUG_ON(). Previously the device inherited its dma_ops via the assignment
      to dev->ofdev.dev.archdata. However after commit 5657933d the
      dma_ops are moved into dev->ofdev.dev, and so they need to be explicitly
      copied.
      
      Fixes: 5657933d ("treewide: Move dma_ops from struct dev_archdata into struct device")
      Signed-off-by: NLarry Finger <Larry.Finger@lwfinger.net>
      Suggested-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      [mpe: Rewrite change log, add backtrace]
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      46f401c4
  2. 09 3月, 2017 5 次提交
    • A
      powerpc/powernv/ioda2: Update iommu table base on ownership change · db08e1d5
      Alexey Kardashevskiy 提交于
      On POWERNV platform, in order to do DMA via IOMMU (i.e. 32bit DMA in
      our case), a device needs an iommu_table pointer set via
      set_iommu_table_base().
      
      The codeflow is:
      - pnv_pci_ioda2_setup_dma_pe()
      	- pnv_pci_ioda2_setup_default_config()
      	- pnv_ioda_setup_bus_dma() [1]
      
      pnv_pci_ioda2_setup_dma_pe() creates IOMMU groups,
      pnv_pci_ioda2_setup_default_config() does default DMA setup,
      pnv_ioda_setup_bus_dma() takes a bus PE (on IODA2, all physical function
      PEs as bus PEs except NPU), walks through all underlying buses and
      devices, adds all devices to an IOMMU group and sets iommu_table.
      
      On IODA2, when VFIO is used, it takes ownership over a PE which means it
      removes all tables and creates new ones (with a possibility of sharing
      them among PEs). So when the ownership is returned from VFIO to
      the kernel, the iommu_table pointer written to a device at [1] is
      stale and needs an update.
      
      This adds an "add_to_group" parameter to pnv_ioda_setup_bus_dma()
      (in fact re-adds as it used to be there a while ago for different
      reasons) to tell the helper if a device needs to be added to
      an IOMMU group with an iommu_table update or just the latter.
      
      This calls pnv_ioda_setup_bus_dma(..., false) from
      pnv_ioda2_release_ownership() so when the ownership is restored,
      32bit DMA can work again for a device. This does the same thing
      on obtaining ownership as the iommu_table point is stale at this point
      anyway and it is safer to have NULL there.
      
      We did not hit this earlier as all tested devices in recent years were
      only using 64bit DMA; the rare exception for this is MPT3 SAS adapter
      which uses both 32bit and 64bit DMA access and it has not been tested
      with VFIO much.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Acked-by: NGavin Shan <gwshan@linux.vnet.ibm.com>
      Reviewed-by: NDavid Gibson <david@gibson.dropbear.id.au>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      db08e1d5
    • A
      powerpc/powernv/ioda2: Gracefully fail if too many TCE levels requested · 7aafac11
      Alexey Kardashevskiy 提交于
      The IODA2 specification says that a 64 DMA address cannot use top 4 bits
      (3 are reserved and one is a "TVE select"); bottom page_shift bits
      cannot be used for multilevel table addressing either.
      
      The existing IODA2 table allocation code aligns the minimum TCE table
      size to PAGE_SIZE so in the case of 64K system pages and 4K IOMMU pages,
      we have 64-4-12=48 bits. Since 64K page stores 8192 TCEs, i.e. needs
      13 bits, the maximum number of levels is 48/13 = 3 so we physically
      cannot address more and EEH happens on DMA accesses.
      
      This adds a check that too many levels were requested.
      
      It is still possible to have 5 levels in the case of 4K system page size.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Acked-by: NGavin Shan <gwshan@linux.vnet.ibm.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      7aafac11
    • C
      selftests/powerpc: Replace stxvx and lxvx with stxvd2x/lxvd2x · 605df8d6
      Cyril Bur 提交于
      On POWER8 (ISA 2.07) lxvx and stxvx are defined to be extended mnemonics
      of lxvd2x and stxvd2x. For POWER9 (ISA 3.0) the HW architects in their
      infinite wisdom made lxvx and stxvx instructions in their own right.
      
      POWER9 aware GCC will use the POWER9 instruction for lxvx and stxvx
      causing these selftests to fail on POWER8. Further compounding the
      issue, because of the way -mvsx works it will cause the power9
      instructions to be used regardless of -mcpu=power8 to GCC or -mpower8 to
      AS.
      
      The safest way to address the problem for now is to not use the extended
      mnemonic. We don't care how the CPU loads the values from memory since
      the tests only performs register comparisons, so using stdvd2x/lxvd2x
      does not impact the test.
      Signed-off-by: NCyril Bur <cyrilbur@gmail.com>
      Acked-by: Balbir Singh<bsingharora@gmail.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      605df8d6
    • M
      powerpc/perf: Handle sdar_mode for marked event in power9 · 78b4416a
      Madhavan Srinivasan 提交于
      MMCRA[SDAR_MODE] specifices how the SDAR should be updated in
      continous sampling mode. On P9 it must be set to 0b00 when
      MMCRA[63] is set.
      
      Fixes: c7c3f568 ('powerpc/perf: macros for power9 format encoding')
      Signed-off-by: NMadhavan Srinivasan <maddy@linux.vnet.ibm.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      78b4416a
    • M
      powerpc/perf: Fix perf_get_data_addr() for power9 DD1 · f04d1080
      Madhavan Srinivasan 提交于
      Power9 DD1 do not support PMU_HAS_SIER flag and sdsync in
      perf_get_data_addr() defaults to MMCRA_SDSYNC which is wrong. Since
      power9 MMCRA does not support SDSYNC bit, patch includes PPMU_NO_SIAR
      flag to the check and set the sdsync with MMCRA_SAMPLE_ENABLE;
      
      Fixes: 27593d72 ("powerpc/perf: Use MSR to report privilege level on P9 DD1")
      Signed-off-by: NMadhavan Srinivasan <maddy@linux.vnet.ibm.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      f04d1080
  3. 08 3月, 2017 5 次提交
    • M
      powerpc/boot: Fix zImage TOC alignment · 97ee351b
      Michael Ellerman 提交于
      Recent toolchains force the TOC to be 256 byte aligned. We need to
      enforce this alignment in the zImage linker script, otherwise pointers
      to our TOC variables (__toc_start) could be incorrect. If the actual
      start of the TOC and __toc_start don't have the same value we crash
      early in the zImage wrapper.
      
      Cc: stable@vger.kernel.org
      Suggested-by: NAlan Modra <amodra@gmail.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      97ee351b
    • L
      Merge tag 'powerpc-4.11-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · f7d6a728
      Linus Torvalds 提交于
      Pull powerpc fixes from Michael Ellerman:
       "Five fairly small fixes for things that went in this cycle.
      
        A fairly large patch to rework the CAS logic on Power9, necessitated
        by a late change to the firmware API, and we can't boot without it.
      
        Three fixes going to stable, allowing more instructions to be emulated
        on LE, fixing a boot crash on 32-bit Freescale BookE machines, and the
        OPAL XICS workaround.
      
        And a patch from me to sort the selects under CONFIG PPC. Annoying
        churn, but worth it in the long run, and best for it to go in now to
        avoid conflicts.
      
        Thanks to:
          Alexey Kardashevskiy, Anton Blanchard, Balbir Singh, Gautham R.
          Shenoy, Laurentiu Tudor, Nicholas Piggin, Paul Mackerras, Ravi
          Bangoria, Sachin Sant, Shile Zhang, Suraj Jitindar Singh"
      
      * tag 'powerpc-4.11-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc: Sort the selects under CONFIG_PPC
        powerpc/64: Fix L1D cache shape vector reporting L1I values
        powerpc/64: Avoid panic during boot due to divide by zero in init_cache_info()
        powerpc: Update to new option-vector-5 format for CAS
        powerpc: Parse the command line before calling CAS
        powerpc/xics: Work around limitations of OPAL XICS priority handling
        powerpc/64: Fix checksum folding in csum_add()
        powerpc/powernv: Fix opal tracepoints with JUMP_LABEL=n
        powerpc/booke: Fix boot crash due to null hugepd
        powerpc: Fix compiling a BE kernel with a powerpc64le toolchain
        selftest/powerpc: Fix false failures for skipped tests
        powerpc/powernv: Fix bug due to labeling ambiguity in power_enter_stop
        powerpc/64: Invalidate process table caching after setting process table
        powerpc: emulate_step() tests for load/store instructions
        powerpc: Emulation support for load/store instructions on LE
      f7d6a728
    • L
      Merge branch 'stable/for-linus-4.11' of... · 8c2c8ed8
      Linus Torvalds 提交于
      Merge branch 'stable/for-linus-4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/swiotlb
      
      Pull swiotlb updates from Konrad Rzeszutek Wilk:
       "Two tiny implementations of the DMA API for callback in ARM (for Xen)"
      
      * 'stable/for-linus-4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/swiotlb:
        swiotlb-xen: implement xen_swiotlb_get_sgtable callback
        swiotlb-xen: implement xen_swiotlb_dma_mmap callback
      8c2c8ed8
    • L
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace · 304362a8
      Linus Torvalds 提交于
      Pull namespace fix from Eric Biederman:
       "This fixes a race between put_ucounts and get_ucounts that can cause a
        use after free. The fix works by simplifying the code and so there is
        not even a temptation to be clever and play spinlock vs atomic
        reference games"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace:
        ucount: Remove the atomicity from ucount->count
      304362a8
    • L
      Merge tag 'trace-v4.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace · f26db964
      Linus Torvalds 提交于
      Pull tracing fixes from Steven Rostedt:
       "There was some breakage with the changes for jump labels in the 4.11
        merge window:
      
         - powerpc broke as jump labels uses the two LSB bits as flags in
           initialization.
      
           A check was added to make sure that all jump label entries were 4
           bytes aligned, but powerpc didn't work that way for modules. Adding
           an alignment in the module linker script appeared to be the best
           solution.
      
         - Jump labels also added an anonymous union to access those LSB bits
           as a normal long. But because this structure had static
           initialization, it broke older compilers that could not statically
           initialize anonymous unions without brackets.
      
         - The command line parameter for setting function graph filter broke
           the "EMPTY_HASH" descriptor by modifying it instead of creating a
           new hash to hold the entries.
      
         - The command line parameter ftrace_graph_max_depth was added to
           allow its setting at boot time. It uses existing code and only the
           command line hook was added.
      
           This is not really a fix, but as it uses existing code without
           affecting anything else, I added it to this release. It was ready
           before the merge window closed, but I wanted to let it sit in
           linux-next for a couple of days first"
      
      * tag 'trace-v4.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
        ftrace/graph: Add ftrace_graph_max_depth kernel parameter
        tracing: Add #undef to fix compile error
        jump_label: Add comment about initialization order for anonymous unions
        jump_label: Fix anonymous union initialization
        module: set __jump_table alignment to 8
        ftrace/graph: Do not modify the EMPTY_HASH for the function_graph filter
        tracing: Fix code comment for ftrace_ops_get_func()
      f26db964
  4. 07 3月, 2017 1 次提交
  5. 06 3月, 2017 7 次提交
    • M
      powerpc: Sort the selects under CONFIG_PPC · a7d2475a
      Michael Ellerman 提交于
      We have a big list of selects under CONFIG_PPC, and currently they're
      completely unsorted. This means people tend to add new selects at the
      bottom of the list, and so two commits which both add a new select will
      often conflict.
      
      Instead sort it alphabetically. This is nicer in and of itself, but also
      means two commits that add a new select will have a greater chance of
      not conflicting.
      
      Add a note at the top and bottom asking people to keep it sorted.
      
      And while we're here pad out the 'if' expressions to make them stand
      out.
      Suggested-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      a7d2475a
    • M
      powerpc/64: Fix L1D cache shape vector reporting L1I values · 9c7a0086
      Michael Ellerman 提交于
      It seems we didn't pay quite enough attention when testing the new cache
      shape vectors, which means we didn't notice the bug where the vector for
      the L1D was using the L1I values. Fix it, resulting in eg:
      
        L1I  cache size:     0x8000      32768B         32K
        L1I  line size:        0x80       8-way associative
        L1D  cache size:    0x10000      65536B         64K
        L1D  line size:        0x80       8-way associative
      
      Fixes: 98a5f361 ("powerpc: Add new cache geometry aux vectors")
      Cut-and-paste-bug-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Badly-reviewed-by: NMichael Ellerman <mpe@ellerman.id.au>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      9c7a0086
    • A
      powerpc/64: Avoid panic during boot due to divide by zero in init_cache_info() · 6ba422c7
      Anton Blanchard 提交于
      I see a panic in early boot when building with a recent gcc toolchain.
      The issue is a divide by zero, which is undefined. Older toolchains
      let us get away with it:
      
      int foo(int a) { return a / 0; }
      
      foo:
      	li 9,0
      	divw 3,3,9
      	extsw 3,3
      	blr
      
      But newer ones catch it:
      
      foo:
      	trap
      
      Add a check to avoid the divide by zero.
      
      Fixes: e2827fe5 ("powerpc/64: Clean up ppc64_caches using a struct per cache")
      Signed-off-by: NAnton Blanchard <anton@samba.org>
      Acked-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      6ba422c7
    • S
      powerpc: Update to new option-vector-5 format for CAS · 014d02cb
      Suraj Jitindar Singh 提交于
      On POWER9 the ibm,client-architecture-support (CAS) negotiation process
      has been updated to change how the host to guest negotiation is done for
      the new hash/radix mmu as well as the nest mmu, process tables and guest
      translation shootdown (GTSE).
      
      This is documented in the unreleased PAPR ACR "CAS option vector
      additions for P9".
      
      The host tells the guest which options it supports in
      ibm,arch-vec-5-platform-support. The guest then chooses a subset of these
      to request in the CAS call and these are agreed to in the
      ibm,architecture-vec-5 property of the chosen node.
      
      Thus we read ibm,arch-vec-5-platform-support and make our selection before
      calling CAS. We then parse the ibm,architecture-vec-5 property of the
      chosen node to check whether we should run as hash or radix.
      
      ibm,arch-vec-5-platform-support format:
      
      index value pairs: <index, val> ... <index, val>
      
      index: Option vector 5 byte number
      val:   Some representation of supported values
      Signed-off-by: NSuraj Jitindar Singh <sjitindarsingh@gmail.com>
      Acked-by: NPaul Mackerras <paulus@ozlabs.org>
      [mpe: Don't print about unknown options, be consistent with OV5_FEAT]
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      014d02cb
    • S
      powerpc: Parse the command line before calling CAS · 12cc9fd6
      Suraj Jitindar Singh 提交于
      On POWER9 the hypervisor requires the guest to decide whether it would
      like to use a hash or radix mmu model at the time it calls
      ibm,client-architecture-support (CAS) based on what the hypervisor has
      said it's allowed to do. It is possible to disable radix by passing
      "disable_radix" on the command line. The next patch will add support for
      the new CAS format, thus we need to parse the command line before calling
      CAS so we can correctly select which mmu we would like to use.
      Signed-off-by: NSuraj Jitindar Singh <sjitindarsingh@gmail.com>
      Reviewed-by: NPaul Mackerras <paulus@ozlabs.org>
      Acked-by: NBalbir Singh <bsingharora@gmail.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      12cc9fd6
    • B
      powerpc/xics: Work around limitations of OPAL XICS priority handling · a69e2fb7
      Balbir Singh 提交于
      The CPPR (Current Processor Priority Register) of a XICS interrupt
      presentation controller contains a value N, such that only interrupts
      with a priority "more favoured" than N will be received by the CPU,
      where "more favoured" means "less than". So if the CPPR has the value 5
      then only interrupts with a priority of 0-4 inclusive will be received.
      
      In theory the CPPR can support a value of 0 to 255 inclusive.
      In practice Linux only uses values of 0, 4, 5 and 0xff. Setting the CPPR
      to 0 rejects all interrupts, setting it to 0xff allows all interrupts.
      The values 4 and 5 are used to differentiate IPIs from external
      interrupts. Setting the CPPR to 5 allows IPIs to be received but not
      external interrupts.
      
      The CPPR emulation in the OPAL XICS implementation only directly
      supports priorities 0 and 0xff. All other priorities are considered
      equivalent, and mapped to a single priority value internally. This means
      when using icp-opal we can not allow IPIs but not externals.
      
      This breaks Linux's use of priority values when a CPU is hot unplugged.
      After migrating IRQs away from the CPU that is being offlined, we set
      the priority to 5, meaning we still want the offline CPU to receive
      IPIs. But the effect of the OPAL XICS emulation's use of a single
      priority value is that all interrupts are rejected by the CPU. With the
      CPU offline, and not receiving IPIs, we may not be able to wake it up to
      bring it back online.
      
      The first part of the fix is in icp_opal_set_cpu_priority(). CPPR values
      of 0 to 4 inclusive will correctly cause all interrupts to be rejected,
      so we pass those CPPR values through to OPAL. However if we are called
      with a CPPR of 5 or greater, the caller is expecting to be able to allow
      IPIs but not external interrupts. We know this doesn't work, so instead
      of rejecting all interrupts we choose the opposite which is to allow all
      interrupts. This is still not correct behaviour, but we know for the
      only existing caller (xics_migrate_irqs_away()), that it is the better
      option.
      
      The other part of the fix is in xics_migrate_irqs_away(). Instead of
      setting priority (CPPR) to 0, and then back to 5 before migrating IRQs,
      we migrate the IRQs before setting the priority back to 5. This should
      have no effect on an ICP backend with a working set_priority(), and on
      icp-opal it means we will keep all interrupts blocked until after we've
      finished doing the IRQ migration. Additionally we wait for 5ms after
      doing the migration to make sure there are no IRQs in flight.
      
      Fixes: d7436188 ("powerpc/xics: Add ICP OPAL backend")
      Cc: stable@vger.kernel.org # v4.8+
      Suggested-by: NMichael Ellerman <mpe@ellerman.id.au>
      Reported-by: NVaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>
      Tested-by: NVaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>
      Signed-off-by: NBalbir Singh <bsingharora@gmail.com>
      [mpe: Rewrote comments and change log, change delay to 5ms]
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      a69e2fb7
    • L
      Linux 4.11-rc1 · c1ae3cfa
      Linus Torvalds 提交于
      c1ae3cfa
  6. 05 3月, 2017 5 次提交
    • L
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 8d70eeb8
      Linus Torvalds 提交于
      Pull networking fixes from David Miller:
      
       1) Fix double-free in batman-adv, from Sven Eckelmann.
      
       2) Fix packet stats for fast-RX path, from Joannes Berg.
      
       3) Netfilter's ip_route_me_harder() doesn't handle request sockets
          properly, fix from Florian Westphal.
      
       4) Fix sendmsg deadlock in rxrpc, from David Howells.
      
       5) Add missing RCU locking to transport hashtable scan, from Xin Long.
      
       6) Fix potential packet loss in mlxsw driver, from Ido Schimmel.
      
       7) Fix race in NAPI handling between poll handlers and busy polling,
          from Eric Dumazet.
      
       8) TX path in vxlan and geneve need proper RCU locking, from Jakub
          Kicinski.
      
       9) SYN processing in DCCP and TCP need to disable BH, from Eric
          Dumazet.
      
      10) Properly handle net_enable_timestamp() being invoked from IRQ
          context, also from Eric Dumazet.
      
      11) Fix crash on device-tree systems in xgene driver, from Alban Bedel.
      
      12) Do not call sk_free() on a locked socket, from Arnaldo Carvalho de
          Melo.
      
      13) Fix use-after-free in netvsc driver, from Dexuan Cui.
      
      14) Fix max MTU setting in bonding driver, from WANG Cong.
      
      15) xen-netback hash table can be allocated from softirq context, so use
          GFP_ATOMIC. From Anoob Soman.
      
      16) Fix MAC address change bug in bgmac driver, from Hari Vyas.
      
      17) strparser needs to destroy strp_wq on module exit, from WANG Cong.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (69 commits)
        strparser: destroy workqueue on module exit
        sfc: fix IPID endianness in TSOv2
        sfc: avoid max() in array size
        rds: remove unnecessary returned value check
        rxrpc: Fix potential NULL-pointer exception
        nfp: correct DMA direction in XDP DMA sync
        nfp: don't tell FW about the reserved buffer space
        net: ethernet: bgmac: mac address change bug
        net: ethernet: bgmac: init sequence bug
        xen-netback: don't vfree() queues under spinlock
        xen-netback: keep a local pointer for vif in backend_disconnect()
        netfilter: nf_tables: don't call nfnetlink_set_err() if nfnetlink_send() fails
        netfilter: nft_set_rbtree: incorrect assumption on lower interval lookups
        netfilter: nf_conntrack_sip: fix wrong memory initialisation
        can: flexcan: fix typo in comment
        can: usb_8dev: Fix memory leak of priv->cmd_msg_buffer
        can: gs_usb: fix coding style
        can: gs_usb: Don't use stack memory for USB transfers
        ixgbe: Limit use of 2K buffers on architectures with 256B or larger cache lines
        ixgbe: update the rss key on h/w, when ethtool ask for it
        ...
      8d70eeb8
    • L
      Merge tag 'kvm-4.11-2' of git://git.kernel.org/pub/scm/virt/kvm/kvm · 2d62e076
      Linus Torvalds 提交于
      Pull more KVM updates from Radim Krčmář:
       "Second batch of KVM changes for the 4.11 merge window:
      
        PPC:
         - correct assumption about ASDR on POWER9
         - fix MMIO emulation on POWER9
      
        x86:
         - add a simple test for ioperm
         - cleanup TSS (going through KVM tree as the whole undertaking was
           caused by VMX's use of TSS)
         - fix nVMX interrupt delivery
         - fix some performance counters in the guest
      
        ... and two cleanup patches"
      
      * tag 'kvm-4.11-2' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
        KVM: nVMX: Fix pending events injection
        x86/kvm/vmx: remove unused variable in segment_base()
        selftests/x86: Add a basic selftest for ioperm
        x86/asm: Tidy up TSS limit code
        kvm: convert kvm.users_count from atomic_t to refcount_t
        KVM: x86: never specify a sample period for virtualized in_tx_cp counters
        KVM: PPC: Book3S HV: Don't use ASDR for real-mode HPT faults on POWER9
        KVM: PPC: Book3S HV: Fix software walk of guest process page tables
      2d62e076
    • L
      Merge tag 'docs-4.11-fixes' of git://git.lwn.net/linux · be834aaf
      Linus Torvalds 提交于
      Pull documentation fixes from Jonathan Corbet:
       "A few fixes for the docs tree, including one for a 4.11 build
        regression"
      
      * tag 'docs-4.11-fixes' of git://git.lwn.net/linux:
        Documentation/sphinx: fix primary_domain configuration
        docs: Fix htmldocs build failure
        doc/ko_KR/memory-barriers: Update control-dependencies section
        pcieaer doc: update the link
        Documentation: Update path to sysrq.txt
      be834aaf
    • L
      Merge tag 'staging-4.11-rc1-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging · 91aff98b
      Linus Torvalds 提交于
      Pull staging/IIO driver fixes from Greg KH:
       "Here are a few small staging and IIO driver fixes for issues that
        showed up after the big set if changes you merged last week.
      
        Nothing major, just small bugs resolved in some IIO drivers, a lustre
        allocation fix, and some RaspberryPi driver fixes for reported
        problems, as well as a MAINTAINERS entry update.
      
        All of these have been in linux-next for a week with no reported
        issues"
      
      * tag 'staging-4.11-rc1-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
        staging: fsl-mc: fix warning in DT ranges parser
        MAINTAINERS: Remove Noralf Trønnes as fbtft maintainer
        staging: vchiq_2835_arm: Make cache-line-size a required DT property
        staging: bcm2835/mmal-vchiq: unlock on error in buffer_from_host()
        staging/lustre/lnet: Fix allocation size for sv_cpt_data
        iio: adc: xilinx: Fix error handling
        iio: 104-quad-8: Fix off-by-one error when addressing flag register
        iio: adc: handle unknow of_device_id data
      91aff98b
    • L
      Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 · 33a8b3e9
      Linus Torvalds 提交于
      Pull crypto fixes from Herbert Xu:
      
       - vmalloc stack regression in CCM
      
       - Build problem in CRC32 on ARM
      
       - Memory leak in cavium
      
       - Missing Kconfig dependencies in atmel and mediatek
      
       - XTS Regression on some platforms (s390 and ppc)
      
       - Memory overrun in CCM test vector
      
      * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
        crypto: vmx - Use skcipher for xts fallback
        crypto: vmx - Use skcipher for cbc fallback
        crypto: testmgr - Pad aes_ccm_enc_tv_template vector
        crypto: arm/crc32 - add build time test for CRC instruction support
        crypto: arm/crc32 - fix build error with outdated binutils
        crypto: ccm - move cbcmac input off the stack
        crypto: xts - Propagate NEED_FALLBACK bit
        crypto: api - Add crypto_requires_off helper
        crypto: atmel - CRYPTO_DEV_MEDIATEK should depend on HAS_DMA
        crypto: atmel - CRYPTO_DEV_ATMEL_TDES and CRYPTO_DEV_ATMEL_SHA should depend on HAS_DMA
        crypto: cavium - fix leak on curr if curr->head fails to be allocated
        crypto: cavium - Fix couple of static checker errors
      33a8b3e9
  7. 04 3月, 2017 15 次提交
    • S
      powerpc/64: Fix checksum folding in csum_add() · 6ad966d7
      Shile Zhang 提交于
      Paul's patch to fix checksum folding, commit b492f7e4 ("powerpc/64:
      Fix checksum folding in csum_tcpudp_nofold and ip_fast_csum_nofold")
      missed a case in csum_add(). Fix it.
      Signed-off-by: NShile Zhang <shile.zhang@nokia.com>
      Acked-by: NPaul Mackerras <paulus@ozlabs.org>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      6ad966d7
    • A
      powerpc/powernv: Fix opal tracepoints with JUMP_LABEL=n · 2a9c4f40
      Alexey Kardashevskiy 提交于
      The recent commit to allow calling OPAL calls in real mode, commit
      ab9bad0e ("powerpc/powernv: Remove separate entry for OPAL real mode
      calls"), introduced a bug when CONFIG_JUMP_LABEL=n.
      
      The commit moved the "mfmsr r12" prior to the call to OPAL_BRANCH, but
      we missed that OPAL_BRANCH clobbers r12 when jump labels are disabled.
      This leads to us using the tracepoint refcount as the MSR value,
      typically zero, and saving that into PACASAVEDMSR. When we return from
      OPAL we use that value as the MSR value for rfid, meaning we switch to
      32-bit BE real mode - hilarity ensues.
      
      Fix it by using r11 in OPAL_BRANCH, which is not live at the time the
      macro is used in OPAL_CALL.
      
      Fixes: ab9bad0e ("powerpc/powernv: Remove separate entry for OPAL real mode calls")
      Suggested-by: NPaul Mackerras <paulus@samba.org>
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      2a9c4f40
    • L
      Merge branch 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 0710f3ff
      Linus Torvalds 提交于
      Pull misc final vfs updates from Al Viro:
       "A few unrelated patches that got beating in -next.
      
        Everything else will have to go into the next window ;-/"
      
      * 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
        hfs: fix hfs_readdir()
        selftest for default_file_splice_read() infoleak
        9p: constify ->d_name handling
      0710f3ff
    • L
      Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · a3b4924b
      Linus Torvalds 提交于
      Pull more SCSI updates from James Bottomley:
       "This is the set of stuff that didn't quite make the initial pull and a
        set of fixes for stuff which did.
      
        The new stuff is basically lpfc (nvme), qedi and aacraid. The fixes
        cover a lot of previously submitted stuff, the most important of which
        probably covers some of the failing irq vectors allocation and other
        fallout from having the SCSI command allocated as part of the block
        allocation functions"
      
      * tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (59 commits)
        scsi: qedi: Fix memory leak in tmf response processing.
        scsi: aacraid: remove redundant zero check on ret
        scsi: lpfc: use proper format string for dma_addr_t
        scsi: lpfc: use div_u64 for 64-bit division
        scsi: mac_scsi: Fix MAC_SCSI=m option when SCSI=m
        scsi: cciss: correct check map error.
        scsi: qla2xxx: fix spelling mistake: "seperator" -> "separator"
        scsi: aacraid: Fixed expander hotplug for SMART family
        scsi: mpt3sas: switch to pci_alloc_irq_vectors
        scsi: qedf: fixup compilation warning about atomic_t usage
        scsi: remove scsi_execute_req_flags
        scsi: merge __scsi_execute into scsi_execute
        scsi: simplify scsi_execute_req_flags
        scsi: make the sense header argument to scsi_test_unit_ready mandatory
        scsi: sd: improve TUR handling in sd_check_events
        scsi: always zero sshdr in scsi_normalize_sense
        scsi: scsi_dh_emc: return success in clariion_std_inquiry()
        scsi: fix memory leak of sdpk on when gd fails to allocate
        scsi: sd: make sd_devt_release() static
        scsi: qedf: Add QLogic FastLinQ offload FCoE driver framework.
        ...
      a3b4924b
    • W
      strparser: destroy workqueue on module exit · f78ef7cd
      WANG Cong 提交于
      Fixes: 43a0c675 ("strparser: Stream parser for messages")
      Cc: Tom Herbert <tom@herbertland.com>
      Signed-off-by: NCong Wang <xiyou.wangcong@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f78ef7cd
    • D
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf · 20b83643
      David S. Miller 提交于
      Pablo Neira Ayuso says:
      
      ====================
      Netfilter fixes for net
      
      The following patchset contains Netfilter fixes for your net tree,
      they are:
      
      1) Missing check for full sock in ip_route_me_harder(), from
         Florian Westphal.
      
      2) Incorrect sip helper structure initilization that breaks it when
         several ports are used, from Christophe Leroy.
      
      3) Fix incorrect assumption when looking up for matching with adjacent
         intervals in the nft_set_rbtree.
      
      4) Fix broken netlink event error reporting in nf_tables that results
         in misleading ESRCH errors propagated to userspace listeners.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      20b83643
    • L
      Merge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm · 0b94da8d
      Linus Torvalds 提交于
      Pull libnvdimm fixes from Dan Williams:
       "A fix and regression test case for nvdimm namespace label
        compatibility.
      
        Details:
      
         - An "nvdimm namespace label" is metadata on an nvdimm that
           provisions dimm capacity into a "namespace" that can host a block
           device / dax-filesytem, or a device-dax character device.
      
           A namespace is an object that other operating environment and
           platform firmware needs to comprehend for capabilities like booting
           from an nvdimm.
      
           The label metadata contains a checksum that Linux was not
           calculating correctly leading to other environments rejecting the
           Linux label.
      
         These have received a build success notification from the kbuild
         robot, and a positive test result from Nick who reported the problem"
      
      * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm:
        nfit, libnvdimm: fix interleave set cookie calculation
        tools/testing/nvdimm: make iset cookie predictable
      0b94da8d
    • L
      Merge tag 'pci-v4.11-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci · e27fd02d
      Linus Torvalds 提交于
      Pull PCI fixes from Bjorn Helgaas:
      
       - fix NULL pointer dereferences in many DesignWare-based drivers due to
         refactoring error
      
       - fix Altera config write breakage due to my refactoring error
      
      * tag 'pci-v4.11-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci:
        PCI: altera: Fix TLP_CFG_DW0 for TLP write
        PCI: dwc: Fix crashes seen due to missing assignments
      e27fd02d
    • L
      Merge branch 'parisc-4.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux · f47e2db4
      Linus Torvalds 提交于
      Pull parisc fixes and cleanups from Helge Deller:
       "Nothing really important in this patchset: fix resource leaks in error
        paths, coding style cleanups and code removal"
      
      * 'parisc-4.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
        parisc: Remove flush_user_dcache_range and flush_user_icache_range
        parisc: fix a printk
        parisc: ccio-dma: Handle return NULL error from ioremap_nocache
        parisc: Define access_ok() as macro
        parisc: eisa: Fix resource leaks in error paths
        parisc: eisa: Remove coding style errors
      f47e2db4
    • L
      Merge tag 'xtensa-20170303' of git://github.com/jcmvbkbc/linux-xtensa · 606ed721
      Linus Torvalds 提交于
      Pull Xtensa updates from Max Filippov:
      
       - clean up bootable image build targets: provide separate 'Image',
         'zImage' and 'uImage' make targets that only build corresponding
         image type. Make 'all' build all images appropriate for a platform
      
       - allow merging vectors code into .text section as a preparation step
         for XIP support
      
       - fix handling external FDT when the kernel is built without
         BLK_DEV_INITRD support
      
      * tag 'xtensa-20170303' of git://github.com/jcmvbkbc/linux-xtensa:
        xtensa: allow merging vectors into .text section
        xtensa: clean up bootable image build targets
        xtensa: move parse_tag_fdt out of #ifdef CONFIG_BLK_DEV_INITRD
      606ed721
    • L
      Merge tag 'armsoc-late' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · a1a0db36
      Linus Torvalds 提交于
      Pull ARM SoC late DT updates from Arnd Bergmann:
       "These updates have been kept in a separate branch mostly because they
        rely on updates to the respective clk drivers to keep the shared
        header files in sync.
      
        This includes two branches for arm64 dt updates, both following up on
        earlier changes for the same platforms that are already merged:
      
        Samsung:
         - add USB3 support in Exynos7
         - minor PM related updates
      
        Amlogic:
         - new machines: WeTek Set-top-boxes
         - various devices added to DT
      
        There are also a couple of bugfixes that trickled in since the start
        of the merge window:
      
         - The moxart_defconfig was not building the intended platform
         - CPU-hotplug was broken on ux500
         - Coresight was broken on Juno (never worked)"
      
      * tag 'armsoc-late' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (26 commits)
        ARM: deconfig: fix the moxart defconfig
        ARM: ux500: resume the second core properly
        arm64: dts: juno: update definition for programmable replicator
        arm64: dts: exynos: Add regulators for Vbus and Vbus-Boost
        arm64: dts: exynos: Add USB 3.0 controller node for Exynos7
        arm64: dts: exynos: Use macros for pinctrl configuration on Exynos7
        pinctrl: dt-bindings: samsung: Add Exynos7 specific pinctrl macro definitions
        arm64: dts: exynos: Add initial configuration for DISP clocks for TM2/TM2e
        ARM64: dts: meson-gxbb-p200: add ADC laddered keys
        ARM64: dts: meson: meson-gx: add the SAR ADC
        ARM64: dts: meson-gxl: add the pwm_ao_b pin
        ARM64: dts: meson-gx: add the missing pwm_AO_ab node
        clk: gxbb: fix CLKID_ETH defined twice
        ARM64: dts: meson-gxl: rename Nexbox A95x for consistency
        clk: gxbb: add the SAR ADC clocks and expose them
        dt-bindings: amlogic: Add WeTek boards
        ARM64: dts: meson-gxbb: Add support for WeTek Hub and Play
        dt-bindings: vendor-prefix: Add wetek vendor prefix
        ARM64: dts: meson-gxm: Rename q200 and q201 DT files for consistency
        ARM64: dts: meson-gx: Add HDMI HPD/DDC pinctrl nodes
        ...
      a1a0db36
    • L
      Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 · 0a040b21
      Linus Torvalds 提交于
      Pull SMB3 fixes from Steve French:
       "Some small bug fixes as well as SMB2.1/SMB3 enablement for DFS (global
        namespace) which previously was only enabled for CIFS"
      
      * 'for-next' of git://git.samba.org/sfrench/cifs-2.6:
        smb2: Enforce sec= mount option
        CIFS: Fix sparse warnings
        CIFS: implement get_dfs_refer for SMB2+
        CIFS: use DFS pathnames in SMB2+ Create requests
        CIFS: set signing flag in SMB2+ TreeConnect if needed
        CIFS: let ses->ipc_tid hold smb2 TreeIds
        CIFS: add use_ipc flag to SMB2_ioctl()
        CIFS: add build_path_from_dentry_optional_prefix()
        CIFS: move DFS response parsing out of SMB1 code
        CIFS: Fix possible use after free in demultiplex thread
      0a040b21
    • J
      Documentation/sphinx: fix primary_domain configuration · fd5d6669
      John Keeping 提交于
      With Sphinx 1.5.3 I get the warning:
      
      	WARNING: primary_domain 'C' not found, ignored.
      
      It seems that domain names in Sphinx are case-sensitive and for the C
      domain the name must be lower case.
      Signed-off-by: NJohn Keeping <john@metanate.com>
      Signed-off-by: NJonathan Corbet <corbet@lwn.net>
      fd5d6669
    • M
      docs: Fix htmldocs build failure · f3fc83e5
      Martyn Welch 提交于
      Build of HTML docs failing due to conversion of deviceiobook.tmpl in
      8a8a602f and regulator.tmpl in 028f2533 to RST without removing from
      DOCBOOKS in Makefile, resulting (in the case of deviceiobook) the
      following error:
      
      make[1]: *** No rule to make target 'Documentation/DocBook/deviceiobook.xml', needed by 'Documentation/DocBook/deviceiobook.aux.xml'.  Stop.
      Makefile:1452: recipe for target 'htmldocs' failed
      make: *** [htmldocs] Error 2
      
      Update DOCBOOKS to reflect available books.
      Signed-off-by: NMartyn Welch <martyn.welch@collabora.co.uk>
      Signed-off-by: NJonathan Corbet <corbet@lwn.net>
      f3fc83e5
    • S
      doc/ko_KR/memory-barriers: Update control-dependencies section · 9857b1ad
      SeongJae Park 提交于
      This commit applies upstream change, commit c8241f85 ("doc: Update
      control-dependencies section of memory-barriers.txt"), to Korean
      translation.
      Signed-off-by: NSeongJae Park <sj38.park@gmail.com>
      Signed-off-by: NJonathan Corbet <corbet@lwn.net>
      9857b1ad