net: phy: meson-gxl: implement meson_gxl_phy_resume()
Subsystems (4)
PATCH v2 1/1 net: phy: meson-gxl: implement meson_gxl_phy_resume()
After suspend and resume, the meson GXL internal PHY config needs to be initialized again or the carrier cannot be found.
--- drivers/net/phy/meson-gxl.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-)
drivers/net/phy/meson-gxl.c +13 -1
@@ -132,6 +132,18 @@ static int meson_gxl_config_init(struct phy_device *phydev)return 0 ; } +static int meson_gxl_phy_resume (struct phy_device *phydev) +{ +int ret; + +genphy_resume (); + ret =meson_gxl_config_init (phydev); +if (ret) +return ret; + +return 0 ; +} +/* This function is provided to cope with the possible failures of this phy * during aneg process. When aneg fails, the PHY reports that aneg is done * but the value found in MII_LPA is wrong:
@@ -196,7 +208,7 @@ static struct phy_driver meson_gxl_phy[] = { .config_intr = smsc_phy_config_intr, .handle_interrupt = smsc_phy_handle_interrupt, .suspend = genphy_suspend, - .resume = genphy_resume, + .resume = meson_gxl_phy_resume, .read_mmd = genphy_read_mmd_unsupported, .write_mmd = genphy_write_mmd_unsupported, }, {
Signature · 1 line
2.39.2
kernel test robot
build botkernel test robot noticed the following build errors:
Hi Da,
kernel test robot noticed the following build errors:
[auto build test ERROR on net-next/main]
[also build test ERROR on net/main linus/master v6.5-rc4 next-20230804] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Da-Xue/net-phy-meson-gxl-implement-meson_gxl_phy_resume/20230805-042033 base: net-next/main patch link: https://lore.kernel.org/r/20230804201903.1303713-1-da%40libre.computer patch subject: [PATCH] [PATCH v2] net: phy: meson-gxl: implement meson_gxl_phy_resume() config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20230806/[email protected]/config) compiler: gcc-12 (Debian 12.2.0-14) 12.2.0 reproduce: (https://download.01.org/0day-ci/archive/20230806/[email protected]/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
drivers/net/phy/meson-gxl.c: In function 'meson_gxl_phy_resume':
>> drivers/net/phy/meson-gxl.c:139:9: error: too few arguments to function 'genphy_resume'
139 | genphy_resume();
| ^~~~~~~~~~~~~
In file included from drivers/net/phy/meson-gxl.c:13:
include/linux/phy.h:1794:5: note: declared here
1794 | int genphy_resume(struct phy_device *phydev);
| ^~~~~~~~~~~~~vim +/genphy_resume +139 drivers/net/phy/meson-gxl.c
134
135 static int meson_gxl_phy_resume(struct phy_device *phydev)
136 {
137 int ret;
138
> 139 genphy_resume();
140 ret = meson_gxl_config_init(phydev);
141 if (ret)
142 return ret;
143
144 return 0;
145 }
146
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
Simon Horman
reviewerQuoted 4 lines · Da Xue
After suspend and resume, the meson GXL internal PHY config needs to be initialized again or the carrier cannot be found.
Signed-off-by Luke Lu <[email protected]>Reviewed-by Da Xue <[email protected]>
Hi Da Xue,
as the posted of this patch you need to provide your signed-off-by line.
From the way things are structured above it is unclear what Luke's role is. Was he the author of the patch? If so the body of the email, just above the patch description, should start with:
From: Luke Lu <[email protected]>
Quoted 9 lines
--- drivers/net/phy/meson-gxl.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-)drivers/net/phy/meson-gxl.c +0
-0
drivers/net/phy/meson-gxl.c static int meson_gxl_config_init(struct phy_device *phydev) · line 139
Quoted 8 lines
drivers/net/phy/meson-gxl.c +5
-0@@ -132,6 +132,18 @@ static int meson_gxl_config_init(struct phy_device *phydev)return 0 ; } +static int meson_gxl_phy_resume (struct phy_device *phydev) +{ +int ret; + +genphy_resume ();
This patch doesn't compile because the call to genphy_resume() has too few arguments.
Quoted 23 lines
drivers/net/phy/meson-gxl.c +8
-1+ ret =meson_gxl_config_init (phydev); +if (ret) +return ret; + +return 0 ; +} +/* This function is provided to cope with the possible failures of this phy * during aneg process. When aneg fails, the PHY reports that aneg is done * but the value found in MII_LPA is wrong: @@ -196,7 +208,7 @@ static struct phy_driver meson_gxl_phy[] = { .config_intr = smsc_phy_config_intr, .handle_interrupt = smsc_phy_handle_interrupt, .suspend = genphy_suspend, - .resume = genphy_resume, + .resume = meson_gxl_phy_resume, .read_mmd = genphy_read_mmd_unsupported, .write_mmd = genphy_write_mmd_unsupported, }, {Signature · 1 line
2.39.2