Migrate comet to P24 zumapro codebase

Bug: 287173316
Change-Id: Id03e526ff8ca67d8d9ee83a9d3bacfb1473e9a25
This commit is contained in:
Robin Peng 2023-06-14 15:29:33 +00:00
parent a6b4f6f575
commit e5d2a88616
9 changed files with 26 additions and 28 deletions

View file

@ -14,12 +14,12 @@
# limitations under the License.
#
TARGET_LINUX_KERNEL_VERSION := 5.15
TARGET_LINUX_KERNEL_VERSION := 6.1
USE_SWIFTSHADER := true
BOARD_USES_SWIFTSHADER := true
$(call inherit-product, device/google/zuma/aosp_common.mk)
$(call inherit-product, device/google/zumapro/aosp_common.mk)
$(call inherit-product, device/google/comet/device-comet.mk)
PRODUCT_NAME := aosp_comet

View file

@ -19,7 +19,7 @@ TARGET_SCREEN_DENSITY := 420
BOARD_USES_GENERIC_AUDIO := true
USES_DEVICE_GOOGLE_COMET := true
include device/google/zuma/BoardConfig-common.mk
-include vendor/google_devices/zuma/prebuilts/BoardConfigVendor.mk
include device/google/zumapro/BoardConfig-common.mk
-include vendor/google_devices/zumapro/prebuilts/BoardConfigVendor.mk
include device/google/comet-sepolicy/comet-sepolicy.mk
include device/google/comet/wifi/BoardConfig-wifi.mk

View file

@ -1,5 +1,5 @@
# Comet specific init.rc
import /vendor/etc/init/hw/init.zuma.rc
import /vendor/etc/init/hw/init.zumapro.rc
on init && property:ro.vendor.factory=1
import /vendor/etc/init/hw/init.factory.rc

View file

@ -19,12 +19,12 @@ TARGET_BOARD_KERNEL_HEADERS := device/google/comet-kernel/kernel-headers
TARGET_RECOVERY_DEFAULT_ROTATION := ROTATION_RIGHT
$(call inherit-product-if-exists, vendor/google_devices/comet/prebuilts/device-vendor-comet.mk)
$(call inherit-product-if-exists, vendor/google_devices/zuma/prebuilts/device-vendor.mk)
$(call inherit-product-if-exists, vendor/google_devices/zuma/proprietary/device-vendor.mk)
$(call inherit-product-if-exists, vendor/google_devices/zumapro/prebuilts/device-vendor.mk)
$(call inherit-product-if-exists, vendor/google_devices/zumapro/proprietary/device-vendor.mk)
$(call inherit-product-if-exists, vendor/google_devices/comet/proprietary/comet/device-vendor-comet.mk)
$(call inherit-product-if-exists, vendor/qorvo/uwb/qm35-hal/Device.mk)
include device/google/zuma/device-shipping-common.mk
include device/google/zumapro/device-shipping-common.mk
include device/google/comet/audio/comet/audio-tables.mk
include hardware/google/pixel/vibrator/cs40l26/device.mk
include device/google/gs-common/bcmbt/bluetooth.mk

View file

@ -1,4 +1,4 @@
<compatibility-matrix version="1.0" type="framework" level="8">
<compatibility-matrix version="1.0" type="framework" level="7">
<hal format="hidl">
<name>vendor.samsung.hardware.gnss</name>
<transport>hwbinder</transport>

View file

@ -14,9 +14,9 @@
# limitations under the License.
#
TARGET_LINUX_KERNEL_VERSION := 5.15
TARGET_LINUX_KERNEL_VERSION := 6.1
$(call inherit-product, device/google/zuma/factory_common.mk)
$(call inherit-product, device/google/zumapro/factory_common.mk)
$(call inherit-product, device/google/comet/device-comet.mk)
include device/google/comet/audio/comet/factory-audio-tables.mk

View file

@ -1,4 +1,4 @@
<manifest version="1.0" type="device" target-level="8">
<manifest version="1.0" type="device" target-level="7">
<hal format="hidl">
<name>vendor.samsung.hardware.gnss</name>
<transport>hwbinder</transport>

View file

@ -15,7 +15,7 @@
soong_namespace {
imports: [
"hardware/google/pixel",
"device/google/zuma/powerstats",
"device/google/zumapro/powerstats",
]
}
@ -37,6 +37,6 @@ cc_binary {
],
shared_libs: [
"android.hardware.power.stats-impl.zuma",
"android.hardware.power.stats-impl.zumapro",
],
}

View file

@ -18,7 +18,7 @@
#include <dataproviders/DisplayStateResidencyDataProvider.h>
#include <dataproviders/PowerStatsEnergyConsumer.h>
#include <ZumaCommonDataProviders.h>
#include <ZumaProCommonDataProviders.h>
#include <PowerStatsAidl.h>
#include <android-base/logging.h>
@ -35,11 +35,11 @@ void addDisplay(std::shared_ptr<PowerStats> p) {
// Add display residency stats
std::vector<std::string> states = {
"Off",
"LP: 1080x2340@30",
"On: 1080x2340@60",
"On: 1080x2340@90",
"HBM: 1080x2340@60",
"HBM: 1080x2340@90"};
"LP: 1440x3120@30",
"On: 1440x3120@60",
"On: 1440x3120@90",
"HBM: 1440x3120@60",
"HBM: 1440x3120@90"};
p->addStateResidencyDataProvider(std::make_unique<DisplayStateResidencyDataProvider>(
"Display",
@ -47,13 +47,11 @@ void addDisplay(std::shared_ptr<PowerStats> p) {
states));
// Add display energy consumer
p->addEnergyConsumer(PowerStatsEnergyConsumer::createMeterAndEntityConsumer(
p, EnergyConsumerType::DISPLAY, "display", {"PPVAR_VSYS_PWR_DISP"}, "Display",
{{"LP: 1080x2340@30", 1},
{"On: 1080x2340@60", 2},
{"On: 1080x2340@90", 3},
{"HBM: 1080x2340@60", 4},
{"HBM: 1080x2340@90", 5}}));
p->addEnergyConsumer(PowerStatsEnergyConsumer::createMeterConsumer(
p,
EnergyConsumerType::DISPLAY,
"Display",
{"VSYS_PWR_DISPLAY"}));
}
int main() {
@ -64,7 +62,7 @@ int main() {
std::shared_ptr<PowerStats> p = ndk::SharedRefBase::make<PowerStats>();
addZumaCommonDataProviders(p);
addZumaProCommonDataProviders(p);
addDisplay(p);
const std::string instance = std::string() + PowerStats::descriptor + "/default";