Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 1 | include device/linaro/dragonboard/BoardConfigCommon.mk |
| 2 | |
| 3 | # Primary Arch |
| 4 | TARGET_ARCH := arm64 |
| 5 | TARGET_ARCH_VARIANT := armv9-a |
| 6 | TARGET_CPU_VARIANT := kryo385 |
| 7 | TARGET_CPU_ABI := arm64-v8a |
| 8 | |
| 9 | # Board Information |
| 10 | TARGET_BOOTLOADER_BOARD_NAME := sm8x50 |
| 11 | TARGET_BOARD_PLATFORM := sm8x50 |
| 12 | |
| 13 | TARGET_NO_KERNEL := false |
| 14 | BOARD_INCLUDE_DTB_IN_BOOTIMG := true |
| 15 | BOARD_BOOT_HEADER_VERSION := 2 # XXX v4 is WIP |
| 16 | BOARD_MKBOOTIMG_ARGS := --header_version $(BOARD_BOOT_HEADER_VERSION) |
| 17 | |
| 18 | BOARD_KERNEL_BASE := 0x80000000 |
| 19 | BOARD_KERNEL_PAGESIZE := 4096 |
| 20 | BOARD_KERNEL_CMDLINE += earlycon firmware_class.path=/vendor/firmware/ |
| 21 | BOARD_KERNEL_CMDLINE += init=/init printk.devkmsg=on |
| 22 | BOARD_KERNEL_CMDLINE += deferred_probe_timeout=30 |
| 23 | BOARD_KERNEL_CMDLINE += qcom_geni_serial.con_enabled=1 |
| 24 | BOARD_KERNEL_CMDLINE += console=ttyMSM0,115200n8 |
| 25 | BOARD_KERNEL_CMDLINE += allow_mismatched_32bit_el0 clk_ignore_unused pd_ignore_unused |
Amit Pundir | ef6d03d | 2024-04-13 23:52:27 +0530 | [diff] [blame] | 26 | |
| 27 | ifeq ($(TARGET_SDCARD_BOOT), true) |
| 28 | BOARD_KERNEL_CMDLINE += androidboot.boot_devices=soc@0/8804000.mmc |
| 29 | else |
Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 30 | BOARD_KERNEL_CMDLINE += androidboot.boot_devices=soc@0/1d84000.ufs |
Amit Pundir | ef6d03d | 2024-04-13 23:52:27 +0530 | [diff] [blame] | 31 | endif |
| 32 | |
Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 33 | BOARD_KERNEL_CMDLINE += androidboot.hardware=sm8x50 |
| 34 | BOARD_KERNEL_CMDLINE += androidboot.verifiedbootstate=orange |
| 35 | |
| 36 | # Image Configuration |
| 37 | BOARD_BOOTIMAGE_PARTITION_SIZE := 67108864 #64M |
Amit Pundir | ef6d03d | 2024-04-13 23:52:27 +0530 | [diff] [blame] | 38 | |
| 39 | ifeq ($(TARGET_SDCARD_BOOT), true) |
| 40 | BOARD_USERDATAIMAGE_PARTITION_SIZE := 8589934592 #8G |
| 41 | BOARD_FLASH_BLOCK_SIZE := 4096 |
| 42 | # Super partition |
| 43 | BOARD_SUPER_PARTITION_SIZE := 4294967296 #4G |
| 44 | BOARD_DB_DYNAMIC_PARTITIONS_SIZE := 4290772992 # Reserve 4M for DAP metadata |
| 45 | BOARD_SEPOLICY_DIRS += device/linaro/dragonboard/shared/utils/sdcard-boot/sepolicy/ |
| 46 | else |
Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 47 | BOARD_USERDATAIMAGE_PARTITION_SIZE := 223226966016 #200+G |
| 48 | BOARD_FLASH_BLOCK_SIZE := 131072 |
| 49 | # Super partition |
| 50 | BOARD_SUPER_PARTITION_SIZE := 6442450944 #6GB |
| 51 | BOARD_DB_DYNAMIC_PARTITIONS_SIZE := 6438256640 # Reserve 4M for DAP metadata |
Amit Pundir | ef6d03d | 2024-04-13 23:52:27 +0530 | [diff] [blame] | 52 | endif |
| 53 | |
Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 54 | BOARD_SUPER_PARTITION_METADATA_DEVICE := super |
| 55 | BOARD_SUPER_IMAGE_IN_UPDATE_PACKAGE := true |
| 56 | BOARD_DB_DYNAMIC_PARTITIONS_PARTITION_LIST := system vendor system_ext product |
| 57 | |
| 58 | # Platform specific sepolicies |
| 59 | BOARD_SEPOLICY_DIRS += device/linaro/dragonboard/sm8x50/sepolicy/ |
| 60 | |
| 61 | # dlkm partitions |
| 62 | include device/linaro/dragonboard/shared/utils/dlkm_loader/BoardConfig.mk |
| 63 | BOARD_DB_DYNAMIC_PARTITIONS_PARTITION_LIST += system_dlkm vendor_dlkm |
| 64 | BOARD_SEPOLICY_DIRS += device/linaro/dragonboard/shared/utils/dlkm_loader/sepolicy/ |
| 65 | |
| 66 | # Graphics |
| 67 | include device/linaro/dragonboard/shared/graphics/drm_hwcomposer/BoardConfig.mk |
Amit Pundir | e4d2a61 | 2024-04-04 01:31:11 +0530 | [diff] [blame] | 68 | ifeq ($(TARGET_USES_SWR), true) |
Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 69 | BOARD_SEPOLICY_DIRS += device/linaro/dragonboard/shared/graphics/swangle/sepolicy |
Amit Pundir | e4d2a61 | 2024-04-04 01:31:11 +0530 | [diff] [blame] | 70 | else |
| 71 | include device/linaro/dragonboard/shared/graphics/mesa/BoardConfig.mk |
| 72 | endif |
Amit Pundir | bd765d6 | 2024-03-08 22:31:43 +0530 | [diff] [blame] | 73 | BOARD_SEPOLICY_DIRS += device/linaro/dragonboard/shared/graphics/minigbm_msm/sepolicy |