From a15917fcf84019f89e58ce164feb4c6dde780fb0 Mon Sep 17 00:00:00 2001 From: SagarMakhar Date: Mon, 21 Jun 2021 03:15:19 +0000 Subject: [PATCH] RMX2170: Initial device tree for Realme 7 pro Signed-off-by: SagarMakhar --- Android.bp | 5 +++++ Android.mk | 20 ++++++++++++++++++++ AndroidProducts.mk | 8 ++++++++ BoardConfig.mk | 16 ++++++++++++++++ README.md | 25 +++++++++++++++++++++++++ aosp_RMX2170.mk | 32 ++++++++++++++++++++++++++++++++ device.mk | 15 +++++++++++++++ extract-files.sh | 23 +++++++++++++++++++++++ proprietary-files.txt | 0 setup-makefiles.sh | 17 +++++++++++++++++ 10 files changed, 161 insertions(+) create mode 100644 Android.bp create mode 100644 Android.mk create mode 100644 AndroidProducts.mk create mode 100644 BoardConfig.mk create mode 100644 README.md create mode 100644 aosp_RMX2170.mk create mode 100644 device.mk create mode 100755 extract-files.sh create mode 100644 proprietary-files.txt create mode 100755 setup-makefiles.sh diff --git a/Android.bp b/Android.bp new file mode 100644 index 0000000..1dc4197 --- /dev/null +++ b/Android.bp @@ -0,0 +1,5 @@ +soong_namespace { + imports: [ + "device/realme/sm7125-common", + ], +} diff --git a/Android.mk b/Android.mk new file mode 100644 index 0000000..97df4e7 --- /dev/null +++ b/Android.mk @@ -0,0 +1,20 @@ +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# This contains the module build definitions for the hardware-specific +# components for this device. +# +# As much as possible, those components should be built unconditionally, +# with device-specific names to avoid collisions, to avoid device-specific +# bitrot and build breakages. Building a component unconditionally does +# *not* include it on all devices, so it is safe even with hardware-specific +# components. + +LOCAL_PATH := $(call my-dir) + +ifeq ($(TARGET_DEVICE),RMX2170) +include $(call all-makefiles-under,$(LOCAL_PATH)) +endif diff --git a/AndroidProducts.mk b/AndroidProducts.mk new file mode 100644 index 0000000..8953d13 --- /dev/null +++ b/AndroidProducts.mk @@ -0,0 +1,8 @@ +# +# Copyright (C) 2020 The DotOS +# +# SPDX-License-Identifier: Apache-2.0 +# + +PRODUCT_MAKEFILES := \ + $(LOCAL_DIR)/aosp_RMX2170.mk diff --git a/BoardConfig.mk b/BoardConfig.mk new file mode 100644 index 0000000..6354900 --- /dev/null +++ b/BoardConfig.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# Inherit from sm7125-common +include device/realme/sm7125-common/BoardConfigCommon.mk + +# Inherit proprietary blobs +-include vendor/realme/RMX2170/BoardConfigVendor.mk + +DEVICE_PATH := device/realme/RMX2170 + +# OTA assert +#TARGET_OTA_ASSERT_DEVICE := RMX2170 diff --git a/README.md b/README.md new file mode 100644 index 0000000..7bb32b0 --- /dev/null +++ b/README.md @@ -0,0 +1,25 @@ +The Realme 7 Pro (codenamed _"RMX2170"_) is a mid-range smartphone from OPPO's sub-brand Realme launched in Sept. 2020. + +## Device specifications + +| Device | Realme 7 Pro | +| ----------------------- | :---------------------------------------------------------- | +| SoC | Qualcomm SM7125 Snapdragon 720G | +| CPU | Qualcomm® Kryo™ 465, 2x Gold @ 2.3GHz & 6x Silver @ 1.8GHz | +| GPU | Adreno 618 | +| Memory | 6/8 GB RAM (LPDDR4X) | +| Shipped Android version | 10 with RealmeUI 1.0 | +| Storage | 128GB eMMC 5.1 flash storage | +| MicroSD | Up to 512 GB | +| Battery | Non-removable Li-Ion 4500 mAh | +| Dimensions | 160.90 x 74.30 x 8.70 mm | +| Display | 2400 x 1080 (20:9), 6.40 inch | +| Rear camera 1 | 64 MP, f/1.8, standard, 1/1.72", 1.12µm, PDAF | +| Rear camera 2 | 8 MP, f/2.3, wideangle, 1/4", 1.12µm | +| Rear camera 4 | 2 MP, f/2.4, portrait, 1.75µm | +| Front camera | 32 MP, f/2.5, macro, 1/4", 1.00µm | + + +## Device picture + +![Realme 7 Pro](https://st1.bgr.in/wp-content/uploads/2020/09/realme-7-pro.jpg) diff --git a/aosp_RMX2170.mk b/aosp_RMX2170.mk new file mode 100644 index 0000000..13bc354 --- /dev/null +++ b/aosp_RMX2170.mk @@ -0,0 +1,32 @@ +# +# Copyright (C) 2020 The DotOS +# +# SPDX-License-Identifier: Apache-2.0 +# + +# Inherit from RMX2170 device +$(call inherit-product, device/realme/RMX2170/device.mk) + +# Inherit some common AospExtended stuff +$(call inherit-product, vendor/aosp/common.mk) + +# Bootanimation Resolution +TARGET_BOOT_ANIMATION_RES := 1080 + +# Device identifier +PRODUCT_NAME := aosp_RMX2170 +PRODUCT_DEVICE := RMX2170 +PRODUCT_BRAND := Realme +PRODUCT_MODEL := Realme 7 Pro +PRODUCT_MANUFACTURER := Xiaomi + +PRODUCT_GMS_CLIENTID_BASE := android-realme + +PRODUCT_BUILD_PROP_OVERRIDES += \ + PRIVATE_BUILD_DESC="atoll-user 11 RKQ1.200903.002/ eng.root.04080114.013112 release-keys" + +BUILD_FINGERPRINT := "qti/atoll/atoll:11/RKQ1.200903.002/root04080114:user/release-keys" + +PRODUCT_BUILD_PROP_OVERRIDES += \ + PRODUCT_NAME="RMX2170" \ + TARGET_DEVICE="RMX2170" diff --git a/device.mk b/device.mk new file mode 100644 index 0000000..f01e48d --- /dev/null +++ b/device.mk @@ -0,0 +1,15 @@ +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# Inherit from sm7125-common +$(call inherit-product, device/realme/sm7125-common/common.mk) + +# Inherit proprietary targets +$(call inherit-product-if-exists, vendor/realme/RMX2170/RMX2170-vendor.mk) + +# Soong namespaces +PRODUCT_SOONG_NAMESPACES += \ + $(LOCAL_PATH) diff --git a/extract-files.sh b/extract-files.sh new file mode 100755 index 0000000..cb4d3c1 --- /dev/null +++ b/extract-files.sh @@ -0,0 +1,23 @@ +#!/bin/bash +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# If we're being sourced by the common script that we called, +# stop right here. No need to go down the rabbit hole. +if [ "${BASH_SOURCE[0]}" != "${0}" ]; then + return +fi + +set -e + +# Required! +export DEVICE=RMX2170 +export DEVICE_COMMON=sm7125-common +export VENDOR=realme + +export DEVICE_BRINGUP_YEAR=2020 + +"./../../${VENDOR}/${DEVICE_COMMON}/extract-files.sh" "$@" diff --git a/proprietary-files.txt b/proprietary-files.txt new file mode 100644 index 0000000..e69de29 diff --git a/setup-makefiles.sh b/setup-makefiles.sh new file mode 100755 index 0000000..8c22c80 --- /dev/null +++ b/setup-makefiles.sh @@ -0,0 +1,17 @@ +#!/bin/bash +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +set -e + +# Required! +export DEVICE=RMX2170 +export DEVICE_COMMON=sm7125-common +export VENDOR=realme + +export DEVICE_BRINGUP_YEAR=2020 + +"./../../${VENDOR}/${DEVICE_COMMON}/setup-makefiles.sh" "$@"