blob: b30c32871d995ba270b0abc203ab2388517a4fe1 [file] [log] [blame]
Amit Pundiraf628c22016-11-02 16:37:00 +08001include device/linaro/hikey/BoardConfigCommon.mk
2
Dmitry Shmidta167bf62017-08-24 12:51:42 -07003TARGET_BOOTLOADER_BOARD_NAME := hikey
4TARGET_BOARD_PLATFORM := hikey
5
Jake Weinsteinf2de1342017-06-23 12:23:08 -04006TARGET_CPU_VARIANT := cortex-a53
7TARGET_2ND_CPU_VARIANT := cortex-a53
8
Alistair Strachandadf8342019-01-16 14:10:47 -08009BOARD_KERNEL_CMDLINE := androidboot.hardware=hikey firmware_class.path=/vendor/firmware efi=noruntime init=/init
10BOARD_KERNEL_CMDLINE += androidboot.boot_devices=soc/f723d000.dwmmc0
11BOARD_KERNEL_CMDLINE += console=ttyAMA3,115200 androidboot.console=ttyAMA3
Amit Pundiraf628c22016-11-02 16:37:00 +080012
John Stultz62183352019-04-25 16:06:53 -070013# On kernels before 4.14, enable dtb fstab with android-verity. On kernels >=
14# 4.14, both dtb fstab and android-verity are deprecated, so until we have
Alistair Strachandadf8342019-01-16 14:10:47 -080015# avb2 support in the bootloader, don't enable either feature. The ramdisk
16# fstab needed for the new mechanism will be installed unconditionally; if
17# dtb fstab is present, it will override it automatically.
18ifneq ($(TARGET_KERNEL_USE),4.19)
John Stultz62183352019-04-25 16:06:53 -070019ifneq ($(TARGET_KERNEL_USE),4.14)
Alistair Strachan11c5e3e2018-07-31 17:28:51 -070020BOARD_KERNEL_CMDLINE += overlay_mgr.overlay_dt_entry=hardware_cfg_enable_android_fstab_v2
Alistair Strachandadf8342019-01-16 14:10:47 -080021BOARD_KERNEL_CMDLINE += rootwait ro root=/dev/dm-0
Alistair Strachan11c5e3e2018-07-31 17:28:51 -070022BOARD_KERNEL_CMDLINE += dm=\"system none ro,0 1 android-verity 179:9\"
23BOARD_BUILD_SYSTEM_ROOT_IMAGE := true
Alistair Strachandadf8342019-01-16 14:10:47 -080024endif
John Stultz62183352019-04-25 16:06:53 -070025endif
John Stultz3424dc32018-04-11 15:37:34 -070026
Ben Fennema52301e42017-10-17 12:24:04 -070027ifneq ($(TARGET_SENSOR_MEZZANINE),)
28BOARD_KERNEL_CMDLINE += overlay_mgr.overlay_dt_entry=hardware_cfg_$(TARGET_SENSOR_MEZZANINE)
29endif
30
Yongqin Liudb3edca2017-03-28 22:44:07 +080031## printk.devkmsg only has meaning for kernel 4.9 and later
Alistair Strachan77081492019-01-14 09:03:22 -080032## it would be ignored by kernel 4.4
Yongqin Liudb3edca2017-03-28 22:44:07 +080033BOARD_KERNEL_CMDLINE += printk.devkmsg=on
34
Dmitry Shmidt5d080802017-04-11 14:20:03 -070035TARGET_NO_DTIMAGE := true
36
John Stultz5e1a47d2019-05-14 11:33:51 -070037BOARD_BOOTIMAGE_PARTITION_SIZE := 67108864
Amit Pundiraf628c22016-11-02 16:37:00 +080038BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1610612736
Mark Salyzyn97ae2202017-05-26 14:56:52 -070039ifeq ($(TARGET_USERDATAIMAGE_4GB), true) # to build for aosp-4g partition table
Amit Pundiraf628c22016-11-02 16:37:00 +080040BOARD_USERDATAIMAGE_PARTITION_SIZE := 1595915776
41else
Mark Salyzyn97ae2202017-05-26 14:56:52 -070042ifeq ($(TARGET_WITH_SWAP), true) # to build for swap-8g partition table
43BOARD_USERDATAIMAGE_PARTITION_SIZE := 4246715904
44else
Amit Pundiraf628c22016-11-02 16:37:00 +080045BOARD_USERDATAIMAGE_PARTITION_SIZE := 5588893184
46endif
Mark Salyzyn97ae2202017-05-26 14:56:52 -070047endif
Amit Pundiraf628c22016-11-02 16:37:00 +080048BOARD_FLASH_BLOCK_SIZE := 131072
Dmitry Shmidte04aca32018-04-10 11:10:33 -070049
50# Vendor partition definitions
51TARGET_COPY_OUT_VENDOR := vendor
52BOARD_VENDORIMAGE_PARTITION_SIZE := 268435456 # 256MB
53BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE := ext4
54BOARD_VENDORIMAGE_JOURNAL_SIZE := 0
55BOARD_VENDORIMAGE_EXTFS_INODE_COUNT := 2048
Alistair Strachan10c509c2018-11-20 18:09:27 -080056
57TARGET_RECOVERY_FSTAB := device/linaro/hikey/hikey/$(TARGET_FSTAB)