generic: backport missing helper for phy interfaces
authorNick Hainke <vincent@systemli.org>
Fri, 26 May 2023 20:16:27 +0000 (22:16 +0200)
committerNick Hainke <vincent@systemli.org>
Fri, 26 May 2023 20:56:15 +0000 (22:56 +0200)
commit537624db39a92e6f388fe054b9d54951e40c0746
tree2c91d370fd97a101183bf78f6c3be4a58e22791a
parent2388b119de9279d7adaa525c7ba502fcae1fe187
generic: backport missing helper for phy interfaces

The function was defined before in the patch
"hack-5.15/795-backport-phylink_pcs-helpers.patch". However, the hack
did not move to 6.1. Instead of using the hack do the backport of
upstream accepted version.

Fixes errors in the form of:
  make[8]: Entering directory '/home/nick/openwrt/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/linux-6.1.29'
    CC      drivers/net/pcs/pcs-mtk-lynxi.o
  drivers/net/pcs/pcs-mtk-lynxi.c: In function 'mtk_pcs_lynxi_config':
  drivers/net/pcs/pcs-mtk-lynxi.c:160:30: error: implicit declaration of function 'phylink_get_link_timer_ns' [-Werror=implicit-function-declaration]
    160 |                 link_timer = phylink_get_link_timer_ns(interface);
        |                              ^~~~~~~~~~~~~~~~~~~~~~~~~
  cc1: all warnings being treated as errors

Fixes: fa79baf4a6e2 ("generic: copy backport, hack, pending patch and config from 5.15 to 6.1")
Signed-off-by: Nick Hainke <vincent@systemli.org>
target/linux/generic/backport-6.1/700-net-phylink-add-phylink_get_link_timer_ns-helper.patch [new file with mode: 0644]