]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
generic: net: phy: psb6970: fix missing-prototypes warnings 19174/head
authorShiji Yang <yangshiji66@outlook.com>
Thu, 8 May 2025 13:20:22 +0000 (21:20 +0800)
committerHauke Mehrtens <hauke@hauke-m.de>
Wed, 18 Jun 2025 18:23:20 +0000 (20:23 +0200)
Fix the following build warnings on 6.12 kernel:

drivers/net/phy/psb6970.c:426:12: error: no previous prototype for 'psb6970_init' [-Werror=missing-prototypes]
  426 | int __init psb6970_init(void)
      |            ^~~~~~~~~~~~
drivers/net/phy/psb6970.c:434:13: error: no previous prototype for 'psb6970_exit' [-Werror=missing-prototypes]
  434 | void __exit psb6970_exit(void)
      |             ^~~~~~~~~~~~

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/19174
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/generic/files/drivers/net/phy/psb6970.c

index 2af32df1727e0a7264e2a974007274e7b58b6495..e8b1b06f636532efaa452db5b95366b63af679b9 100644 (file)
@@ -423,7 +423,7 @@ static struct phy_driver psb6970_driver = {
        .read_status = &psb6970_read_status,
 };
 
-int __init psb6970_init(void)
+static int __init psb6970_init(void)
 {
        phy_register_fixup_for_id(PHY_ANY_ID, psb6970_fixup);
        return phy_driver_register(&psb6970_driver, THIS_MODULE);
@@ -431,7 +431,7 @@ int __init psb6970_init(void)
 
 module_init(psb6970_init);
 
-void __exit psb6970_exit(void)
+static void __exit psb6970_exit(void)
 {
        phy_driver_unregister(&psb6970_driver);
 }