Skip to content

Commit

Permalink
Kernel: Xiaomi kernel changes for Mi 10 Lite 5G, Mi 10 Lite Zoom Andr…
Browse files Browse the repository at this point in the history
…oid Q.

The Patch based on QualComm release TAG: LA.UM.8.13.r1-04700-SAIPAN.0.
The kernel config file used are monet_user_defconfig and vangogh_user_defconfig.

Change-Id: Iabc2c19ad4a5171c9ff4bdd62ddce52aa2ee3362
Signed-off-by: bsp-open <bsp-open@xiaomi.com>
  • Loading branch information
bsp-open committed Jul 17, 2020
1 parent 62b7e12 commit ce6e246
Show file tree
Hide file tree
Showing 1,092 changed files with 589,045 additions and 949 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -140,4 +140,4 @@ kernel/configs/android-*.cfg
arch/arm64/boot/dts/vendor/

# Tech package directories
techpack/
#techpack/
8 changes: 8 additions & 0 deletions AndroidKernel.mk
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ KERNEL_CONFIG_OVERRIDE := CONFIG_ANDROID_BINDER_IPC_32BIT=y
endif
endif

ifeq ($(FACTORY_BUILD),1)
KERNEL_CONFIG_OVERRIDE_FACTORY := CONFIG_FACTORY_BUILD=y
endif

TARGET_KERNEL_CROSS_COMPILE_PREFIX := $(strip $(TARGET_KERNEL_CROSS_COMPILE_PREFIX))
ifeq ($(TARGET_KERNEL_CROSS_COMPILE_PREFIX),)
KERNEL_CROSS_COMPILE := arm-eabi-
Expand Down Expand Up @@ -205,6 +209,10 @@ $(KERNEL_HEADERS_INSTALL): $(KERNEL_OUT)
echo "Overriding kernel config with '$(KERNEL_CONFIG_OVERRIDE)'"; \
echo $(KERNEL_CONFIG_OVERRIDE) >> $(KERNEL_OUT)/.config; \
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) oldconfig; fi
$(hide) if [ ! -z "$(KERNEL_CONFIG_OVERRIDE_FACTORY)" ]; then \
echo "Overriding kernel config with '$(KERNEL_CONFIG_OVERRIDE_FACTORY)'"; \
echo $(KERNEL_CONFIG_OVERRIDE_FACTORY) >> $(KERNEL_OUT)/.config; \
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) oldconfig; fi

# Creating a dtb.img once the kernel is compiled if TARGET_KERNEL_APPEND_DTB is set to be false
$(INSTALLED_DTBIMAGE_TARGET): $(TARGET_PREBUILT_INT_KERNEL)
Expand Down
11 changes: 11 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,17 @@ export VERSION PATCHLEVEL SUBLEVEL KERNELRELEASE KERNELVERSION

include scripts/subarch.include

# Make sure the kernel could be compiled successfully
LINK_DUM :=$(shell if [ ! -L "$(abspath $(srctree))/include/linux/rtmm.h" ]; then \
ln -s -f $(abspath $(srctree))/include/dum/rtmm.h $(abspath $(srctree))/include/linux/rtmm.h; \
ln -s -f $(abspath $(srctree))/include/dum/ktrace.h $(abspath $(srctree))/include/linux/ktrace.h; \
mkdir -p $(abspath $(srctree))/drivers/staging/rtmm; \
touch $(abspath $(srctree))/drivers/staging/rtmm/Kconfig; \
touch $(abspath $(srctree))/drivers/staging/rtmm/Makefile; \
mkdir -p $(abspath $(srctree))/drivers/staging/ktrace; \
touch $(abspath $(srctree))/drivers/staging/ktrace/Kconfig; \
touch $(abspath $(srctree))/drivers/staging/ktrace/Makefile; fi;)

# Cross compiling and selecting different set of gcc/bin-utils
# ---------------------------------------------------------------------------
#
Expand Down
14 changes: 14 additions & 0 deletions arch/arm64/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1479,6 +1479,13 @@ config KRYO_PMU_WORKAROUND

Enable this flag for effect SoCs.

config BOOT_INFO
bool "Boot information from bootloader"
default y
help
On embedded linux device, we try to collect more information from
bootloader to kernel. eg. powerup reason.

config BUILD_ARM64_DT_OVERLAY
bool "enable DT overlay compilation support"
depends on OF
Expand Down Expand Up @@ -1545,3 +1552,10 @@ source "arch/arm64/kvm/Kconfig"
if CRYPTO
source "arch/arm64/crypto/Kconfig"
endif

config FACTORY_BUILD
bool "distiguish factory versionion from dev version"
default n
help
This macro will be defined Whenen build factory version. It is used to
distinguish factory and dev codes in kernel.
1 change: 1 addition & 0 deletions arch/arm64/boot/dts/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
vendor
1 change: 1 addition & 0 deletions arch/arm64/configs/monet_user_defconfig
1 change: 1 addition & 0 deletions arch/arm64/configs/vangogh_user_defconfig
1 change: 0 additions & 1 deletion arch/arm64/configs/vendor/bengal-perf_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ CONFIG_ARCH_BENGAL=y
CONFIG_PCI=y
CONFIG_SCHED_MC=y
CONFIG_NR_CPUS=8
CONFIG_HZ_100=y
CONFIG_SECCOMP=y
# CONFIG_UNMAP_KERNEL_AT_EL0 is not set
CONFIG_HARDEN_BRANCH_PREDICTOR=y
Expand Down
1 change: 0 additions & 1 deletion arch/arm64/configs/vendor/bengal_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ CONFIG_ARCH_SCUBA=y
CONFIG_PCI=y
CONFIG_SCHED_MC=y
CONFIG_NR_CPUS=8
CONFIG_HZ_100=y
CONFIG_SECCOMP=y
# CONFIG_UNMAP_KERNEL_AT_EL0 is not set
CONFIG_HARDEN_BRANCH_PREDICTOR=y
Expand Down
1 change: 0 additions & 1 deletion arch/arm64/configs/vendor/lito-perf_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ CONFIG_ARCH_LAGOON=y
CONFIG_PCI=y
CONFIG_SCHED_MC=y
CONFIG_NR_CPUS=8
CONFIG_HZ_100=y
CONFIG_SECCOMP=y
# CONFIG_UNMAP_KERNEL_AT_EL0 is not set
CONFIG_ARM64_SSBD=y
Expand Down
1 change: 0 additions & 1 deletion arch/arm64/configs/vendor/lito_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ CONFIG_ARCH_LAGOON=y
CONFIG_PCI=y
CONFIG_SCHED_MC=y
CONFIG_NR_CPUS=8
CONFIG_HZ_100=y
CONFIG_SECCOMP=y
# CONFIG_UNMAP_KERNEL_AT_EL0 is not set
CONFIG_ARM64_SSBD=y
Expand Down
Loading

0 comments on commit ce6e246

Please sign in to comment.