0
0
mirror of https://git.openwrt.org/openwrt/openwrt.git synced 2025-07-17 16:44:45 +00:00
Files
openwrt/target/linux/generic/pending-6.6/703-phy-add-detach-callback-to-struct-phy_driver.patch
John Audia 836a4cc6d3 kernel: bump 6.6 to 6.6.94
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.94

Removed upstreamed:
	generic/backport-6.6/421-01-v6.16-spi-bcm63xx-spi-fix-shared-reset.patch[1]
	generic/backport-6.6/421-02-v6.16-spi-bcm63xx-hsspi-fix-shared-reset.patch[2]
	generic/backport-6.6/725-01-v6.16-net-dsa-tag_brcm-legacy-fix-pskb_may_pull-length.patch[3]
	mvebu/patches-6.6/0001-v6.16-pinctrl-armada-37xx-use-correct-OUTPUT_VAL-register-.patch[4]
	mvebu/patches-6.6/0002-v6.16-pinctrl-armada-37xx-set-GPIO-output-value-before-set.patch[5]

Added new back-port:
	generic/backport-6.6/001-powerpc-kernel-Fix-pcc_save_regs-inclusion.patch[6]
All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.94&id=29abb7fc82443bee273ba4623ce319bf7ba1d43d
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.94&id=59d5f3134b5c265df233b7f385bbe718191411be
3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.94&id=2e02edb66427e3b8752e1f3dd3cfc1bef3f2357b
4. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.94&id=39ed85ae485d991ffb24d25629a679c0b22e2d8f
5. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.94&id=8f0f45a312151a52aae920a091ea4b454ac97caf
6. Addresses a build failure for pcc

Build system: x86/64
Build-tested: flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3, x86/64
Run-tested: flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3, x86/64

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/19183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-06-21 13:54:17 +02:00

39 lines
1.1 KiB
Diff

From: Gabor Juhos <juhosg@openwrt.org>
Subject: generic: add detach callback to struct phy_driver
lede-commit: fe61fc2d7d0b3fb348b502f68f98243b3ddf5867
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
---
drivers/net/phy/phy_device.c | 3 +++
include/linux/phy.h | 6 ++++++
2 files changed, 9 insertions(+)
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
@@ -1912,6 +1912,9 @@ void phy_detach(struct phy_device *phyde
phydev->devlink = NULL;
}
+ if (phydev->drv && phydev->drv->detach)
+ phydev->drv->detach(phydev);
+
if (phydev->sysfs_links) {
if (dev)
sysfs_remove_link(&dev->dev.kobj, "phydev");
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -977,6 +977,12 @@ struct phy_driver {
/** @handle_interrupt: Override default interrupt handling */
irqreturn_t (*handle_interrupt)(struct phy_device *phydev);
+ /*
+ * Called before an ethernet device is detached
+ * from the PHY.
+ */
+ void (*detach)(struct phy_device *phydev);
+
/** @remove: Clears up any memory if needed */
void (*remove)(struct phy_device *phydev);