Skip to content

Commit 3781648

Browse files
committed
Merge tag 'net-6.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Pull networking fixes from Jakub Kicinski: Previous releases - regressions: - netlink: avoid infinite retry looping in netlink_unicast() Previous releases - always broken: - packet: fix a race in packet_set_ring() and packet_notifier() - ipv6: reject malicious packets in ipv6_gso_segment() - sched: mqprio: fix stack out-of-bounds write in tc entry parsing - net: drop UFO packets (injected via virtio) in udp_rcv_segment() - eth: mlx5: correctly set gso_segs when LRO is used, avoid false positive checksum validation errors - netpoll: prevent hanging NAPI when netcons gets enabled - phy: mscc: fix parsing of unicast frames for PTP timestamping - a number of device tree / OF reference leak fixes" * tag 'net-6.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (44 commits) pptp: fix pptp_xmit() error path net: ti: icssg-prueth: Fix skb handling for XDP_PASS net: Update threaded state in napi config in netif_set_threaded selftests: netdevsim: Xfail nexthop test on slow machines eth: fbnic: Lock the tx_dropped update eth: fbnic: Fix tx_dropped reporting eth: fbnic: remove the debugging trick of super high page bias net: ftgmac100: fix potential NULL pointer access in ftgmac100_phy_disconnect dt-bindings: net: Replace bouncing Alexandru Tachici emails dpll: zl3073x: ZL3073X_I2C and ZL3073X_SPI should depend on NET net/sched: mqprio: fix stack out-of-bounds write in tc entry parsing Revert "net: mdio_bus: Use devm for getting reset GPIO" selftests: net: packetdrill: xfail all problems on slow machines net/packet: fix a race in packet_set_ring() and packet_notifier() benet: fix BUG when creating VFs net: airoha: npu: Add missing MODULE_FIRMWARE macros net: devmem: fix DMA direction on unmapping ipa: fix compile-testing with qcom-mdt=m eth: fbnic: unlink NAPIs from queues on error to open net: Add locking to protect skb->dev access in ip_output ...
2 parents bec0771 + ae63338 commit 3781648

File tree

46 files changed

+363
-138
lines changed

Some content is hidden

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

46 files changed

+363
-138
lines changed

Documentation/devicetree/bindings/net/adi,adin.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
77
title: Analog Devices ADIN1200/ADIN1300 PHY
88

99
maintainers:
10-
- Alexandru Tachici <alexandru.tachici@analog.com>
10+
- Marcelo Schmitt <marcelo.schmitt@analog.com>
1111

1212
description: |
1313
Bindings for Analog Devices Industrial Ethernet PHYs

Documentation/devicetree/bindings/net/adi,adin1110.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
77
title: ADI ADIN1110 MAC-PHY
88

99
maintainers:
10-
- Alexandru Tachici <alexandru.tachici@analog.com>
10+
- Marcelo Schmitt <marcelo.schmitt@analog.com>
1111

1212
description: |
1313
The ADIN1110 is a low power single port 10BASE-T1L MAC-

Documentation/netlink/specs/ethtool.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2342,16 +2342,16 @@ operations:
23422342

23432343
do: &module-eeprom-get-op
23442344
request:
2345-
attributes:
2346-
- header
2347-
reply:
23482345
attributes:
23492346
- header
23502347
- offset
23512348
- length
23522349
- page
23532350
- bank
23542351
- i2c-address
2352+
reply:
2353+
attributes:
2354+
- header
23552355
- data
23562356
dump: *module-eeprom-get-op
23572357
-

drivers/dpll/zl3073x/Kconfig

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0-only
22

33
config ZL3073X
4-
tristate "Microchip Azurite DPLL/PTP/SyncE devices"
4+
tristate "Microchip Azurite DPLL/PTP/SyncE devices" if COMPILE_TEST
55
depends on NET
66
select DPLL
77
select NET_DEVLINK
@@ -16,9 +16,9 @@ config ZL3073X
1616

1717
config ZL3073X_I2C
1818
tristate "I2C bus implementation for Microchip Azurite devices"
19-
depends on I2C && ZL3073X
19+
depends on I2C && NET
2020
select REGMAP_I2C
21-
default m
21+
select ZL3073X
2222
help
2323
This is I2C bus implementation for Microchip Azurite DPLL/PTP/SyncE
2424
devices.
@@ -28,9 +28,9 @@ config ZL3073X_I2C
2828

2929
config ZL3073X_SPI
3030
tristate "SPI bus implementation for Microchip Azurite devices"
31-
depends on SPI && ZL3073X
31+
depends on NET && SPI
3232
select REGMAP_SPI
33-
default m
33+
select ZL3073X
3434
help
3535
This is SPI bus implementation for Microchip Azurite DPLL/PTP/SyncE
3636
devices.

drivers/net/ethernet/airoha/airoha_npu.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -579,6 +579,8 @@ static struct platform_driver airoha_npu_driver = {
579579
};
580580
module_platform_driver(airoha_npu_driver);
581581

582+
MODULE_FIRMWARE(NPU_EN7581_FIRMWARE_DATA);
583+
MODULE_FIRMWARE(NPU_EN7581_FIRMWARE_RV32);
582584
MODULE_LICENSE("GPL");
583585
MODULE_AUTHOR("Lorenzo Bianconi <[email protected]>");
584586
MODULE_DESCRIPTION("Airoha Network Processor Unit driver");

drivers/net/ethernet/airoha/airoha_ppe.c

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -508,9 +508,11 @@ static void airoha_ppe_foe_flow_stats_update(struct airoha_ppe *ppe,
508508
FIELD_PREP(AIROHA_FOE_IB2_NBQ, nbq);
509509
}
510510

511-
struct airoha_foe_entry *airoha_ppe_foe_get_entry(struct airoha_ppe *ppe,
512-
u32 hash)
511+
static struct airoha_foe_entry *
512+
airoha_ppe_foe_get_entry_locked(struct airoha_ppe *ppe, u32 hash)
513513
{
514+
lockdep_assert_held(&ppe_lock);
515+
514516
if (hash < PPE_SRAM_NUM_ENTRIES) {
515517
u32 *hwe = ppe->foe + hash * sizeof(struct airoha_foe_entry);
516518
struct airoha_eth *eth = ppe->eth;
@@ -537,6 +539,18 @@ struct airoha_foe_entry *airoha_ppe_foe_get_entry(struct airoha_ppe *ppe,
537539
return ppe->foe + hash * sizeof(struct airoha_foe_entry);
538540
}
539541

542+
struct airoha_foe_entry *airoha_ppe_foe_get_entry(struct airoha_ppe *ppe,
543+
u32 hash)
544+
{
545+
struct airoha_foe_entry *hwe;
546+
547+
spin_lock_bh(&ppe_lock);
548+
hwe = airoha_ppe_foe_get_entry_locked(ppe, hash);
549+
spin_unlock_bh(&ppe_lock);
550+
551+
return hwe;
552+
}
553+
540554
static bool airoha_ppe_foe_compare_entry(struct airoha_flow_table_entry *e,
541555
struct airoha_foe_entry *hwe)
542556
{
@@ -651,7 +665,7 @@ airoha_ppe_foe_commit_subflow_entry(struct airoha_ppe *ppe,
651665
struct airoha_flow_table_entry *f;
652666
int type;
653667

654-
hwe_p = airoha_ppe_foe_get_entry(ppe, hash);
668+
hwe_p = airoha_ppe_foe_get_entry_locked(ppe, hash);
655669
if (!hwe_p)
656670
return -EINVAL;
657671

@@ -703,7 +717,7 @@ static void airoha_ppe_foe_insert_entry(struct airoha_ppe *ppe,
703717

704718
spin_lock_bh(&ppe_lock);
705719

706-
hwe = airoha_ppe_foe_get_entry(ppe, hash);
720+
hwe = airoha_ppe_foe_get_entry_locked(ppe, hash);
707721
if (!hwe)
708722
goto unlock;
709723

@@ -818,7 +832,7 @@ airoha_ppe_foe_flow_l2_entry_update(struct airoha_ppe *ppe,
818832
u32 ib1, state;
819833
int idle;
820834

821-
hwe = airoha_ppe_foe_get_entry(ppe, iter->hash);
835+
hwe = airoha_ppe_foe_get_entry_locked(ppe, iter->hash);
822836
if (!hwe)
823837
continue;
824838

@@ -855,7 +869,7 @@ static void airoha_ppe_foe_flow_entry_update(struct airoha_ppe *ppe,
855869
if (e->hash == 0xffff)
856870
goto unlock;
857871

858-
hwe_p = airoha_ppe_foe_get_entry(ppe, e->hash);
872+
hwe_p = airoha_ppe_foe_get_entry_locked(ppe, e->hash);
859873
if (!hwe_p)
860874
goto unlock;
861875

drivers/net/ethernet/emulex/benet/be_cmds.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3856,8 +3856,8 @@ int be_cmd_set_mac_list(struct be_adapter *adapter, u8 *mac_array,
38563856
status = be_mcc_notify_wait(adapter);
38573857

38583858
err:
3859-
dma_free_coherent(&adapter->pdev->dev, cmd.size, cmd.va, cmd.dma);
38603859
spin_unlock_bh(&adapter->mcc_lock);
3860+
dma_free_coherent(&adapter->pdev->dev, cmd.size, cmd.va, cmd.dma);
38613861
return status;
38623862
}
38633863

drivers/net/ethernet/faraday/ftgmac100.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1750,16 +1750,17 @@ static int ftgmac100_setup_mdio(struct net_device *netdev)
17501750
static void ftgmac100_phy_disconnect(struct net_device *netdev)
17511751
{
17521752
struct ftgmac100 *priv = netdev_priv(netdev);
1753+
struct phy_device *phydev = netdev->phydev;
17531754

1754-
if (!netdev->phydev)
1755+
if (!phydev)
17551756
return;
17561757

1757-
phy_disconnect(netdev->phydev);
1758+
phy_disconnect(phydev);
17581759
if (of_phy_is_fixed_link(priv->dev->of_node))
17591760
of_phy_deregister_fixed_link(priv->dev->of_node);
17601761

17611762
if (priv->use_ncsi)
1762-
fixed_phy_unregister(netdev->phydev);
1763+
fixed_phy_unregister(phydev);
17631764
}
17641765

17651766
static void ftgmac100_destroy_mdio(struct net_device *netdev)

drivers/net/ethernet/freescale/dpaa/dpaa_ethtool.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -371,8 +371,10 @@ static int dpaa_get_ts_info(struct net_device *net_dev,
371371
of_node_put(ptp_node);
372372
}
373373

374-
if (ptp_dev)
374+
if (ptp_dev) {
375375
ptp = platform_get_drvdata(ptp_dev);
376+
put_device(&ptp_dev->dev);
377+
}
376378

377379
if (ptp)
378380
info->phc_index = ptp->phc_index;

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

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -829,19 +829,29 @@ static int enetc_pf_register_with_ierb(struct pci_dev *pdev)
829829
{
830830
struct platform_device *ierb_pdev;
831831
struct device_node *ierb_node;
832+
int ret;
832833

833834
ierb_node = of_find_compatible_node(NULL, NULL,
834835
"fsl,ls1028a-enetc-ierb");
835-
if (!ierb_node || !of_device_is_available(ierb_node))
836+
if (!ierb_node)
836837
return -ENODEV;
837838

839+
if (!of_device_is_available(ierb_node)) {
840+
of_node_put(ierb_node);
841+
return -ENODEV;
842+
}
843+
838844
ierb_pdev = of_find_device_by_node(ierb_node);
839845
of_node_put(ierb_node);
840846

841847
if (!ierb_pdev)
842848
return -EPROBE_DEFER;
843849

844-
return enetc_ierb_register_pf(ierb_pdev, pdev);
850+
ret = enetc_ierb_register_pf(ierb_pdev, pdev);
851+
852+
put_device(&ierb_pdev->dev);
853+
854+
return ret;
845855
}
846856

847857
static const struct enetc_si_ops enetc_psi_ops = {

0 commit comments

Comments
 (0)