blob: 90bbc6c7d867c9a7c15c59e13d0709849ed773bc [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
Dmitry Shmidt20f2bc12017-05-11 17:05:01 -07009ifeq ($(TARGET_KERNEL_USE), 3.18)
vishal46787b62018-04-10 19:56:30 +053010BOARD_KERNEL_CMDLINE := console=ttyAMA3,115200 androidboot.console=ttyAMA3 androidboot.hardware=hikey firmware_class.path=/vendor/firmware efi=noruntime
Amit Pundiraf628c22016-11-02 16:37:00 +080011else
John Stultz719a0942018-12-05 16:50:42 -080012ifeq ($(TARGET_KERNEL_USE), 4.19)
13BOARD_KERNEL_CMDLINE := console=ttyAMA3,115200 androidboot.console=ttyAMA3 androidboot.hardware=hikey firmware_class.path=/vendor/firmware efi=noruntime
14else
15# FIQ debugger is deprecated and we'll remoeve this once kernel support in prebuilts are yanked
vishal46787b62018-04-10 19:56:30 +053016BOARD_KERNEL_CMDLINE := console=ttyFIQ0 androidboot.console=ttyFIQ0 androidboot.hardware=hikey firmware_class.path=/vendor/firmware efi=noruntime
Amit Pundiraf628c22016-11-02 16:37:00 +080017endif
John Stultz719a0942018-12-05 16:50:42 -080018endif
Amit Pundiraf628c22016-11-02 16:37:00 +080019
Alistair Strachan11c5e3e2018-07-31 17:28:51 -070020ifneq ($(TARGET_ANDROID_VERITY),)
21# Enable dtb fstab for treble, with verity and system-as-root
22# NOTE: Disabled by default until b/111829702 is fixed
23BOARD_KERNEL_CMDLINE += overlay_mgr.overlay_dt_entry=hardware_cfg_enable_android_fstab_v2
24BOARD_KERNEL_CMDLINE += rootwait ro init=/init root=/dev/dm-0
25BOARD_KERNEL_CMDLINE += dm=\"system none ro,0 1 android-verity 179:9\"
26BOARD_BUILD_SYSTEM_ROOT_IMAGE := true
27else
28# Enable dtb fstab for treble
John Stultz3424dc32018-04-11 15:37:34 -070029BOARD_KERNEL_CMDLINE += overlay_mgr.overlay_dt_entry=hardware_cfg_enable_android_fstab
Alistair Strachan11c5e3e2018-07-31 17:28:51 -070030endif
John Stultz3424dc32018-04-11 15:37:34 -070031
Ben Fennema52301e42017-10-17 12:24:04 -070032ifneq ($(TARGET_SENSOR_MEZZANINE),)
33BOARD_KERNEL_CMDLINE += overlay_mgr.overlay_dt_entry=hardware_cfg_$(TARGET_SENSOR_MEZZANINE)
34endif
35
Yongqin Liudb3edca2017-03-28 22:44:07 +080036## printk.devkmsg only has meaning for kernel 4.9 and later
Dmitry Shmidt20f2bc12017-05-11 17:05:01 -070037## it would be ignored by kernel 3.18 and kernel 4.4
Yongqin Liudb3edca2017-03-28 22:44:07 +080038BOARD_KERNEL_CMDLINE += printk.devkmsg=on
39
Dmitry Shmidt5d080802017-04-11 14:20:03 -070040TARGET_NO_DTIMAGE := true
41
Amit Pundiraf628c22016-11-02 16:37:00 +080042BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1610612736
Mark Salyzyn97ae2202017-05-26 14:56:52 -070043ifeq ($(TARGET_USERDATAIMAGE_4GB), true) # to build for aosp-4g partition table
Amit Pundiraf628c22016-11-02 16:37:00 +080044BOARD_USERDATAIMAGE_PARTITION_SIZE := 1595915776
45else
Mark Salyzyn97ae2202017-05-26 14:56:52 -070046ifeq ($(TARGET_WITH_SWAP), true) # to build for swap-8g partition table
47BOARD_USERDATAIMAGE_PARTITION_SIZE := 4246715904
48else
Amit Pundiraf628c22016-11-02 16:37:00 +080049BOARD_USERDATAIMAGE_PARTITION_SIZE := 5588893184
50endif
Mark Salyzyn97ae2202017-05-26 14:56:52 -070051endif
Amit Pundiraf628c22016-11-02 16:37:00 +080052BOARD_FLASH_BLOCK_SIZE := 131072
Dmitry Shmidte04aca32018-04-10 11:10:33 -070053
54# Vendor partition definitions
55TARGET_COPY_OUT_VENDOR := vendor
56BOARD_VENDORIMAGE_PARTITION_SIZE := 268435456 # 256MB
57BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE := ext4
58BOARD_VENDORIMAGE_JOURNAL_SIZE := 0
59BOARD_VENDORIMAGE_EXTFS_INODE_COUNT := 2048