generic.mk 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. define Device/FitImage
  2. KERNEL_SUFFIX := -uImage.itb
  3. KERNEL = kernel-bin | libdeflate-gzip | fit gzip $$(KDIR)/image-$$(DEVICE_DTS).dtb
  4. KERNEL_NAME := Image
  5. endef
  6. define Device/FitImageLzma
  7. KERNEL_SUFFIX := -uImage.itb
  8. KERNEL = kernel-bin | lzma | fit lzma $$(KDIR)/image-$$(DEVICE_DTS).dtb
  9. KERNEL_NAME := Image
  10. endef
  11. define Device/UbiFit
  12. KERNEL_IN_UBI := 1
  13. IMAGES := factory.ubi sysupgrade.bin
  14. IMAGE/factory.ubi := append-ubi
  15. IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
  16. endef
  17. define Device/buffalo_wxr-5950ax12
  18. $(call Device/FitImage)
  19. DEVICE_VENDOR := Buffalo
  20. DEVICE_MODEL := WXR-5950AX12
  21. BLOCKSIZE := 128k
  22. PAGESIZE := 2048
  23. DEVICE_DTS_CONFIG := config@hk01
  24. SOC := ipq8074
  25. IMAGES := sysupgrade.bin
  26. IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
  27. DEVICE_PACKAGES := ipq-wifi-buffalo_wxr-5950ax12
  28. endef
  29. TARGET_DEVICES += buffalo_wxr-5950ax12
  30. define Device/compex_wpq873
  31. $(call Device/FitImage)
  32. $(call Device/UbiFit)
  33. DEVICE_VENDOR := Compex
  34. DEVICE_MODEL := WPQ873
  35. BLOCKSIZE := 128k
  36. PAGESIZE := 2048
  37. DEVICE_DTS_CONFIG := [email protected]
  38. SOC := ipq8072
  39. IMAGE/factory.ubi := append-ubi | qsdk-ipq-factory-nand
  40. endef
  41. TARGET_DEVICES += compex_wpq873
  42. define Device/dynalink_dl-wrx36
  43. $(call Device/FitImage)
  44. $(call Device/UbiFit)
  45. DEVICE_VENDOR := Dynalink
  46. DEVICE_MODEL := DL-WRX36
  47. BLOCKSIZE := 128k
  48. PAGESIZE := 2048
  49. DEVICE_DTS_CONFIG := config@rt5010w-d350-rev0
  50. SOC := ipq8072
  51. DEVICE_PACKAGES := ipq-wifi-dynalink_dl-wrx36
  52. endef
  53. TARGET_DEVICES += dynalink_dl-wrx36
  54. define Device/edgecore_eap102
  55. $(call Device/FitImage)
  56. $(call Device/UbiFit)
  57. DEVICE_VENDOR := Edgecore
  58. DEVICE_MODEL := EAP102
  59. BLOCKSIZE := 128k
  60. PAGESIZE := 2048
  61. DEVICE_DTS_CONFIG := config@ac02
  62. SOC := ipq8071
  63. DEVICE_PACKAGES := ipq-wifi-edgecore_eap102
  64. IMAGE/factory.ubi := append-ubi | qsdk-ipq-factory-nand
  65. endef
  66. TARGET_DEVICES += edgecore_eap102
  67. define Device/edimax_cax1800
  68. $(call Device/FitImage)
  69. $(call Device/UbiFit)
  70. DEVICE_VENDOR := Edimax
  71. DEVICE_MODEL := CAX1800
  72. BLOCKSIZE := 128k
  73. PAGESIZE := 2048
  74. DEVICE_DTS_CONFIG := config@ac03
  75. SOC := ipq8070
  76. DEVICE_PACKAGES := ipq-wifi-edimax_cax1800
  77. endef
  78. TARGET_DEVICES += edimax_cax1800
  79. define Device/netgear_wax218
  80. $(call Device/FitImage)
  81. $(call Device/UbiFit)
  82. ARTIFACTS := web-ui-factory.fit
  83. DEVICE_VENDOR := Netgear
  84. DEVICE_MODEL := WAX218
  85. DEVICE_DTS_CONFIG := config@hk07
  86. BLOCKSIZE := 128k
  87. PAGESIZE := 2048
  88. SOC := ipq8072
  89. ARTIFACT/web-ui-factory.fit := append-image initramfs-uImage.itb | \
  90. ubinize-kernel | qsdk-ipq-factory-nand
  91. DEVICE_PACKAGES := kmod-spi-gpio kmod-spi-bitbang kmod-gpio-nxp-74hc164 \
  92. ipq-wifi-netgear_wax218
  93. endef
  94. TARGET_DEVICES += netgear_wax218
  95. define Device/qnap_301w
  96. $(call Device/FitImage)
  97. DEVICE_VENDOR := QNAP
  98. DEVICE_MODEL := 301w
  99. DEVICE_DTS_CONFIG := config@hk01
  100. KERNEL_SIZE := 16384k
  101. BLOCKSIZE := 512k
  102. SOC := ipq8072
  103. IMAGES += factory.bin sysupgrade.bin
  104. IMAGE/factory.bin := append-rootfs | pad-rootfs | pad-to 64k
  105. IMAGE/sysupgrade.bin/squashfs := append-rootfs | pad-to 64k | sysupgrade-tar rootfs=$$$$@ | append-metadata
  106. DEVICE_PACKAGES := ipq-wifi-qnap_301w e2fsprogs kmod-fs-ext4 losetup
  107. endef
  108. TARGET_DEVICES += qnap_301w
  109. define Device/redmi_ax6
  110. $(call Device/xiaomi_ax3600)
  111. DEVICE_VENDOR := Redmi
  112. DEVICE_MODEL := AX6
  113. DEVICE_PACKAGES := ipq-wifi-redmi_ax6
  114. endef
  115. TARGET_DEVICES += redmi_ax6
  116. define Device/xiaomi_ax3600
  117. $(call Device/FitImage)
  118. $(call Device/UbiFit)
  119. DEVICE_VENDOR := Xiaomi
  120. DEVICE_MODEL := AX3600
  121. BLOCKSIZE := 128k
  122. PAGESIZE := 2048
  123. DEVICE_DTS_CONFIG := config@ac04
  124. SOC := ipq8071
  125. KERNEL_SIZE := 36608k
  126. DEVICE_PACKAGES := ipq-wifi-xiaomi_ax3600 kmod-ath10k-ct-smallbuffers ath10k-firmware-qca9887-ct
  127. ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),)
  128. ARTIFACTS := initramfs-factory.ubi
  129. ARTIFACT/initramfs-factory.ubi := append-image-stage initramfs-uImage.itb | ubinize-kernel
  130. endif
  131. endef
  132. TARGET_DEVICES += xiaomi_ax3600
  133. define Device/xiaomi_ax9000
  134. $(call Device/FitImage)
  135. $(call Device/UbiFit)
  136. DEVICE_VENDOR := Xiaomi
  137. DEVICE_MODEL := AX9000
  138. BLOCKSIZE := 128k
  139. PAGESIZE := 2048
  140. DEVICE_DTS_CONFIG := config@hk14
  141. SOC := ipq8072
  142. KERNEL_SIZE := 57344k
  143. DEVICE_PACKAGES := ipq-wifi-xiaomi_ax9000 kmod-ath11k-pci ath11k-firmware-qcn9074 \
  144. kmod-ath10k-ct ath10k-firmware-qca9887-ct
  145. ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),)
  146. ARTIFACTS := initramfs-factory.ubi
  147. ARTIFACT/initramfs-factory.ubi := append-image-stage initramfs-uImage.itb | ubinize-kernel
  148. endif
  149. endef
  150. TARGET_DEVICES += xiaomi_ax9000
  151. define Device/zyxel_nbg7815
  152. $(call Device/FitImage)
  153. DEVICE_VENDOR := ZYXEL
  154. DEVICE_MODEL := NBG7815
  155. DEVICE_DTS_CONFIG := config@nbg7815
  156. BLOCKSIZE := 128k
  157. PAGESIZE := 2048
  158. SOC := ipq8074
  159. IMAGES += factory.bin sysupgrade.bin
  160. IMAGE/factory.bin := append-rootfs | pad-rootfs | pad-to 64k
  161. IMAGE/sysupgrade.bin/squashfs := append-rootfs | pad-to 64k | sysupgrade-tar rootfs=$$$$@ | append-metadata
  162. DEVICE_PACKAGES := ipq-wifi-zyxel_nbg7815 kmod-ath11k-pci e2fsprogs kmod-fs-ext4 losetup \
  163. kmod-hwmon-tmp103 kmod-bluetooth
  164. endef
  165. TARGET_DEVICES += zyxel_nbg7815