From: Sebastian Reichel <hidden> Date: 2013-12-13 18:17:26
Hi,
This patchset adds DT support for the N900 panel. The patchset is based on
Tomi's work/dss-dt-2 branch [0]. I suggest to send the DT changes through
Benoits queue, since I have more N900 DT changes for 3.14. Also the patch
editing the rx51 boardcode can be dropped, since the file is removed in 3.14.
I included those two with this patchset, since they are needed to test the
other two patches.
I did not include a documentation for the DT API, since the omapdss
documentation is still missing.
I have successfully tested this on the N900.
[0] https://git.kernel.org/cgit/linux/kernel/git/tomba/linux.git/log/?h=work/dss-dt-2
-- Sebastian
Sebastian Reichel (4):
OMAPDSS: Add DT support to SDI
OMAPDSS: ACX565AKM: Add DT support
ARM: OMAP: rx51: DT boot: disable legacy dss init
ARM: dts: omap3-n900: Add display support
arch/arm/boot/dts/omap3-n900.dts | 18 ++++++++++-
arch/arm/mach-omap2/board-rx51-video.c | 2 +-
.../omap2/displays-new/panel-sony-acx565akm.c | 35 +++++++++++++++++++++-
drivers/video/omap2/dss/sdi.c | 20 +++++++++++++
4 files changed, 72 insertions(+), 3 deletions(-)
--
1.8.5.1
From: Sebastian Reichel <hidden> Date: 2013-12-13 18:17:27
Add the code to make the SDI driver work with device tree on OMAP3.
Signed-off-by: Sebastian Reichel <redacted>
---
drivers/video/omap2/dss/sdi.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
From: Sebastian Reichel <hidden> Date: 2013-12-13 18:17:28
This adds DT support to the ACX565AKM panel driver.
Signed-off-by: Sebastian Reichel <redacted>
---
.../omap2/displays-new/panel-sony-acx565akm.c | 35 +++++++++++++++++++++-
1 file changed, 34 insertions(+), 1 deletion(-)
@@ -531,7 +533,9 @@ static int acx565akm_panel_power_on(struct omap_dss_device *dssdev)dev_dbg(&ddata->spi->dev,"%s\n",__func__);in->ops.sdi->set_timings(in,&ddata->videomode);-in->ops.sdi->set_datapairs(in,ddata->datapairs);++if(ddata->datapairs>=0)+in->ops.sdi->set_datapairs(in,ddata->datapairs);r=in->ops.sdi->enable(in);if(r){
@@ -710,6 +714,30 @@ static int acx565akm_probe_pdata(struct spi_device *spi)return0;}+staticintacx565akm_probe_of(structspi_device*spi)+{+structpanel_drv_data*ddata=dev_get_drvdata(&spi->dev);+structdevice_node*np=spi->dev.of_node;+structomap_dss_device*dssdev;+intret;++ddata->reset_gpio=of_get_named_gpio(np,"reset-gpio",0);++ddata->datapairs=-1;+ddata->in=omapdss_of_find_source_for_first_ep(np);+if(IS_ERR(ddata->in)){+dev_err(&spi->dev,"failed to find video source\n");+returnPTR_ERR(ddata->in);+}++dssdev=&ddata->dssdev;+ret=of_property_read_string(np,"label",&dssdev->name);+if(ret<0)+returnret;++return0;+}+staticintacx565akm_probe(structspi_device*spi){structpanel_drv_data*ddata;
@@ -737,7 +765,12 @@ static int acx565akm_probe(struct spi_device *spi)r=acx565akm_probe_pdata(spi);if(r)returnr;+}elseif(spi->dev.of_node){+r=acx565akm_probe_of(spi);+if(r)+returnr;}else{+dev_err(&spi->dev,"platform data missing!\n");return-ENODEV;}
From: Sebastian Reichel <hidden> Date: 2013-12-13 18:17:29
This disables legacy initialization of the
omapdss, if the N900 is booted via DT.
Signed-off-by: Sebastian Reichel <redacted>
---
arch/arm/mach-omap2/board-rx51-video.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
From: Sebastian Reichel <hidden> Date: 2013-12-13 18:17:30
Add support for the Nokia N900's display.
Signed-off-by: Sebastian Reichel <redacted>
---
arch/arm/boot/dts/omap3-n900.dts | 18 +++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)
From: Tomi Valkeinen <hidden> Date: 2013-12-17 07:37:35
Hi,
On 2013-12-13 20:17, Sebastian Reichel wrote:
Hi,
This patchset adds DT support for the N900 panel. The patchset is based on
Tomi's work/dss-dt-2 branch [0]. I suggest to send the DT changes through
Benoits queue, since I have more N900 DT changes for 3.14. Also the patch
editing the rx51 boardcode can be dropped, since the file is removed in 3.14.
I included those two with this patchset, since they are needed to test the
other two patches.
I did not include a documentation for the DT API, since the omapdss
documentation is still missing.
I have successfully tested this on the N900.
[0] https://git.kernel.org/cgit/linux/kernel/git/tomba/linux.git/log/?h=work/dss-dt-2
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
Tomi
From: Sebastian Reichel <hidden> Date: 2013-12-17 17:14:14
On Tue, Dec 17, 2013 at 09:37:35AM +0200, Tomi Valkeinen wrote:
Hi,
On 2013-12-13 20:17, Sebastian Reichel wrote:
quoted
Hi,
This patchset adds DT support for the N900 panel. The patchset is based on
Tomi's work/dss-dt-2 branch [0]. I suggest to send the DT changes through
Benoits queue, since I have more N900 DT changes for 3.14. Also the patch
editing the rx51 boardcode can be dropped, since the file is removed in 3.14.
I included those two with this patchset, since they are needed to test the
other two patches.
I did not include a documentation for the DT API, since the omapdss
documentation is still missing.
I have successfully tested this on the N900.
[0] https://git.kernel.org/cgit/linux/kernel/git/tomba/linux.git/log/?h=work/dss-dt-2
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
I just tried it and it does not work. On a first look the pinmuxing
looks fishy: 0x0d4 is muxed two times.
I will have a more detailed look into this later.
-- Sebastian
From: Tomi Valkeinen <hidden> Date: 2013-12-17 17:29:34
On 2013-12-17 19:14, Sebastian Reichel wrote:
On Tue, Dec 17, 2013 at 09:37:35AM +0200, Tomi Valkeinen wrote:
quoted
Hi,
On 2013-12-13 20:17, Sebastian Reichel wrote:
quoted
Hi,
This patchset adds DT support for the N900 panel. The patchset is based on
Tomi's work/dss-dt-2 branch [0]. I suggest to send the DT changes through
Benoits queue, since I have more N900 DT changes for 3.14. Also the patch
editing the rx51 boardcode can be dropped, since the file is removed in 3.14.
I included those two with this patchset, since they are needed to test the
other two patches.
I did not include a documentation for the DT API, since the omapdss
documentation is still missing.
I have successfully tested this on the N900.
[0] https://git.kernel.org/cgit/linux/kernel/git/tomba/linux.git/log/?h=work/dss-dt-2
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
I just tried it and it does not work. On a first look the pinmuxing
looks fishy: 0x0d4 is muxed two times.
Hmm, so it is.
I'm not really familiar with SDI, I just muxed all the SDI pins, except
datapair3. I previously thought that there's only the data and clock
pairs for SDI, but the TRM revealed more sdi pins, so I included them.
It is well possible that these can be removed:
0x0d0 (PIN_OUTPUT | MUX_MODE1) /* dss_data18.sdi_vsync */
0x0d2 (PIN_OUTPUT | MUX_MODE1) /* dss_data19.sdi_hsync */
0x0d4 (PIN_OUTPUT | MUX_MODE1) /* dss_data20.sdi_den */
0x0d6 (PIN_OUTPUT | MUX_MODE1) /* dss_data21.sdi_stp */
Tomi
From: Sebastian Reichel <hidden> Date: 2013-12-18 21:55:37
On Tue, Dec 17, 2013 at 07:29:34PM +0200, Tomi Valkeinen wrote:
quoted
quoted
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
I just tried it and it does not work. On a first look the pinmuxing
looks fishy: 0x0d4 is muxed two times.
Hmm, so it is.
I'm not really familiar with SDI, I just muxed all the SDI pins, except
datapair3. I previously thought that there's only the data and clock
pairs for SDI, but the TRM revealed more sdi pins, so I included them.
It is well possible that these can be removed:
0x0d0 (PIN_OUTPUT | MUX_MODE1) /* dss_data18.sdi_vsync */
0x0d2 (PIN_OUTPUT | MUX_MODE1) /* dss_data19.sdi_hsync */
0x0d4 (PIN_OUTPUT | MUX_MODE1) /* dss_data20.sdi_den */
0x0d6 (PIN_OUTPUT | MUX_MODE1) /* dss_data21.sdi_stp */
Just removing the dss_data20.sdi_den pin was enough to get a working display. I
don't know if the other pins are needed, because the display pins are already
muxed correctly by the bootloader.
-- Sebastian
From: Sebastian Reichel <hidden> Date: 2013-12-19 00:51:52
On Wed, Dec 18, 2013 at 10:55:37PM +0100, Sebastian Reichel wrote:
On Tue, Dec 17, 2013 at 07:29:34PM +0200, Tomi Valkeinen wrote:
quoted
quoted
quoted
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
I just tried it and it does not work. On a first look the pinmuxing
looks fishy: 0x0d4 is muxed two times.
Hmm, so it is.
I'm not really familiar with SDI, I just muxed all the SDI pins, except
datapair3. I previously thought that there's only the data and clock
pairs for SDI, but the TRM revealed more sdi pins, so I included them.
It is well possible that these can be removed:
0x0d0 (PIN_OUTPUT | MUX_MODE1) /* dss_data18.sdi_vsync */
0x0d2 (PIN_OUTPUT | MUX_MODE1) /* dss_data19.sdi_hsync */
0x0d4 (PIN_OUTPUT | MUX_MODE1) /* dss_data20.sdi_den */
0x0d6 (PIN_OUTPUT | MUX_MODE1) /* dss_data21.sdi_stp */
Just removing the dss_data20.sdi_den pin was enough to get a working display. I
don't know if the other pins are needed, because the display pins are already
muxed correctly by the bootloader.
I just had a look in the leaked n900 schematics. According to it the
following pins are connected to the display:
DSS_DATA20 (E28) GPIO 90 LCD_RST
DSS_DATA10 (AD28) SDI_DAT1N CDP 0
DSS_DATA11 (AD27) SDI_DAT1P CDP 1
DSS_DATA12 (AB28) SDI_DAT2N CDP 2
DSS_DATA13 (AB27) SDI_DAT2P CDP 3
DSS_DATA14 (AA28) SDI_DAT3N CDP 4
DSS_DATA15 (AA27) SDI_DAT3P CDP 5
DSS_DATA22 (AC27) SDI_CLKP CDP 6
DSS_DATA23 (AC28) SDI_CLKN CDP 7
I also noticed that dss_data19.sdi_hsync is used as gpio 89 for the
N900's proximity sensor. Thus I suggest the following SDI pin muxing:
dss_sdi_pins: pinmux_dss_sdi_pins {
pinctrl-single,pins = <
0x0c0 (PIN_OUTPUT | MUX_MODE1) /* dss_data10.sdi_dat1n */
0x0c2 (PIN_OUTPUT | MUX_MODE1) /* dss_data11.sdi_dat1p */
0x0c4 (PIN_OUTPUT | MUX_MODE1) /* dss_data12.sdi_dat2n */
0x0c6 (PIN_OUTPUT | MUX_MODE1) /* dss_data13.sdi_dat2p */
0x0c8 (PIN_OUTPUT | MUX_MODE1) /* dss_data14.sdi_dat3n */
0x0ca (PIN_OUTPUT | MUX_MODE1) /* dss_data15.sdi_dat3p */
0x0d8 (PIN_OUTPUT | MUX_MODE1) /* dss_data22.sdi_clkp */
0x0da (PIN_OUTPUT | MUX_MODE1) /* dss_data23.sdi_clkn */
>;
};
-- Sebastian
From: Tomi Valkeinen <hidden> Date: 2013-12-19 05:30:50
On 2013-12-19 02:51, Sebastian Reichel wrote:
On Wed, Dec 18, 2013 at 10:55:37PM +0100, Sebastian Reichel wrote:
quoted
On Tue, Dec 17, 2013 at 07:29:34PM +0200, Tomi Valkeinen wrote:
quoted
quoted
quoted
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
I just tried it and it does not work. On a first look the pinmuxing
looks fishy: 0x0d4 is muxed two times.
Hmm, so it is.
I'm not really familiar with SDI, I just muxed all the SDI pins, except
datapair3. I previously thought that there's only the data and clock
pairs for SDI, but the TRM revealed more sdi pins, so I included them.
It is well possible that these can be removed:
0x0d0 (PIN_OUTPUT | MUX_MODE1) /* dss_data18.sdi_vsync */
0x0d2 (PIN_OUTPUT | MUX_MODE1) /* dss_data19.sdi_hsync */
0x0d4 (PIN_OUTPUT | MUX_MODE1) /* dss_data20.sdi_den */
0x0d6 (PIN_OUTPUT | MUX_MODE1) /* dss_data21.sdi_stp */
Just removing the dss_data20.sdi_den pin was enough to get a working display. I
don't know if the other pins are needed, because the display pins are already
muxed correctly by the bootloader.
I just had a look in the leaked n900 schematics. According to it the
following pins are connected to the display:
DSS_DATA20 (E28) GPIO 90 LCD_RST
DSS_DATA10 (AD28) SDI_DAT1N CDP 0
DSS_DATA11 (AD27) SDI_DAT1P CDP 1
DSS_DATA12 (AB28) SDI_DAT2N CDP 2
DSS_DATA13 (AB27) SDI_DAT2P CDP 3
DSS_DATA14 (AA28) SDI_DAT3N CDP 4
DSS_DATA15 (AA27) SDI_DAT3P CDP 5
DSS_DATA22 (AC27) SDI_CLKP CDP 6
DSS_DATA23 (AC28) SDI_CLKN CDP 7
I also noticed that dss_data19.sdi_hsync is used as gpio 89 for the
N900's proximity sensor. Thus I suggest the following SDI pin muxing:
dss_sdi_pins: pinmux_dss_sdi_pins {
pinctrl-single,pins = <
0x0c0 (PIN_OUTPUT | MUX_MODE1) /* dss_data10.sdi_dat1n */
0x0c2 (PIN_OUTPUT | MUX_MODE1) /* dss_data11.sdi_dat1p */
0x0c4 (PIN_OUTPUT | MUX_MODE1) /* dss_data12.sdi_dat2n */
0x0c6 (PIN_OUTPUT | MUX_MODE1) /* dss_data13.sdi_dat2p */
0x0c8 (PIN_OUTPUT | MUX_MODE1) /* dss_data14.sdi_dat3n */
0x0ca (PIN_OUTPUT | MUX_MODE1) /* dss_data15.sdi_dat3p */
0x0d8 (PIN_OUTPUT | MUX_MODE1) /* dss_data22.sdi_clkp */
0x0da (PIN_OUTPUT | MUX_MODE1) /* dss_data23.sdi_clkn */
>;
};
Thanks, I'll do the modifications. The dat3 lines are not needed, but if
they're connected to the panel, I don't see any harm in muxing them.
Although, makes me wonder. If the panel supports only 2 datalanes, why
does it have connectors for 3? And if it supports 3, why would N900 use
only 2?
Are you able to check if the bootloader muxes dat3 to SDI mode?
Tomi
From: Sebastian Reichel <hidden> Date: 2013-12-19 10:08:40
On Thu, Dec 19, 2013 at 07:30:50AM +0200, Tomi Valkeinen wrote:
On 2013-12-19 02:51, Sebastian Reichel wrote:
quoted
On Wed, Dec 18, 2013 at 10:55:37PM +0100, Sebastian Reichel wrote:
quoted
On Tue, Dec 17, 2013 at 07:29:34PM +0200, Tomi Valkeinen wrote:
quoted
quoted
quoted
I added N900 display DT support on top of my v2 series, including
pinmuxing. Can you check if it looks right and works?
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git work/dss-dt
I just tried it and it does not work. On a first look the pinmuxing
looks fishy: 0x0d4 is muxed two times.
Hmm, so it is.
I'm not really familiar with SDI, I just muxed all the SDI pins, except
datapair3. I previously thought that there's only the data and clock
pairs for SDI, but the TRM revealed more sdi pins, so I included them.
It is well possible that these can be removed:
0x0d0 (PIN_OUTPUT | MUX_MODE1) /* dss_data18.sdi_vsync */
0x0d2 (PIN_OUTPUT | MUX_MODE1) /* dss_data19.sdi_hsync */
0x0d4 (PIN_OUTPUT | MUX_MODE1) /* dss_data20.sdi_den */
0x0d6 (PIN_OUTPUT | MUX_MODE1) /* dss_data21.sdi_stp */
Just removing the dss_data20.sdi_den pin was enough to get a working display. I
don't know if the other pins are needed, because the display pins are already
muxed correctly by the bootloader.
I just had a look in the leaked n900 schematics. According to it the
following pins are connected to the display:
DSS_DATA20 (E28) GPIO 90 LCD_RST
DSS_DATA10 (AD28) SDI_DAT1N CDP 0
DSS_DATA11 (AD27) SDI_DAT1P CDP 1
DSS_DATA12 (AB28) SDI_DAT2N CDP 2
DSS_DATA13 (AB27) SDI_DAT2P CDP 3
DSS_DATA14 (AA28) SDI_DAT3N CDP 4
DSS_DATA15 (AA27) SDI_DAT3P CDP 5
DSS_DATA22 (AC27) SDI_CLKP CDP 6
DSS_DATA23 (AC28) SDI_CLKN CDP 7
I also noticed that dss_data19.sdi_hsync is used as gpio 89 for the
N900's proximity sensor. Thus I suggest the following SDI pin muxing:
dss_sdi_pins: pinmux_dss_sdi_pins {
pinctrl-single,pins = <
0x0c0 (PIN_OUTPUT | MUX_MODE1) /* dss_data10.sdi_dat1n */
0x0c2 (PIN_OUTPUT | MUX_MODE1) /* dss_data11.sdi_dat1p */
0x0c4 (PIN_OUTPUT | MUX_MODE1) /* dss_data12.sdi_dat2n */
0x0c6 (PIN_OUTPUT | MUX_MODE1) /* dss_data13.sdi_dat2p */
0x0c8 (PIN_OUTPUT | MUX_MODE1) /* dss_data14.sdi_dat3n */
0x0ca (PIN_OUTPUT | MUX_MODE1) /* dss_data15.sdi_dat3p */
0x0d8 (PIN_OUTPUT | MUX_MODE1) /* dss_data22.sdi_clkp */
0x0da (PIN_OUTPUT | MUX_MODE1) /* dss_data23.sdi_clkn */
>;
};
Thanks, I'll do the modifications. The dat3 lines are not needed, but if
they're connected to the panel, I don't see any harm in muxing them.
Although, makes me wonder. If the panel supports only 2 datalanes, why
does it have connectors for 3? And if it supports 3, why would N900 use
only 2?
I wondered about the same and I also assumed, that the muxing should be
safe.
Are you able to check if the bootloader muxes dat3 to SDI mode?
The bootloader's source code is not available as far as i know.
I tried to cat /sys/kernel/debug/pinctrl/48002030.pinmux/pins, but I
get an external abort on non-linefetch.
So I can't check it :(
-- Sebastian