Commit 5deaa985 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull networking fixes from Jakub Kicinski:
 "Including fixes from wireless, bluetooth, bpf and netfilter.

  Current release - regressions:

   - Revert "net: team: use IFF_NO_ADDRCONF flag to prevent ipv6
     addrconf", fix nsna_ping mode of team

   - wifi: mt76: fix bugs in Rx queue handling and DMA mapping

   - eth: mlx5:
      - add missing mutex_unlock in error reporter
      - protect global IPsec ASO with a lock

  Current release - new code bugs:

   - rxrpc: fix wrong error return in rxrpc_connect_call()

  Previous releases - regressions:

   - bluetooth: hci_sync: fix use of HCI_OP_LE_READ_BUFFER_SIZE_V2

   - wifi:
      - mac80211: fix crashes on Rx due to incorrect initialization of
        rx->link and rx->link_sta
      - mac80211: fix bugs in iTXQ conversion - Tx stalls, incorrect
        aggregation handling, crashes
      - brcmfmac: fix regression for Broadcom PCIe wifi devices
      - rndis_wlan: prevent buffer overflow in rndis_query_oid

   - netfilter: conntrack: handle tcp challenge acks during connection
     reuse

   - sched: avoid grafting on htb_destroy_class_offload when destroying

   - virtio-net: correctly enable callback during start_xmit, fix stalls

   - tcp: avoid the lookup process failing to get sk in ehash table

   - ipa: disable ipa interrupt during suspend

   - eth: stmmac: enable all safety features by default

  Previous releases - always broken:

   - bpf:
      - fix pointer-leak due to insufficient speculative store bypass
        mitigation (Spectre v4)
      - skip task with pid=1 in send_signal_common() to avoid a splat
      - fix BPF program ID information in BPF_AUDIT_UNLOAD as well as
        PERF_BPF_EVENT_PROG_UNLOAD events
      - fix potential deadlock in htab_lock_bucket from same bucket
        index but different map_locked index

   - bluetooth:
      - fix a buffer overflow in mgmt_mesh_add()
      - hci_qca: fix driver shutdown on closed serdev
      - ISO: fix possible circular locking dependency
      - CIS: hci_event: fix invalid wait context

   - wifi: brcmfmac: fixes for survey dump handling

   - mptcp: explicitly specify sock family at subflow creation time

   - netfilter: nft_payload: incorrect arithmetics when fetching VLAN
     header bits

   - tcp: fix rate_app_limited to default to 1

   - l2tp: close all race conditions in l2tp_tunnel_register()

   - eth: mlx5: fixes for QoS config and eswitch configuration

   - eth: enetc: avoid deadlock in enetc_tx_onestep_tstamp()

   - eth: stmmac: fix invalid call to mdiobus_get_phy()

  Misc:

   - ethtool: add netlink attr in rss get reply only if the value is not
     empty"

* tag 'net-6.2-rc5-2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (88 commits)
  Revert "Merge branch 'octeontx2-af-CPT'"
  tcp: fix rate_app_limited to default to 1
  bnxt: Do not read past the end of test names
  net: stmmac: enable all safety features by default
  octeontx2-af: add mbox to return CPT_AF_FLT_INT info
  octeontx2-af: update cpt lf alloc mailbox
  octeontx2-af: restore rxc conf after teardown sequence
  octeontx2-af: optimize cpt pf identification
  octeontx2-af: modify FLR sequence for CPT
  octeontx2-af: add mbox for CPT LF reset
  octeontx2-af: recover CPT engine when it gets fault
  net: dsa: microchip: ksz9477: port map correction in ALU table entry register
  selftests/net: toeplitz: fix race on tpacket_v3 block close
  net/ulp: use consistent error code when blocking ULP
  octeontx2-pf: Fix the use of GFP_KERNEL in atomic context on rt
  tcp: avoid the lookup process failing to get sk in ehash table
  Revert "net: team: use IFF_NO_ADDRCONF flag to prevent ipv6 addrconf"
  MAINTAINERS: add networking entries for Willem
  net: sched: gred: prevent races when adding offloads to stats
  l2tp: prevent lockdep issue in l2tp_tunnel_register()
  ...
parents 4a0c7a68 45a919bb
Loading
Loading
Loading
Loading
+20 −1
Original line number Diff line number Diff line
@@ -1104,7 +1104,6 @@ S: Supported
F:	arch/arm64/boot/dts/amd/
AMD XGBE DRIVER
M:	Tom Lendacky <thomas.lendacky@amd.com>
M:	"Shyam Sundar S K" <Shyam-sundar.S-k@amd.com>
L:	netdev@vger.kernel.org
S:	Supported
@@ -15750,6 +15749,12 @@ S: Maintained
W:	https://wireless.wiki.kernel.org/en/users/Drivers/p54
F:	drivers/net/wireless/intersil/p54/
PACKET SOCKETS
M:	Willem de Bruijn <willemdebruijn.kernel@gmail.com>
S:	Maintained
F:	include/uapi/linux/if_packet.h
F:	net/packet/af_packet.c
PACKING
M:	Vladimir Oltean <olteanv@gmail.com>
L:	netdev@vger.kernel.org
@@ -19326,6 +19331,13 @@ L: alsa-devel@alsa-project.org (moderated for non-subscribers)
S:	Orphan
F:	sound/soc/uniphier/
SOCKET TIMESTAMPING
M:	Willem de Bruijn <willemdebruijn.kernel@gmail.com>
S:	Maintained
F:	Documentation/networking/timestamping.rst
F:	include/uapi/linux/net_tstamp.h
F:	tools/testing/selftests/net/so_txtime.c
SOEKRIS NET48XX LED SUPPORT
M:	Chris Boot <bootc@bootc.net>
S:	Maintained
@@ -21746,6 +21758,13 @@ T: git git://linuxtv.org/media_tree.git
F:	Documentation/admin-guide/media/zr364xx*
F:	drivers/staging/media/deprecated/zr364xx/
USER DATAGRAM PROTOCOL (UDP)
M:	Willem de Bruijn <willemdebruijn.kernel@gmail.com>
S:	Maintained
F:	include/linux/udp.h
F:	net/ipv4/udp.c
F:	net/ipv6/udp.c
USER-MODE LINUX (UML)
M:	Richard Weinberger <richard@nod.at>
M:	Anton Ivanov <anton.ivanov@cambridgegreys.com>
+7 −0
Original line number Diff line number Diff line
@@ -2164,10 +2164,17 @@ static void qca_serdev_shutdown(struct device *dev)
	int timeout = msecs_to_jiffies(CMD_TRANS_TIMEOUT_MS);
	struct serdev_device *serdev = to_serdev_device(dev);
	struct qca_serdev *qcadev = serdev_device_get_drvdata(serdev);
	struct hci_uart *hu = &qcadev->serdev_hu;
	struct hci_dev *hdev = hu->hdev;
	struct qca_data *qca = hu->priv;
	const u8 ibs_wake_cmd[] = { 0xFD };
	const u8 edl_reset_soc_cmd[] = { 0x01, 0x00, 0xFC, 0x01, 0x05 };

	if (qcadev->btsoc_type == QCA_QCA6390) {
		if (test_bit(QCA_BT_OFF, &qca->flags) ||
		    !test_bit(HCI_RUNNING, &hdev->flags))
			return;

		serdev_device_write_flush(serdev);
		ret = serdev_device_write_buf(serdev, ibs_wake_cmd,
					      sizeof(ibs_wake_cmd));
+2 −2
Original line number Diff line number Diff line
@@ -540,10 +540,10 @@ int ksz9477_fdb_del(struct ksz_device *dev, int port,
		ksz_read32(dev, REG_SW_ALU_VAL_D, &alu_table[3]);

		/* clear forwarding port */
		alu_table[2] &= ~BIT(port);
		alu_table[1] &= ~BIT(port);

		/* if there is no port to forward, clear table */
		if ((alu_table[2] & ALU_V_PORT_MAP) == 0) {
		if ((alu_table[1] & ALU_V_PORT_MAP) == 0) {
			alu_table[0] = 0;
			alu_table[1] = 0;
			alu_table[2] = 0;
+15 −8
Original line number Diff line number Diff line
@@ -524,19 +524,28 @@ static void xgbe_disable_vxlan(struct xgbe_prv_data *pdata)
	netif_dbg(pdata, drv, pdata->netdev, "VXLAN acceleration disabled\n");
}

static unsigned int xgbe_get_fc_queue_count(struct xgbe_prv_data *pdata)
{
	unsigned int max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES;

	/* From MAC ver 30H the TFCR is per priority, instead of per queue */
	if (XGMAC_GET_BITS(pdata->hw_feat.version, MAC_VR, SNPSVER) >= 0x30)
		return max_q_count;
	else
		return min_t(unsigned int, pdata->tx_q_count, max_q_count);
}

static int xgbe_disable_tx_flow_control(struct xgbe_prv_data *pdata)
{
	unsigned int max_q_count, q_count;
	unsigned int reg, reg_val;
	unsigned int i;
	unsigned int i, q_count;

	/* Clear MTL flow control */
	for (i = 0; i < pdata->rx_q_count; i++)
		XGMAC_MTL_IOWRITE_BITS(pdata, i, MTL_Q_RQOMR, EHFC, 0);

	/* Clear MAC flow control */
	max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES;
	q_count = min_t(unsigned int, pdata->tx_q_count, max_q_count);
	q_count = xgbe_get_fc_queue_count(pdata);
	reg = MAC_Q0TFCR;
	for (i = 0; i < q_count; i++) {
		reg_val = XGMAC_IOREAD(pdata, reg);
@@ -553,9 +562,8 @@ static int xgbe_enable_tx_flow_control(struct xgbe_prv_data *pdata)
{
	struct ieee_pfc *pfc = pdata->pfc;
	struct ieee_ets *ets = pdata->ets;
	unsigned int max_q_count, q_count;
	unsigned int reg, reg_val;
	unsigned int i;
	unsigned int i, q_count;

	/* Set MTL flow control */
	for (i = 0; i < pdata->rx_q_count; i++) {
@@ -579,8 +587,7 @@ static int xgbe_enable_tx_flow_control(struct xgbe_prv_data *pdata)
	}

	/* Set MAC flow control */
	max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES;
	q_count = min_t(unsigned int, pdata->tx_q_count, max_q_count);
	q_count = xgbe_get_fc_queue_count(pdata);
	reg = MAC_Q0TFCR;
	for (i = 0; i < q_count; i++) {
		reg_val = XGMAC_IOREAD(pdata, reg);
+24 −0
Original line number Diff line number Diff line
@@ -496,6 +496,7 @@ static enum xgbe_an xgbe_an73_tx_training(struct xgbe_prv_data *pdata,
	reg |= XGBE_KR_TRAINING_ENABLE;
	reg |= XGBE_KR_TRAINING_START;
	XMDIO_WRITE(pdata, MDIO_MMD_PMAPMD, MDIO_PMA_10GBR_PMD_CTRL, reg);
	pdata->kr_start_time = jiffies;

	netif_dbg(pdata, link, pdata->netdev,
		  "KR training initiated\n");
@@ -632,6 +633,8 @@ static enum xgbe_an xgbe_an73_incompat_link(struct xgbe_prv_data *pdata)

	xgbe_switch_mode(pdata);

	pdata->an_result = XGBE_AN_READY;

	xgbe_an_restart(pdata);

	return XGBE_AN_INCOMPAT_LINK;
@@ -1275,9 +1278,30 @@ static bool xgbe_phy_aneg_done(struct xgbe_prv_data *pdata)
static void xgbe_check_link_timeout(struct xgbe_prv_data *pdata)
{
	unsigned long link_timeout;
	unsigned long kr_time;
	int wait;

	link_timeout = pdata->link_check + (XGBE_LINK_TIMEOUT * HZ);
	if (time_after(jiffies, link_timeout)) {
		if ((xgbe_cur_mode(pdata) == XGBE_MODE_KR) &&
		    pdata->phy.autoneg == AUTONEG_ENABLE) {
			/* AN restart should not happen while KR training is in progress.
			 * The while loop ensures no AN restart during KR training,
			 * waits up to 500ms and AN restart is triggered only if KR
			 * training is failed.
			 */
			wait = XGBE_KR_TRAINING_WAIT_ITER;
			while (wait--) {
				kr_time = pdata->kr_start_time +
					  msecs_to_jiffies(XGBE_AN_MS_TIMEOUT);
				if (time_after(jiffies, kr_time))
					break;
				/* AN restart is not required, if AN result is COMPLETE */
				if (pdata->an_result == XGBE_AN_COMPLETE)
					return;
				usleep_range(10000, 11000);
			}
		}
		netif_dbg(pdata, link, pdata->netdev, "AN link timeout\n");
		xgbe_phy_config_aneg(pdata);
	}
Loading