1. 28 Nov, 2016 16 commits
  2. 27 Nov, 2016 6 commits
  3. 26 Nov, 2016 18 commits
    • Linus Torvalds's avatar
      Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux · e3480312
      Linus Torvalds authored
      Pull i2c fixes from Wolfram Sang:
       "Here is a revert and two bugfixes for the I2C designware driver.
      
        Please note that we are still hunting down a regression for the
        i2c-octeon driver. While there is a fix pending, we have unclear
        feedback from the testers currently. An rc8 would be quite helpful
        for this case"
      
      * 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
        Revert "i2c: designware: do not disable adapter after transfer"
        i2c: designware: fix rx fifo depth tracking
        i2c: designware: report short transfers
      e3480312
    • Linus Torvalds's avatar
      Merge branch 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm · a56f3eb2
      Linus Torvalds authored
      Pull ARM fix from Russell King:
       "This resolves the ksyms issues by reverting the commit which
        introduced the breakage"
      
      There was what I consider to be a better fix, but it's late in the rc
      game, so I'll take the revert.
      
      * 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm:
        Revert "arm: move exports to definitions"
      a56f3eb2
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · a0d60e62
      Linus Torvalds authored
      Pull networking fixes from David Miller:
      
       1) Fix leak in fsl/fman driver, from Dan Carpenter.
      
       2) Call flow dissector initcall earlier than any networking driver can
          register and start to use it, from Eric Dumazet.
      
       3) Some dup header fixes from Geliang Tang.
      
       4) TIPC link monitoring compat fix from Jon Paul Maloy.
      
       5) Link changes require EEE re-negotiation in bcm_sf2 driver, from
          Florian Fainelli.
      
       6) Fix bogus handle ID passed into tfilter_notify_chain(), from Roman
          Mashak.
      
       7) Fix dump size calculation in rtnl_calcit(), from Zhang Shengju.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (26 commits)
        tipc: resolve connection flow control compatibility problem
        mvpp2: use correct size for memset
        net/mlx5: drop duplicate header delay.h
        net: ieee802154: drop duplicate header delay.h
        ibmvnic: drop duplicate header seq_file.h
        fsl/fman: fix a leak in tgec_free()
        net: ethtool: don't require CAP_NET_ADMIN for ETHTOOL_GLINKSETTINGS
        tipc: improve sanity check for received domain records
        tipc: fix compatibility bug in link monitoring
        net: ethernet: mvneta: Remove IFF_UNICAST_FLT which is not implemented
        dwc_eth_qos: drop duplicate headers
        net sched filters: fix filter handle ID in tfilter_notify_chain()
        net: dsa: bcm_sf2: Ensure we re-negotiate EEE during after link change
        bnxt: do not busy-poll when link is down
        udplite: call proper backlog handlers
        ipv6: bump genid when the IFA_F_TENTATIVE flag is clear
        net/mlx4_en: Free netdev resources under state lock
        net: revert "net: l2tp: Treat NET_XMIT_CN as success in l2tp_eth_dev_xmit"
        rtnetlink: fix the wrong minimal dump size getting from rtnl_calcit()
        bnxt_en: Fix a VXLAN vs GENEVE issue
        ...
      a0d60e62
    • Linus Torvalds's avatar
      Merge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm · 30e2b7cf
      Linus Torvalds authored
      Pull libnvdimm fixes from Dan Williams:
      
       - Fix a crash that occurs at driver initialization if the memory region
         is already busy (request_mem_region() fails).
      
       - Fix a vma validation check that mistakenly allows a private device-
         dax mapping to be established. Device-dax explicitly forbids private
         mappings so it can guarantee a given fault granularity and backing
         memory type.
      
       Both of these fixes have soaked in -next and are tagged for -stable.
      
      * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm:
        device-dax: fail all private mapping attempts
        device-dax: check devm_nsio_enable() return value
      30e2b7cf
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm · fc13ca19
      Linus Torvalds authored
      Pull KVM fixes from Radim Krčmář:
       "Four fixes for bugs found by syzkaller on x86, all for stable"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
        KVM: x86: check for pic and ioapic presence before use
        KVM: x86: fix out-of-bounds accesses of rtc_eoi map
        KVM: x86: drop error recovery in em_jmp_far and em_ret_far
        KVM: x86: fix out-of-bounds access in lapic
      fc13ca19
    • Linus Torvalds's avatar
      Merge tag 'powerpc-4.9-6' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · 39c15737
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
       "Fixes marked for stable:
         - Set missing wakeup bit in LPCR on POWER9
         - Fix the early OPAL console wrappers
         - Fixup kernel read only mapping
      
        Fixes for code merged this cycle:
         - Fix missing CRCs, add more asm-prototypes.h declarations"
      
      * tag 'powerpc-4.9-6' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc/mm: Fixup kernel read only mapping
        powerpc/boot: Fix the early OPAL console wrappers
        powerpc: Fix missing CRCs, add more asm-prototypes.h declarations
        powerpc: Set missing wakeup bit in LPCR on POWER9
      39c15737
    • 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
    • David S. Miller's avatar
      Merge branch 'mlxsw-trap-groups-and-policers' · e5f12b3f
      David S. Miller authored
      Jiri Pirko says:
      
      ====================
      mlxsw: traps, trap groups and policers
      
      Nogah says:
      
      For a packet to be sent from the HW to the cpu, it needs to be trapped.
      For a trap to be activate it should be assigned to a trap group.
      Those trap groups can have policers, to limit the packet rate (the max
      number of packets that can be sent to the cpu in a time slot, the rest
      will be discarded) or the data rate (the same, but the count is not by the
      number of packets but by their total length in bytes).
      
      This patchset rearrange the trap setting API, re-write the traps and the
      trap groups list in spectrum and assign them policers.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e5f12b3f
    • Nogah Frankel's avatar
      mlxsw: spectrum: Add policers for trap groups · 9148e7cf
      Nogah Frankel authored
      Configure policers and connect them to trap groups.
      
      While many trap groups share policer's configuration they don't share
      the actual policer because each trap group represents a different
      flow / protocol and we don't want one of them to be able to exceed its
      rate on behalf of another.
      For example, if STP and LLDP gets to send 128 packets/sec each, if we
      put them in one 256 packets/sec policer, one can send 200 packets while
      the other only 50.
      
      Note that IP2ME covers lots of flows, so it's limit is set to match the
      cpu ability to handle data.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      9148e7cf
    • Nogah Frankel's avatar
      mlxsw: reg: Add QoS Policer Configuration Register · 76a4c7d3
      Nogah Frankel authored
      The QPCR register is used to create and control policers.
      A policer can discard or change the color of packets that are
      trapped by a specific trap.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      76a4c7d3
    • Nogah Frankel's avatar
      mlxsw: resources: Add max cpu policers resource · 2b77958b
      Nogah Frankel authored
      Add a new resource to resources query: max cpu policers which tells us how
      many policers can be used to limit the data rate to the cpu port.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Reviewed-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      2b77958b
    • Nogah Frankel's avatar
      mlxsw: Create a different trap group list for each device · 117b0dad
      Nogah Frankel authored
      Trap groups can be used to control traps priority, both in terms of
      which trap "wins" if a packet matches two traps (priority) and in terms
      of packets from which trap group will be scheduled to the cpu first (tc).
      They can also be used to set rate limiters (policers) on them (will be
      added in the next patches).
      
      Currently, we support two trap groups. In Spectrum we want a better
      resolution, so every protocol / flow will have a different trap group,
      so we can control its parameters separately. Once the policers will be
      implemented, it will also allow us limit the rate of each protocol by
      itself.
      
      This patch change the trap group list to include:
      * the emad trap group, which is shared for all the devices.
      * Switchx2's trap groups, which are a copy of the current trap groups.
      * Spectrum's new trap groups, in order to match the above guidelines.
      (Switchib is using only the emad trap group, so it require no changes).
      
      This patch also includes new configuration for Spectrum's trap groups,
      with primary priority order within them.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      117b0dad
    • Nogah Frankel's avatar
      mlxsw: spectrum: Add BGP trap · 616d8040
      Nogah Frankel authored
      Add a trap for BGP protocol that was previously trapped by the generic trap
      for IP2ME. This trap will allow us to have better control (over priority
      and rate) of the traffic.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      616d8040
    • Nogah Frankel's avatar
      mlxsw: Change trap groups setting · 579c82e4
      Nogah Frankel authored
      Trap groups have many options which we currently set to default values.
      In the next patches we will use many of them with non-default values.
      
      Some of these options have no default value, so this patch sets them as
      params for the trap group set function. Others almost always use the same
      values, so the set function will use this default values. In the rare cases
      when they will need to be with other values, these values can be set
      directly (using the macros for fields in registers).
      
      Parameters without default value:
      TC - the traffic class for packets that hit this trap group.
          (old default is the max tc)
      priority - if one packet hits multiple trap groups, the group with the
      	   higher priority will "catch" it. (old default is 0)
      policer - limit rate policer (old default is disabled)
      
      Default parameters:
      swid - switch id, relevant for the emad trap only, ignored on Spectrum.
             (new default is 0)
      rdq - CPU receive descriptor queue (new default is identical to trap
            group id)
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      579c82e4
    • Nogah Frankel's avatar
      mlxsw: resources: Add max trap groups resource · 23432cb8
      Nogah Frankel authored
      Add the max number of trap groups to resource query.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Reviewed-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      23432cb8
    • Nogah Frankel's avatar
      mlxsw: core: Change emad trap group settings · 9d87fcea
      Nogah Frankel authored
      Currently, the emad trap init was done in the core. In the future we will
      want to add some changes to the traps groups, according to device type.
      This commit create a driver function to create the trap group for the
      emad, so later it can be changed by devices. It also changes the emad
      registration to use the new generic functions.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      9d87fcea
    • Nogah Frankel's avatar
      mlxsw: Add option to choose trap group · 0fb78a4e
      Nogah Frankel authored
      Currently, we set the trap group to pre-determined option, based on whether
      it is an rx or event trap.
      This commit adds a possibility to chose the trap group, so it can be set
      to different values in the following patches.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      0fb78a4e
    • Nogah Frankel's avatar
      mlxsw: Change trap set function · d570b7ee
      Nogah Frankel authored
      Change trap setting function so instead of determining the trap group by
      trap id, it gets it as a parameter (so later we can have different trap
      groups for Spectrum and Switchx2).
      Add "is_ctrl" parameter to the trap setting function. It control whether
      the trapped packets wait in a designated control buffer or in their
      default one. This parameter is ignored by Switchx2 and Switchib.
      Add these parameters to the traps array in Spectrum, Switchx2 and
      Switchib.
      Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d570b7ee