Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
pmaports
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
postmarketOS
pmaports
Commits
8f8ef591
Unverified
Commit
8f8ef591
authored
4 years ago
by
Jeremy O'Brien
Committed by
Alexey Minnekhanov
4 years ago
Browse files
Options
Downloads
Patches
Plain Diff
motorola-channel: add mdss patch fix xorg (MR 1239)
parent
05969fc3
Branches
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#194559
passed
4 years ago
Stage: first
Stage: second
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
device/testing/linux-motorola-channel/APKBUILD
+4
-2
4 additions, 2 deletions
device/testing/linux-motorola-channel/APKBUILD
device/testing/linux-motorola-channel/mdss-panel-to-fb-var.patch
+118
-0
118 additions, 0 deletions
...testing/linux-motorola-channel/mdss-panel-to-fb-var.patch
with
122 additions
and
2 deletions
device/testing/linux-motorola-channel/APKBUILD
+
4
−
2
View file @
8f8ef591
...
...
@@ -4,14 +4,14 @@
pkgname
=
linux-motorola-channel
pkgver
=
4.9.203
pkgrel
=
0
pkgrel
=
1
pkgdesc
=
"Motorola G7 Play kernel fork"
arch
=
"aarch64"
_carch
=
"arm64"
_flavor
=
"motorola-channel"
url
=
"https://kernel.org"
license
=
"GPL-2.0-only"
options
=
"!strip !check !tracedeps"
options
=
"!strip !check !tracedeps
pmb:cross-native
"
makedepends
=
"bash bc dtc bison devicepkg-dev flex openssl-dev perl dtbtool xz"
# Source
...
...
@@ -22,6 +22,7 @@ source="
$pkgname
-
$_commit
.tar.gz::https://github.com/LineageOS/
$_repository
/archive/
$_commit
.tar.gz
disable_tty_port_set_policy.patch
disable_skip_initramfs.patch
mdss-panel-to-fb-var.patch
$_config
"
builddir
=
"
$srcdir
/
$_repository
-
$_commit
"
...
...
@@ -45,4 +46,5 @@ package() {
sha512sums
=
"41bbbe33864866407877c5769882782e099a3f48898eb26ea08f172ff0bcc1239e2fb2d250c491a44c3bc5a3718d373ced4b26682aaa574077d1cb7abbb282c5 linux-motorola-channel-db8fd3bcfeee53f5ad5ae71df30c2b88076ff002.tar.gz
0fd5fd59e16c24a85302de83f61468591df472afbddaeab2b3dbf59cf9d48af2ac8ecc1a48a72b7a1db44077fbd4856dc60f2b2885eb1adf1f8e96b3a311eaad disable_tty_port_set_policy.patch
65048fb6474fd543b14bc99d9d95cfe5297da239af211d327a8509f7777d489bd01dd911364e0c62ec0e68f4c22ebb3b145eabfe01cad2abf57cf46896a1e58f disable_skip_initramfs.patch
d5b868c64b8ebddcf74cb3aa478f30f0897af1e14e4fc42d977921104a6c568cc0bf36fc8a3b0f538cd3ca2ebf59244fdf23186a903259e5acc14d1c4ef4ccc3 mdss-panel-to-fb-var.patch
d976d46e1892db749e5b9fd7037c747f80733e611919f98b19155d6419a79ce5fa2bb9720c250b1a11ba7a999fa1384063549a0014cd66c5e6986a2167282bbb config-motorola-channel.aarch64"
This diff is collapsed.
Click to expand it.
device/testing/linux-motorola-channel/mdss-panel-to-fb-var.patch
0 → 100644
+
118
−
0
View file @
8f8ef591
From fe5131b250c373d152b7e73895f17846d1f1e6bd Mon Sep 17 00:00:00 2001
From: Ion Agorria <ion@agorria.com>
Date: Thu, 24 Jan 2019 18:52:58 +0100
Subject: [PATCH] mdss: update fb mode at mdss_panelinfo_to_fb_var to fix Xorg
When mdss_panelinfo_to_fb_var is called at
screen unblank it updates the values in fb_info->var,
meanwhile the fb_info->mode and modelist remain with old
values set at registering the fb causing mismatch when
Xorg attempts to set mode.
---
drivers/video/fbdev/msm/mdss_fb.c | 25 ++++++++++++++++------
drivers/video/fbdev/msm/mdss_fb.h | 3 +--
drivers/video/fbdev/msm/mdss_mdp_overlay.c | 2 +-
3 files changed, 20 insertions(+), 10 deletions(-)
diff --git a/drivers/video/fbdev/msm/mdss_fb.c b/drivers/video/fbdev/msm/mdss_fb.c
index 3e632076639d..2d2b37bffa5d 100644
--- a/drivers/video/fbdev/msm/mdss_fb.c
+++ b/drivers/video/fbdev/msm/mdss_fb.c
@@ -2339,7 +2339,7 @@
static void mdss_panel_validate_debugfs_info(struct msm_fb_data_type *mfd)
if (is_panel_split(mfd) && pdata->next)
mdss_fb_validate_split(pdata->panel_info.xres,
pdata->next->panel_info.xres, mfd);
- mdss_panelinfo_to_fb_var(panel_info, var);
+ mdss_panelinfo_to_fb_var(mfd);
if (mdss_fb_send_panel_event(mfd, MDSS_EVENT_CHECK_PARAMS,
panel_info))
pr_err("Failed to send panel event CHECK_PARAMS\n");
@@ -2452,7 +2452,7 @@
static int mdss_fb_blank_unblank(struct msm_fb_data_type *mfd)
* programmed in the controller.
* Update this info in the upstream structs.
*/
- mdss_panelinfo_to_fb_var(panel_info, var);
+ mdss_panelinfo_to_fb_var(mfd);
/* Start the work thread to signal idle time */
if (mfd->idle_time)
@@ -3196,7 +3196,7 @@
static int mdss_fb_register(struct msm_fb_data_type *mfd)
return ret;
}
- mdss_panelinfo_to_fb_var(panel_info, var);
+ mdss_panelinfo_to_fb_var(mfd);
fix->type = panel_info->is_3d_panel;
if (mfd->mdp.fb_stride)
@@ -3900,7 +3900,7 @@
static void mdss_fb_update_resolution(struct msm_fb_data_type *mfd,
}
var->xres_virtual = var->xres;
var->yres_virtual = pinfo->yres * mfd->fb_page;
- mdss_panelinfo_to_fb_var(pinfo, var);
+ mdss_panelinfo_to_fb_var(mfd);
}
int mdss_fb_atomic_commit(struct fb_info *info,
@@ -4149,9 +4149,14 @@
static void mdss_fb_var_to_panelinfo(struct fb_var_screeninfo *var,
pinfo->lcdc.v_polarity = 1;
}
-void mdss_panelinfo_to_fb_var(struct mdss_panel_info *pinfo,
- struct fb_var_screeninfo *var)
+void mdss_panelinfo_to_fb_var(struct msm_fb_data_type *mfd)
{
+ if (!mfd)
+ return -EINVAL;
+
+ struct mdss_panel_info *pinfo = mfd->panel_info;
+ struct fb_info *fbi = mfd->fbi;
+ struct fb_var_screeninfo *var = &fbi->var;
u32 frame_rate;
var->xres = mdss_fb_get_panel_xres(pinfo);
@@ -4185,7 +4190,13 @@
void mdss_panelinfo_to_fb_var(struct mdss_panel_info *pinfo,
if (pinfo->physical_height)
var->height = pinfo->physical_height;
- pr_debug("ScreenInfo: res=%dx%d [%d, %d] [%d, %d]\n",
+ //Hack to update current fbi->mode according to fbi->var when var is updated from panel info
+ if (fbi->mode) {
+ printk("Updating mdss fb mode from fb var\n");
+ fb_var_to_videomode(fbi->mode, var);
+ }
+
+ printk("ScreenInfo: res=%dx%d [%d, %d] [%d, %d]\n",
var->xres, var->yres, var->left_margin,
var->right_margin, var->upper_margin,
var->lower_margin);
diff --git a/drivers/video/fbdev/msm/mdss_fb.h b/drivers/video/fbdev/msm/mdss_fb.h
index c6e8d37d7bc8..bbd17e1c72e2 100644
--- a/drivers/video/fbdev/msm/mdss_fb.h
+++ b/drivers/video/fbdev/msm/mdss_fb.h
@@ -484,8 +484,7 @@
int mdss_fb_async_position_update(struct fb_info *info,
u32 mdss_fb_get_mode_switch(struct msm_fb_data_type *mfd);
void mdss_fb_report_panel_dead(struct msm_fb_data_type *mfd);
-void mdss_panelinfo_to_fb_var(struct mdss_panel_info *pinfo,
- struct fb_var_screeninfo *var);
+void mdss_panelinfo_to_fb_var(struct msm_fb_data_type *mfd);
void mdss_fb_calc_fps(struct msm_fb_data_type *mfd);
void mdss_fb_idle_pc(struct msm_fb_data_type *mfd);
#endif /* MDSS_FB_H */
diff --git a/drivers/video/fbdev/msm/mdss_mdp_overlay.c b/drivers/video/fbdev/msm/mdss_mdp_overlay.c
index 81218319d58b..cee8a8e5e449 100644
--- a/drivers/video/fbdev/msm/mdss_mdp_overlay.c
+++ b/drivers/video/fbdev/msm/mdss_mdp_overlay.c
@@ -3534,7 +3534,7 @@
int mdss_mdp_dfps_update_params(struct msm_fb_data_type *mfd,
* data, so any further call to get the screen
* info has the updated timings.
*/
- mdss_panelinfo_to_fb_var(&pdata->panel_info, var);
+ mdss_panelinfo_to_fb_var(mfd);
MDSS_XLOG(dfps);
mutex_unlock(&mdp5_data->dfps_lock);
--
2.25.1
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment