developer | 1bfe18b | 2022-07-13 16:05:35 +0800 | [diff] [blame] | 1 | diff --git a/package/kernel/mt76/Makefile b/package/kernel/mt76/Makefile |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 2 | index 628ea79..9bf5d27 100644 |
developer | 1bfe18b | 2022-07-13 16:05:35 +0800 | [diff] [blame] | 3 | --- a/package/kernel/mt76/Makefile |
| 4 | +++ b/package/kernel/mt76/Makefile |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 5 | @@ -220,7 +220,7 @@ endef |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 6 | |
| 7 | define KernelPackage/mt7915e |
| 8 | $(KernelPackage/mt76-default) |
| 9 | - TITLE:=MediaTek MT7915e wireless driver |
| 10 | + TITLE:=MediaTek MT7915e/MT7986/MT7916 wireless driver |
| 11 | DEPENDS+=@PCI_SUPPORT +kmod-mt7615-common +kmod-hwmon-core +kmod-thermal +@DRIVER_11AX_SUPPORT +@KERNEL_RELAY |
| 12 | FILES:= $(PKG_BUILD_DIR)/mt7915/mt7915e.ko |
| 13 | AUTOLOAD:=$(call AutoProbe,mt7915e) |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 14 | @@ -228,10 +228,26 @@ endef |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 15 | |
| 16 | define KernelPackage/mt7986-firmware |
| 17 | $(KernelPackage/mt76-default) |
| 18 | - DEPENDS:=@TARGET_mediatek_filogic |
| 19 | + DEPENDS:=+@TARGET_mediatek_mt7986 |
| 20 | TITLE:=MediaTek MT7986 firmware |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 21 | endef |
| 22 | |
developer | 7800b8d | 2022-06-23 22:15:56 +0800 | [diff] [blame] | 23 | +define KernelPackage/besra |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 24 | + $(KernelPackage/mt76-default) |
| 25 | + TITLE:=MediaTek MT7902/MT7990 wireless driver |
developer | 3ef2333 | 2022-06-10 11:48:11 +0800 | [diff] [blame] | 26 | + DEPENDS+=@PCI_SUPPORT +kmod-mt76-core +kmod-mt76-connac +kmod-hwmon-core +kmod-thermal +@DRIVER_11AX_SUPPORT +@DRIVER_11BE_SUPPORT |
developer | 7800b8d | 2022-06-23 22:15:56 +0800 | [diff] [blame] | 27 | + FILES:= $(PKG_BUILD_DIR)/besra/besra.ko |
| 28 | + AUTOLOAD:=$(call AutoProbe,besra) |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 29 | +endef |
| 30 | + |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 31 | +define KernelPackage/mt7996e |
| 32 | + $(KernelPackage/mt76-default) |
| 33 | + TITLE:=MediaTek MT7996/MT7995/MT7919 wireless driver |
developer | 4fb9904 | 2022-11-08 00:25:27 +0800 | [diff] [blame] | 34 | + DEPENDS+=@PCI_SUPPORT +kmod-mt76-core +kmod-mt76-connac +kmod-hwmon-core +kmod-thermal +@DRIVER_11AX_SUPPORT +@DRIVER_11BE_SUPPORT |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 35 | + FILES:= $(PKG_BUILD_DIR)/mt7996/mt7996e.ko |
| 36 | + AUTOLOAD:=$(call AutoProbe,mt7996e) |
| 37 | +endef |
| 38 | + |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 39 | define KernelPackage/mt7921-common |
| 40 | $(KernelPackage/mt76-default) |
| 41 | TITLE:=MediaTek MT7615 wireless driver common code |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 42 | @@ -287,6 +303,11 @@ ifdef CONFIG_PACKAGE_MAC80211_MESH |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 43 | NOSTDINC_FLAGS += -DCONFIG_MAC80211_MESH |
| 44 | endif |
| 45 | |
| 46 | +ifdef CONFIG_PACKAGE_MAC80211_DEBUGFS |
| 47 | + NOSTDINC_FLAGS += -DCONFIG_MAC80211_DEBUGFS |
| 48 | + PKG_MAKE_FLAGS += CONFIG_MAC80211_DEBUGFS=y |
| 49 | +endif |
| 50 | + |
| 51 | ifdef CONFIG_PACKAGE_CFG80211_TESTMODE |
| 52 | NOSTDINC_FLAGS += -DCONFIG_NL80211_TESTMODE |
| 53 | PKG_MAKE_FLAGS += CONFIG_NL80211_TESTMODE=y |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 54 | @@ -349,11 +370,17 @@ ifdef CONFIG_PACKAGE_kmod-mt7663u |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 55 | endif |
| 56 | ifdef CONFIG_PACKAGE_kmod-mt7915e |
| 57 | PKG_MAKE_FLAGS += CONFIG_MT7915E=m |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 58 | - ifdef CONFIG_TARGET_mediatek_filogic |
| 59 | + ifdef CONFIG_TARGET_mediatek_mt7986 |
| 60 | PKG_MAKE_FLAGS += CONFIG_MT7986_WMAC=y |
| 61 | NOSTDINC_FLAGS += -DCONFIG_MT7986_WMAC |
| 62 | endif |
| 63 | endif |
developer | 7800b8d | 2022-06-23 22:15:56 +0800 | [diff] [blame] | 64 | +ifdef CONFIG_PACKAGE_kmod-besra |
| 65 | + PKG_MAKE_FLAGS += CONFIG_BESRA=m |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 66 | +endif |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 67 | +ifdef CONFIG_PACKAGE_kmod-mt7996e |
| 68 | + PKG_MAKE_FLAGS += CONFIG_MT7996E=m |
| 69 | +endif |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 70 | ifdef CONFIG_PACKAGE_kmod-mt7921-common |
| 71 | PKG_MAKE_FLAGS += CONFIG_MT7921_COMMON=m |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 72 | endif |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 73 | @@ -457,6 +484,12 @@ define KernelPackage/mt7915e/install |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 74 | $(PKG_BUILD_DIR)/firmware/mt7915_wa.bin \ |
| 75 | $(PKG_BUILD_DIR)/firmware/mt7915_wm.bin \ |
| 76 | $(PKG_BUILD_DIR)/firmware/mt7915_rom_patch.bin \ |
| 77 | + $(PKG_BUILD_DIR)/firmware/mt7916_wa.bin \ |
| 78 | + $(PKG_BUILD_DIR)/firmware/mt7916_wm.bin \ |
| 79 | + $(PKG_BUILD_DIR)/firmware/mt7916_rom_patch.bin \ |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 80 | + $(PKG_BUILD_DIR)/firmware/mt7916_eeprom.bin \ |
| 81 | + $(PKG_BUILD_DIR)/firmware/mt7915_eeprom.bin \ |
| 82 | + $(PKG_BUILD_DIR)/firmware/mt7915_eeprom_dbdc.bin \ |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 83 | $(1)/lib/firmware/mediatek |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 84 | endef |
| 85 | |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 86 | @@ -470,9 +503,52 @@ define KernelPackage/mt7986-firmware/install |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 87 | $(PKG_BUILD_DIR)/firmware/mt7986_rom_patch.bin \ |
| 88 | $(PKG_BUILD_DIR)/firmware/mt7986_eeprom_mt7975_dual.bin \ |
| 89 | $(PKG_BUILD_DIR)/firmware/mt7986_eeprom_mt7976_dual.bin \ |
| 90 | + $(PKG_BUILD_DIR)/firmware/mt7986_eeprom_mt7975.bin \ |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 91 | + $(PKG_BUILD_DIR)/firmware/mt7986_eeprom_mt7976.bin \ |
| 92 | + $(PKG_BUILD_DIR)/firmware/mt7986_eeprom_mt7976_dbdc.bin \ |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 93 | $(1)/lib/firmware/mediatek |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 94 | +ifdef CONFIG_NET_MEDIATEK_SOC_WED |
| 95 | + cp \ |
| 96 | + $(PKG_BUILD_DIR)/firmware/mt7986_wo_0.bin \ |
| 97 | + $(PKG_BUILD_DIR)/firmware/mt7986_wo_1.bin \ |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 98 | + $(1)/lib/firmware/mediatek |
developer | e786110 | 2022-04-04 18:16:16 +0800 | [diff] [blame] | 99 | +endif |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 100 | endef |
| 101 | |
developer | 7800b8d | 2022-06-23 22:15:56 +0800 | [diff] [blame] | 102 | +ifdef CONFIG_PACKAGE_kmod-besra |
| 103 | +define KernelPackage/besra/install |
developer | 13601d9 | 2022-11-08 22:17:56 +0800 | [diff] [blame] | 104 | + $(INSTALL_DIR) $(1)/lib/firmware/mediatek/mt7996 |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 105 | + cp \ |
developer | 13601d9 | 2022-11-08 22:17:56 +0800 | [diff] [blame] | 106 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wa.bin \ |
| 107 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wm.bin \ |
| 108 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_rom_patch.bin \ |
| 109 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wf_rom.bin \ |
| 110 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wf_rom_sram.bin \ |
| 111 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_eeprom.bin \ |
| 112 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wm_7977.bin \ |
| 113 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wf_rom_7977.bin \ |
| 114 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_wf_rom_sram_7977.bin \ |
| 115 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7902_eeprom_7977.bin \ |
| 116 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_wa.bin \ |
| 117 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_wm.bin \ |
| 118 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_rom_patch.bin \ |
| 119 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_eeprom.bin \ |
| 120 | + $(1)/lib/firmware/mediatek/mt7996 |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 121 | +endef |
| 122 | +endif |
| 123 | + |
| 124 | +ifdef CONFIG_PACKAGE_kmod-mt7996e |
| 125 | +define KernelPackage/mt7996e/install |
developer | 13601d9 | 2022-11-08 22:17:56 +0800 | [diff] [blame] | 126 | + $(INSTALL_DIR) $(1)/lib/firmware/mediatek/mt7996 |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 127 | + cp \ |
developer | 13601d9 | 2022-11-08 22:17:56 +0800 | [diff] [blame] | 128 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_wa.bin \ |
| 129 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_wm.bin \ |
| 130 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_rom_patch.bin \ |
| 131 | + $(PKG_BUILD_DIR)/firmware/mt7996/mt7996_eeprom.bin \ |
| 132 | + $(1)/lib/firmware/mediatek/mt7996 |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 133 | +endef |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 134 | +endif |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 135 | + |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 136 | define KernelPackage/mt7921e/install |
| 137 | $(INSTALL_DIR) $(1)/lib/firmware/mediatek |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 138 | cp \ |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 139 | @@ -513,5 +589,7 @@ $(eval $(call KernelPackage,mt7921-common)) |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 140 | $(eval $(call KernelPackage,mt7921u)) |
| 141 | $(eval $(call KernelPackage,mt7921s)) |
| 142 | $(eval $(call KernelPackage,mt7921e)) |
developer | 782053a | 2022-10-24 17:40:58 +0800 | [diff] [blame] | 143 | +$(eval $(call KernelPackage,mt7996e)) |
developer | 7800b8d | 2022-06-23 22:15:56 +0800 | [diff] [blame] | 144 | +$(eval $(call KernelPackage,besra)) |
developer | b11a539 | 2022-03-31 00:34:47 +0800 | [diff] [blame] | 145 | $(eval $(call KernelPackage,mt76)) |
| 146 | $(eval $(call BuildPackage,mt76-test)) |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 147 | -- |
developer | ad3184f | 2022-08-30 13:15:07 +0800 | [diff] [blame] | 148 | 2.36.1 |
developer | 2cf5f9a | 2022-03-25 02:46:17 +0800 | [diff] [blame] | 149 | |