From: Pavel Machek <pavel@ucw.cz>
To: Sebastian Reichel <sre@kernel.org>
Cc: Tony Lindgren <tony@atomide.com>,
pali.rohar@gmail.com, kernel list <linux-kernel@vger.kernel.org>,
linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
linux-omap@vger.kernel.org, khilman@kernel.org,
aaro.koskinen@iki.fi, ivo.g.dimitrov.75@gmail.com,
patrikbachan@gmail.com, serge@hallyn.com, abcloriens@gmail.com,
clayton@craftyguy.net, martijn@brixit.nl,
sakari.ailus@linux.intel.com, filip.matijevic.pz@gmail.com
Subject: Backlight on Nokia N900 was Re: 4.13 (and probably all recent) kernels refuse to boot on one Nokia N950, work or another
Date: Fri, 27 Oct 2017 22:27:43 +0200 [thread overview]
Message-ID: <20171027202743.GA17874@amd> (raw)
In-Reply-To: <20171026093115.4bc6ctxjx72ng7ld@earth>
[-- Attachment #1: Type: text/plain, Size: 2404 bytes --]
Hi!
> > I got "uncompressing Linux 4.13" on serial console now, debug LEDs
> > blinking, and if I use a flashlight, I see output on the screen, too.
> >
> > (What do I need to do to get the backlight working?)
>
> Glad you got it working :) For backlight you can add this
> in drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c:
>
> add the following code at the end of dsicm_probe:
>
> -----------------------------------------------------------
> mutex_unlock(&ddata->lock);
> mutex_lock(&ddata->lock);
> ddata->in->ops.dsi->bus_lock(ddata->in);
> r = dsicm_wake_up(ddata);
> if (!r)
> r = dsicm_dcs_write_1(ddata, DCS_BRIGHTNESS, 100);
> ddata->in->ops.dsi->bus_unlock(ddata->in);
> mutex_unlock(&ddata->lock);
> -----------------------------------------------------------
Ok, I tried that, and did not help. I also tried removing first
mutex_unlock(), since that's unbalanced and strange. Did not work. So
I commented it out with #if 0, and tried more hacks, but no luck :-(.
(I still see the display.. but no backlight so reading it is
.. difficult.)
Best regards,
Pavel
diff --git a/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c b/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c
index 8f74633..c0bbb42 100644
--- a/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c
+++ b/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c
@@ -668,6 +668,7 @@ static int dsicm_power_on(struct panel_drv_data *ddata)
goto err;
r = dsicm_dcs_write_1(ddata, DCS_BRIGHTNESS, 0xff);
+ mdelay(1000);
if (r)
goto err;
@@ -703,6 +704,8 @@ static int dsicm_power_on(struct panel_drv_data *ddata)
in->ops.dsi->enable_hs(in, ddata->channel, true);
+ r = dsicm_dcs_write_1(ddata, DCS_BRIGHTNESS, 0xff);
+
return 0;
err:
dev_err(&ddata->pdev->dev, "error while enabling panel, issuing HW reset\n");
@@ -1396,6 +1399,15 @@ static int dsicm_probe(struct platform_device *pdev)
goto err_bl;
}
+#if 0
+ mutex_lock(&ddata->lock);
+ ddata->in->ops.dsi->bus_lock(ddata->in);
+ r = dsicm_wake_up(ddata);
+ if (!r)
+ r = dsicm_dcs_write_1(ddata, DCS_BRIGHTNESS, 100);
+ ddata->in->ops.dsi->bus_unlock(ddata->in);
+ mutex_unlock(&ddata->lock);
+#endif
return 0;
err_bl:
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]
next prev parent reply other threads:[~2017-10-27 20:28 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-25 20:34 4.13 (and probably all recent) kernels refuse to boot on one Nokia N950, work or another Pavel Machek
2017-10-25 21:28 ` Tony Lindgren
2017-10-25 21:34 ` Aaro Koskinen
2017-10-26 7:16 ` Pavel Machek
2017-10-26 7:34 ` Filip Matijević
2017-10-26 8:49 ` Pavel Machek
2017-10-26 9:13 ` Pavel Machek
2017-10-26 9:31 ` Sebastian Reichel
2017-10-26 9:57 ` Pavel Machek
2017-10-26 12:01 ` Sebastian Reichel
2017-10-26 16:28 ` Pavel Machek
2017-10-27 10:19 ` Pavel Machek
2017-10-27 12:58 ` Filip Matijević
2017-10-30 19:43 ` n950: mmc fails to work, omap_hsmmc 480b4000.mmc: RX DMA channel request failed ? was " Pavel Machek
2017-10-30 20:02 ` Pavel Machek
2017-10-27 20:27 ` Pavel Machek [this message]
2017-10-30 7:51 ` Pavel Machek
2017-10-26 9:53 ` Pavel Machek
2017-10-26 6:25 ` Filip Matijević
2017-10-26 7:08 ` Pavel Machek
2017-10-26 7:21 ` Pali Rohár
2017-10-26 7:27 ` Pavel Machek
2017-10-26 7:32 ` Pali Rohár
2017-10-26 8:24 ` Pavel Machek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171027202743.GA17874@amd \
--to=pavel@ucw.cz \
--cc=aaro.koskinen@iki.fi \
--cc=abcloriens@gmail.com \
--cc=clayton@craftyguy.net \
--cc=filip.matijevic.pz@gmail.com \
--cc=ivo.g.dimitrov.75@gmail.com \
--cc=khilman@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=martijn@brixit.nl \
--cc=pali.rohar@gmail.com \
--cc=patrikbachan@gmail.com \
--cc=sakari.ailus@linux.intel.com \
--cc=serge@hallyn.com \
--cc=sre@kernel.org \
--cc=tony@atomide.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).