xiaomi-santoni: use msm-3.18 upstream kernel (!289)

device-xiaomi-santoni: use mdss-fb-init-hack to refresh the display, and
swapfile to fix "out of memory" when loading proprietary blobs.

I have tested the kernel, USB Networking, Display, USB OTG, Wi-Fi (with
proprietary blobs) works fine, through I haven't figured out how to get
Bluetooth and among of other stuff to work. Audio works. For more
information on how to get Wi-Fi and Audio to work, check out the wiki
page for this device, I have updated it.

[ci:skip-build]: already built successfully in CI
This commit is contained in:
Danct12 2019-03-25 19:29:19 +07:00 committed by Oliver Smith
parent c6aae11598
commit 95198e12e9
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB
6 changed files with 376 additions and 277 deletions

View file

@ -2,12 +2,12 @@
pkgname="device-xiaomi-santoni"
pkgdesc="Xiaomi Redmi 4X"
pkgver=0.1
pkgrel=2
pkgrel=3
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="postmarketos-base linux-xiaomi-santoni mkbootimg mesa-dri-swrast msm-fb-refresher"
depends="postmarketos-base linux-xiaomi-santoni mkbootimg mesa-dri-swrast mdss-fb-init-hack"
makedepends="devicepkg-dev"
source="deviceinfo"
@ -19,4 +19,4 @@ package() {
devicepkg_package $startdir $pkgname
}
sha512sums="eefcaf34229346068244d511e6a4006c04ebc45849468d3f955fa9f71bac78681817f43a526d4cd6716a608e00c84c484d37726ab7940f652e336ada1289b98e deviceinfo"
sha512sums="827454ba88387de7b3493c087533b0a560a636e52f7cc00e05309e1de7eaf3ce39c869f52535245b47492e63ba38e8c30a793c5220a1e70b54f3a54e92f73c5a deviceinfo"

View file

@ -1,11 +1,11 @@
# Reference: <https://postmarketos.org/deviceinfo>
# Please use double quotes only. You can source this file in shell scripts.
deviceinfo_format_version="0"
deviceinfo_format_version="1"
deviceinfo_name="Xiaomi Redmi 4X"
deviceinfo_manufacturer="Xiaomi"
deviceinfo_codename="xiaomi-santoni"
deviceinfo_date=""
deviceinfo_date="04/29/2017 (Malaysia)"
deviceinfo_dtb=""
deviceinfo_modules_initfs=""
deviceinfo_arch="aarch64"
@ -15,14 +15,14 @@ deviceinfo_keyboard="false"
deviceinfo_external_storage="true"
deviceinfo_screen_width="1280"
deviceinfo_screen_height="720"
deviceinfo_dev_touchscreen=""
deviceinfo_dev_touchscreen_calibration=""
deviceinfo_dev_touchscreen="/dev/input/event1"
deviceinfo_dev_touchscreen_calibration=""
deviceinfo_dev_keyboard=""
deviceinfo_swap_size_recommended="1024"
# Bootloader related
deviceinfo_flash_method="fastboot"
deviceinfo_kernel_cmdline="androidboot.hardware=qcom msm_rtb.filter=0x237 ehci-hcd.park=3 lpm_levels.sleep_disabled=1 androidboot.bootdevice=7824900.sdhci earlycon=msm_hsl_uart,0x78B0000 androidboot.selinux=permissive buildvariant=eng"
deviceinfo_kernel_cmdline="androidboot.hardware=qcom msm_rtb.filter=0x237 ehci-hcd.park=3 lpm_levels.sleep_disabled=1 androidboot.bootdevice=7824900.sdhci earlycon=msm_hsl_uart,0x78B0000 androidboot.selinux=permissive buildvariant=userdebug"
deviceinfo_generate_bootimg="true"
deviceinfo_bootimg_qcdt="false"
deviceinfo_flash_offset_base="0x80000000"

View file

@ -1,13 +0,0 @@
diff --git a/drivers/video/msm/msm_dba/msm_dba.c b/drivers/video/msm/msm_dba/msm_dba.c
index cc6512a..eb073a7 100644
--- a/drivers/video/msm/msm_dba/msm_dba.c
+++ b/drivers/video/msm/msm_dba/msm_dba.c
@@ -22,7 +22,7 @@
#include <linux/err.h>
#include <video/msm_dba.h>
-#include <msm_dba_internal.h>
+#include "msm_dba_internal.h"
static DEFINE_MUTEX(register_mutex);

View file

@ -1,22 +0,0 @@
diff --git a/drivers/net/ethernet/msm/rndis_ipa_trace.h b/drivers/net/ethernet/msm/rndis_ipa_trace.h
index c0fc573..c18046b 100644
--- a/drivers/net/ethernet/msm/rndis_ipa_trace.h
+++ b/drivers/net/ethernet/msm/rndis_ipa_trace.h
@@ -77,5 +77,5 @@ TRACE_EVENT(
/* This part must be outside protection */
#undef TRACE_INCLUDE_PATH
-#define TRACE_INCLUDE_PATH .
+#define TRACE_INCLUDE_PATH ../../drivers/net/ethernet/msm/
#include <trace/define_trace.h>
diff --git a/drivers/platform/msm/ipa/ipa_v2/ipa_trace.h b/drivers/platform/msm/ipa/ipa_v2/ipa_trace.h
index d70abdf..7f7e452 100644
--- a/drivers/platform/msm/ipa/ipa_v2/ipa_trace.h
+++ b/drivers/platform/msm/ipa/ipa_v2/ipa_trace.h
@@ -131,5 +131,5 @@ TRACE_EVENT(
/* This part must be outside protection */
#undef TRACE_INCLUDE_PATH
-#define TRACE_INCLUDE_PATH .
+#define TRACE_INCLUDE_PATH ../../drivers/platform/msm/ipa/ipa_v2/
#include <trace/define_trace.h>

View file

@ -1,9 +1,9 @@
# Kernel config based on: arch/arm64/configs/S88536AA2-perf_defconfig
pkgname="linux-xiaomi-santoni"
pkgver=3.18.31
pkgrel=2
pkgdesc="Xiaomi Redmi 4X kernel fork"
pkgver=3.18.136
pkgrel=0
pkgdesc="Xiaomi Redmi 4X kernel fork - msm-3.18 rebased"
arch="aarch64"
_carch="arm64"
_flavor="xiaomi-santoni"
@ -12,9 +12,8 @@ license="GPL2"
options="!strip !check !tracedeps"
makedepends="perl sed installkernel bash gmp-dev bc linux-headers elfutils-dev gcc6"
# Compiler: this kernel was only tested with GCC6. Feel free to make a merge
# request if you find out that it is booting working with newer GCCs as
# well. See <https://postmarketos.org/vendorkernel> for instructions.
# Tested with GCC-8, won't boot, PSTORE doesn't work so no logs are provided.
# Looks like we're stuck with GCC-6. For a while, through.
if [ "${CC:0:5}" != "gcc6-" ]; then
CC="gcc6-$CC"
HOSTCC="gcc6-gcc"
@ -22,15 +21,13 @@ if [ "${CC:0:5}" != "gcc6-" ]; then
fi
# Source
_repository="Xiaomi_Kernel_OpenSource"
_commit="09baf1a3dd0e13a81e484035f0be71dcb2ecc723"
_repository="msm-3.18"
_commit="adc4e69112d26b6b74c1b3f7e890109faf7c6a7e"
_config="config-${_flavor}.${arch}"
source="
$pkgname-$_commit.tar.gz::https://github.com/MiCode/${_repository}/archive/${_commit}.tar.gz
$pkgname-$_commit.tar.gz::https://github.com/Danct12/${_repository}/archive/${_commit}.tar.gz
$_config
compiler-gcc6.h
02_fix_msm_dba.patch
03_fix_rndis_ipa_trace_header_not_found.patch
"
builddir="$srcdir/${_repository}-${_commit}"
@ -80,8 +77,6 @@ package() {
fi
}
sha512sums="f776fe0fbb5e155da8af9cbcb29bd7f712a74d3ae6f4617e5d31b119b5ff160e66196e8be107a7216d670cad7be89c108426fef5b2cd3f2baedbf8496db9f4f6 linux-xiaomi-santoni-09baf1a3dd0e13a81e484035f0be71dcb2ecc723.tar.gz
e5e84c9eb1dcd14a81c00000d35b0af506869aaaa5845cb6213e9a2eaee0150f342b9e6c6f80723923b32165f7750ee05483c1f03ce763e358514b2970ec0d7f config-xiaomi-santoni.aarch64
d80980e9474c82ba0ef1a6903b434d8bd1b092c40367ba543e72d2c119301c8b2d05265740e4104ca1ac5d15f6c4aa49e8776cb44264a9a28dc551e0d1850dcc compiler-gcc6.h
7e765cb696fa8c3dfbc305b05cbf1fad85fb9572613d5391e945341dae5974a745f4906c795dc841e5562b19ab77d5257f9741e514af2c2573aa4bb8b262ce51 02_fix_msm_dba.patch
9c549714f03c7a7666e8aa7508a48cfdccab7cf3e97fb59c4df8fa97f75492365926f82c4a677c50780d68d4905504dcccbdd6de6344bd8d4b88b2331933ed46 03_fix_rndis_ipa_trace_header_not_found.patch"
sha512sums="66d3fe05d7cfaae719608f349a557ca331de86d74023a26e97710e1ac756892e9f690cdfc353058e12a41ae0927aaaf7506739a009433465fe372a52964af6aa linux-xiaomi-santoni-adc4e69112d26b6b74c1b3f7e890109faf7c6a7e.tar.gz
4bf0b6ac007aa32c3739b6a4aeae589612995a2a333445619a4e50e3551a2ee80b6f42e31252ac5a55537bf7ce0d9a1e43a748a46bd74ead4a6e36ad34b63539 config-xiaomi-santoni.aarch64
d80980e9474c82ba0ef1a6903b434d8bd1b092c40367ba543e72d2c119301c8b2d05265740e4104ca1ac5d15f6c4aa49e8776cb44264a9a28dc551e0d1850dcc compiler-gcc6.h"

File diff suppressed because it is too large Load diff