device/linux-zte-p731a20: fix starting Xorg (!877)
This commit is contained in:
parent
1c46348201
commit
b80714ba8a
3 changed files with 53 additions and 10 deletions
|
@ -3,7 +3,7 @@
|
|||
|
||||
pkgname="linux-zte-p731a20"
|
||||
pkgver=3.10.17
|
||||
pkgrel=0
|
||||
pkgrel=1
|
||||
pkgdesc="ZTE_P731A20 kernel"
|
||||
arch="armv7"
|
||||
_carch="arm"
|
||||
|
@ -19,17 +19,19 @@ HOSTCC="${HOSTCC#${CROSS_COMPILE}}"
|
|||
|
||||
# Source
|
||||
_repository="android_kernel_zte_P731A20"
|
||||
_commit="a1b2e761517f0e2bed0dd5e1a94053d7c648614d"
|
||||
_config="config-${_flavor}.${arch}"
|
||||
_commit="0004a6b85c34e31dacbb49525e608ad75e167082"
|
||||
_config="config-$_flavor.$arch"
|
||||
source="
|
||||
$pkgname-$_commit.tar.gz::https://github.com/blade-af3/${_repository}/archive/${_commit}.tar.gz
|
||||
$pkgname-$_commit.tar.gz::https://github.com/ave4/$_repository/archive/$_commit.tar.gz
|
||||
$_config
|
||||
gcc7-give-up-on-ilog2-const-optimizations.patch
|
||||
gcc8-fix-put-user.patch
|
||||
00_return_address.patch
|
||||
fix_cross_compile.patch
|
||||
qcom,msm-id_fix.patch"
|
||||
builddir="$srcdir/${_repository}-${_commit}"
|
||||
qcom,msm-id_fix.patch
|
||||
sprdfb-fix-swapped-colors.patch
|
||||
sprdfb-check-for-buffering.patch"
|
||||
builddir="$srcdir/$_repository-$_commit"
|
||||
|
||||
prepare() {
|
||||
default_prepare
|
||||
|
@ -64,10 +66,12 @@ echo "--[ Installing modules ]--"
|
|||
INSTALL_MOD_PATH="$pkgdir" INSTALL_MOD_STRIP=1 modules_install
|
||||
}
|
||||
|
||||
sha512sums="e29e9b242c235fe48278643a5ee4bb487c6a7cab09b23a16f796b945371da5505cdd3791b322837d29df4a401a91373f0a65c01794ad4576b2ab925487cdc64d linux-zte-p731a20-a1b2e761517f0e2bed0dd5e1a94053d7c648614d.tar.gz
|
||||
sha512sums="38600cd20cd22e1ac7636597f5b1fbf6ef60e918f4d197ee8ac8073eb6740cec33147fd5a381a587fe74861bddd7a6d45617e80e38f0e072f731198211c5bcf8 linux-zte-p731a20-0004a6b85c34e31dacbb49525e608ad75e167082.tar.gz
|
||||
ed722be637b335cdb5b2a7a231a5253235c250cd904506808bc99a560db2b91f61b52104d4943164f2223afac5d50df23222ada16d4ed3affdd014e97ff555eb config-zte-p731a20.armv7
|
||||
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
|
||||
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
|
||||
c40eaa11547f5bc2b1ff965506bdfe3015ff16e4b5ad9ccb3b8134ceafd1d32407c4ef2b213e02e036ce1e9bdcbfe768dff7d4b054bec77705a176c1f783b6f5 00_return_address.patch
|
||||
2bedb0af8a23f5febc5f23a41c91174bffa5cb3b9af699fd61c86089a5bead77a08aca23daa62a3b7e93845e9cf86a1f5cc2a5fb4c4a56af09cf5befa2287d31 fix_cross_compile.patch
|
||||
0b3ae537793ebd6d24dfca9ec81674fc14b2aece4592bf2700795382f059501285a3e673c02a7114e8239040d41e096b10b819173f14ef837346ed60b0f55574 qcom,msm-id_fix.patch"
|
||||
0b3ae537793ebd6d24dfca9ec81674fc14b2aece4592bf2700795382f059501285a3e673c02a7114e8239040d41e096b10b819173f14ef837346ed60b0f55574 qcom,msm-id_fix.patch
|
||||
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch
|
||||
e33ed12de874c1c8bc9231aea3b0389b18ee0ff804e39c0f47d9cbf657ea19015370d6114846c2d142fbdb88f472f0e65811c53b9b335feb8ae2f30dffdf4846 sprdfb-check-for-buffering.patch"
|
||||
|
|
24
device/linux-zte-p731a20/sprdfb-check-for-buffering.patch
Executable file
24
device/linux-zte-p731a20/sprdfb-check-for-buffering.patch
Executable file
|
@ -0,0 +1,24 @@
|
|||
sprdfb_check_var() has two problems:
|
||||
I) it is not buffering-aware, which all Spreadtrum devices use;
|
||||
II) it checks values that are already in yres_virtual, not those that we
|
||||
are trying to overwrite.
|
||||
Those problems stop X11 and charging-sdl from working properly.
|
||||
X11 error:
|
||||
(EE) FBDEV(0): FBIOPUT_VSCREENINFO: Invalid argument
|
||||
This patch fixes first problem, however, the correct way is fixing
|
||||
the second one, as this might have less side effects.
|
||||
|
||||
diff --git a/drivers/video/sprdfb/sprdfb_main.c b/drivers/video/sprdfb/sprdfb_main.c
|
||||
index 43876285..751616a1 100644
|
||||
--- a/drivers/video/sprdfb/sprdfb_main.c
|
||||
+++ b/drivers/video/sprdfb/sprdfb_main.c
|
||||
@@ -531,7 +531,8 @@ static int sprdfb_check_var(struct fb_var_screeninfo *var, struct fb_info *fb)
|
||||
if ((var->xres != fb->var.xres) ||
|
||||
(var->yres != fb->var.yres) ||
|
||||
(var->xres_virtual != fb->var.xres_virtual) ||
|
||||
- (var->yres_virtual != fb->var.yres_virtual) ||
|
||||
+ // (var->yres_virtual != fb->var.yres_virtual) ||
|
||||
+ (fb->var.yres_virtual % var->yres_virtual != 0) ||
|
||||
(var->xoffset != fb->var.xoffset) ||
|
||||
#ifndef BIT_PER_PIXEL_SURPPORT
|
||||
(var->bits_per_pixel != fb->var.bits_per_pixel) ||
|
15
device/linux-zte-p731a20/sprdfb-fix-swapped-colors.patch
Executable file
15
device/linux-zte-p731a20/sprdfb-fix-swapped-colors.patch
Executable file
|
@ -0,0 +1,15 @@
|
|||
By default, color channels on Spreadtrum devices are swapped. This patch makes kernel use BGR565, which has normal color channels.
|
||||
|
||||
diff --git a/drivers/video/sprdfb/sprdfb_main.c b/drivers/video/sprdfb/sprdfb_main.c
|
||||
index 3e6c70d..80fceb9 100644
|
||||
--- a/drivers/video/sprdfb/sprdfb_main.c
|
||||
+++ b/drivers/video/sprdfb/sprdfb_main.c
|
||||
@@ -51,7 +51,7 @@ enum{
|
||||
SPRD_IN_DATA_TYPE_LIMIT
|
||||
};
|
||||
|
||||
-#define SPRDFB_IN_DATA_TYPE SPRD_IN_DATA_TYPE_ABGR888
|
||||
+#define SPRDFB_IN_DATA_TYPE SPRD_IN_DATA_TYPE_BGR565
|
||||
|
||||
#ifdef CONFIG_FB_TRIPLE_FRAMEBUFFER
|
||||
#define FRAMEBUFFER_NR (3)
|
Loading…
Reference in a new issue