-
Notifications
You must be signed in to change notification settings - Fork 19.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ramips: fix mt7621 kernel compilation
The OF LED configuration patch fails on MT7621, as the necessary headers were only included for the mediatek subtarget with an additional patch. Fixes: 242fe86 ("generic: add hack for MT753x LED configuration") Signed-off-by: David Bauer <[email protected]>
- Loading branch information
1 parent
b8fe2ac
commit fbaaae5
Showing
2 changed files
with
14 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,13 @@ Signed-off-by: David Bauer <[email protected]> | |
|
||
--- a/drivers/net/phy/mediatek-ge.c | ||
+++ b/drivers/net/phy/mediatek-ge.c | ||
@@ -53,6 +53,36 @@ static int mt7530_phy_config_init(struct | ||
@@ -1,4 +1,5 @@ | ||
// SPDX-License-Identifier: GPL-2.0+ | ||
+#include <linux/of.h> | ||
#include <linux/bitfield.h> | ||
#include <linux/module.h> | ||
#include <linux/phy.h> | ||
@@ -53,6 +54,36 @@ static int mt7530_phy_config_init(struct | ||
return 0; | ||
} | ||
|
||
|
@@ -54,7 +60,7 @@ Signed-off-by: David Bauer <[email protected]> | |
static int mt7531_phy_config_init(struct phy_device *phydev) | ||
{ | ||
mtk_gephy_config_init(phydev); | ||
@@ -65,6 +95,9 @@ static int mt7531_phy_config_init(struct | ||
@@ -65,6 +96,9 @@ static int mt7531_phy_config_init(struct | ||
phy_write_mmd(phydev, MDIO_MMD_VEND1, 0x13, 0x404); | ||
phy_write_mmd(phydev, MDIO_MMD_VEND1, 0x14, 0x404); | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -55,8 +55,8 @@ Signed-off-by: Daniel Golle <[email protected]> | |
help | ||
--- a/drivers/net/phy/mediatek-ge.c | ||
+++ b/drivers/net/phy/mediatek-ge.c | ||
@@ -1,6 +1,9 @@ | ||
// SPDX-License-Identifier: GPL-2.0+ | ||
@@ -2,6 +2,9 @@ | ||
#include <linux/of.h> | ||
#include <linux/bitfield.h> | ||
#include <linux/module.h> | ||
+#include <linux/nvmem-consumer.h> | ||
|
@@ -65,7 +65,7 @@ Signed-off-by: Daniel Golle <[email protected]> | |
#include <linux/phy.h> | ||
|
||
#define MTK_EXT_PAGE_ACCESS 0x1f | ||
@@ -11,6 +14,275 @@ | ||
@@ -12,6 +15,275 @@ | ||
#define MTK_PHY_PAGE_EXTENDED_2A30 0x2a30 | ||
#define MTK_PHY_PAGE_EXTENDED_52B5 0x52b5 | ||
|
||
|
@@ -341,7 +341,7 @@ Signed-off-by: Daniel Golle <[email protected]> | |
static int mtk_gephy_read_page(struct phy_device *phydev) | ||
{ | ||
return __phy_read(phydev, MTK_EXT_PAGE_ACCESS); | ||
@@ -68,6 +340,1059 @@ static int mt7531_phy_config_init(struct | ||
@@ -102,6 +374,1059 @@ static int mt7531_phy_config_init(struct | ||
return 0; | ||
} | ||
|
||
|
@@ -1401,7 +1401,7 @@ Signed-off-by: Daniel Golle <[email protected]> | |
static struct phy_driver mtk_gephy_driver[] = { | ||
{ | ||
PHY_ID_MATCH_EXACT(0x03a29412), | ||
@@ -97,6 +1422,30 @@ static struct phy_driver mtk_gephy_drive | ||
@@ -131,6 +1456,30 @@ static struct phy_driver mtk_gephy_drive | ||
.read_page = mtk_gephy_read_page, | ||
.write_page = mtk_gephy_write_page, | ||
}, | ||
|
@@ -1432,7 +1432,7 @@ Signed-off-by: Daniel Golle <[email protected]> | |
}; | ||
|
||
module_phy_driver(mtk_gephy_driver); | ||
@@ -107,6 +1456,8 @@ static struct mdio_device_id __maybe_unu | ||
@@ -141,6 +1490,8 @@ static struct mdio_device_id __maybe_unu | ||
}; | ||
|
||
MODULE_DESCRIPTION("MediaTek Gigabit Ethernet PHY driver"); | ||
|