mirror of
https://github.com/Dasharo/linux.git
synced 2026-03-06 15:25:10 -08:00
Merge tag 'net-6.3-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Pull networking fixes from Paolo Abeni:
"Including fixes from netfilter and bpf.
There are a few fixes for new code bugs, including the Mellanox one
noted in the last networking pull. No known regressions outstanding.
Current release - regressions:
- sched: clear actions pointer in miss cookie init fail
- mptcp: fix accept vs worker race
- bpf: fix bpf_arch_text_poke() with new_addr == NULL on s390
- eth: bnxt_en: fix a possible NULL pointer dereference in unload
path
- eth: veth: take into account peer device for
NETDEV_XDP_ACT_NDO_XMIT xdp_features flag
Current release - new code bugs:
- eth: revert "net/mlx5: Enable management PF initialization"
Previous releases - regressions:
- netfilter: fix recent physdev match breakage
- bpf: fix incorrect verifier pruning due to missing register
precision taints
- eth: virtio_net: fix overflow inside xdp_linearize_page()
- eth: cxgb4: fix use after free bugs caused by circular dependency
problem
- eth: mlxsw: pci: fix possible crash during initialization
Previous releases - always broken:
- sched: sch_qfq: prevent slab-out-of-bounds in qfq_activate_agg
- netfilter: validate catch-all set elements
- bridge: don't notify FDB entries with "master dynamic"
- eth: bonding: fix memory leak when changing bond type to ethernet
- eth: i40e: fix accessing vsi->active_filters without holding lock
Misc:
- Mat is back as MPTCP co-maintainer"
* tag 'net-6.3-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (33 commits)
net: bridge: switchdev: don't notify FDB entries with "master dynamic"
Revert "net/mlx5: Enable management PF initialization"
MAINTAINERS: Resume MPTCP co-maintainer role
mailmap: add entries for Mat Martineau
e1000e: Disable TSO on i219-LM card to increase speed
bnxt_en: fix free-runnig PHC mode
net: dsa: microchip: ksz8795: Correctly handle huge frame configuration
bpf: Fix incorrect verifier pruning due to missing register precision taints
hamradio: drop ISA_DMA_API dependency
mlxsw: pci: Fix possible crash during initialization
mptcp: fix accept vs worker race
mptcp: stops worker on unaccepted sockets at listener close
net: rpl: fix rpl header size calculation
net: vmxnet3: Fix NULL pointer dereference in vmxnet3_rq_rx_complete()
bonding: Fix memory leak when changing bond type to Ethernet
veth: take into account peer device for NETDEV_XDP_ACT_NDO_XMIT xdp_features flag
mlxfw: fix null-ptr-deref in mlxfw_mfa2_tlv_next()
bnxt_en: Fix a possible NULL pointer dereference in unload path
bnxt_en: Do not initialize PTP on older P3/P4 chips
netfilter: nf_tables: tighten netlink attribute requirements for catch-all elements
...
This commit is contained in:
2
.mailmap
2
.mailmap
@@ -299,6 +299,8 @@ Martin Kepplinger <martink@posteo.de> <martin.kepplinger@puri.sm>
|
||||
Martin Kepplinger <martink@posteo.de> <martin.kepplinger@theobroma-systems.com>
|
||||
Martyna Szapar-Mudlaw <martyna.szapar-mudlaw@linux.intel.com> <martyna.szapar-mudlaw@intel.com>
|
||||
Mathieu Othacehe <m.othacehe@gmail.com>
|
||||
Mat Martineau <martineau@kernel.org> <mathew.j.martineau@linux.intel.com>
|
||||
Mat Martineau <martineau@kernel.org> <mathewm@codeaurora.org>
|
||||
Matthew Wilcox <willy@infradead.org> <matthew.r.wilcox@intel.com>
|
||||
Matthew Wilcox <willy@infradead.org> <matthew@wil.cx>
|
||||
Matthew Wilcox <willy@infradead.org> <mawilcox@linuxonhyperv.com>
|
||||
|
||||
@@ -7,6 +7,21 @@ ice devlink support
|
||||
This document describes the devlink features implemented by the ``ice``
|
||||
device driver.
|
||||
|
||||
Parameters
|
||||
==========
|
||||
|
||||
.. list-table:: Generic parameters implemented
|
||||
|
||||
* - Name
|
||||
- Mode
|
||||
- Notes
|
||||
* - ``enable_roce``
|
||||
- runtime
|
||||
- mutually exclusive with ``enable_iwarp``
|
||||
* - ``enable_iwarp``
|
||||
- runtime
|
||||
- mutually exclusive with ``enable_roce``
|
||||
|
||||
Info versions
|
||||
=============
|
||||
|
||||
|
||||
@@ -14594,6 +14594,7 @@ F: net/netlabel/
|
||||
|
||||
NETWORKING [MPTCP]
|
||||
M: Matthieu Baerts <matthieu.baerts@tessares.net>
|
||||
M: Mat Martineau <martineau@kernel.org>
|
||||
L: netdev@vger.kernel.org
|
||||
L: mptcp@lists.linux.dev
|
||||
S: Maintained
|
||||
|
||||
@@ -539,7 +539,7 @@ static void bpf_jit_plt(void *plt, void *ret, void *target)
|
||||
{
|
||||
memcpy(plt, bpf_plt, BPF_PLT_SIZE);
|
||||
*(void **)((char *)plt + (bpf_plt_ret - bpf_plt)) = ret;
|
||||
*(void **)((char *)plt + (bpf_plt_target - bpf_plt)) = target;
|
||||
*(void **)((char *)plt + (bpf_plt_target - bpf_plt)) = target ?: ret;
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -2010,7 +2010,9 @@ int bpf_arch_text_poke(void *ip, enum bpf_text_poke_type t,
|
||||
} __packed insn;
|
||||
char expected_plt[BPF_PLT_SIZE];
|
||||
char current_plt[BPF_PLT_SIZE];
|
||||
char new_plt[BPF_PLT_SIZE];
|
||||
char *plt;
|
||||
char *ret;
|
||||
int err;
|
||||
|
||||
/* Verify the branch to be patched. */
|
||||
@@ -2032,12 +2034,15 @@ int bpf_arch_text_poke(void *ip, enum bpf_text_poke_type t,
|
||||
err = copy_from_kernel_nofault(current_plt, plt, BPF_PLT_SIZE);
|
||||
if (err < 0)
|
||||
return err;
|
||||
bpf_jit_plt(expected_plt, (char *)ip + 6, old_addr);
|
||||
ret = (char *)ip + 6;
|
||||
bpf_jit_plt(expected_plt, ret, old_addr);
|
||||
if (memcmp(current_plt, expected_plt, BPF_PLT_SIZE))
|
||||
return -EINVAL;
|
||||
/* Adjust the call address. */
|
||||
bpf_jit_plt(new_plt, ret, new_addr);
|
||||
s390_kernel_write(plt + (bpf_plt_target - bpf_plt),
|
||||
&new_addr, sizeof(void *));
|
||||
new_plt + (bpf_plt_target - bpf_plt),
|
||||
sizeof(void *));
|
||||
}
|
||||
|
||||
/* Adjust the mask of the branch. */
|
||||
|
||||
@@ -1777,14 +1777,15 @@ void bond_lower_state_changed(struct slave *slave)
|
||||
|
||||
/* The bonding driver uses ether_setup() to convert a master bond device
|
||||
* to ARPHRD_ETHER, that resets the target netdevice's flags so we always
|
||||
* have to restore the IFF_MASTER flag, and only restore IFF_SLAVE if it was set
|
||||
* have to restore the IFF_MASTER flag, and only restore IFF_SLAVE and IFF_UP
|
||||
* if they were set
|
||||
*/
|
||||
static void bond_ether_setup(struct net_device *bond_dev)
|
||||
{
|
||||
unsigned int slave_flag = bond_dev->flags & IFF_SLAVE;
|
||||
unsigned int flags = bond_dev->flags & (IFF_SLAVE | IFF_UP);
|
||||
|
||||
ether_setup(bond_dev);
|
||||
bond_dev->flags |= IFF_MASTER | slave_flag;
|
||||
bond_dev->flags |= IFF_MASTER | flags;
|
||||
bond_dev->priv_flags &= ~IFF_TX_SKB_SHARING;
|
||||
}
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@ static int ksz8795_change_mtu(struct ksz_device *dev, int frame_size)
|
||||
|
||||
if (frame_size > KSZ8_LEGAL_PACKET_SIZE)
|
||||
ctrl2 |= SW_LEGAL_PACKET_DISABLE;
|
||||
else if (frame_size > KSZ8863_NORMAL_PACKET_SIZE)
|
||||
if (frame_size > KSZ8863_NORMAL_PACKET_SIZE)
|
||||
ctrl1 |= SW_HUGE_PACKET;
|
||||
|
||||
ret = ksz_rmw8(dev, REG_SW_CTRL_1, SW_HUGE_PACKET, ctrl1);
|
||||
|
||||
@@ -2388,7 +2388,7 @@ static int bnxt_async_event_process(struct bnxt *bp,
|
||||
case ASYNC_EVENT_CMPL_EVENT_ID_PHC_UPDATE: {
|
||||
switch (BNXT_EVENT_PHC_EVENT_TYPE(data1)) {
|
||||
case ASYNC_EVENT_CMPL_PHC_UPDATE_EVENT_DATA1_FLAGS_PHC_RTC_UPDATE:
|
||||
if (bp->fw_cap & BNXT_FW_CAP_PTP_RTC) {
|
||||
if (BNXT_PTP_USE_RTC(bp)) {
|
||||
struct bnxt_ptp_cfg *ptp = bp->ptp_cfg;
|
||||
u64 ns;
|
||||
|
||||
@@ -7627,7 +7627,7 @@ static int __bnxt_hwrm_ptp_qcfg(struct bnxt *bp)
|
||||
u8 flags;
|
||||
int rc;
|
||||
|
||||
if (bp->hwrm_spec_code < 0x10801) {
|
||||
if (bp->hwrm_spec_code < 0x10801 || !BNXT_CHIP_P5_THOR(bp)) {
|
||||
rc = -ENODEV;
|
||||
goto no_ptp;
|
||||
}
|
||||
|
||||
@@ -304,7 +304,7 @@ void bnxt_rdma_aux_device_uninit(struct bnxt *bp)
|
||||
struct auxiliary_device *adev;
|
||||
|
||||
/* Skip if no auxiliary device init was done. */
|
||||
if (!(bp->flags & BNXT_FLAG_ROCE_CAP))
|
||||
if (!bp->aux_priv)
|
||||
return;
|
||||
|
||||
aux_priv = bp->aux_priv;
|
||||
@@ -324,6 +324,7 @@ static void bnxt_aux_dev_release(struct device *dev)
|
||||
bp->edev = NULL;
|
||||
kfree(aux_priv->edev);
|
||||
kfree(aux_priv);
|
||||
bp->aux_priv = NULL;
|
||||
}
|
||||
|
||||
static void bnxt_set_edev_info(struct bnxt_en_dev *edev, struct bnxt *bp)
|
||||
@@ -359,19 +360,18 @@ void bnxt_rdma_aux_device_init(struct bnxt *bp)
|
||||
if (!(bp->flags & BNXT_FLAG_ROCE_CAP))
|
||||
return;
|
||||
|
||||
bp->aux_priv = kzalloc(sizeof(*bp->aux_priv), GFP_KERNEL);
|
||||
if (!bp->aux_priv)
|
||||
aux_priv = kzalloc(sizeof(*bp->aux_priv), GFP_KERNEL);
|
||||
if (!aux_priv)
|
||||
goto exit;
|
||||
|
||||
bp->aux_priv->id = ida_alloc(&bnxt_aux_dev_ids, GFP_KERNEL);
|
||||
if (bp->aux_priv->id < 0) {
|
||||
aux_priv->id = ida_alloc(&bnxt_aux_dev_ids, GFP_KERNEL);
|
||||
if (aux_priv->id < 0) {
|
||||
netdev_warn(bp->dev,
|
||||
"ida alloc failed for ROCE auxiliary device\n");
|
||||
kfree(bp->aux_priv);
|
||||
kfree(aux_priv);
|
||||
goto exit;
|
||||
}
|
||||
|
||||
aux_priv = bp->aux_priv;
|
||||
aux_dev = &aux_priv->aux_dev;
|
||||
aux_dev->id = aux_priv->id;
|
||||
aux_dev->name = "rdma";
|
||||
@@ -380,10 +380,11 @@ void bnxt_rdma_aux_device_init(struct bnxt *bp)
|
||||
|
||||
rc = auxiliary_device_init(aux_dev);
|
||||
if (rc) {
|
||||
ida_free(&bnxt_aux_dev_ids, bp->aux_priv->id);
|
||||
kfree(bp->aux_priv);
|
||||
ida_free(&bnxt_aux_dev_ids, aux_priv->id);
|
||||
kfree(aux_priv);
|
||||
goto exit;
|
||||
}
|
||||
bp->aux_priv = aux_priv;
|
||||
|
||||
/* From this point, all cleanup will happen via the .release callback &
|
||||
* any error unwinding will need to include a call to
|
||||
|
||||
@@ -1135,7 +1135,7 @@ void cxgb4_cleanup_tc_flower(struct adapter *adap)
|
||||
return;
|
||||
|
||||
if (adap->flower_stats_timer.function)
|
||||
del_timer_sync(&adap->flower_stats_timer);
|
||||
timer_shutdown_sync(&adap->flower_stats_timer);
|
||||
cancel_work_sync(&adap->flower_stats_work);
|
||||
rhashtable_destroy(&adap->flower_tbl);
|
||||
adap->tc_flower_initialized = false;
|
||||
|
||||
@@ -5288,31 +5288,6 @@ static void e1000_watchdog_task(struct work_struct *work)
|
||||
ew32(TARC(0), tarc0);
|
||||
}
|
||||
|
||||
/* disable TSO for pcie and 10/100 speeds, to avoid
|
||||
* some hardware issues
|
||||
*/
|
||||
if (!(adapter->flags & FLAG_TSO_FORCE)) {
|
||||
switch (adapter->link_speed) {
|
||||
case SPEED_10:
|
||||
case SPEED_100:
|
||||
e_info("10/100 speed: disabling TSO\n");
|
||||
netdev->features &= ~NETIF_F_TSO;
|
||||
netdev->features &= ~NETIF_F_TSO6;
|
||||
break;
|
||||
case SPEED_1000:
|
||||
netdev->features |= NETIF_F_TSO;
|
||||
netdev->features |= NETIF_F_TSO6;
|
||||
break;
|
||||
default:
|
||||
/* oops */
|
||||
break;
|
||||
}
|
||||
if (hw->mac.type == e1000_pch_spt) {
|
||||
netdev->features &= ~NETIF_F_TSO;
|
||||
netdev->features &= ~NETIF_F_TSO6;
|
||||
}
|
||||
}
|
||||
|
||||
/* enable transmits in the hardware, need to do this
|
||||
* after setting TARC(0)
|
||||
*/
|
||||
@@ -7526,6 +7501,32 @@ static int e1000_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
||||
NETIF_F_RXCSUM |
|
||||
NETIF_F_HW_CSUM);
|
||||
|
||||
/* disable TSO for pcie and 10/100 speeds to avoid
|
||||
* some hardware issues and for i219 to fix transfer
|
||||
* speed being capped at 60%
|
||||
*/
|
||||
if (!(adapter->flags & FLAG_TSO_FORCE)) {
|
||||
switch (adapter->link_speed) {
|
||||
case SPEED_10:
|
||||
case SPEED_100:
|
||||
e_info("10/100 speed: disabling TSO\n");
|
||||
netdev->features &= ~NETIF_F_TSO;
|
||||
netdev->features &= ~NETIF_F_TSO6;
|
||||
break;
|
||||
case SPEED_1000:
|
||||
netdev->features |= NETIF_F_TSO;
|
||||
netdev->features |= NETIF_F_TSO6;
|
||||
break;
|
||||
default:
|
||||
/* oops */
|
||||
break;
|
||||
}
|
||||
if (hw->mac.type == e1000_pch_spt) {
|
||||
netdev->features &= ~NETIF_F_TSO;
|
||||
netdev->features &= ~NETIF_F_TSO6;
|
||||
}
|
||||
}
|
||||
|
||||
/* Set user-changeable features (subset of all device features) */
|
||||
netdev->hw_features = netdev->features;
|
||||
netdev->hw_features |= NETIF_F_RXFCS;
|
||||
|
||||
@@ -11059,8 +11059,11 @@ static void i40e_rebuild(struct i40e_pf *pf, bool reinit, bool lock_acquired)
|
||||
pf->hw.aq.asq_last_status));
|
||||
}
|
||||
/* reinit the misc interrupt */
|
||||
if (pf->flags & I40E_FLAG_MSIX_ENABLED)
|
||||
if (pf->flags & I40E_FLAG_MSIX_ENABLED) {
|
||||
ret = i40e_setup_misc_vector(pf);
|
||||
if (ret)
|
||||
goto end_unlock;
|
||||
}
|
||||
|
||||
/* Add a filter to drop all Flow control frames from any VSI from being
|
||||
* transmitted. By doing so we stop a malicious VF from sending out
|
||||
@@ -14133,15 +14136,15 @@ static int i40e_add_vsi(struct i40e_vsi *vsi)
|
||||
vsi->id = ctxt.vsi_number;
|
||||
}
|
||||
|
||||
vsi->active_filters = 0;
|
||||
clear_bit(__I40E_VSI_OVERFLOW_PROMISC, vsi->state);
|
||||
spin_lock_bh(&vsi->mac_filter_hash_lock);
|
||||
vsi->active_filters = 0;
|
||||
/* If macvlan filters already exist, force them to get loaded */
|
||||
hash_for_each_safe(vsi->mac_filter_hash, bkt, h, f, hlist) {
|
||||
f->state = I40E_FILTER_NEW;
|
||||
f_count++;
|
||||
}
|
||||
spin_unlock_bh(&vsi->mac_filter_hash_lock);
|
||||
clear_bit(__I40E_VSI_OVERFLOW_PROMISC, vsi->state);
|
||||
|
||||
if (f_count) {
|
||||
vsi->flags |= I40E_VSI_FLAG_FILTER_CHANGED;
|
||||
|
||||
@@ -59,9 +59,6 @@ bool mlx5_eth_supported(struct mlx5_core_dev *dev)
|
||||
if (!IS_ENABLED(CONFIG_MLX5_CORE_EN))
|
||||
return false;
|
||||
|
||||
if (mlx5_core_is_management_pf(dev))
|
||||
return false;
|
||||
|
||||
if (MLX5_CAP_GEN(dev, port_type) != MLX5_CAP_PORT_TYPE_ETH)
|
||||
return false;
|
||||
|
||||
@@ -201,9 +198,6 @@ bool mlx5_rdma_supported(struct mlx5_core_dev *dev)
|
||||
if (!IS_ENABLED(CONFIG_MLX5_INFINIBAND))
|
||||
return false;
|
||||
|
||||
if (mlx5_core_is_management_pf(dev))
|
||||
return false;
|
||||
|
||||
if (dev->priv.flags & MLX5_PRIV_FLAGS_DISABLE_IB_ADEV)
|
||||
return false;
|
||||
|
||||
|
||||
@@ -75,10 +75,6 @@ int mlx5_ec_init(struct mlx5_core_dev *dev)
|
||||
if (!mlx5_core_is_ecpf(dev))
|
||||
return 0;
|
||||
|
||||
/* Management PF don't have a peer PF */
|
||||
if (mlx5_core_is_management_pf(dev))
|
||||
return 0;
|
||||
|
||||
return mlx5_host_pf_init(dev);
|
||||
}
|
||||
|
||||
@@ -89,10 +85,6 @@ void mlx5_ec_cleanup(struct mlx5_core_dev *dev)
|
||||
if (!mlx5_core_is_ecpf(dev))
|
||||
return;
|
||||
|
||||
/* Management PF don't have a peer PF */
|
||||
if (mlx5_core_is_management_pf(dev))
|
||||
return;
|
||||
|
||||
mlx5_host_pf_cleanup(dev);
|
||||
|
||||
err = mlx5_wait_for_pages(dev, &dev->priv.page_counters[MLX5_HOST_PF]);
|
||||
|
||||
@@ -1488,7 +1488,7 @@ int mlx5_esw_sf_max_hpf_functions(struct mlx5_core_dev *dev, u16 *max_sfs, u16 *
|
||||
void *hca_caps;
|
||||
int err;
|
||||
|
||||
if (!mlx5_core_is_ecpf(dev) || mlx5_core_is_management_pf(dev)) {
|
||||
if (!mlx5_core_is_ecpf(dev)) {
|
||||
*max_sfs = 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -31,6 +31,8 @@ mlxfw_mfa2_tlv_next(const struct mlxfw_mfa2_file *mfa2_file,
|
||||
|
||||
if (tlv->type == MLXFW_MFA2_TLV_MULTI_PART) {
|
||||
multi = mlxfw_mfa2_tlv_multi_get(mfa2_file, tlv);
|
||||
if (!multi)
|
||||
return NULL;
|
||||
tlv_len = NLA_ALIGN(tlv_len + be16_to_cpu(multi->total_len));
|
||||
}
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
#define MLXSW_PCI_CIR_TIMEOUT_MSECS 1000
|
||||
|
||||
#define MLXSW_PCI_SW_RESET_TIMEOUT_MSECS 900000
|
||||
#define MLXSW_PCI_SW_RESET_WAIT_MSECS 200
|
||||
#define MLXSW_PCI_SW_RESET_WAIT_MSECS 400
|
||||
#define MLXSW_PCI_FW_READY 0xA1844
|
||||
#define MLXSW_PCI_FW_READY_MASK 0xFFFF
|
||||
#define MLXSW_PCI_FW_READY_MAGIC 0x5E
|
||||
|
||||
@@ -541,7 +541,6 @@ int efx_net_open(struct net_device *net_dev)
|
||||
else
|
||||
efx->state = STATE_NET_UP;
|
||||
|
||||
efx_selftest_async_start(efx);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -544,6 +544,8 @@ void efx_start_all(struct efx_nic *efx)
|
||||
/* Start the hardware monitor if there is one */
|
||||
efx_start_monitor(efx);
|
||||
|
||||
efx_selftest_async_start(efx);
|
||||
|
||||
/* Link state detection is normally event-driven; we have
|
||||
* to poll now because we could have missed a change
|
||||
*/
|
||||
|
||||
@@ -47,7 +47,7 @@ config BPQETHER
|
||||
|
||||
config SCC
|
||||
tristate "Z8530 SCC driver"
|
||||
depends on ISA && AX25 && ISA_DMA_API
|
||||
depends on ISA && AX25
|
||||
help
|
||||
These cards are used to connect your Linux box to an amateur radio
|
||||
in order to communicate with other computers. If you want to use
|
||||
|
||||
@@ -1262,11 +1262,12 @@ static void veth_set_xdp_features(struct net_device *dev)
|
||||
|
||||
peer = rtnl_dereference(priv->peer);
|
||||
if (peer && peer->real_num_tx_queues <= dev->real_num_rx_queues) {
|
||||
struct veth_priv *priv_peer = netdev_priv(peer);
|
||||
xdp_features_t val = NETDEV_XDP_ACT_BASIC |
|
||||
NETDEV_XDP_ACT_REDIRECT |
|
||||
NETDEV_XDP_ACT_RX_SG;
|
||||
|
||||
if (priv->_xdp_prog || veth_gro_requested(dev))
|
||||
if (priv_peer->_xdp_prog || veth_gro_requested(peer))
|
||||
val |= NETDEV_XDP_ACT_NDO_XMIT |
|
||||
NETDEV_XDP_ACT_NDO_XMIT_SG;
|
||||
xdp_set_features_flag(dev, val);
|
||||
@@ -1504,19 +1505,23 @@ static int veth_set_features(struct net_device *dev,
|
||||
{
|
||||
netdev_features_t changed = features ^ dev->features;
|
||||
struct veth_priv *priv = netdev_priv(dev);
|
||||
struct net_device *peer;
|
||||
int err;
|
||||
|
||||
if (!(changed & NETIF_F_GRO) || !(dev->flags & IFF_UP) || priv->_xdp_prog)
|
||||
return 0;
|
||||
|
||||
peer = rtnl_dereference(priv->peer);
|
||||
if (features & NETIF_F_GRO) {
|
||||
err = veth_napi_enable(dev);
|
||||
if (err)
|
||||
return err;
|
||||
|
||||
xdp_features_set_redirect_target(dev, true);
|
||||
if (peer)
|
||||
xdp_features_set_redirect_target(peer, true);
|
||||
} else {
|
||||
xdp_features_clear_redirect_target(dev);
|
||||
if (peer)
|
||||
xdp_features_clear_redirect_target(peer);
|
||||
veth_napi_del(dev);
|
||||
}
|
||||
return 0;
|
||||
@@ -1598,13 +1603,13 @@ static int veth_xdp_set(struct net_device *dev, struct bpf_prog *prog,
|
||||
peer->max_mtu = max_mtu;
|
||||
}
|
||||
|
||||
xdp_features_set_redirect_target(dev, true);
|
||||
xdp_features_set_redirect_target(peer, true);
|
||||
}
|
||||
|
||||
if (old_prog) {
|
||||
if (!prog) {
|
||||
if (!veth_gro_requested(dev))
|
||||
xdp_features_clear_redirect_target(dev);
|
||||
if (peer && !veth_gro_requested(dev))
|
||||
xdp_features_clear_redirect_target(peer);
|
||||
|
||||
if (dev->flags & IFF_UP)
|
||||
veth_disable_xdp(dev);
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user