Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0d86e1c2 authored by Sahil Sonar's avatar Sahil Sonar 💬
Browse files

Merge branch '1083-a15-FP5' into 'a15'

FP5: Import fpcamera & /e/OS patches

See merge request !41
parents 1b361947 7b61409b
Loading
Loading
Loading
Loading
+14 −3
Original line number Diff line number Diff line
@@ -49,6 +49,9 @@ BOARD_USES_ALSA_AUDIO := true
# Bootloader
TARGET_BOOTLOADER_BOARD_NAME := FP5

# Bootanimation
TARGET_USES_MURENA_BOOTANIMATION := true

# Display
TARGET_GRALLOC_HANDLE_HAS_RESERVED_SIZE := true
TARGET_SCREEN_DENSITY := 480
@@ -157,15 +160,23 @@ VENDOR_SECURITY_PATCH := $(BOOT_SECURITY_PATCH)
# SEPolicy
include device/qcom/sepolicy_vndr/SEPolicy.mk
BOARD_VENDOR_SEPOLICY_DIRS += $(DEVICE_PATH)/sepolicy/vendor
SYSTEM_EXT_PUBLIC_SEPOLICY_DIRS += $(DEVICE_PATH)/sepolicy/public
SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += $(DEVICE_PATH)/sepolicy/private

# Verified Boot
STOCK_SECURITY_PATCH := 2025-06-05 # Latest stock update available
BOARD_AVB_ENABLE := true
BOARD_AVB_MAKE_VBMETA_IMAGE_ARGS += --flags 3
ifneq (,$(wildcard $(KEYS_DIR)/avb_murena_rsa4096.pem))
BOARD_AVB_ALGORITHM := SHA256_RSA4096
BOARD_AVB_KEY_PATH := $(KEYS_DIR)/avb_murena_rsa4096.pem
endif
BOARD_AVB_VBMETA_SYSTEM := system system_ext product
BOARD_AVB_VBMETA_SYSTEM_ALGORITHM := SHA256_RSA4096
ifneq (,$(wildcard $(KEYS_DIR)/avb_murena_rsa4096.pem))
BOARD_AVB_VBMETA_SYSTEM_KEY_PATH := $(KEYS_DIR)/avb_murena_rsa4096.pem
else
BOARD_AVB_VBMETA_SYSTEM_KEY_PATH := external/avb/test/data/testkey_rsa4096.pem
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX := $(shell date -d 'TZ="GMT" $(STOCK_SECURITY_PATCH)' +%s)
endif
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX_LOCATION := 2

# Wifi
+27 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2016 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
  -->
<permissions>
    <privapp-permissions package="com.fp5.camera">
         <permission name="android.permission.SYSTEM_CAMERA"/>
         <permission name="android.permission.WRITE_MEDIA_STORAGE"/>
         <permission name="android.permission.START_ACTIVITIES_FROM_BACKGROUND"/>
         <permission name="android.permission.STOP_APP_SWITCHES"/>
         <permission name="android.permission.WRITE_SECURE_SETTINGS"/>
         <permission name="android.permission.INTERACT_ACROSS_USERS"/>
         <permission name="android.permission.CHANGE_CONFIGURATION"/>
    </privapp-permissions>
</permissions>
+12 −0
Original line number Diff line number Diff line
@@ -25,6 +25,9 @@ PRODUCT_PACKAGES += \
    checkpoint_gc \
    otapreopt_script

PRODUCT_PACKAGES += \
    RefreshRateController

# Audio
PRODUCT_PACKAGES += \
    android.hardware.audio@6.0-impl \
@@ -96,6 +99,9 @@ PRODUCT_PACKAGES += \
    android.hardware.camera.provider@2.4-impl \
    android.hardware.camera.provider@2.4-service_64

PRODUCT_PACKAGES += \
    FairphoneCameraService

PRODUCT_COPY_FILES += \
    frameworks/native/data/etc/android.hardware.camera.flash-autofocus.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.flash-autofocus.xml \
    frameworks/native/data/etc/android.hardware.camera.front.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.front.xml \
@@ -149,6 +155,10 @@ PRODUCT_PACKAGES += \
PRODUCT_COPY_FILES += \
    frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml

# FPCamera
PRODUCT_COPY_FILES += \
    $(LOCAL_PATH)/configs/privapp-permissions-fpcam.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/permissions/privapp-permissions-fpcam.xml

# GPS
PRODUCT_PACKAGES += \
    android.hardware.gnss@2.1-impl-qti:64 \
@@ -245,6 +255,7 @@ DEVICE_PACKAGE_OVERLAYS += \
PRODUCT_ENFORCE_RRO_TARGETS := *
PRODUCT_PACKAGES += \
    CarrierConfigResCommon \
    eCameraTarget \
    FrameworksResCommon \
    FrameworksResTarget \
    NcmTetheringOverlay \
@@ -253,6 +264,7 @@ PRODUCT_PACKAGES += \
    SystemUIResCommon \
    SystemUIResTarget \
    TelephonyResCommon \
    UpdaterResTarget \
    WifiResCommon \
    WifiResTarget

display/Android.bp

0 → 100644
+13 −0
Original line number Diff line number Diff line
//
// Copyright (C) 2025 E FOUNDATION
// SPDX-License-Identifier: Apache-2.0
//

android_app {
    name: "RefreshRateController",
    srcs: ["src/**/*.java"],
    certificate: "platform",
    platform_apis: true,
    privileged: true,
    system_ext_specific: true,
}
+28 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="foundation.e.refreshratecontroller"
    android:sharedUserId="android.uid.system">

    <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
    <uses-permission android:name="android.permission.WRITE_SETTINGS"/>

    <application
        android:label="RefreshRateController"
        android:persistent="true"
        android:directBootAware="true"
        android:defaultToDeviceProtectedStorage="true">

        <receiver
            android:name=".RefreshRateBroadcastReceiver"
            android:exported="false">
            <intent-filter>
                <action android:name="android.intent.action.LOCKED_BOOT_COMPLETED"/>
            </intent-filter>
        </receiver>

        <service
            android:name=".RefreshRateMonitoringService"
            android:exported="false"/>

    </application>
</manifest>
Loading