From f68568c2ab83d792568917d38f8939b600ea6e9a Mon Sep 17 00:00:00 2001 From: Tianling Shen Date: Thu, 10 Aug 2023 12:47:06 +0800 Subject: [PATCH] r8152: fix build with kernel 5.4.252 Signed-off-by: Tianling Shen --- .../r8152/patches/010-kernel-5.4.252.patch | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 package/kernel/r8152/patches/010-kernel-5.4.252.patch diff --git a/package/kernel/r8152/patches/010-kernel-5.4.252.patch b/package/kernel/r8152/patches/010-kernel-5.4.252.patch new file mode 100644 index 0000000000..e7244dea02 --- /dev/null +++ b/package/kernel/r8152/patches/010-kernel-5.4.252.patch @@ -0,0 +1,22 @@ +--- a/compatibility.h ++++ b/compatibility.h +@@ -21,7 +21,6 @@ + #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,0) */ + #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,31) */ + +-#if LINUX_VERSION_CODE < KERNEL_VERSION(5,15,0) + #if LINUX_VERSION_CODE < KERNEL_VERSION(5,12,0) + #define PHY_MAC_INTERRUPT PHY_IGNORE_INTERRUPT + #if LINUX_VERSION_CODE < KERNEL_VERSION(5,9,0) +@@ -608,11 +607,6 @@ + #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(5,8,0) */ + #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(5,9,0) */ + #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(5,12,0) */ +- static inline void eth_hw_addr_set(struct net_device *dev, const u8 *addr) +- { +- memcpy(dev->dev_addr, addr, 6); +- } +-#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(5,15,0) */ + + #ifndef FALSE + #define TRUE 1