]> www.infradead.org Git - users/hch/misc.git/commitdiff
net: dsa: mv88e6xxx: move mv88e6xxx_hwtstamp_work() prototype
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Tue, 16 Sep 2025 20:35:08 +0000 (21:35 +0100)
committerJakub Kicinski <kuba@kernel.org>
Thu, 18 Sep 2025 01:21:12 +0000 (18:21 -0700)
Since mv88e6xxx_hwtstamp_work() is defined in hwtstamp.c, its prototype
should be in hwtstamp.h, so move it there. Remove it's redundant stub
definition, as both hwtstamp.c (the function provider) and ptp.c (the
consumer) are both dependent on the same config symbol.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Reviewed-by: Vladimir Oltean <olteanv@gmail.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/dsa/mv88e6xxx/hwtstamp.h
drivers/net/dsa/mv88e6xxx/ptp.h

index 22e4acc957f0ba713def36d40ff087676e206648..c359821d5a6eaa0ae1a3fd2ff8a0292074e86178 100644 (file)
@@ -124,6 +124,7 @@ void mv88e6xxx_port_txtstamp(struct dsa_switch *ds, int port,
 int mv88e6xxx_get_ts_info(struct dsa_switch *ds, int port,
                          struct kernel_ethtool_ts_info *info);
 
+long mv88e6xxx_hwtstamp_work(struct ptp_clock_info *ptp);
 int mv88e6xxx_hwtstamp_setup(struct mv88e6xxx_chip *chip);
 void mv88e6xxx_hwtstamp_free(struct mv88e6xxx_chip *chip);
 int mv88e6352_hwtstamp_port_enable(struct mv88e6xxx_chip *chip, int port);
index 529ac5d0907b83f699c62860f0c47402032510ad..95bdddb0bf39f86234fbb5ccd136acbfc03e399c 100644 (file)
@@ -66,7 +66,6 @@
 
 #ifdef CONFIG_NET_DSA_MV88E6XXX_PTP
 
-long mv88e6xxx_hwtstamp_work(struct ptp_clock_info *ptp);
 int mv88e6xxx_ptp_setup(struct mv88e6xxx_chip *chip);
 void mv88e6xxx_ptp_free(struct mv88e6xxx_chip *chip);
 
@@ -79,11 +78,6 @@ extern const struct mv88e6xxx_ptp_ops mv88e6390_ptp_ops;
 
 #else /* !CONFIG_NET_DSA_MV88E6XXX_PTP */
 
-static inline long mv88e6xxx_hwtstamp_work(struct ptp_clock_info *ptp)
-{
-       return -1;
-}
-
 static inline int mv88e6xxx_ptp_setup(struct mv88e6xxx_chip *chip)
 {
        return 0;