1
0
Fork 0
mirror of https://gitlab.postmarketos.org/postmarketOS/pmaports.git synced 2025-07-24 15:25:13 +03:00

motorola-falcon: split downstream into separate package (MR 6491)

This commit is contained in:
Luca Weiss 2025-05-11 21:33:57 +02:00
parent 9adacec8f6
commit ba3c38b51f
No known key found for this signature in database
GPG key ID: 72D843B89D4DD756
12 changed files with 85 additions and 37 deletions

View file

@ -1,23 +1,23 @@
# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-motorola-falcon
pkgdesc="Moto G (2013)"
pkgver=3
pkgver=4
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="armv7"
options="!check !archcheck"
depends="postmarketos-base mkbootimg soc-qcom-msm8226"
makedepends="devicepkg-dev"
subpackages="
$pkgname-kernel-downstream:kernel_downstream
$pkgname-kernel-mainline:kernel_mainline
$pkgname-nonfree-firmware:nonfree_firmware
depends="
firmware-motorola-falcon
linux-postmarketos-qcom-msm8226
mkbootimg
postmarketos-base
soc-qcom-msm8226
"
makedepends="devicepkg-dev"
source="
deviceinfo
modules-initfs.mainline
modules-initfs
"
build() {
@ -28,25 +28,7 @@ package() {
devicepkg_package $startdir $pkgname
}
kernel_downstream() {
pkgdesc="Downstream kernel"
depends="linux-motorola-falcon msm-fb-refresher"
devicepkg_subpackage_kernel $startdir $pkgname $subpkgname
}
kernel_mainline() {
pkgdesc="Close to mainline kernel"
depends="linux-postmarketos-qcom-msm8226"
devicepkg_subpackage_kernel $startdir $pkgname $subpkgname
}
nonfree_firmware() {
pkgdesc="Wifi firmware"
depends="firmware-motorola-falcon"
mkdir "$subpkgdir"
}
sha512sums="
c7f10570f98bf9080da79c15c93a0e0a9b22895b488ae73e5a0c0e746a9ef68e15525a32cbc68acd30549f8fb9d9577e9fb4781abea4abbcc6c7db50b8538c06 deviceinfo
35701f944fb4d1dd365fb2d3363620271ce748647c7462e9e8d6a2447df766f94cf1d07aa366c66c745fbb0fdaa6960e3f77176f9b6f4f9ca0dbc5d2f5989067 modules-initfs.mainline
d65b09730b3a8e66a2df50f4f594a572bdf28ad78697100d492fdc298a4afb06b0129167e3c4a1462ec7844bff10fa3935a14edc8727b85513337ddf0a58ed6c deviceinfo
35701f944fb4d1dd365fb2d3363620271ce748647c7462e9e8d6a2447df766f94cf1d07aa366c66c745fbb0fdaa6960e3f77176f9b6f4f9ca0dbc5d2f5989067 modules-initfs
"

View file

@ -6,8 +6,8 @@ deviceinfo_name="Motorola Moto G (2013)"
deviceinfo_manufacturer="Motorola"
deviceinfo_codename="motorola-falcon"
deviceinfo_year="2013"
deviceinfo_dtb_mainline="msm8226-motorola-falcon"
deviceinfo_append_dtb_mainline="true"
deviceinfo_dtb="msm8226-motorola-falcon"
deviceinfo_append_dtb="true"
deviceinfo_arch="armv7"
# Device related
@ -20,11 +20,9 @@ deviceinfo_dev_touchscreen="/dev/input/event2"
# Bootloader related
deviceinfo_flash_method="fastboot"
deviceinfo_kernel_cmdline_downstream="androidboot.bootdevice=msm_sdcc.1 androidboot.hardware=qcom vmalloc=400M utags.blkdev=/dev/block/platform/msm_sdcc.1/by-name/utags buildvariant=userdebug"
deviceinfo_kernel_cmdline_mainline="clk_ignore_unused pd_ignore_unused"
deviceinfo_kernel_cmdline="clk_ignore_unused pd_ignore_unused"
deviceinfo_generate_bootimg="true"
deviceinfo_generate_extlinux_config="true"
deviceinfo_bootimg_qcdt_downstream="true"
deviceinfo_flash_offset_base="0x00000000"
deviceinfo_flash_offset_kernel="0x00008000"
deviceinfo_flash_offset_ramdisk="0x01000000"

View file

@ -1,49 +0,0 @@
From aeea3592a13bf12861943e44fc48f1f270941f8d Mon Sep 17 00:00:00 2001
From: Behan Webster <behanw@converseincode.com>
Date: Wed, 24 Sep 2014 01:06:46 +0100
Subject: [PATCH] ARM: 8158/1: LLVMLinux: use static inline in ARM ftrace.h
With compilers which follow the C99 standard (like modern versions of gcc and
clang), "extern inline" does the wrong thing (emits code for an externally
linkable version of the inline function). In this case using static inline
and removing the NULL version of return_address in return_address.c does
the right thing.
Signed-off-by: Behan Webster <behanw@converseincode.com>
Reviewed-by: Mark Charlebois <charlebm@gmail.com>
Acked-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
---
arch/arm/include/asm/ftrace.h | 2 +-
arch/arm/kernel/return_address.c | 5 -----
2 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/arch/arm/include/asm/ftrace.h b/arch/arm/include/asm/ftrace.h
index 39eb16b0066f2..bfe2a2f5a644e 100644
--- a/arch/arm/include/asm/ftrace.h
+++ b/arch/arm/include/asm/ftrace.h
@@ -45,7 +45,7 @@ void *return_address(unsigned int);
#else
-extern inline void *return_address(unsigned int level)
+static inline void *return_address(unsigned int level)
{
return NULL;
}
diff --git a/arch/arm/kernel/return_address.c b/arch/arm/kernel/return_address.c
index fafedd86885dd..f6aa84d5b93c9 100644
--- a/arch/arm/kernel/return_address.c
+++ b/arch/arm/kernel/return_address.c
@@ -63,11 +63,6 @@ void *return_address(unsigned int level)
#warning "TODO: return_address should use unwind tables"
#endif
-void *return_address(unsigned int level)
-{
- return NULL;
-}
-
#endif /* if defined(CONFIG_FRAME_POINTER) && !defined(CONFIG_ARM_UNWIND) / else */
EXPORT_SYMBOL_GPL(return_address);

View file

@ -1,33 +0,0 @@
source:
https://github.com/ShinySide/HispAsian_Lollipop_G6/commit/b7756b6fc4bb728722b14d2dfdbaf1dc843812e9
* These need to be static to avoid these errors:
drivers/built-in.o: In function `.LANCHOR1':
msm_iommu_sec.c:(.data+0x9298): undefined reference to `kgsl_iommu_sync_lock'
msm_iommu_sec.c:(.data+0x929c): undefined reference to `kgsl_iommu_sync_unlock'
Makefile:877: recipe for target '.tmp_vmlinux1' failed
make: *** [.tmp_vmlinux1] Error 1
Signed-off-by: Chet Kener <Cl3Kener@gmail.com>
--- a/drivers/gpu/msm/kgsl_iommu.c
+++ b/drivers/gpu/msm/kgsl_iommu.c
@@ -1010,7 +1010,7 @@ static int kgsl_iommu_init_sync_lock(struct kgsl_mmu *mmu)
*
* Return - int - number of commands.
*/
-inline unsigned int kgsl_iommu_sync_lock(struct kgsl_mmu *mmu,
+static inline unsigned int kgsl_iommu_sync_lock(struct kgsl_mmu *mmu,
unsigned int *cmds)
{
struct kgsl_device *device = mmu->device;
@@ -1080,7 +1080,7 @@ inline unsigned int kgsl_iommu_sync_lock(struct kgsl_mmu *mmu,
*
* Return - int - number of commands.
*/
-inline unsigned int kgsl_iommu_sync_unlock(struct kgsl_mmu *mmu,
+static inline unsigned int kgsl_iommu_sync_unlock(struct kgsl_mmu *mmu,
unsigned int *cmds)
{
struct kgsl_device *device = mmu->device;

View file

@ -1,14 +0,0 @@
Fixes incorrect panel refresh rate, makes it constant
diff --git a/drivers/video/msm/mdss/mdss_fb.c b/drivers/video/msm/mdss/mdss_fb.c
index b37fd1e07ac1..1f091a261d22 100644
--- a/drivers/video/msm/mdss/mdss_fb.c
+++ b/drivers/video/msm/mdss/mdss_fb.c
@@ -2668,7 +2668,7 @@ static int mdss_fb_register(struct msm_fb_data_type *mfd)
var->left_margin = panel_info->lcdc.h_back_porch;
var->right_margin = panel_info->lcdc.h_front_porch;
var->hsync_len = panel_info->lcdc.h_pulse_width;
- var->pixclock = panel_info->clk_rate / 1000;
+ var->pixclock = 1000000 / 60;
/*
* Store the cont splash state in the var reserved[3] field.

View file

@ -1,67 +0,0 @@
# Kernel config based on: arch/arm/configs/falcon_defconfig
pkgname=linux-motorola-falcon
pkgver=3.4.113
pkgrel=10
pkgdesc="Moto G (2013) kernel fork"
arch="armv7"
_carch="arm"
_flavor="motorola-falcon"
url="https://kernel.org"
license="GPL2"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="coreutils perl sed installkernel bash gmp-dev bc linux-headers elfutils-dev devicepkg-dev xz dtbtool 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.
if [ "${CC:0:5}" != "gcc6-" ]; then
CC="gcc6-$CC"
HOSTCC="gcc6-gcc"
CROSS_COMPILE="gcc6-$CROSS_COMPILE"
fi
# Source
_repository="android_kernel_motorola_msm8226"
_commit="22bc4ed7f4149f95c84634e6c1baccbbd16c5cc5"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://github.com/LineageOS/$_repository/archive/$_commit.tar.gz
$_config
00_fix_return_address.patch
02_gpu-msm-fix-gcc5-compile.patch
03_mdss_fb_refresh_rate.patch
gcc10-extern_YYLOC_global_declaration.patch
fix_redish_display.patch
"
builddir="$srcdir/$_repository-$_commit"
prepare() {
default_prepare
. downstreamkernel_prepare
}
build() {
unset LDFLAGS
make ARCH="$_carch" CC="${CC:-gcc}" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
# Generate master DTB
dtbTool -s 2048 -p "scripts/dtc/" -o "arch/arm/boot/dt.img" "arch/arm/boot/"
}
package() {
downstreamkernel_package "$builddir" "$pkgdir" "$_carch" "$_flavor"
# We need the dtb file
install -Dm644 "$builddir/arch/arm/boot/dt.img" \
"$pkgdir/boot/dt.img"
}
sha512sums="5e55db19f198fadf0f914c2726c034eeaf9a1f4ad5823a7e8a4e9be2664eb0279c91fb2f1c6a9292be2ac523e367551475ff40569676775a03a709ae50a3d0ec linux-motorola-falcon-22bc4ed7f4149f95c84634e6c1baccbbd16c5cc5.tar.gz
b2b0384dc9402e1d53a0856a4be2b1f098d1d50ce7e5e7dc4f562db96b0f58469d4ae34db7148e7f2b7c065624ff365ec1dc100573fde873819a814a78d72007 config-motorola-falcon.armv7
ea1d3b5a234fa565e3c1a792de48f4fc4e6023d281d303c8e319c7ef28edc5739ab0e4dea0139a41f0a5c7d03e27921ccaa214fd0ac5c72245a094ce60128864 00_fix_return_address.patch
7be03a9e78b7ac330a54b1f00509caa0621a95c0c55901878ad757f9dd69cc05ba2c8b5ea987063ae1224f92c4d090d515fa5d369e7755181a4871b0d0f82881 02_gpu-msm-fix-gcc5-compile.patch
83e52e5c5eb9721fe256c04f371197e9befeb129c6a0826c134000b96f8c1987f5634a6a207f1924bd2e833c7822866794742b91b1833d14998d80b5c1d5e646 03_mdss_fb_refresh_rate.patch
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
ebd2ff424c889775fce822da3dbdf580ff339bfd1a01739b19be9cb8f4edd176468e421d6bd3bbd6fefc302a2e656048d38fdc0760e6a2fb6bc072817a6d3a13 fix_redish_display.patch"

View file

@ -1,13 +0,0 @@
diff --git a/drivers/video/msm/mdss/mdss_fb.c b/drivers/video/msm/mdss/mdss_fb.c
index 53112ca6..69673017 100644
--- a/drivers/video/msm/mdss/mdss_fb.c
+++ b/drivers/video/msm/mdss/mdss_fb.c
@@ -569,7 +569,7 @@ static int mdss_fb_probe(struct platform_device *pdev)
mfd->bl_level = 0;
mfd->bl_scale = 1024;
mfd->bl_min_lvl = 30;
- mfd->fb_imgType = MDP_RGBA_8888;
+ mfd->fb_imgType = MDP_RGB_888;
mfd->pdev = pdev;
if (pdata->next)

View file

@ -1 +0,0 @@
../../.shared-patches/linux/gcc10-extern_YYLOC_global_declaration.patch