summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlistair Strachan2018-12-26 15:43:00 -0600
committerAlistair Strachan2018-12-26 15:44:38 -0600
commit68e49d0ebdf332e7a1f506d097f7781da9548105 (patch)
treeb09e33923bc502606f2b92f9e663f0740cef20b9
parente1ccb4762a1a7d7456a921298c31cd1b4992d909 (diff)
downloaddevice-ti-beagle-x15-68e49d0ebdf332e7a1f506d097f7781da9548105.tar.gz
device-ti-beagle-x15-68e49d0ebdf332e7a1f506d097f7781da9548105.tar.xz
device-ti-beagle-x15-68e49d0ebdf332e7a1f506d097f7781da9548105.zip
Introduce TARGET_KERNEL_USE to specify kernel version
Copied from device/linaro/hikey. This uses a command line variable, TARGET_KERNEL_USE, to specify which kernel to install and use at runtime. The correct kernel and dtb file are picked up automatically. The kernel defaults to 4.14. Bug: 110964307 Change-Id: I044038de8ba82beb9bc46ddb749efbd308fba03b Signed-off-by: Alistair Strachan <astrachan@google.com>
-rw-r--r--boot_fit/Android.mk4
-rw-r--r--device.mk3
2 files changed, 4 insertions, 3 deletions
diff --git a/boot_fit/Android.mk b/boot_fit/Android.mk
index c16ccfe..d816146 100644
--- a/boot_fit/Android.mk
+++ b/boot_fit/Android.mk
@@ -17,12 +17,12 @@ $(BOOTIMG_FIT): PRIVATE_BOARD_DIR := $(BOARD_DIR)
17$(BOOTIMG_FIT): PRIVATE_INSTALLED_KERNEL_TARGET := $(BOOTIMG_FIT_INSTALLED_KERNEL_TARGET) 17$(BOOTIMG_FIT): PRIVATE_INSTALLED_KERNEL_TARGET := $(BOOTIMG_FIT_INSTALLED_KERNEL_TARGET)
18$(BOOTIMG_FIT): PRIVATE_INSTALLED_RAMDISK_TARGET := $(BOOTIMG_FIT_INSTALLED_RAMDISK_TARGET) 18$(BOOTIMG_FIT): PRIVATE_INSTALLED_RAMDISK_TARGET := $(BOOTIMG_FIT_INSTALLED_RAMDISK_TARGET)
19$(BOOTIMG_FIT): $(BOOTIMG_FIT_INSTALLED_KERNEL_TARGET) $(BOOTIMG_FIT_INSTALLED_RAMDISK_TARGET) 19$(BOOTIMG_FIT): $(BOOTIMG_FIT_INSTALLED_KERNEL_TARGET) $(BOOTIMG_FIT_INSTALLED_RAMDISK_TARGET)
20$(BOOTIMG_FIT): $(BOARD_DIR)/$(ITS) $(MKIMAGE) $(DTC) $(wildcard $(LOCAL_KERNEL)/*.dtb) 20$(BOOTIMG_FIT): $(BOARD_DIR)/$(ITS) $(MKIMAGE) $(DTC) $(wildcard $(LOCAL_KERNEL)/$(TARGET_KERNEL_USE)/*.dtb)
21 mkdir -p $(PRIVATE_INTERMEDIATES) 21 mkdir -p $(PRIVATE_INTERMEDIATES)
22 cp $(PRIVATE_BOARD_DIR)/$(PRIVATE_ITS) $(PRIVATE_INTERMEDIATES)/ 22 cp $(PRIVATE_BOARD_DIR)/$(PRIVATE_ITS) $(PRIVATE_INTERMEDIATES)/
23 cp $(PRIVATE_INSTALLED_RAMDISK_TARGET) $(PRIVATE_INTERMEDIATES)/ 23 cp $(PRIVATE_INSTALLED_RAMDISK_TARGET) $(PRIVATE_INTERMEDIATES)/
24 cp $(PRIVATE_INSTALLED_KERNEL_TARGET) $(PRIVATE_INTERMEDIATES)/zImage 24 cp $(PRIVATE_INSTALLED_KERNEL_TARGET) $(PRIVATE_INTERMEDIATES)/zImage
25 cp $(LOCAL_KERNEL)/*.dtb $(PRIVATE_INTERMEDIATES)/ 25 cp $(LOCAL_KERNEL)/$(TARGET_KERNEL_USE)/*.dtb $(PRIVATE_INTERMEDIATES)/
26 PATH=$(HOST_OUT_EXECUTABLES):$$PATH $(PRIVATE_MKIMAGE) -D "$(PRIVATE_DTC_FLAGS_MKIMAGE)" -f $(PRIVATE_INTERMEDIATES)/$(PRIVATE_ITS) $@ 26 PATH=$(HOST_OUT_EXECUTABLES):$$PATH $(PRIVATE_MKIMAGE) -D "$(PRIVATE_DTC_FLAGS_MKIMAGE)" -f $(PRIVATE_INTERMEDIATES)/$(PRIVATE_ITS) $@
27 27
28include $(CLEAR_VARS) 28include $(CLEAR_VARS)
diff --git a/device.mk b/device.mk
index 1530e5c..74911a0 100644
--- a/device.mk
+++ b/device.mk
@@ -21,7 +21,8 @@ $(call inherit-product, frameworks/native/build/tablet-7in-xhdpi-2048-dalvik-hea
21DEVICE_PACKAGE_OVERLAYS := device/ti/beagle_x15/overlay 21DEVICE_PACKAGE_OVERLAYS := device/ti/beagle_x15/overlay
22 22
23LOCAL_KERNEL := device/ti/beagle_x15-kernel 23LOCAL_KERNEL := device/ti/beagle_x15-kernel
24TARGET_PREBUILT_KERNEL := $(LOCAL_KERNEL)/zImage 24TARGET_KERNEL_USE ?= 4.14
25TARGET_PREBUILT_KERNEL := $(LOCAL_KERNEL)/$(TARGET_KERNEL_USE)/zImage
25PRODUCT_COPY_FILES += $(TARGET_PREBUILT_KERNEL):kernel 26PRODUCT_COPY_FILES += $(TARGET_PREBUILT_KERNEL):kernel
26 27
27# Graphics 28# Graphics