developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 1 | #@TYPE: Machine |
| 2 | #@NAME: mediatek filogic |
| 3 | #@NEEDED_BSPLAYERS: meta-filogic |
| 4 | #@DESCRIPTION: Machine configuration for running a RDK broadband on mediatek filogic |
| 5 | #@RDK_FLAVOR: rdkb |
| 6 | |
| 7 | DEFAULTTUNE ?= "cortexa53" |
| 8 | |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 9 | include conf/machine/include/soc-family.inc |
| 10 | |
| 11 | SOC_FAMILY = "mediatek" |
| 12 | |
developer | 880c829 | 2022-07-11 11:52:59 +0800 | [diff] [blame] | 13 | MACHINEOVERRIDES .="${@bb.utils.contains('DISTRO_FEATURES','switch_gsw_mode',':gsw','',d)}" |
developer | a84877f | 2023-01-18 09:21:27 +0800 | [diff] [blame] | 14 | MACHINEOVERRIDES .="${@bb.utils.contains('DISTRO_FEATURES','emmc',':emmc','',d)}" |
developer | 880c829 | 2022-07-11 11:52:59 +0800 | [diff] [blame] | 15 | |
developer | de7341a | 2023-10-17 17:59:50 +0800 | [diff] [blame] | 16 | KERNEL_DEVICETREE_mt7988_mt7988d_gsw = " \ |
| 17 | mediatek/mt7988d-gsw-10g-spim-nand.dtb \ |
| 18 | " |
| 19 | |
| 20 | KERNEL_DEVICETREE_mt7988_mt7988d = " \ |
| 21 | mediatek/mt7988d-dsa-10g-spim-nand.dtb \ |
| 22 | " |
| 23 | |
developer | 266c529 | 2022-10-18 16:32:50 +0800 | [diff] [blame] | 24 | KERNEL_DEVICETREE_mt7988_gsw = " \ |
| 25 | mediatek/mt7988a-gsw-10g-spim-nand.dtb \ |
| 26 | " |
| 27 | |
| 28 | KERNEL_DEVICETREE_mt7988 = " \ |
| 29 | mediatek/mt7988a-dsa-10g-spim-nand.dtb \ |
| 30 | " |
developer | 965804d | 2024-04-30 09:49:41 +0800 | [diff] [blame] | 31 | |
| 32 | KERNEL_DEVICETREE_mt7988_bpi4 = " \ |
| 33 | mediatek/mt7988a-bananapi-bpi-r4-nand.dtb \ |
| 34 | " |
developer | 87a78c3 | 2024-10-17 17:04:30 +0800 | [diff] [blame^] | 35 | KERNEL_DEVICETREE_mt7987 = " \ |
| 36 | mediatek/mt7987a-spim-nand.dtb \ |
| 37 | " |
developer | 266c529 | 2022-10-18 16:32:50 +0800 | [diff] [blame] | 38 | KERNEL_DEVICETREE_mt7986_gsw = " \ |
developer | 880c829 | 2022-07-11 11:52:59 +0800 | [diff] [blame] | 39 | mediatek/mt7986a-2500wan-gsw-spim-nand-rfb.dtb \ |
| 40 | mediatek/mt7986b-2500wan-gsw-spim-nand-rfb.dtb \ |
| 41 | " |
developer | 266c529 | 2022-10-18 16:32:50 +0800 | [diff] [blame] | 42 | KERNEL_DEVICETREE_mt7986 = " \ |
developer | 158c9ee | 2022-10-24 16:43:53 +0800 | [diff] [blame] | 43 | mediatek/mt7986a-2500wan-spim-nand-rfb.dtb \ |
| 44 | mediatek/mt7986b-2500wan-spim-nand-rfb.dtb \ |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 45 | " |
developer | a84877f | 2023-01-18 09:21:27 +0800 | [diff] [blame] | 46 | |
| 47 | KERNEL_DEVICETREE_mt7988_emmc = " \ |
| 48 | mediatek/mt7988a-dsa-10g-emmc.dtb \ |
| 49 | " |
| 50 | |
developer | 965804d | 2024-04-30 09:49:41 +0800 | [diff] [blame] | 51 | KERNEL_DEVICETREE_mt7988_bpi4_emmc = " \ |
| 52 | mediatek/mt7988a-bananapi-bpi-r4-emmc.dtb \ |
| 53 | " |
| 54 | |
developer | a84877f | 2023-01-18 09:21:27 +0800 | [diff] [blame] | 55 | KERNEL_DEVICETREE_mt7986_emmc = " \ |
| 56 | mediatek/mt7986a-emmc-rfb.dtb \ |
| 57 | mediatek/mt7986b-emmc-rfb.dtb \ |
| 58 | " |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 59 | KERNEL_IMAGETYPE = "fitImage" |
| 60 | KERNEL_CLASSES = "kernel-fitimage" |
developer | 5d62759 | 2022-12-02 10:26:07 +0800 | [diff] [blame] | 61 | KERNEL_CLASSES += "${@bb.utils.contains('DISTRO_FEATURES','secure_boot',' kernel_secure_boot-filogic','',d)}" |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 62 | |
| 63 | UBOOT_CONFIG = "mt7622_rfb_defconfig" |
| 64 | |
| 65 | UBOOT_ARCH = "arm64" |
| 66 | UBOOT_LOADADDRESS = "0x48080000" |
| 67 | UBOOT_ENTRYPOINT = "0x48080000" |
| 68 | MACHINE_EXTRA_RRECOMMENDS += "kernel-modules" |
| 69 | |
| 70 | TCLIBC = "glibc" |
| 71 | |
| 72 | MACHINEOVERRIDES .= ":broadband:filogic" |
| 73 | |
developer | 3d8c09d | 2022-07-11 18:14:15 +0800 | [diff] [blame] | 74 | IMAGE_FSTYPES ="${@bb.utils.contains('DISTRO_FEATURES','kernel_in_ubi',' squashfs-xz',' ubi',d)}" |
| 75 | IMAGE_FSTYPES_DEBUGFS = "" |
| 76 | IMAGE_GEN_DEBUGFS = "0" |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 77 | # Parameters for MT7986 RFB1 NAND (byte) |
| 78 | # NAND_LOG_BLOCK_SIZE = NAND_PHY_BLOCK_SIZE - 2 Pages |
| 79 | # NAND_LBLOCK_COUNT = NAND_PHY_BLOCK_COUNT - 53 |
| 80 | NAND_PAGE_SIZE = "4096" |
| 81 | NAND_PHY_BLOCK_SIZE = "262144" |
| 82 | NAND_LOG_BLOCK_SIZE = "253952" |
| 83 | NAND_PHY_BLOCK_COUNT = "2048" |
| 84 | NAND_LOG_BLOCK_COUNT = "1920" |
| 85 | |
| 86 | UBI_VOLNAME = "rootfs" |
| 87 | MKUBIFS_ARGS = "--min-io-size ${NAND_PAGE_SIZE} --leb-size ${NAND_LOG_BLOCK_SIZE} --max-leb-cnt ${NAND_LOG_BLOCK_COUNT}" |
| 88 | UBINIZE_ARGS = "--min-io-size ${NAND_PAGE_SIZE} --peb-size ${NAND_PHY_BLOCK_SIZE} --sub-page-size ${NAND_PAGE_SIZE}" |
| 89 | IMAGE_CLASSES += "image_types-mtk" |
| 90 | |
| 91 | SERIAL_CONSOLE ?= "115200 ttyS0" |
developer | 93e9720 | 2024-01-17 12:29:44 +0800 | [diff] [blame] | 92 | |
| 93 | |