From 4d90bc1647d2c99362abad405a25df4c8c9526a2 Mon Sep 17 00:00:00 2001 From: Nelson Li Date: Thu, 2 May 2024 07:30:50 +0000 Subject: [PATCH 1/3] Refactor product inheritance for slider products Add an additional layer of inheritance for `aosp_slider`, `full_slider`, and `aosp_slider_hwasan`. This change adds a common layer of inheritance for non-factory products (slider_generic.mk). This makes it easier to configure factory and non-factory products differently. Non-factory `slider` products now inherits from `device/google/raviole/slider_generic.mk` which inherit from `device/google/raviole/device-slider.mk`. aconfig flags: Flag: EXEMPT mechanical refactoring build flags: Flag: EXEMPT mechanical refactoring Bug: 338332183 Bug: 338333277 Test: lunch aosp_slider-trunk_staging-userdebug && m lunch full_slider-trunk_staging-userdebug && m lunch aosp_slider_hwasan-trunk_staging-userdebug && m Change-Id: If0bbcdf2d4de3c2eca14e514b863f7416ef12e45 --- aosp_slider.mk | 2 +- slider_generic.mk | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 slider_generic.mk diff --git a/aosp_slider.mk b/aosp_slider.mk index 29351f5..9e65926 100644 --- a/aosp_slider.mk +++ b/aosp_slider.mk @@ -14,7 +14,7 @@ # limitations under the License. # $(call inherit-product, device/google/gs101/aosp_common.mk) -$(call inherit-product, device/google/raviole/device-slider.mk) +$(call inherit-product, device/google/raviole/slider_generic.mk) PRODUCT_NAME := aosp_slider PRODUCT_DEVICE := slider diff --git a/slider_generic.mk b/slider_generic.mk new file mode 100644 index 0000000..52d2542 --- /dev/null +++ b/slider_generic.mk @@ -0,0 +1,17 @@ +# +# Copyright 2024 The Android Open-Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +$(call inherit-product, device/google/raviole/device-slider.mk) From 89304e99bbc56f1bb4599493c3dd46e9272d14f7 Mon Sep 17 00:00:00 2001 From: Nelson Li Date: Thu, 2 May 2024 07:41:44 +0000 Subject: [PATCH 2/3] Refactor product inheritance for whitefin products Add an additional layer of inheritance for `aosp_whitefin`, `aosp_whitefin_64`, `aosp_whitefin_pkvm`, and `aosp_whitefin_hwasan`. This change adds a common layer of inheritance for non-factory products (whitefin_generic.mk). This makes it easier to configure factory and non-factory products differently. Non-factory `whitefin` products now inherits from `device/google/raviole/whitefin_generic.mk` which inherit from `device/google/raviole/device-whitefin.mk`. aconfig flags: Flag: EXEMPT mechanical refactoring build flags: Flag: EXEMPT mechanical refactoring Bug: 338332183 Bug: 338332464 Test: lunch aosp_whitefin-trunk_staging-userdebug && m lunch aosp_whitefin_64-trunk_staging-userdebug && m lunch aosp_whitefin_pkvm-trunk_staging-userdebug && m lunch aosp_whitefin_hwasan-trunk_staging-userdebug && m Change-Id: I151d3e59141e566fad54f62ac01ab4372522fd5f --- aosp_whitefin.mk | 2 +- whitefin_generic.mk | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 whitefin_generic.mk diff --git a/aosp_whitefin.mk b/aosp_whitefin.mk index bcdd616..212e7a6 100644 --- a/aosp_whitefin.mk +++ b/aosp_whitefin.mk @@ -14,7 +14,7 @@ # limitations under the License. # $(call inherit-product, device/google/gs101/aosp_common.mk) -$(call inherit-product, device/google/raviole/device-whitefin.mk) +$(call inherit-product, device/google/raviole/whitefin_generic.mk) PRODUCT_NAME := aosp_whitefin PRODUCT_DEVICE := whitefin diff --git a/whitefin_generic.mk b/whitefin_generic.mk new file mode 100644 index 0000000..a56c609 --- /dev/null +++ b/whitefin_generic.mk @@ -0,0 +1,17 @@ +# +# Copyright 2024 The Android Open-Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +$(call inherit-product, device/google/raviole/device-whitefin.mk) From 2a09185780a25cd4e187f009a0ae419be7947042 Mon Sep 17 00:00:00 2001 From: Qian-Hao Huang Date: Thu, 2 May 2024 21:08:51 +0800 Subject: [PATCH 3/3] Load fips140.ko before all other kernel modules Bug: 337838109 Bug: 331791671 Change-Id: I4186255ad1b9baccf4f2c1e65560515aa6dc42a2 Signed-off-by: Qian-Hao Huang --- oriole/BoardConfig.mk | 1 + raven/BoardConfig.mk | 1 + 2 files changed, 2 insertions(+) diff --git a/oriole/BoardConfig.mk b/oriole/BoardConfig.mk index 50c2ba7..5b13c0f 100644 --- a/oriole/BoardConfig.mk +++ b/oriole/BoardConfig.mk @@ -18,6 +18,7 @@ BOARD_BOOTCONFIG += androidboot.load_modules_parallel=true # The modules which need to be loaded in sequential +BOARD_KERNEL_CMDLINE += fips140.load_sequential=1 BOARD_KERNEL_CMDLINE += exynos_mfc.load_sequential=1 BOARD_KERNEL_CMDLINE += exynos_drm.load_sequential=1 BOARD_KERNEL_CMDLINE += pcie-exynos-core.load_sequential=1 diff --git a/raven/BoardConfig.mk b/raven/BoardConfig.mk index 6a9530e..f47b104 100644 --- a/raven/BoardConfig.mk +++ b/raven/BoardConfig.mk @@ -18,6 +18,7 @@ BOARD_BOOTCONFIG += androidboot.load_modules_parallel=true # The modules which need to be loaded in sequential +BOARD_KERNEL_CMDLINE += fips140.load_sequential=1 BOARD_KERNEL_CMDLINE += exynos_mfc.load_sequential=1 BOARD_KERNEL_CMDLINE += exynos_drm.load_sequential=1 BOARD_KERNEL_CMDLINE += pcie-exynos-core.load_sequential=1