0105-mt76-fix-build-with-kernel-3.18.patch 1.3 KB

12345678910111213141516171819202122232425262728293031323334
  1. From: Matthias Schiffer <mschiffer@universe-factory.net>
  2. Date: Thu, 30 Jun 2016 21:52:02 +0200
  3. Subject: mt76: fix build with kernel 3.18
  4. diff --git a/package/kernel/mac80211/patches/945-netdev_alloc_frag.patch b/package/kernel/mac80211/patches/945-netdev_alloc_frag.patch
  5. new file mode 100644
  6. index 0000000..ea389cd
  7. --- /dev/null
  8. +++ b/package/kernel/mac80211/patches/945-netdev_alloc_frag.patch
  9. @@ -0,0 +1,11 @@
  10. +--- a/backport-include/linux/netdevice.h
  11. ++++ b/backport-include/linux/netdevice.h
  12. +@@ -233,7 +233,7 @@ static inline void backport_unregister_n
  13. + #endif
  14. +
  15. + #if LINUX_VERSION_CODE < KERNEL_VERSION(3,19,0)
  16. +-#define napi_alloc_frag(fragsz) netdev_alloc_frag(fragsz)
  17. ++#define napi_alloc_frag netdev_alloc_frag
  18. + #endif
  19. +
  20. + /*
  21. diff --git a/package/kernel/mt76/Makefile b/package/kernel/mt76/Makefile
  22. index 0f832e4..801188f 100644
  23. --- a/package/kernel/mt76/Makefile
  24. +++ b/package/kernel/mt76/Makefile
  25. @@ -24,7 +24,7 @@ include $(INCLUDE_DIR)/package.mk
  26. define KernelPackage/mt76
  27. SUBMENU:=Wireless Drivers
  28. TITLE:=MediaTek MT76x2/MT7603 wireless driver
  29. - DEPENDS:=+kmod-mac80211 +@DRIVER_11N_SUPPORT @PCI_SUPPORT @!LINUX_3_18
  30. + DEPENDS:=+kmod-mac80211 +@DRIVER_11N_SUPPORT @PCI_SUPPORT
  31. FILES:=\
  32. $(PKG_BUILD_DIR)/mt76.ko \
  33. $(PKG_BUILD_DIR)/mt76x2e.ko \