- 18 3月, 2021 33 次提交
-
-
由 Álvaro Fernández Rojas 提交于
Add support for legacy Broadcom tags, which are similar to DSA_TAG_PROTO_BRCM. These tags are used on BCM5325, BCM5365 and BCM63xx switches. Signed-off-by: NÁlvaro Fernández Rojas <noltari@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Bhaskar Chowdhury 提交于
s/procesing/processing/ s/comparations/comparisons/ Signed-off-by: NBhaskar Chowdhury <unixbhaskar@gmail.com> Acked-by: NRandy Dunlap <rdunlap@infradead.org> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Álvaro Fernández Rojas 提交于
BCM63xx switches are present on bcm63xx and bmips devices. Signed-off-by: NÁlvaro Fernández Rojas <noltari@gmail.com> Acked-by: NFlorian Fainelli <f.fainelli@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Voon Weifeng 提交于
According to Synopsis DesignWare EQoS Databook, the Clock Domain Cross synchronization error is introduced tue to the clock(GMII Tx/Rx clock) being different at the capture as compared to the PTP clock(clk_ptp_ref_i) that is used to generate the time. The CDC synchronization error is almost equal to 2 times the clock period of the PTP clock(clk_ptp_ref_i). On a Intel Tigerlake platform (with Marvell 88E2110 external PHY): Before applying this patch (with CDC synchronization error): ptp4l[64.044]: rms 8 max 13 freq +30877 +/- 11 delay 216 +/- 0 ptp4l[65.047]: rms 13 max 20 freq +30869 +/- 17 delay 213 +/- 0 ptp4l[66.050]: rms 12 max 20 freq +30857 +/- 11 delay 213 +/- 0 ptp4l[67.052]: rms 11 max 22 freq +30849 +/- 10 delay 215 +/- 0 ptp4l[68.055]: rms 10 max 16 freq +30853 +/- 13 delay 215 +/- 0 ptp4l[69.057]: rms 7 max 13 freq +30848 +/- 9 delay 216 +/- 0 ptp4l[70.060]: rms 8 max 13 freq +30846 +/- 10 delay 216 +/- 0 ptp4l[71.063]: rms 9 max 15 freq +30836 +/- 8 delay 218 +/- 0 After applying this patch (CDC syncrhonization error is taken care of): ptp4l[61.516]: rms 773 max 824 freq +31526 +/- 158 delay 200 +/- 0 ptp4l[62.519]: rms 427 max 596 freq +31668 +/- 39 delay 198 +/- 0 ptp4l[63.522]: rms 113 max 206 freq +31482 +/- 57 delay 198 +/- 0 ptp4l[64.525]: rms 40 max 56 freq +31316 +/- 29 delay 200 +/- 0 ptp4l[65.528]: rms 47 max 56 freq +31255 +/- 17 delay 200 +/- 0 ptp4l[66.531]: rms 26 max 36 freq +31246 +/- 9 delay 200 +/- 0 ptp4l[67.534]: rms 12 max 18 freq +31254 +/- 12 delay 202 +/- 0 ptp4l[68.537]: rms 7 max 12 freq +31263 +/- 10 delay 202 +/- 0 Signed-off-by: NVoon Weifeng <weifeng.voon@intel.com> Signed-off-by: NWong Vee Khee <vee.khee.wong@intel.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Jon Maloy says: ==================== tipc: cleanups and simplifications We do a number of cleanups and simplifications, especially regarding call signatures in the binding table. This makes the code easier to understand and serves as preparation for upcoming functional additions. ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We move some warning printouts to more strategic locations to avoid duplicates and yield more detailed information about the reported problem. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We reduce and localize the usage of the tipc_sub_xx() macros by adding a corresponding member, with fields set in host-endian format, to struct tipc_subscription. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
The function tipc_report_overlap() is called from the binding table with numerous parameters taken from an instance of struct publication. A closer look reveals that it always is safe to send along a pointer to the instance itself, and hence reduce the call signature. We do that in this commit. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We reduce the signature of tipc_find_service() and tipc_create_service(). The reason for doing this might not be obvious, but we plan to let struct tipc_uaddr contain information that is relevant for these functions in a later commit. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We simplify the signatures of the functions tipc_service_create_range() and tipc_service_find_range(). Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We reduce the signature of tipc_nametbl_lookup_group() by using a struct tipc_uaddr pointer. This entails a couple of minor changes in the functions tipc_send_group_mcast/anycast/unicast/bcast() in socket.c Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We follow up the preceding commits by reducing the signature of the function tipc_nametbl_lookup_mcast_nodes(). Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We reduce the signature of this function according to the same principle as the preceding commits. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We simplify the signature if function tipc_nametbl_lookup_anycast(), using address structures instead of discrete integers. This also makes it possible to make some improvements to the functions __tipc_sendmsg() in socket.c and tipc_msg_lookup_dest() in msg.c. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
The binding table provides four different lookup functions, which purpose is not obvious neither by their names nor by the (lack of) descriptions. We now give these functions names that better match their purposes, and improve the comments that describe what they are doing. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
Following the principles of the preceding commits, we reduce the number of parameters passed along in tipc_sk_withdraw(), tipc_nametbl_withdraw() and associated functions. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We simplify the call signatures for tipc_nametbl_insert_publ() and tipc_publ_create() so that fewer parameters are passed around. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
Using the new address structure tipc_uaddr, we simplify the signature of function tipc_sk_publish() and tipc_namtbl_publish() so that fewer parameters need to be passed around. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We introduce a simplified version of struct sockaddr_tipc, using anonymous unions and structures. Apart from being nicer to work with, this struct will come in handy when we in a later commit add another address type. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
We instantiate struct publication in tipc_nametbl_insert_publ() instead of as currently in tipc_service_insert_publ(). This has the advantage that we can pass a pointer to the publication struct to the next call levels, instead of the numerous individual parameters we pass on now. It also gives us a location to keep the contents of the additional fields we will introduce in a later commit. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jon Maloy 提交于
In a future commit we will introduce more members to struct publication. In order to keep this structure comprehensible we now group some of its current fields into the sub-structures where they really belong, - A struct tipc_service_range for the functional address the publication is representing. - A struct tipc_socket_addr for the socket bound to that service range. We also rename the stack variable 'publ' to just 'p' in a few places. This is just as easy to understand in the given context, and keeps the number of wrapped code lines to a minimum. There are no functional changes in this commit. Signed-off-by: NJon Maloy <jmaloy@redhat.com> Acked-by: NYing Xue <ying.xue@windriver.com> Acked-by: NHoang Le <hoang.h.le@dektech.com.au> Acked-by: NTung Nguyen <tung.q.nguyen@dektech.com.au> Acked-by: NXin Long <lucien.xin@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Alexander Duyck says: ==================== ethtool: Factor out common code related to writing ethtool strings This patch set is meant to be a cleanup and refactoring of common code bits from several drivers. Specificlly a number of drivers engage in a pattern where they will use some variant on an sprintf or memcpy to write a string into the ethtool string array and then they will increment their pointer by ETH_GSTRING_LEN. Instead of having each driver implement this independently I am refactoring the code so that we have one central function, ethtool_sprintf that does all this and takes a double pointer to access the data, a formatted string to print, and the variable arguments that are associated with the string. Changes from v1: Fixed usage of char ** vs unsigned char ** in hisilicon drivers Changes from RFC: Renamed ethtool_gsprintf to ethtool_sprintf Fixed reverse xmas tree issue in patch 2 ==================== Reviewed-by: NJesse Brandeburg <jesse.brandeburg@intel.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Update the ionic driver to make use of ethtool_sprintf. In addition add separate functions for Tx/Rx stats strings in order to reduce the total amount of indenting needed in the driver code. Acked-by: NShannon Nelson <snelson@pensando.io> Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Update the bnad_get_strings to make use of ethtool_sprintf and avoid unnecessary line wrapping. To do this we invert the logic for the string set test and instead exit immediately if we are not working with the stats strings. In addition the function is broken up into subfunctions for each area so that we can simply call ethtool_sprintf once for each string in a given subsection. Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
So this patch actually does 3 things. First it removes a stray white space at the start of the variable declaration in vmxnet3_get_strings. Second it flips the logic for the string test so that we exit immediately if we are not looking for the stats strings. Doing this we can avoid unnecessary indentation and line wrapping. Then finally it updates the code to use ethtool_sprintf rather than a memcpy and pointer increment to write the ethtool strings. Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Update the code to replace instances of snprintf and a pointer update with just calling ethtool_sprintf. Also replace the char pointer with a u8 pointer to avoid having to recast the pointer type. Acked-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NJason Wang <jasowang@redhat.com> Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Replace instances of sprintf or memcpy with a pointer update with ethtool_sprintf. Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Replace instances of snprintf or memcpy with a pointer update with ethtool_sprintf. Acked-by: NArthur Kiyanovski <akiyano@amazon.com> Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Update the hisilicon drivers to make use of ethtool_sprintf. The general idea is to reduce code size and overhead by replacing the repeated pattern of string printf statements and ETH_STRING_LEN counter increments. Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
The nfp_pr_et function is nearly identical to ethtool_sprintf except for the fact that it passes the pointer by value and as a return whereas ethtool_sprintf passes it as a pointer. Since they are so close just update nfp to make use of ethtool_sprintf Reviewed-by: NSimon Horman <simon.horman@netronome.com> Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Update the Intel drivers to make use of ethtool_sprintf. The general idea is to reduce code size and overhead by replacing the repeated pattern of string printf statements and ETH_STRING_LEN counter increments. Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Acked-by: NJesse Brandeburg <jesse.brandeburg@intel.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Alexander Duyck 提交于
Add a function to handle the common pattern of printing a string into the ethtool strings interface and incrementing the string pointer by the ETH_GSTRING_LEN. Most of the drivers end up doing this and several have implemented their own versions of this function so it would make sense to consolidate on one implementation. Signed-off-by: NAlexander Duyck <alexanderduyck@fb.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
git://git.kernel.org/pub/scm/linux/kernel/git/saeed/linux由 David S. Miller 提交于
Saeed Mahameed says: ==================== mlx5-updates-2021-03-16 mlx5 uplink representor netdev persistence. Before this patchset we used to have separate netdevs for Native NIC mode and Switchdev mode (uplink representor netdev), meaning that if user switches modes between Native to Switchdev and vice versa, the driver would cleanup the current netdev representor and create a new one for the new mode, such behavior created an administrative nightmare for users, where users need to be aware of such loss of both data path and control path configurations, e.g. netdev attributes and arp/route tables, where the later is more painful. A simple solution for this is not to replace the netdev in first place and use a single netdev to serve the uplink/physical port whether it is in switchdev mode or native mode. We already have different HW profiles for each netdev mode, in this series we just replace the HW profile on the fly and we keep the same netdev attached. Refactoring: Some refactoring has been made to overcome some technical difficulties 1) The netdev is created with the maximum amount of tx/rx queues to serve the two profiles. 2) Some ndos are not supported in some modes, so we added a mode check for such cases, e.g legacy sriov ndos must be blocked in switchdev mode. 3) Some mlx5 netdev private attributes need to be moved out of profiles and kept in a persistent place, where the netdev is created e.g devlink port and other global HW resources 4) The netdev devlink port is now always registered with the switch id Implementation: the last three patches implement the mechanism now as the netdev can be shared. 5) Don't recreate the netdev on switchdev mode changes 6) Prevent changing switchdev mode when some netdev operations are active, mostly when TC rules are being processed. This is required since the netdev is kept registered while switchdev mode can be changed. ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
- 17 3月, 2021 7 次提交
-
-
由 Roi Dayan 提交于
We re-use the native NIC port net device instance for the Uplink representor, a driver currently cannot unbind TC setup callback actively, hence protect changing E-Switch mode while adding rules. Signed-off-by: NRoi Dayan <roid@nvidia.com> Reviewed-by: NParav Pandit <parav@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-
由 Roi Dayan 提交于
E-Switch mode change routine will take the write lock to prevent any consumer to access the E-Switch resources while E-Switch is going through a mode change. In the next patch E-Switch consumers (e.g vport representors) will take read_lock prior to accessing E-Switch resources to prevent E-Switch mode changing in the middle of the operation. Signed-off-by: NRoi Dayan <roid@nvidia.com> Reviewed-by: NParav Pandit <parav@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-
由 Roi Dayan 提交于
When switching modes between legacy and switchdev and back, do not reload ethernet interfaces. just change the profile from nic profile to uplink rep profile in switchdev mode. Signed-off-by: NRoi Dayan <roid@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-
由 Roi Dayan 提交于
When we clean all the interfaces, i.e. rescan or reload module, we need to clean eth-reps devices first, before eth devices. We will re-use the native NIC port net device instance for the Uplink representor. Changing eswitch mode will skip destroying the eth device so the net device won't be destroyed and only change the profile. Creating uplink eth-rep will initialize the representor related resources. In that sense when we destroy all devices we first need to destroy eth-rep devices so uplink eth-rep will clean all representor related resources and only then destroy the eth device which will destroy rest of the resources and the net device. Signed-off-by: NRoi Dayan <roid@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-
由 Roi Dayan 提交于
We re-use the native NIC port net device instance for the Uplink representor, and the devlink port. When changing profiles we reset the mlx5e priv but we should still use the devlink port so move it to mlx5e resources. Signed-off-by: NRoi Dayan <roid@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-
由 Roi Dayan 提交于
This is to separate between resources attributes and other attributes we will want to use. Signed-off-by: NRoi Dayan <roid@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-
由 Roi Dayan 提交于
We will re-use the native NIC port net device instance for the Uplink representor. Since the netdev will be kept registered while we engage switchdev mode also the devlink will be kept registered. Register the nic devlink port with switch id so it will be available when changing profiles. Signed-off-by: NRoi Dayan <roid@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
-