Skip to content

Commit dbf8fe8

Browse files
committed
Merge tag 'net-6.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Pull networking fixes from Paolo Abeni: "Including fixes from Bluetooth and WiFi. Notably this includes the fix for the iwlwifi issue you reported. Current release - regressions: - core: avoid prefetching NULL pointers - wifi: - iwlwifi: implement settime64 as stub for MVM/MLD PTP - mac80211: fix list iteration in ieee80211_add_virtual_monitor() - handshake: fix null-ptr-deref in handshake_complete() - eth: mana: fix use-after-free in reset service rescan path Previous releases - regressions: - openvswitch: avoid needlessly taking the RTNL on vport destroy - dsa: properly keep track of conduit reference - ipv4: - fix error route reference count leak with nexthop objects - fib: restore ECMP balance from loopback - mptcp: ensure context reset on disconnect() - bluetooth: fix potential UaF in btusb - nfc: fix deadlock between nfc_unregister_device and rfkill_fop_write - eth: - gve: defer interrupt enabling until NAPI registration - i40e: fix scheduling in set_rx_mode - macb: relocate mog_init_rings() callback from macb_mac_link_up() to macb_open() - rtl8150: fix memory leak on usb_submit_urb() failure - wifi: 8192cu: fix tid out of range in rtl92cu_tx_fill_desc() Previous releases - always broken: - ip6_gre: make ip6gre_header() robust - ipv6: fix a BUG in rt6_get_pcpu_route() under PREEMPT_RT - af_unix: don't post cmsg for SO_INQ unless explicitly asked for - phy: mediatek: fix nvmem cell reference leak in mt798x_phy_calibration - wifi: mac80211: discard beacon frames to non-broadcast address - eth: - iavf: fix off-by-one issues in iavf_config_rss_reg() - stmmac: fix the crash issue for zero copy XDP_TX action - team: fix check for port enabled when priority changes" * tag 'net-6.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (64 commits) ipv6: fix a BUG in rt6_get_pcpu_route() under PREEMPT_RT net: rose: fix invalid array index in rose_kill_by_device() net: enetc: do not print error log if addr is 0 net: macb: Relocate mog_init_rings() callback from macb_mac_link_up() to macb_open() selftests: fib_test: Add test case for ipv4 multi nexthops net: fib: restore ECMP balance from loopback selftests: fib_nexthops: Add test cases for error routes deletion ipv4: Fix reference count leak when using error routes with nexthop objects net: usb: sr9700: fix incorrect command used to write single register ipv6: BUG() in pskb_expand_head() as part of calipso_skbuff_setattr() usbnet: avoid a possible crash in dql_completed() gve: defer interrupt enabling until NAPI registration net: stmmac: fix the crash issue for zero copy XDP_TX action octeontx2-pf: fix "UBSAN: shift-out-of-bounds error" af_unix: don't post cmsg for SO_INQ unless explicitly asked for net: mana: Fix use-after-free in reset service rescan path net: avoid prefetching NULL pointers net: bridge: Describe @tunnel_hash member in net_bridge_vlan_group struct net: nfc: fix deadlock between nfc_unregister_device and rfkill_fop_write net: usb: asix: validate PHY address before use ...
2 parents 8640b74 + 1adaea5 commit dbf8fe8

71 files changed

Lines changed: 428 additions & 194 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

drivers/bluetooth/btusb.c

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4052,7 +4052,7 @@ static int btusb_probe(struct usb_interface *intf,
40524052
return -ENODEV;
40534053
}
40544054

4055-
data = devm_kzalloc(&intf->dev, sizeof(*data), GFP_KERNEL);
4055+
data = kzalloc(sizeof(*data), GFP_KERNEL);
40564056
if (!data)
40574057
return -ENOMEM;
40584058

@@ -4075,8 +4075,10 @@ static int btusb_probe(struct usb_interface *intf,
40754075
}
40764076
}
40774077

4078-
if (!data->intr_ep || !data->bulk_tx_ep || !data->bulk_rx_ep)
4078+
if (!data->intr_ep || !data->bulk_tx_ep || !data->bulk_rx_ep) {
4079+
kfree(data);
40794080
return -ENODEV;
4081+
}
40804082

40814083
if (id->driver_info & BTUSB_AMP) {
40824084
data->cmdreq_type = USB_TYPE_CLASS | 0x01;
@@ -4131,8 +4133,10 @@ static int btusb_probe(struct usb_interface *intf,
41314133
data->recv_acl = hci_recv_frame;
41324134

41334135
hdev = hci_alloc_dev_priv(priv_size);
4134-
if (!hdev)
4136+
if (!hdev) {
4137+
kfree(data);
41354138
return -ENOMEM;
4139+
}
41364140

41374141
hdev->bus = HCI_USB;
41384142
hci_set_drvdata(hdev, data);
@@ -4406,6 +4410,7 @@ static int btusb_probe(struct usb_interface *intf,
44064410
if (data->reset_gpio)
44074411
gpiod_put(data->reset_gpio);
44084412
hci_free_dev(hdev);
4413+
kfree(data);
44094414
return err;
44104415
}
44114416

@@ -4454,6 +4459,7 @@ static void btusb_disconnect(struct usb_interface *intf)
44544459
}
44554460

44564461
hci_free_dev(hdev);
4462+
kfree(data);
44574463
}
44584464

44594465
#ifdef CONFIG_PM

drivers/net/dsa/b53/b53_common.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2169,6 +2169,9 @@ static int b53_fdb_copy(int port, const struct b53_arl_entry *ent,
21692169
if (!ent->is_valid)
21702170
return 0;
21712171

2172+
if (is_multicast_ether_addr(ent->mac))
2173+
return 0;
2174+
21722175
if (port != ent->port)
21732176
return 0;
21742177

drivers/net/ethernet/airoha/airoha_eth.c

Lines changed: 26 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2924,19 +2924,26 @@ static int airoha_alloc_gdm_port(struct airoha_eth *eth,
29242924
port->id = id;
29252925
eth->ports[p] = port;
29262926

2927-
err = airoha_metadata_dst_alloc(port);
2928-
if (err)
2929-
return err;
2927+
return airoha_metadata_dst_alloc(port);
2928+
}
29302929

2931-
err = register_netdev(dev);
2932-
if (err)
2933-
goto free_metadata_dst;
2930+
static int airoha_register_gdm_devices(struct airoha_eth *eth)
2931+
{
2932+
int i;
29342933

2935-
return 0;
2934+
for (i = 0; i < ARRAY_SIZE(eth->ports); i++) {
2935+
struct airoha_gdm_port *port = eth->ports[i];
2936+
int err;
29362937

2937-
free_metadata_dst:
2938-
airoha_metadata_dst_free(port);
2939-
return err;
2938+
if (!port)
2939+
continue;
2940+
2941+
err = register_netdev(port->dev);
2942+
if (err)
2943+
return err;
2944+
}
2945+
2946+
return 0;
29402947
}
29412948

29422949
static int airoha_probe(struct platform_device *pdev)
@@ -3027,6 +3034,10 @@ static int airoha_probe(struct platform_device *pdev)
30273034
}
30283035
}
30293036

3037+
err = airoha_register_gdm_devices(eth);
3038+
if (err)
3039+
goto error_napi_stop;
3040+
30303041
return 0;
30313042

30323043
error_napi_stop:
@@ -3040,10 +3051,12 @@ static int airoha_probe(struct platform_device *pdev)
30403051
for (i = 0; i < ARRAY_SIZE(eth->ports); i++) {
30413052
struct airoha_gdm_port *port = eth->ports[i];
30423053

3043-
if (port && port->dev->reg_state == NETREG_REGISTERED) {
3054+
if (!port)
3055+
continue;
3056+
3057+
if (port->dev->reg_state == NETREG_REGISTERED)
30443058
unregister_netdev(port->dev);
3045-
airoha_metadata_dst_free(port);
3046-
}
3059+
airoha_metadata_dst_free(port);
30473060
}
30483061
free_netdev(eth->napi_dev);
30493062
platform_set_drvdata(pdev, NULL);

drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1928,6 +1928,7 @@ static void xgbe_set_rx_adap_mode(struct xgbe_prv_data *pdata,
19281928
{
19291929
if (pdata->rx_adapt_retries++ >= MAX_RX_ADAPT_RETRIES) {
19301930
pdata->rx_adapt_retries = 0;
1931+
pdata->mode_set = false;
19311932
return;
19321933
}
19331934

@@ -1974,6 +1975,7 @@ static void xgbe_rx_adaptation(struct xgbe_prv_data *pdata)
19741975
*/
19751976
netif_dbg(pdata, link, pdata->netdev, "Block_lock done");
19761977
pdata->rx_adapt_done = true;
1978+
pdata->rx_adapt_retries = 0;
19771979
pdata->mode_set = false;
19781980
return;
19791981
}

drivers/net/ethernet/broadcom/Kconfig

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -255,14 +255,14 @@ config BNXT_HWMON
255255
devices, via the hwmon sysfs interface.
256256

257257
config BNGE
258-
tristate "Broadcom Ethernet device support"
258+
tristate "Broadcom ThorUltra Ethernet device support"
259259
depends on PCI
260260
select NET_DEVLINK
261261
select PAGE_POOL
262262
help
263-
This driver supports Broadcom 50/100/200/400/800 gigabit Ethernet cards.
264-
The module will be called bng_en. To compile this driver as a module,
265-
choose M here.
263+
This driver supports Broadcom ThorUltra 50/100/200/400/800 gigabit
264+
Ethernet cards. The module will be called bng_en. To compile this
265+
driver as a module, choose M here.
266266

267267
config BCMASP
268268
tristate "Broadcom ASP 2.0 Ethernet support"

drivers/net/ethernet/broadcom/bnge/bnge.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#define _BNGE_H_
66

77
#define DRV_NAME "bng_en"
8-
#define DRV_SUMMARY "Broadcom 800G Ethernet Linux Driver"
8+
#define DRV_SUMMARY "Broadcom ThorUltra NIC Ethernet Driver"
99

1010
#include <linux/etherdevice.h>
1111
#include <linux/bnxt/hsi.h>

drivers/net/ethernet/broadcom/bnge/bnge_core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ char bnge_driver_name[] = DRV_NAME;
1919
static const struct {
2020
char *name;
2121
} board_info[] = {
22-
[BCM57708] = { "Broadcom BCM57708 50Gb/100Gb/200Gb/400Gb/800Gb Ethernet" },
22+
[BCM57708] = { "Broadcom BCM57708 ThorUltra 50Gb/100Gb/200Gb/400Gb/800Gb Ethernet" },
2323
};
2424

2525
static const struct pci_device_id bnge_pci_tbl[] = {

drivers/net/ethernet/cadence/macb_main.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -708,7 +708,6 @@ static void macb_mac_link_up(struct phylink_config *config,
708708
/* Initialize rings & buffers as clearing MACB_BIT(TE) in link down
709709
* cleared the pipeline and control registers.
710710
*/
711-
bp->macbgem_ops.mog_init_rings(bp);
712711
macb_init_buffers(bp);
713712

714713
for (q = 0, queue = bp->queues; q < bp->num_queues; ++q, ++queue)
@@ -2954,6 +2953,8 @@ static int macb_open(struct net_device *dev)
29542953
goto pm_exit;
29552954
}
29562955

2956+
bp->macbgem_ops.mog_init_rings(bp);
2957+
29572958
for (q = 0, queue = bp->queues; q < bp->num_queues; ++q, ++queue) {
29582959
napi_enable(&queue->napi_rx);
29592960
napi_enable(&queue->napi_tx);

drivers/net/ethernet/freescale/enetc/netc_blk_ctrl.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -577,11 +577,17 @@ static int imx94_enetc_mdio_phyaddr_config(struct netc_blk_ctrl *priv,
577577
}
578578

579579
addr = netc_get_phy_addr(np);
580-
if (addr <= 0) {
580+
if (addr < 0) {
581581
dev_err(dev, "Failed to get PHY address\n");
582582
return addr;
583583
}
584584

585+
/* The default value of LaBCR[MDIO_PHYAD_PRTAD] is 0,
586+
* so no need to set the register.
587+
*/
588+
if (!addr)
589+
return 0;
590+
585591
if (phy_mask & BIT(addr)) {
586592
dev_err(dev,
587593
"Find same PHY address in EMDIO and ENETC node\n");

drivers/net/ethernet/google/gve/gve_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -558,7 +558,7 @@ static int gve_alloc_notify_blocks(struct gve_priv *priv)
558558
block->priv = priv;
559559
err = request_irq(priv->msix_vectors[msix_idx].vector,
560560
gve_is_gqi(priv) ? gve_intr : gve_intr_dqo,
561-
0, block->name, block);
561+
IRQF_NO_AUTOEN, block->name, block);
562562
if (err) {
563563
dev_err(&priv->pdev->dev,
564564
"Failed to receive msix vector %d\n", i);

0 commit comments

Comments
 (0)