- 30 8月, 2022 15 次提交
-
-
由 Jiri Pirko 提交于
Follow-up the removal of unused internal api of port params made by commit 42ded61a ("devlink: Delete not used port parameters APIs") and stub the commands and add extack message to tell the user what is going on. If later on port params are needed, could be easily re-introduced, but until then it is a dead code. Signed-off-by: NJiri Pirko <jiri@nvidia.com> Reviewed-by: NJakub Kicinski <kuba@kernel.org> Link: https://lore.kernel.org/r/20220826082730.1399735-1-jiri@resnulli.usSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Zhengchao Shao 提交于
Using TCQ_MIN_PRIO_BANDS instead of magic number in prio_tune(). Signed-off-by: NZhengchao Shao <shaozhengchao@huawei.com> Acked-by: NCong Wang <xiyou.wangcong@gmail.com> Link: https://lore.kernel.org/r/20220826041035.80129-1-shaozhengchao@huawei.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Mengyuan Lou 提交于
Add build options and guidance doc. Initialize pci device access for Wangxun Gigabit Ethernet devices. Reviewed-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NMengyuan Lou <mengyuanlou@net-swift.com> Link: https://lore.kernel.org/r/20220826034609.51854-1-mengyuanlou@net-swift.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Paolo Abeni 提交于
Jakub Kicinski says: ==================== netlink: support reporting missing attributes This series adds support for reporting missing attributes in a structured way. We communicate the type of the missing attribute and if it was missing inside a nest the offset of that nest. Example of (YAML-based) user space reporting ethtool header missing: Kernel error: missing attribute: .header I was tempted to integrate the check with the policy but it seems tricky without doing a full scan, and there may be a ton of attrs in the policy. So leaving that for later. ==================== Link: https://lore.kernel.org/r/20220826030935.2165661-1-kuba@kernel.orgSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Jakub Kicinski 提交于
The actual presence check for the header is in ethnl_parse_header_dev_get() but it's a few layers in, and already has a ton of arguments so let's just pick the low hanging fruit and check for missing header in the default request handler. Reviewed-by: NIdo Schimmel <idosch@nvidia.com> Reviewed-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJakub Kicinski <kuba@kernel.org> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Jakub Kicinski 提交于
Strset needs ETHTOOL_A_STRINGSET_ID, use it as an example of reporting attrs missing in nests. Reviewed-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJakub Kicinski <kuba@kernel.org> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Jakub Kicinski 提交于
Devlink with its global attr policy has a lot of attribute presence check, use the new ext ack reporting when they are missing. Reviewed-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJakub Kicinski <kuba@kernel.org> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Jakub Kicinski 提交于
Being able to check attribute presence and set extack if not on one line is handy, add helpers. Reviewed-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJakub Kicinski <kuba@kernel.org> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Jakub Kicinski 提交于
There is currently no way to report via extack in a structured way that an attribute is missing. This leads to families resorting to string messages. Add a pair of attributes - @offset and @type for machine-readable way of reporting missing attributes. The @offset points to the nest which should have contained the attribute, @type is the expected nla_type. The offset will be skipped if the attribute is missing at the message level rather than inside a nest. User space should be able to figure out which attribute enum (AKA attribute space AKA attribute set) the nest pointed to by @offset is using. Reviewed-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJakub Kicinski <kuba@kernel.org> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Jakub Kicinski 提交于
The ext_ack writing code looks very "organically grown". Move the calculation of the size and writing out to helpers. This is more idiomatic and gives us the ability to return early avoiding the long (and randomly ordered) "if" conditions. Reviewed-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJakub Kicinski <kuba@kernel.org> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Pavel Begunkov 提交于
Consolidate alloclen and pagedlen calculation for zerocopy and normal paged requests. The current non-zerocopy paged version can a bit overallocate and unnecessary copy a small chunk of data into the linear part. Cc: Willem de Bruijn <willemb@google.com> Link: https://lore.kernel.org/netdev/CA+FuTSf0+cJ9_N_xrHmCGX_KoVCWcE0YQBdtgEkzGvcLMSv7Qw@mail.gmail.com/Signed-off-by: NPavel Begunkov <asml.silence@gmail.com> Link: https://lore.kernel.org/r/b0e4edb7b91f171c7119891d3c61040b8c56596e.1661428921.git.asml.silence@gmail.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Paolo Abeni 提交于
Simon Horman says: ==================== nfp: port speed and eeprom get/set updates this short series is the initial updates for the NFP driver for the v6.1 Kernel. It covers two enhancements: 1. Patches 1/3 and 2/3: - Support cases where application firmware does not know port speeds a priori by relaying this information from the management firmware to the application firmware. This allows the existing mechanism, whereby the driver reports port speeds to user-space as provided by the application firmware, to work in this case. 2. Patch 2/3: - Add support for eeprom get and set command ==================== Link: https://lore.kernel.org/r/20220825141223.22346-1-simon.horman@corigine.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Baowen Zheng 提交于
Add support for eeprom get and set operation with ethtool command. with this change, we can support commands as: #ethtool -e enp101s0np0 offset 0 length 6 Offset Values ------ ------ 0x0000: 00 15 4d 16 66 33 #ethtool -E enp101s0np0 magic 0x400019ee offset 5 length 1 value 0x88 We make this change to persist MAC change during driver reload and system reboot. Signed-off-by: NBaowen Zheng <baowen.zheng@corigine.com> Signed-off-by: NSimon Horman <simon.horman@corigine.com> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Yinjun Zhang 提交于
A new tlv type is introduced to indicate if application firmware is indifferent to port speed, and inform management firmware of the result. And the result is always true for flower application firmware since it's indifferent to port speed from the start and will never change. Signed-off-by: NYinjun Zhang <yinjun.zhang@corigine.com> Reviewed-by: NLouis Peens <louis.peens@corigine.com> Signed-off-by: NSimon Horman <simon.horman@corigine.com> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
由 Yinjun Zhang 提交于
In future releases the NIC application firmware may be indifferent to port speeds - not built for specific port speeds - and consequently it will not be able to report VF port speeds to the driver without first learning them. With this change, the driver will pass the speed of physical ports from management firmware to application firmware, and the latter will copy the speed of port 0 to all the active VFs. So that the driver can get VF port speed as before. The port speed of a VF may be requested from userspace using: ethtool <vf-intf> Signed-off-by: NYinjun Zhang <yinjun.zhang@corigine.com> Reviewed-by: NLouis Peens <louis.peens@corigine.com> Signed-off-by: NSimon Horman <simon.horman@corigine.com> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
-
- 29 8月, 2022 5 次提交
-
-
由 David S. Miller 提交于
Casper Andersson says: ==================== net: sparx5: add mrouter support This series adds support for multicast router ports to SparX5. To manage mrouter ports the driver must keep track of mdb entries. When adding an mrouter port the driver has to iterate over all mdb entries and modify them accordingly. v2: - add bailout in free_mdb - re-arrange mdb struct to avoid holes - change devm_kzalloc -> kzalloc - change GFP_ATOMIC -> GFP_KERNEL - fix spelling ==================== Reviewed-by: NSteen Hegelund <Steen.Hegelund@microchip.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Casper Andersson 提交于
All multicast should be forwarded to mrouter ports. Mrouter ports must therefore be part of all active multicast groups, and override flooding from being disabled. Signed-off-by: NCasper Andersson <casper.casan@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Casper Andersson 提交于
Keep track of all mdb entries in software for easy access. Signed-off-by: NCasper Andersson <casper.casan@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Casper Andersson 提交于
IP multicast must sometimes be discriminated from non-IP multicast, e.g. when determining the forwarding behavior of a given group in the presence of multicast router ports on an offloaded bridge. Therefore, provide helpers to identify these groups. Signed-off-by: NCasper Andersson <casper.casan@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Jakub Kicinski 提交于
We had historically not checked that genlmsghdr.reserved is 0 on input which prevents us from using those precious bytes in the future. One use case would be to extend the cmd field, which is currently just 8 bits wide and 256 is not a lot of commands for some core families. To make sure that new families do the right thing by default put the onus of opting out of validation on existing families. Signed-off-by: NJakub Kicinski <kuba@kernel.org> Acked-by: Paul Moore <paul@paul-moore.com> (NetLabel) Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
- 27 8月, 2022 12 次提交
-
-
由 Dan Carpenter 提交于
We no longer allow "handle" to be zero, so there is no need to check for that. Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/Ywd4NIoS4aiilnMv@kiliSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Dan Carpenter 提交于
The "fixed_link" is only allocated sometimes but it's freed unconditionally in the error handling. Set it to NULL so we don't free uninitialized data. Fixes: 9ea4742a ("net: fman: Configure fixed link in memac_initialization") Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Reviewed-by: NSean Anderson <sean.anderson@seco.com> Link: https://lore.kernel.org/r/Ywd2X6gdKmTfYBxD@kiliSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Jakub Kicinski 提交于
Andrey Zhadchenko says: ==================== openvswitch: allow specifying ifindex of new interfaces CRIU currently do not support checkpoint/restore of OVS configurations, but there was several requests for it. For example, https://github.com/lxc/lxc/issues/2909 The main problem is ifindexes of newly created interfaces. We realy need to preserve them after restore. Current openvswitch API does not allow to specify ifindex. Most of the time we can just create an interface via generic netlink requests and plug it into ovs but datapaths (generally any OVS_VPORT_TYPE_INTERNAL) can only be created via openvswitch requests which do not support selecting ifindex. This patch allows to do so. For new datapaths I decided to use dp_infindex in header as infindex because it control ifindex for other requests too. For internal vports I reused OVS_VPORT_ATTR_IFINDEX. The only concern I have is that previously dp_ifindex was not used for OVS_DP_VMD_NEW requests and some software may not set it to zero. However we have been running this patch at Virtuozzo for 2 years and have not encountered this problem. Not sure if it is worth to add new ovs_datapath_attr instead. ==================== Link: https://lore.kernel.org/r/20220825020450.664147-1-andrey.zhadchenko@virtuozzo.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Andrey Zhadchenko 提交于
CRIU needs OVS_DP_ATTR_PER_CPU_PIDS to checkpoint/restore newest openvswitch versions. Add pids to generic datapath reply. Limit exported pids amount to nr_cpu_ids. Signed-off-by: NAndrey Zhadchenko <andrey.zhadchenko@virtuozzo.com> Acked-by: NChristian Brauner (Microsoft) <brauner@kernel.org> Signed-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Andrey Zhadchenko 提交于
CRIU is preserving ifindexes of net devices after restoration. However, current Open vSwitch API does not allow to target ifindex, so we cannot correctly restore OVS configuration. Add new OVS_DP_ATTR_IFINDEX for OVS_DP_CMD_NEW and use it as desired ifindex. Use OVS_VPORT_ATTR_IFINDEX during OVS_VPORT_CMD_NEW to specify new netdev ifindex. Signed-off-by: NAndrey Zhadchenko <andrey.zhadchenko@virtuozzo.com> Acked-by: NChristian Brauner (Microsoft) <brauner@kernel.org> Signed-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Sergei Antonov 提交于
This driver always generated a random ethernet address. Leave it as a fallback solution, but add a call to platform_get_ethdev_address(). Handle EPROBE_DEFER returned from platform_get_ethdev_address() to retry when EEPROM is ready. Signed-off-by: NSergei Antonov <saproj@gmail.com> Reviewed-by: NAndrew Lunn <andrew@lunn.ch> Link: https://lore.kernel.org/r/20220824151724.2698107-1-saproj@gmail.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Marcus Carlberg 提交于
p0_mode set to one of the supported serial mode should not prevent configuring the external SMI interface in mv88e6xxx_g2_scratch_gpio_set_smi. The current masking of the p0_mode only checks the first 2 bits. This results in switches supporting serial mode cannot setup external SMI on certain serial modes (Ex: 1000BASE-X and SGMII). Extend the mask of the p0_mode to include the reduced modes and serial modes as allowed modes for the external SMI interface. Signed-off-by: NMarcus Carlberg <marcus.carlberg@axis.com> Link: https://lore.kernel.org/r/20220824093706.19049-1-marcus.carlberg@axis.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Jiri Pirko 提交于
In genl_bind(), currently genl_lock and write cb_lock are taken for iteration of genl_fam_idr and processing of static values stored in struct genl_family. Take just read cb_lock for this task as it is sufficient to guard the idr and the struct against concurrent genl_register/unregister_family() calls. This will allow to run genl command processing in genl_rcv() and mnl_socket_setsockopt(.., NETLINK_ADD_MEMBERSHIP, ..) in parallel. Reported-by: NVikas Gupta <vikas.gupta@broadcom.com> Signed-off-by: NJiri Pirko <jiri@nvidia.com> Link: https://lore.kernel.org/r/20220825081940.1283335-1-jiri@resnulli.usSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Jack Wang 提交于
dma_map_sg return 0 on error. Signed-off-by: NJack Wang <jinpu.wang@ionos.com> Reviewed-by: NLeon Romanovsky <leonro@nvidia.com> Link: https://lore.kernel.org/r/20220825063533.21015-1-jinpu.wang@ionos.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Jiri Pirko 提交于
Similar to devlink_compat_phys_port_name_get(), make sure that devlink_compat_switch_id_get() is called with RTNL lock held. Comment already says so, so put this in code as well. Signed-off-by: NJiri Pirko <jiri@nvidia.com> Link: https://lore.kernel.org/r/20220825112923.1359194-1-jiri@resnulli.usSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Jiri Pirko 提交于
Whenever the type_set() is called on a devlink port, accompany it by matching type_clear() during cleanup. Signed-off-by: NJiri Pirko <jiri@nvidia.com> Link: https://lore.kernel.org/r/20220825114031.1361478-1-jiri@resnulli.usSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Marcus Carlberg 提交于
Since the probe defaults all interfaces to the highest speed possible (10GBASE-X in mv88e6393x) before the phy mode configuration from the devicetree is considered it is currently impossible to use port 0 in RGMII mode. This change will allow RGMII modes to be configurable for port 0 enabling port 0 to be configured as RGMII as well as serial depending on configuration. Signed-off-by: NMarcus Carlberg <marcus.carlberg@axis.com> Link: https://lore.kernel.org/r/20220822144136.16627-1-marcus.carlberg@axis.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
- 26 8月, 2022 8 次提交
-
-
由 Zhengchao Shao 提交于
The memory allocated by using kzallloc_node and kcalloc has been cleared. Therefore, the structure members of the new qdisc are 0. So there's no need to explicitly assign a value of 0. Signed-off-by: NZhengchao Shao <shaozhengchao@huawei.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Merge tag 'wireless-next-2022-08-26-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-next Johannes berg says: ==================== Various updates: * rtw88: operation, locking, warning, and code style fixes * rtw89: small updates * cfg80211/mac80211: more EHT/MLO (802.11be, WiFi 7) work * brcmfmac: a couple of fixes * misc cleanups etc. ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
The Lenovo OneLink+ Dock contains an RTL8153 controller that behaves as a broken CDC device by default. Add the custom Lenovo PID to the r8152 driver to support it properly. Also, systems compatible with this dock provide a BIOS option to enable MAC address passthrough (as per Lenovo document "ThinkPad Docking Solutions 2017"). Add the custom PID to the MAC passthrough list too. Tested on a ThinkPad 13 1st gen with the expected results: passthrough disabled: Invalid header when reading pass-thru MAC addr passthrough enabled: Using pass-thru MAC addr XX:XX:XX:XX:XX:XX Signed-off-by: NJean-Francois Le Fillatre <jflf_kernel@gmx.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue由 David S. Miller 提交于
Tony Nguyen says: ==================== Intel Wired LAN Driver Updates 2022-08-24 (ice) This series contains updates to ice driver only. Marcin adds support for TC parsing on TTL and ToS fields. Anatolli adds support for devlink port split command to allow configuration of various port configurations. Jake allows for passing and writing an additional NVM write activate field by expanding current cmd_flag. Ani makes PHY debug output more readable. ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Ping-Ke Shih 提交于
clang reports uninitialized use: >> drivers/net/wireless/realtek/rtw88/main.c:731:2: warning: variable 'primary_channel_idx' is used uninitialized whenever switch default is taken [-Wsometimes-uninitialized] default: ^~~~~~~ drivers/net/wireless/realtek/rtw88/main.c:754:39: note: uninitialized use occurs here hal->current_primary_channel_index = primary_channel_idx; ^~~~~~~~~~~~~~~~~~~ drivers/net/wireless/realtek/rtw88/main.c:687:24: note: initialize the variable 'primary_channel_idx' to silence this warning u8 primary_channel_idx; ^ = '\0' This situation could not happen, because possible channel bandwidth 20/40/80MHz are enumerated. Fixes: 341dd1f7 ("wifi: rtw88: add the update channel flow to support setting by parameters") Reported-by: Nkernel test robot <lkp@intel.com> Signed-off-by: NPing-Ke Shih <pkshih@realtek.com> Reviewed-by: NNathan Chancellor <nathan@kernel.org> Link: https://lore.kernel.org/r/20220815062004.22920-1-pkshih@realtek.comSigned-off-by: NJohannes Berg <johannes.berg@intel.com>
-
由 Qingfang DENG 提交于
As per RGMII specification v2.0, section 3.4.1, RGMII/RTBI has an optional in-band status feature where the PHY's link status, speed and duplex mode can be passed to the MAC. Allow RGMII/RTBI to use in-band status. Signed-off-by: NQingfang DENG <dqfext@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Maksym Glubokiy says: ==================== net: prestera: matchall features This patch series extracts matchall rules management out of SPAN API implementation and adds 2 features on top of that: - support for egress traffic (mirred egress action) - proper rule priorities management between matchall and flower ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Maksym Glubokiy 提交于
matchall rules can be added only to chain 0 and their priorities have limitations: - new matchall ingress rule's priority must be higher (lower value) than any existing flower rule; - new matchall egress rule's priority must be lower (higher value) than any existing flower rule. The opposite works for flower rule adding: - new flower ingress rule's priority must be lower (higher value) than any existing matchall rule; - new flower egress rule's priority must be higher (lower value) than any existing matchall rule. This is a hardware limitation and thus must be properly handled in driver by reporting errors to the user when newly added rule has such a priority that cannot be installed into the hardware. To achieve this, the driver must maintain both min/max matchall priorities for every flower block when user adds/deletes a matchall rule, as well as both min/max flower priorities for chain 0 for every adding/deletion of flower rules for chain 0. Cc: Serhiy Boiko <serhiy.boiko@plvision.eu> Signed-off-by: NMaksym Glubokiy <maksym.glubokiy@plvision.eu> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-