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 | |
| 9 | require conf/machine/include/tune-cortexa53.inc |
| 10 | include conf/machine/include/soc-family.inc |
| 11 | |
| 12 | SOC_FAMILY = "mediatek" |
| 13 | |
developer | 880c829 | 2022-07-11 11:52:59 +0800 | [diff] [blame] | 14 | MACHINEOVERRIDES .="${@bb.utils.contains('DISTRO_FEATURES','switch_gsw_mode',':gsw','',d)}" |
developer | a84877f | 2023-01-18 09:21:27 +0800 | [diff] [blame^] | 15 | MACHINEOVERRIDES .="${@bb.utils.contains('DISTRO_FEATURES','emmc',':emmc','',d)}" |
developer | 880c829 | 2022-07-11 11:52:59 +0800 | [diff] [blame] | 16 | |
developer | 266c529 | 2022-10-18 16:32:50 +0800 | [diff] [blame] | 17 | KERNEL_DEVICETREE_mt7988_gsw = " \ |
| 18 | mediatek/mt7988a-gsw-10g-spim-nand.dtb \ |
| 19 | " |
| 20 | |
| 21 | KERNEL_DEVICETREE_mt7988 = " \ |
| 22 | mediatek/mt7988a-dsa-10g-spim-nand.dtb \ |
| 23 | " |
| 24 | KERNEL_DEVICETREE_mt7986_gsw = " \ |
developer | 880c829 | 2022-07-11 11:52:59 +0800 | [diff] [blame] | 25 | mediatek/mt7986a-2500wan-gsw-spim-nand-rfb.dtb \ |
| 26 | mediatek/mt7986b-2500wan-gsw-spim-nand-rfb.dtb \ |
| 27 | " |
developer | 266c529 | 2022-10-18 16:32:50 +0800 | [diff] [blame] | 28 | KERNEL_DEVICETREE_mt7986 = " \ |
developer | 158c9ee | 2022-10-24 16:43:53 +0800 | [diff] [blame] | 29 | mediatek/mt7986a-2500wan-spim-nand-rfb.dtb \ |
| 30 | mediatek/mt7986b-2500wan-spim-nand-rfb.dtb \ |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 31 | " |
developer | a84877f | 2023-01-18 09:21:27 +0800 | [diff] [blame^] | 32 | |
| 33 | KERNEL_DEVICETREE_mt7988_emmc = " \ |
| 34 | mediatek/mt7988a-dsa-10g-emmc.dtb \ |
| 35 | " |
| 36 | |
| 37 | KERNEL_DEVICETREE_mt7986_emmc = " \ |
| 38 | mediatek/mt7986a-emmc-rfb.dtb \ |
| 39 | mediatek/mt7986b-emmc-rfb.dtb \ |
| 40 | " |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 41 | KERNEL_IMAGETYPE = "fitImage" |
| 42 | KERNEL_CLASSES = "kernel-fitimage" |
developer | 5d62759 | 2022-12-02 10:26:07 +0800 | [diff] [blame] | 43 | 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] | 44 | |
| 45 | UBOOT_CONFIG = "mt7622_rfb_defconfig" |
| 46 | |
| 47 | UBOOT_ARCH = "arm64" |
| 48 | UBOOT_LOADADDRESS = "0x48080000" |
| 49 | UBOOT_ENTRYPOINT = "0x48080000" |
| 50 | MACHINE_EXTRA_RRECOMMENDS += "kernel-modules" |
| 51 | |
| 52 | TCLIBC = "glibc" |
| 53 | |
| 54 | MACHINEOVERRIDES .= ":broadband:filogic" |
| 55 | |
developer | 3d8c09d | 2022-07-11 18:14:15 +0800 | [diff] [blame] | 56 | IMAGE_FSTYPES ="${@bb.utils.contains('DISTRO_FEATURES','kernel_in_ubi',' squashfs-xz',' ubi',d)}" |
| 57 | IMAGE_FSTYPES_DEBUGFS = "" |
| 58 | IMAGE_GEN_DEBUGFS = "0" |
developer | f11ee16 | 2022-04-12 11:17:45 +0800 | [diff] [blame] | 59 | # Parameters for MT7986 RFB1 NAND (byte) |
| 60 | # NAND_LOG_BLOCK_SIZE = NAND_PHY_BLOCK_SIZE - 2 Pages |
| 61 | # NAND_LBLOCK_COUNT = NAND_PHY_BLOCK_COUNT - 53 |
| 62 | NAND_PAGE_SIZE = "4096" |
| 63 | NAND_PHY_BLOCK_SIZE = "262144" |
| 64 | NAND_LOG_BLOCK_SIZE = "253952" |
| 65 | NAND_PHY_BLOCK_COUNT = "2048" |
| 66 | NAND_LOG_BLOCK_COUNT = "1920" |
| 67 | |
| 68 | UBI_VOLNAME = "rootfs" |
| 69 | MKUBIFS_ARGS = "--min-io-size ${NAND_PAGE_SIZE} --leb-size ${NAND_LOG_BLOCK_SIZE} --max-leb-cnt ${NAND_LOG_BLOCK_COUNT}" |
| 70 | UBINIZE_ARGS = "--min-io-size ${NAND_PAGE_SIZE} --peb-size ${NAND_PHY_BLOCK_SIZE} --sub-page-size ${NAND_PAGE_SIZE}" |
| 71 | IMAGE_CLASSES += "image_types-mtk" |
| 72 | |
| 73 | SERIAL_CONSOLE ?= "115200 ttyS0" |