- 24 Feb, 2020 40 commits
-
-
Jules Irenge authored
Sparse reports a warning at nr_node_start() warning: context imbalance in nr_node_start() - wrong count at exit The root cause is the missing annotation at nr_node_start() Add the missing __acquires(&nr_node_list_lock) annotation Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jules Irenge authored
Sparse reports a warning at nr_info_stop() warning: context imbalance in nr_info_stop() - unexpected unlock The root cause is the missing annotation at nr_info_stop() Add the missing __releases(&nr_list_lock) Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jules Irenge authored
Sparse reports a warning at nr_info_start() warning: context imbalance in nr_info_start() - wrong count at exit The root cause is the missing annotation at nr_info_start() Add the missing __acquires(&nr_list_lock) Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jules Irenge authored
Sparse reports a warning at llc_seq_start() warning: context imbalance in llc_seq_start() - wrong count at exit The root cause is the msiing annotation at llc_seq_start() Add the missing __acquires(RCU) annotation Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jules Irenge authored
Sparse reports a warning at sctp_transport_walk_stop() warning: context imbalance in sctp_transport_walk_stop - wrong count at exit The root cause is the missing annotation at sctp_transport_walk_stop() Add the missing __releases(RCU) annotation Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jules Irenge authored
Sparse reports a warning at sctp_transport_walk_start() warning: context imbalance in sctp_transport_walk_start - wrong count at exit The root cause is the missing annotation at sctp_transport_walk_start() Add the missing __acquires(RCU) annotation Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jules Irenge authored
Sparse reports a warning at sctp_err_finish() warning: context imbalance in sctp_err_finish() - unexpected unlock The root cause is a missing annotation at sctp_err_finish() Add the missing __releases(&((__sk)->sk_lock.slock)) annotation Signed-off-by: Jules Irenge <jbi.octave@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Amol Grover authored
ip6mr_for_each_table() macro uses list_for_each_entry_rcu() for traversing outside an RCU read side critical section but under the protection of rtnl_mutex. Hence add the corresponding lockdep expression to silence the following false-positive warnings: [ 4.319479] ============================= [ 4.319480] WARNING: suspicious RCU usage [ 4.319482] 5.5.4-stable #17 Tainted: G E [ 4.319483] ----------------------------- [ 4.319485] net/ipv6/ip6mr.c:1243 RCU-list traversed in non-reader section!! [ 4.456831] ============================= [ 4.456832] WARNING: suspicious RCU usage [ 4.456834] 5.5.4-stable #17 Tainted: G E [ 4.456835] ----------------------------- [ 4.456837] net/ipv6/ip6mr.c:1582 RCU-list traversed in non-reader section!! Signed-off-by: Amol Grover <frextrite@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Min Li authored
The IDT 82P33 Synchronization Management Unit (SMU) family provides tools to manage timing references, clock sources and timing paths for IEEE 1588 / Precision Time Protocol (PTP) and Synchronous Ethernet (SyncE) based clocks. The device supports up to three independent timing paths that control: PTP clock synthesis; SyncE clock generation; and general purpose frequency translation. The device supports physical layer timing with Digital PLLs (DPLLs) and it supports packet based timing with Digitally Controlled Oscillators (DCOs). This patch adds support for ptp clock based on the device. Changes since v1: - As suggested by Richard Cochran: 1. Replace _mask_bit_count with the existing hweight8 2. Prefix all functions with idt82p33 3. Fix white space issues in Kconfig and Makefile 4. Remove forward declaration 5. Use adjfine instead of adjfreq for better resolution - As suggested by David Miller: 1. Replace CHAN_INIT macro with a static function idt82p33_channel_init 2. Employ reverse christmas tree ordering for local variables 3. Fix indentation problem by appropriate number of TAB then SPACE character Signed-off-by: Min Li <min.li.xe@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Min Li authored
Add device tree binding doc for the PTP clock based on IDT 82P33 Synchronization Management Unit (SMU). Changes since v1: - As suggested by Rob Herring: 1. Drop reg description for i2c 2. Replace i2c@1 with i2c 3. Add addtionalProperties: false Signed-off-by: Min Li <min.li.xe@renesas.com> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Amol Grover authored
md5sig->head maybe traversed using hlist_for_each_entry_rcu outside an RCU read-side critical section but under the protection of socket lock. Hence, add corresponding lockdep expression to silence false-positive warnings, and harden RCU lists. Signed-off-by: Amol Grover <frextrite@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Madhuparna Bhowmik authored
list_for_each_entry_rcu() has built-in RCU and lock checking. Pass cond argument to list_for_each_entry_rcu() to silence false lockdep warning when CONFIG_PROVE_RCU_LIST is enabled by default. Signed-off-by: Madhuparna Bhowmik <madhuparnabhowmik10@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Amol Grover authored
tcp_ulp_list is traversed using list_for_each_entry_rcu outside an RCU read-side critical section but under the protection of tcp_ulp_list_lock. Hence, add corresponding lockdep expression to silence false-positive warnings, and harden RCU lists.t Signed-off-by: Amol Grover <frextrite@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
David S. Miller authored
Jiri Pirko says: ==================== mlxsw: Introduce ACL traps This patchset allows to track packets that are dropped in HW by ACL. Unlike the existing mlxsw traps, ACL traps are "source traps". That means the action is not controlled by HPKT register but directly in ACL TRAP action. When devlink user changes action from drop to trap and vice versa, it would be needed to go over all instances of ACL TRAP action and do change. That does not scale. Instead, resolve this by introducing "dummy" group with "thin" policer. The purpose of this policer is to drop as many packets as possible. The ones that pass through are going to be dropped in devlink code - patch #6 takes care of that. First four patches are preparation for introduction of ACL traps in mlxsw so it possible to easily change from drop to trap for source traps as well - by changing group to "dummy" and back. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Add a test to check functionality of ACL traps. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Currently the helpers assume pref 1 and handle 101. Make that explicit and pass the values from callers. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Include test of forbidding to have drop rule on mixed-bound shared block. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Add the trap group used to report ACL drops. Setup the trap IDs for ingress/egress flow action drop. Register the two packet traps associated with ACL trap group with devlink during driver initialization. As these are "source traps", set the disabled trap group to be the dummy, discarding as many packets in HW as possible. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
For "source traps" it is not possible to change HPKT action to discard. But there is still need to disallow packets arriving to CPU as much as possible. Handle this by introduction of a "dummy group". It has a "thin" policer, which passes as less packets to CPU as possible. The rest is going to be discarded there. The "dummy group" is to be used later on by ACL trap (which is a "source trap"). Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Extend the mlxsw_listener struct to contain trap group for disabled traps too. Rename the original "trap_group" item to "en_trap_group" as it represents enabled state. Let both groups be the same for MLXSW_RXL however extend MLXSW_RXL_DIS to register separate groups for enable and disable. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
For source traps, the "thin policer" is going to be used in order to reduce the amount of trapped packets to minimum. However, there will be still small number of packets coming in that need to be dropped in the driver. Allow to enable/disable rx_listener related to specific trap in order to prevent unwanted packets to go up the stack. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Introduce a new set of traps: DISCARD_INGRESS_ACL and DISCARD_EGRESS_ACL Set the trap_action from NOP to TRAP which causes the packets dropped by the TRAP action to be trapped under new trap IDs, depending on the ingress/egress binding point. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
The ACL flex action will have to know if it is in ingress or egress, so it can use correct trap ID. Pass the ingress indication down to it. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Action drop is going to be tracked by two separate traps, one for ingress and one for egress. Prepare for it and disallow the possibility to have drop action in blocks which are bound to both ingress and egress. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Count the number of ingress and egress block bindings. Use the egress counter in "is_egress_bound" helper. Add couple of helpers to check ingress and mixed bound. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Add packet traps that can report packets that were dropped during ACL processing. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Rename function mlxsw_core_trap_action_set() to mlxsw_core_trap_state_set() and pass bool enabled instead of action. Figure out the action according to the enabled state there. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
The listener fields en_action and dis_action now contain the actions to be used for TRAP and DROP devlink trap actions. Use them directly instead of the hard-coded values. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Introduce a new macro MLXSW_RXL_DIS that allows to register listeners as disabled. That allows that from now on, the "action" can be understood always as "enabled action" and "unreg_action" as "disabled action". Rename them and treat them accordingly. Use the new macro for defining drops in spectrum_trap.c. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Jiri Pirko authored
Currently it does not really matter if it is set to DISCARD or SET_FW_DEFAULT because it is set only during unregister of the listener. The unreg_action is going to be used for disabling the listener too, so change to SET_FW_DEFAULT and ensure the HW is going to behave correctly. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
David S. Miller authored
Leon Romanovsky says: ==================== Clean driver, module and FW versions Change log: v1: * Split all FW cleanups patches to separate patches * Fixed commit message * Deleted odd DRV_RELDATE * Added everyone from MAINTAINERS file v0: https://lore.kernel.org/netdev/20200220145855.255704-1-leon@kernel.org This is first patchset to netdev (already sent RDMA [1] and arch/um [2]) in attempt to unify the version management for in-tree kernel code. The patches follow already accepted ethtool change [3] to set as a default linux kernel version. It allows us to remove driver version and present to the users unified picture of driver version, which is similar to default MODULE_VERSION(). As part of this series, I deleted various creative attempts to mark absence of FW. There is no need to set "N/A" in ethtool ->fw_version field and it is enough to do not set it. 1. The code is compile tested and passes 0-day kbuild. 2. The proposed changes are based on commit: 2bb07f4e ("tc-testing: updated tdc tests for basic filter") 3. WIP branch is [4]. [1] https://lore.kernel.org/linux-rdma/20200220071239.231800-1-leon@kernel.org/ [2] http://lists.infradead.org/pipermail/linux-um/2020-February/002913.html [3] https://lore.kernel.org/linux-rdma/20200127072028.19123-1-leon@kernel.org/ [4] https://git.kernel.org/pub/scm/linux/kernel/git/leon/linux-rdma.git/log/?h=ethtool ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
Use linux kernel version for ethtool and module versions. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Acked-by: Chris Snook <chris.snook@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
Drop constant driver version in favour of global linux kernel. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
There is no need to keep module and driver versions in in-tree kernel code. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
There is no need to set "N/A" if FW is not available. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
Delete module version in favor of global and unique linux kernel. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
Convert AMD drivers to respect universal linux kernel version. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
Upstream drivers are managed inside global repository and released all together, this ensure that driver version is the same as linux kernel, so update amazon drivers to properly reflect it. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
Convert to use default version provided by ethtool. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-
Leon Romanovsky authored
The acenic driver assigns FW version in driver version field, as part of cleanup driver version, set FW version properly. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-