From 318eac2fa92f2623373a13fb9a00f3b7a8c10490 Mon Sep 17 00:00:00 2001 From: Danny Wood Date: Thu, 25 Apr 2019 14:08:21 +0100 Subject: [PATCH] a7xelte: Initial device tree Change-Id: I27ba9d9b27be581499171d86bb726c8b06331537 --- Android.mk | 23 +++++++++++++++++++ AndroidProducts.mk | 20 ++++++++++++++++ BoardConfig.mk | 20 ++++++++++++++++ device.mk | 26 +++++++++++++++++++++ full_a7xelte.mk | 28 +++++++++++++++++++++++ lineage.mk | 29 +++++++++++++++++++++++ ramdisk/Android.mk | 12 ++++++++++ ramdisk/etc/init.target.rc | 47 ++++++++++++++++++++++++++++++++++++++ 8 files changed, 205 insertions(+) create mode 100644 Android.mk create mode 100644 AndroidProducts.mk create mode 100644 BoardConfig.mk create mode 100644 device.mk create mode 100644 full_a7xelte.mk create mode 100644 lineage.mk create mode 100644 ramdisk/Android.mk create mode 100644 ramdisk/etc/init.target.rc diff --git a/Android.mk b/Android.mk new file mode 100644 index 0000000..fc793c3 --- /dev/null +++ b/Android.mk @@ -0,0 +1,23 @@ +# +# Copyright (C) 2018 The LineageOS 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. +# + +LOCAL_PATH := device/samsung/a7xelte + +ifneq ($(filter a7xelte,$(TARGET_DEVICE)),) + +include $(call all-makefiles-under,$(LOCAL_PATH)) + +endif diff --git a/AndroidProducts.mk b/AndroidProducts.mk new file mode 100644 index 0000000..29dadcc --- /dev/null +++ b/AndroidProducts.mk @@ -0,0 +1,20 @@ +# +# Copyright (C) 2018 The LineageOS 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. +# + +LOCAL_PATH := device/samsung/a7xelte + +PRODUCT_MAKEFILES := \ + $(LOCAL_PATH)/full_a7xelte.mk diff --git a/BoardConfig.mk b/BoardConfig.mk new file mode 100644 index 0000000..3c542e3 --- /dev/null +++ b/BoardConfig.mk @@ -0,0 +1,20 @@ +# +# Copyright (C) 2018 The LineageOS 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. +# + +# Inherit from universal7580-common +include device/samsung/universal7580-common/BoardConfigCommon.mk + +LOCAL_PATH := device/samsung/a7xelte diff --git a/device.mk b/device.mk new file mode 100644 index 0000000..1ee61e5 --- /dev/null +++ b/device.mk @@ -0,0 +1,26 @@ +# +# Copyright (C) 2018 The LineageOS 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. +# + +LOCAL_PATH := device/samsung/a7xelte + +$(call inherit-product, $(SRC_TARGET_DIR)/product/languages_full.mk) + +# Ramdisk +PRODUCT_PACKAGES += \ + init.target.rc + +# Inherit from universal7580-common +$(call inherit-product, device/samsung/universal7580-common/device-common.mk) diff --git a/full_a7xelte.mk b/full_a7xelte.mk new file mode 100644 index 0000000..9dd9036 --- /dev/null +++ b/full_a7xelte.mk @@ -0,0 +1,28 @@ +# +# Copyright (C) 2018 The LineageOS 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. +# + +LOCAL_PATH := device/samsung/a7xelte + +# Inherit from those products. Most specific first. +$(call inherit-product, $(LOCAL_PATH)/device.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/full_base_telephony.mk) + +# Set those variables here to overwrite the inherited values. +PRODUCT_NAME := full_a7xelte +PRODUCT_DEVICE := a7xelte +PRODUCT_MODEL := SM-A710F +PRODUCT_BRAND := Samsung +PRODUCT_MANUFACTURER := samsung diff --git a/lineage.mk b/lineage.mk new file mode 100644 index 0000000..0a84207 --- /dev/null +++ b/lineage.mk @@ -0,0 +1,29 @@ +# +# Copyright (C) 2018 The LineageOS 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. +# + +LOCAL_PATH := device/samsung/a7xelte + +$(call inherit-product, $(LOCAL_PATH)/full_a7xelte.mk) + +# Inherit some common Lineage stuff. +$(call inherit-product, vendor/lineage/config/common_full_phone.mk) + +# Set those variables here to overwrite the inherited values. +PRODUCT_NAME := lineage_a7xelte +PRODUCT_DEVICE := a7xelte +PRODUCT_MODEL := SM-a710F +PRODUCT_BRAND := Samsung +PRODUCT_MANUFACTURER := samsung diff --git a/ramdisk/Android.mk b/ramdisk/Android.mk new file mode 100644 index 0000000..6685b24 --- /dev/null +++ b/ramdisk/Android.mk @@ -0,0 +1,12 @@ +LOCAL_PATH := $(call my-dir) + +# Init scripts + +include $(CLEAR_VARS) +LOCAL_MODULE := init.target.rc +LOCAL_MODULE_TAGS := optional eng +LOCAL_MODULE_CLASS := ETC +LOCAL_SRC_FILES := etc/init.target.rc +LOCAL_MODULE_PATH := $(TARGET_ROOT_OUT) +include $(BUILD_PREBUILT) + diff --git a/ramdisk/etc/init.target.rc b/ramdisk/etc/init.target.rc new file mode 100644 index 0000000..17c6292 --- /dev/null +++ b/ramdisk/etc/init.target.rc @@ -0,0 +1,47 @@ +on boot + # Assign TCP buffer thresholds to be ceiling value of technology maximums + # Increased technology maximums should be reflected here. + write /proc/sys/net/core/rmem_max 2097152 + write /proc/sys/net/core/wmem_max 2097152 + +on fs + # Permissions for LCD + chown system system /sys/class/lcd/panel/ldu_correction + chown system system /sys/class/lcd/panel/lux + chown system media_rw /sys/class/lcd/panel/adaptive_control + + # Permissions for Touchkey + chown system radio /sys/class/sec/sec_touchkey/sar_enable + chown system radio /sys/class/sec/sec_touchkey/sw_reset + chown system radio /sys/class/sec/sec_touchkey/touchkey_earjack + + # Accelerometer_sensor + chown system radio /sys/class/sensors/accelerometer_sensor/mcu_rev + chown system radio /sys/class/sensors/accelerometer_sensor/mcu_name + + # Fingerprint_sensor + chown system radio /sys/class/fingerprint/fingerprint/type_check + chown system radio /sys/class/fingerprint/fingerprint/name + chown system radio /sys/class/fingerprint/fingerprint/vendor + + # BHY + chown system radio /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/event_shealth_int + chown system radio /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/pedometer_steps + chown system radio /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_cadence + chown system radio /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_cadence_enable + chown system radio /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_enable + chown system radio /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_flush_cadence + chmod 660 /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/event_shealth_int + chmod 660 /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/pedometer_steps + chmod 660 /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_cadence_enable + chmod 660 /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_enable + chmod 660 /sys/devices/13870000.hsi2c/i2c-0/0-0028/iio:device0/shealth_flush_cadence + +on property:sys.boot_completed=1 + write /proc/sys/vm/dirty_bytes 41943040 + write /proc/sys/vm/dirty_background_bytes 20971520 + + # Set best cache size for internal and external storages + write /sys/block/mmcblk0/bdi/read_ahead_kb 128 + write /sys/block/mmcblk1/bdi/read_ahead_kb 2048 + -- 2.20.1