Verified Commit 89aafe23 authored by Shinjo Park's avatar Shinjo Park Committed by Oliver Smith
Browse files

shared-patches: add spreadtrum patches (MR 3242)

Merge and move Spreadtrum patches from these kernels to shared-patches:
* linux-finepower-f1
* linux-samsung-{gtel3g,gtelwifi,j1mini3g,j3xnlte}
* linux-zte-p731a20

[ci:skip-build]: already built successfully in CI
parent 2eb1a119
Pipeline #567332823 passed with stages
in 3 minutes and 41 seconds
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) ||
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)
Change color mode so charging-sdl works and RGB channels are not swapped
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)
../../.shared-patches/linux/sprd/sprdfb-fix-swapped-colors.patch
\ No newline at end of file
From c5bb0d59161730e546f279bfbbd097f5eb3e3a7e Mon Sep 17 00:00:00 2001
From: DolphinChips <DoIphinChips@protonmail.com>
Date: Mon, 21 Oct 2019 19:58:45 +0500
Subject: [PATCH] Add a little hack to sprdfb_main.c
---
drivers/video/sprdfb/sprdfb_main.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
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) ||
../../.shared-patches/linux/sprd/sprdfb-check-for-buffering.patch
\ No newline at end of file
......@@ -3,7 +3,7 @@
pkgname=linux-finepower-f1
pkgver=3.10.65
pkgrel=5
pkgrel=6
pkgdesc="FinePower F1 kernel fork"
arch="armv7"
_carch="arm"
......@@ -59,7 +59,8 @@ package() {
}
sha512sums="bcbb8f6e99bd53b173715765c86845f991c2f769e9c13c72503e4f9062dc7bc97a073a4ad730e804d43efd2bcbcd7b91a0890d6194b5986e453d40a79f08249b linux-finepower-f1-b30390f1645dcf1ebd08148d7d4086a544c56435.zip
sha512sums="
bcbb8f6e99bd53b173715765c86845f991c2f769e9c13c72503e4f9062dc7bc97a073a4ad730e804d43efd2bcbcd7b91a0890d6194b5986e453d40a79f08249b linux-finepower-f1-b30390f1645dcf1ebd08148d7d4086a544c56435.zip
19785c0f028b736c1b163859be9cbd928e0d0a968ef39448c101286bacdfc410c0befde8fefdc058eba69eb01849e0e99b9db46e95d141f605ecf9a75e6a4403 config-finepower-f1.armv7
c626828d9eac7b52a4509055d8d3b14b4dd74100e254cc212349bc4046e5583d91042f9332fb903e8d9dc6bade03cc898f26e3ac43732f423d8b6473182b357c sprd-scx20_sp7731ceb.dts
31f289fc3b63ace4dcd56ce289e63c55b1f622084b5d2fecc96f8f44eccccf51463ae6c7b9cdded3781d652a9be1b9f45ca4c64dfaa6160aa2f96b56d4af91ce lcd_st7796s_mipi.c
......@@ -69,6 +70,7 @@ ad0182a483791fc88e058838bc331b2f04a75ba291e763767babdb815efadfc3b4fda97e69e2e3f0
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
5e271f6e8ef2b1a31acafaf3b38b64cccd5d6732e93e92a2fcaa885f4ac24529bd1598e9982b553797e85d64deed6390e41768e0d952ef659add0766b44a6687 01-remove-path-to-missing-driver.patch
3a3d94c4912e8b9d64c1c4af5a568dbc8061c623bb39bcb605f30de0fa9e2f2b3c805cd0e0c9401c21ecdb49a61852e458f7b3fc599491f743e52d5d80e530e7 02-fix-includes-dump-lowpower-regs.patch
fb72f9c38f5305b92872c784a06e8eaca2ebb7b75d904f0a75473bb10b87ca56aca7d33c14d26362c2eba4797d3503ac84447e08660fd90e8ec2eb06ed83da0a 03-set-BGR565-color-mode.patch
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 03-set-BGR565-color-mode.patch
d54f7bf0cfd991ce303b5ac31cecb5a8b658f7e1794dcc2901a773601a521dade50ee186160b75e78040a18060a6d4c01d92eb56b121de50016739638adb980d 04-add-st7796s-mipi-panel-support.patch
1bab85f34cb955f25eae3c28e519c325dca3b1b87ad25c15a78f5538a775b3bc2699b615bfc5182e1cb0fdb4520999ff7a0ee03fe3c6a1cef70baa4fb3809b40 05-fix-X11.patch"
e33ed12de874c1c8bc9231aea3b0389b18ee0ff804e39c0f47d9cbf657ea19015370d6114846c2d142fbdb88f472f0e65811c53b9b335feb8ae2f30dffdf4846 05-fix-X11.patch
"
......@@ -3,7 +3,7 @@
pkgname=linux-samsung-gtel3g
pkgver=3.10.17
pkgrel=4
pkgrel=5
pkgdesc="Samsung Galaxy Tab E 9.6 kernel fork"
arch="armv7"
_carch="arm"
......@@ -51,7 +51,8 @@ package() {
install -Dm644 "$_outdir/arch/$_carch/boot"/dt.img "$pkgdir"/boot/dt.img
}
sha512sums="46b60368a79483f4cc322934027b413cea602b70ca2fd5683913c2a350f03ed26acb409a33c39431cc83fc75500ffd35ce820bc6b1032cf6fce869221e059bba linux-samsung-gtel3g-138e4fdf85854bd9ba791ae05ad9bd036d8b64fd.tar.gz
sha512sums="
46b60368a79483f4cc322934027b413cea602b70ca2fd5683913c2a350f03ed26acb409a33c39431cc83fc75500ffd35ce820bc6b1032cf6fce869221e059bba linux-samsung-gtel3g-138e4fdf85854bd9ba791ae05ad9bd036d8b64fd.tar.gz
0b0355d6f26f6376526b1c671857e752303ce40aff043be05fb367e91d1e3e78cfd579aa766eceb4f36f2d029cd6243877ce11db50e66546ec27ac45b899685f config-samsung-gtel3g.armv7
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
......@@ -60,4 +61,5 @@ sha512sums="46b60368a79483f4cc322934027b413cea602b70ca2fd5683913c2a350f03ed26acb
ea1d3b5a234fa565e3c1a792de48f4fc4e6023d281d303c8e319c7ef28edc5739ab0e4dea0139a41f0a5c7d03e27921ccaa214fd0ac5c72245a094ce60128864 00_fix_return_address.patch
cf417e27474788ee89738427e0298a1c6e3c73e24514cec5dfc7528dde1f55afec3d15fec0c9ead13da3cb0c998756a9da6a9fd67035dd7e7062d5d8c13c578c fix-dts.patch
fa11ab7040b83dad145a8f2ca3e5b17b3189b90ca43a8f64e63be4fcb4ba2debe8134b3e28f6f663bc8b7f1e72b1f3a68f342300eed45cb72de70cefba4fa0c2 sprdfb-check-for-buffering.patch
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch"
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch
"
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)
../../.shared-patches/linux/sprd/sprdfb-fix-swapped-colors.patch
\ No newline at end of file
......@@ -3,7 +3,7 @@
pkgname=linux-samsung-gtelwifi
pkgver=3.10.17
pkgrel=3
pkgrel=4
pkgdesc="Samsung Galaxy Tab E 9.6 kernel fork"
arch="armv7"
_carch="arm"
......@@ -51,7 +51,8 @@ package() {
install -Dm644 "$_outdir/arch/$_carch/boot"/dt.img "$pkgdir"/boot/dt.img
}
sha512sums="1d951c9e33d79250513665a617867816d81df866e869ba20664c9f4b2f05845e6ff7c667ba0ef11f9287109e6716d1b45164848a750e36202c4f95665759a2aa linux-samsung-gtelwifi-e81e8d5094db8f10ff44cc95f55939c90df35e51.tar.gz
sha512sums="
1d951c9e33d79250513665a617867816d81df866e869ba20664c9f4b2f05845e6ff7c667ba0ef11f9287109e6716d1b45164848a750e36202c4f95665759a2aa linux-samsung-gtelwifi-e81e8d5094db8f10ff44cc95f55939c90df35e51.tar.gz
f25a8ed914371359f3dd0a85e112acca3e3831531576b30411ec7c90c48687e425b3c0b496ebdc9da38f632dbf49af1660302f8daad68aee2838b55624b3f408 config-samsung-gtelwifi.armv7
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
......@@ -60,4 +61,5 @@ ad0182a483791fc88e058838bc331b2f04a75ba291e763767babdb815efadfc3b4fda97e69e2e3f0
32911549f0c89972d06af838954978ee90fb2eabacc1393c0bffa12deb9d80ddec5322f859df772d90afea733965bd669e85d5e90657d4f69995ae9fc25dd4f3 fix-recordmcount.patch
e8137de3cc4d49d5447cad6c299f0f88c2d2e60e012168bc857f4898ebc1da5c88c679927227c8675211af079d5a56b5b1baef4a3dbc86cb4e921c14d3f93357 fix-dtb_qcom,msm-id.patch
c985b4a320904c0c66fb976a4f66dd2671f21d7b86ea98c019684efc41b5801f4b9c23012f4aa37bc5ce3efd70a30523c9c78fcd6e5fbbcff172ff19d11a6579 sprdfb-check-for-buffering.patch
f1b7fcf323241361ac0574964afe50821e18f56b2c036d22a0312af00fc8ce446a3ff82162cba950de7b16a5452d4f37848e5c250005dafdfbe8dd2a57a32ab5 sprdfb-fix-swapped-colors.patch"
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch
"
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)
../../.shared-patches/linux/sprd/sprdfb-fix-swapped-colors.patch
\ No newline at end of file
......@@ -3,7 +3,7 @@
pkgname=linux-samsung-j1mini3g
pkgver=3.10.106
pkgrel=6
pkgrel=7
pkgdesc="Samsung Galaxy J1 mini kernel fork"
arch="armv7"
_carch="arm"
......@@ -50,10 +50,12 @@ package() {
"$pkgdir/boot/dt.img"
}
sha512sums="f1686df6ee6e1f24c6460295c830b67b2146ab5b34ead2291fa92c3f83ba12884db875b0c6e31ff305ff64a82636648ee237c13f09c99e158449457285352388 linux-samsung-j1mini3g-6a377f7c43a84b578df39300dcce9fb9cb387a21.tar.gz
sha512sums="
f1686df6ee6e1f24c6460295c830b67b2146ab5b34ead2291fa92c3f83ba12884db875b0c6e31ff305ff64a82636648ee237c13f09c99e158449457285352388 linux-samsung-j1mini3g-6a377f7c43a84b578df39300dcce9fb9cb387a21.tar.gz
b542ac60f989c52266aeac366cab2988128d6f86fc4fd797b2f811c98734147506ad82b7de2c8f9beeda1740035d4210d5d9b02e440ab6430cecdebefa4908e2 config-samsung-j1mini3g.armv7
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch
e33ed12de874c1c8bc9231aea3b0389b18ee0ff804e39c0f47d9cbf657ea19015370d6114846c2d142fbdb88f472f0e65811c53b9b335feb8ae2f30dffdf4846 sprdfb-check-for-buffering.patch"
e33ed12de874c1c8bc9231aea3b0389b18ee0ff804e39c0f47d9cbf657ea19015370d6114846c2d142fbdb88f472f0e65811c53b9b335feb8ae2f30dffdf4846 sprdfb-check-for-buffering.patch
"
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) ||
../../.shared-patches/linux/sprd/sprdfb-check-for-buffering.patch
\ No newline at end of file
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)
../../.shared-patches/linux/sprd/sprdfb-fix-swapped-colors.patch
\ No newline at end of file
......@@ -3,7 +3,7 @@
pkgname=linux-samsung-j3xnlte
pkgver=3.10.100
pkgrel=5
pkgrel=6
pkgdesc="Samsung Galaxy J3 kernel fork"
arch="armv7"
_carch="arm"
......@@ -52,7 +52,8 @@ package() {
"$pkgdir/boot/dt.img"
}
sha512sums="733f04dee55effcbbd8c28b9b2b84b05ca9e95d538bd10177edc40f36ee640cd260f080c50497d28828a441c9c96046debdf1085453a4d8871ac8a3ef300380f linux-samsung-j3xnlte-e3381e42b00e1ff977815b365cea53f18afff7a8.tar.gz
sha512sums="
733f04dee55effcbbd8c28b9b2b84b05ca9e95d538bd10177edc40f36ee640cd260f080c50497d28828a441c9c96046debdf1085453a4d8871ac8a3ef300380f linux-samsung-j3xnlte-e3381e42b00e1ff977815b365cea53f18afff7a8.tar.gz
10bcfe0614f3c454b696d90a4f7ea806b104cbaa090e5c6f84db5aa745842561031d448179e1294c6c013a4483121381c06fbb1a8970a0d6401bdb0132b8f615 config-samsung-j3xnlte.armv7
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
......@@ -60,4 +61,5 @@ sha512sums="733f04dee55effcbbd8c28b9b2b84b05ca9e95d538bd10177edc40f36ee640cd260f
6aa11a75f422ac5c20cddfce23bff81940e61e65bc86fe1070c60714a6ccf631b2da70bff20e2b88e723706f0f233eb03540a8d9389adffd495592e8ab6bd82a fix_recordmcount.patch
54eb205043b9e1b12f4f88d8163611e6769a702490045f5704483c92b17c9297250fde7d257b6d0e82d0cdbaed88d52d85137aeafcd4c4b138cecfffc921857e fix_touchscreen.patch
e33ed12de874c1c8bc9231aea3b0389b18ee0ff804e39c0f47d9cbf657ea19015370d6114846c2d142fbdb88f472f0e65811c53b9b335feb8ae2f30dffdf4846 sprdfb-check-for-buffering.patch
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch"
6836001b24508d413a059f19b0c6f6f547037f68886c22159ad51be91d1a089e3d1d9ed79c3c62724648df7f810cd81d96a83f4a34368b373524b649e5539656 sprdfb-fix-swapped-colors.patch
"
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) ||
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment