ARM: at91: dts: sama5d3: add dt support for atmel isi and ov2640 sensor
Subsystems (3)
v2 cover ARM: at91: dts: sama5d3: add dt support for atmel isi and ov2640 sensor
This patch series add ISI and ov2640 support on dts files.
As the ov2640 driver dt is still in review. The patch is in: https://patchwork.linuxtv.org/patch/27554/
So I want to send this dt patch early for a review.
v1 -> v2:
1. add one more patch to change the pin name of ISI_MCK
2. rewrite the commit [4/8] ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}.
3. move the common chip parts of ISI node to sama5d3.dtsi.
Bo Shen (3):
ARM: at91: dts: sama5d3: split isi pinctrl
ARM: at91: dts: sama5d3: add missing pins of isi
ARM: at91: dts: sama5d3: move the isi mck pin to mb
Josh Wu (5):
ARM: at91: dts: sama5d3: add isi clock
ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}
ARM: at91: dts: sama5d3: change name of pinctrl of ISI_MCK
ARM: at91: dts: sama5d3: add ov2640 camera sensor support
ARM: at91: sama5: enable atmel-isi and ov2640 in defconfig
arch/arm/boot/dts/sama5d3.dtsi | 24 ++++++++++++++++++----- arch/arm/boot/dts/sama5d3xmb.dtsi | 40 +++++++++++++++++++++++++++++++++++---- arch/arm/configs/sama5_defconfig | 6 ++++++ 3 files changed, 61 insertions(+), 9 deletions(-)
Signature · 1 line
1.9.1
PATCH v2 1/8 ARM: at91: dts: sama5d3: add isi clock
Add ISI peripheral clock in sama5d3.dtsi.
--- arch/arm/boot/dts/sama5d3.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm/boot/dts/sama5d3.dtsi +2 -0
@@ -214,6 +214,8 @@ compatible = "atmel,at91sam9g45-isi"; reg = <0xf0034000 0x4000>; interrupts = <37 IRQ_TYPE_LEVEL_HIGH 5>; + clocks = <&isi_clk>; + clock-names = "isi_clk"; status = "disabled"; };
Signature · 1 line
1.9.1
PATCH v2 2/8 ARM: at91: dts: sama5d3: split isi pinctrl
In reply to Josh WuFrom: Bo Shen <[email protected]>
As the ISI has 12 data lines, however we only use 8 data lines with sensor module. So, split the data line into two groups which make it can be choosed depends on the hardware design.
--- arch/arm/boot/dts/sama5d3.dtsi | 11 ++++++++--- arch/arm/boot/dts/sama5d3xmb.dtsi | 2 +- 2 files changed, 9 insertions(+), 4 deletions(-)
arch/arm/boot/dts/sama5d3.dtsi +8 -3
@@ -547,7 +547,7 @@ }; isi { - pinctrl_isi: isi-0 { + pinctrl_isi_data_0_7: isi-0-data-0-7 { atmel,pins = <AT91_PIOA 16 AT91_PERIPH_C AT91_PINCTRL_NONE /* PA16 periph C ISI_D0, conflicts with LCDDAT16 */ AT91_PIOA 17 AT91_PERIPH_C AT91_PINCTRL_NONE /* PA17 periph C ISI_D1, conflicts with LCDDAT17 */
@@ -559,10 +559,15 @@ AT91_PIOA 23 AT91_PERIPH_C AT91_PINCTRL_NONE /* PA23 periph C ISI_D7, conflicts with LCDDAT23, PWML1 */ AT91_PIOC 30 AT91_PERIPH_C AT91_PINCTRL_NONE /* PC30 periph C ISI_PCK, conflicts with UTXD0 */ AT91_PIOA 31 AT91_PERIPH_C AT91_PINCTRL_NONE /* PA31 periph C ISI_HSYNC, conflicts with TWCK0, UTXD1 */ - AT91_PIOA 30 AT91_PERIPH_C AT91_PINCTRL_NONE /* PA30 periph C ISI_VSYNC, conflicts with TWD0, URXD1 */ - AT91_PIOC 29 AT91_PERIPH_C AT91_PINCTRL_NONE /* PC29 periph C ISI_PD8, conflicts with URXD0, PWMFI2 */ + AT91_PIOA 30 AT91_PERIPH_C AT91_PINCTRL_NONE>; /* PA30 periph C ISI_VSYNC, conflicts with TWD0, URXD1 */ + }; + + pinctrl_isi_data_8_9: isi-0-data-8-9 { + atmel,pins = + <AT91_PIOC 29 AT91_PERIPH_C AT91_PINCTRL_NONE /* PC29 periph C ISI_PD8, conflicts with URXD0, PWMFI2 */ AT91_PIOC 28 AT91_PERIPH_C AT91_PINCTRL_NONE>; /* PC28 periph C ISI_PD9, conflicts with SPI1_NPCS3, PWMFI0 */ }; + pinctrl_isi_pck_as_mck: isi_pck_as_mck-0 { atmel,pins = <AT91_PIOD 31 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD31 periph B ISI_MCK */
arch/arm/boot/dts/sama5d3xmb.dtsi +1 -1
@@ -61,7 +61,7 @@ isi: isi at f0034000 { pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_isi &pinctrl_isi_pck_as_mck &pinctrl_isi_power &pinctrl_isi_reset>; + pinctrl-0 = <&pinctrl_isi_data_0_7 &pinctrl_isi_pck_as_mck &pinctrl_isi_power &pinctrl_isi_reset>; }; mmc1: mmc at f8000000 {
Signature · 1 line
1.9.1
PATCH v2 3/8 ARM: at91: dts: sama5d3: add missing pins of isi
In reply to Josh WuFrom: Bo Shen <[email protected]>
The ISI has 12 data lines, add the missing two data lines.
--- arch/arm/boot/dts/sama5d3.dtsi | 6 ++++++ 1 file changed, 6 insertions(+)
arch/arm/boot/dts/sama5d3.dtsi +6 -0
@@ -568,6 +568,12 @@ AT91_PIOC 28 AT91_PERIPH_C AT91_PINCTRL_NONE>; /* PC28 periph C ISI_PD9, conflicts with SPI1_NPCS3, PWMFI0 */ }; + pinctrl_isi_data_10_11: isi-0-data-10-11 { + atmel,pins = + <AT91_PIOC 27 AT91_PERIPH_C AT91_PINCTRL_NONE /* PC27 periph C ISI_PD10, conflicts with SPI1_NPCS2, TWCK1 */ + AT91_PIOC 26 AT91_PERIPH_C AT91_PINCTRL_NONE>; /* PC26 periph C ISI_PD11, conflicts with SPI1_NPCS1, TWD1 */ + }; + pinctrl_isi_pck_as_mck: isi_pck_as_mck-0 { atmel,pins = <AT91_PIOD 31 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD31 periph B ISI_MCK */
Signature · 1 line
1.9.1
PATCH v2 4/8 ARM: at91: dts: sama5d3: move the isi mck pin to mb
In reply to Josh WuFrom: Bo Shen <[email protected]>
The mck is decided by the board design, move it to mb related dtsi file.
--- arch/arm/boot/dts/sama5d3.dtsi | 5 ----- arch/arm/boot/dts/sama5d3xmb.dtsi | 5 +++++ 2 files changed, 5 insertions(+), 5 deletions(-)
arch/arm/boot/dts/sama5d3.dtsi +0 -5
@@ -573,11 +573,6 @@ <AT91_PIOC 27 AT91_PERIPH_C AT91_PINCTRL_NONE /* PC27 periph C ISI_PD10, conflicts with SPI1_NPCS2, TWCK1 */ AT91_PIOC 26 AT91_PERIPH_C AT91_PINCTRL_NONE>; /* PC26 periph C ISI_PD11, conflicts with SPI1_NPCS1, TWD1 */ }; - - pinctrl_isi_pck_as_mck: isi_pck_as_mck-0 { - atmel,pins = - <AT91_PIOD 31 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD31 periph B ISI_MCK */ - }; }; mmc0 {
arch/arm/boot/dts/sama5d3xmb.dtsi +5 -0
@@ -117,6 +117,11 @@ <AT91_PIOD 30 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD30 periph B */ }; + pinctrl_isi_pck_as_mck: isi_pck_as_mck-0 { + atmel,pins = + <AT91_PIOD 31 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD31 periph B ISI_MCK */ + }; + pinctrl_isi_reset: isi_reset-0 { atmel,pins = <AT91_PIOE 24 AT91_PERIPH_GPIO AT91_PINCTRL_NONE>; /* PE24 gpio */
Signature · 1 line
1.9.1
PATCH v2 5/8 ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power, reset}
In reply to Josh WuFor sama5d3xmb board, the pins: pinctrl_isi_{power,reset} is used to power-down or reset camera sensor.
So we should let camera sensor instead of ISI to configure the pins.
This patch will change pinctrl name from pinctrl_isi_{power,reset} to pinctrl_sensor_{power,reset}. And remove these two pinctrl from ISI's DT node. We will add these two pinctrl to sensor's DT node.
---
v1 -> v2:
1. only do things that mentioned in commit message.
arch/arm/boot/dts/sama5d3xmb.dtsi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
arch/arm/boot/dts/sama5d3xmb.dtsi +3 -3
@@ -61,7 +61,7 @@ isi: isi at f0034000 { pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_isi_data_0_7 &pinctrl_isi_pck_as_mck &pinctrl_isi_power &pinctrl_isi_reset>; + pinctrl-0 = <&pinctrl_isi_data_0_7 &pinctrl_isi_pck_as_mck>; }; mmc1: mmc at f8000000 {
@@ -122,12 +122,12 @@ <AT91_PIOD 31 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD31 periph B ISI_MCK */ }; - pinctrl_isi_reset: isi_reset-0 { + pinctrl_sensor_reset: sensor_reset-0 { atmel,pins = <AT91_PIOE 24 AT91_PERIPH_GPIO AT91_PINCTRL_NONE>; /* PE24 gpio */ }; - pinctrl_isi_power: isi_power-0 { + pinctrl_sensor_power: sensor_power-0 { atmel,pins = <AT91_PIOE 29 AT91_PERIPH_GPIO AT91_PINCTRL_NONE>; /* PE29 gpio */ };
Signature · 1 line
1.9.1
PATCH v2 6/8 ARM: at91: dts: sama5d3: change name of pinctrl of ISI_MCK
In reply to Josh WuFor sama5d3xmb board, the pins: pinctrl_isi_pck_as_mck is pck1, and used to provide MCK for camera sensor.
We change its name to: pinctrl_pck1_as_isi_mck.
As we want camera sensor instead of ISI to configure the pck1 (ISI_MCK) pin. So we remove this pinctrl from ISI DT node. It will be added in sensor's DT node.
---
new added in v2.
arch/arm/boot/dts/sama5d3xmb.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/sama5d3xmb.dtsi +2 -2
@@ -61,7 +61,7 @@ isi: isi at f0034000 { pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_isi_data_0_7 &pinctrl_isi_pck_as_mck>; + pinctrl-0 = <&pinctrl_isi_data_0_7>; }; mmc1: mmc at f8000000 {
@@ -117,7 +117,7 @@ <AT91_PIOD 30 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD30 periph B */ }; - pinctrl_isi_pck_as_mck: isi_pck_as_mck-0 { + pinctrl_pck1_as_isi_mck: pck1_as_isi_mck-0 { atmel,pins = <AT91_PIOD 31 AT91_PERIPH_B AT91_PINCTRL_NONE>; /* PD31 periph B ISI_MCK */ };
Signature · 1 line
1.9.1
v2 cover ARM: at91: dts: sama5d3: add dt support for atmel isi and ov2640 sensor
In reply to Josh WuLe 04/01/2015 10:02, Josh Wu a ?crit :
Quoted 15 lines
This patch series add ISI and ov2640 support on dts files.
As the ov2640 driver dt is still in review. The patch is in: https://patchwork.linuxtv.org/patch/27554/
So I want to send this dt patch early for a review.v1 -> v2:
1. add one more patch to change the pin name ofISI_MCK
2. rewrite the commit [4/8] ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}.
3. move the common chip parts of ISI node tosama5d3.dtsi.Bo Shen (3):
ARM: at91: dts: sama5d3: split isi pinctrl
ARM: at91: dts: sama5d3: add missing pins of isi
ARM: at91: dts: sama5d3: move the isi mck pin to mb
Quoted 6 lines
Josh Wu (5):
ARM: at91: dts: sama5d3: add isi clock
ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}
ARM: at91: dts: sama5d3: change name of pinctrl ofISI_MCK
ARM: at91: dts: sama5d3: add ov2640 camera sensor support
ARM: at91: sama5: enable atmel-isi and ov2640 in defconfig
Josh,
It seems that this patch doesn't show up in the series: I only received up to 6/8 patches (2 missing?). Can you please send it(them?)?
Bye,
Quoted 5 lines
arch/arm/boot/dts/sama5d3.dtsi | 24 ++++++++++++++++++----- arch/arm/boot/dts/sama5d3xmb.dtsi | 40 +++++++++++++++++++++++++++++++++++---- arch/arm/configs/sama5_defconfig | 6 ++++++ 3 files changed, 61 insertions(+), 9 deletions(-)
Signature · 1 line
Nicolas Ferre
v2 cover ARM: at91: dts: sama5d3: add dt support for atmel isi and ov2640 sensor
Quoted 22 lines · Nicolas Ferre
Le 04/01/2015 10:02, Josh Wu a ?crit :
Quoted 15 lines
This patch series add ISI and ov2640 support on dts files.
As the ov2640 driver dt is still in review. The patch is in: https://patchwork.linuxtv.org/patch/27554/
So I want to send this dt patch early for a review.v1 -> v2:
1. add one more patch to change the pin name ofISI_MCK
2. rewrite the commit [4/8] ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}.
3. move the common chip parts of ISI node tosama5d3.dtsi.Bo Shen (3):
ARM: at91: dts: sama5d3: split isi pinctrl
ARM: at91: dts: sama5d3: add missing pins of isi
ARM: at91: dts: sama5d3: move the isi mck pin to mbQuoted 6 lines
Josh Wu (5):
ARM: at91: dts: sama5d3: add isi clock
ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}
ARM: at91: dts: sama5d3: change name of pinctrl ofISI_MCK
ARM: at91: dts: sama5d3: add ov2640 camera sensor support
ARM: at91: sama5: enable atmel-isi and ov2640 in defconfig
Quoted 4 lines
Josh,
It seems that this patch doesn't show up in the series: I only received up to 6/8 patches (2 missing?). Can you please send it(them?)?
Thanks you, Nicolas. I am not aware that.
I just sent out the missing 7/8, 8/8 patches right now.
Best Regards,
Josh Wu
Quoted 9 lines
Bye,
Quoted 5 lines
arch/arm/boot/dts/sama5d3.dtsi | 24 ++++++++++++++++++----- arch/arm/boot/dts/sama5d3xmb.dtsi | 40 +++++++++++++++++++++++++++++++++++---- arch/arm/configs/sama5_defconfig | 6 ++++++ 3 files changed, 61 insertions(+), 9 deletions(-)
v2 cover ARM: at91: dts: sama5d3: add dt support for atmel isi and ov2640 sensor
In reply to Nicolas FerreHi Nicolas,
BTW, you can add my ack on the remaining patches (5-7).
Quoted 39 lines · Nicolas Ferre
Le 04/01/2015 10:02, Josh Wu a ?crit :
Quoted 15 lines
This patch series add ISI and ov2640 support on dts files.
As the ov2640 driver dt is still in review. The patch is in: https://patchwork.linuxtv.org/patch/27554/
So I want to send this dt patch early for a review.v1 -> v2:
1. add one more patch to change the pin name ofISI_MCK
2. rewrite the commit [4/8] ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}.
3. move the common chip parts of ISI node tosama5d3.dtsi.Bo Shen (3):
ARM: at91: dts: sama5d3: split isi pinctrl
ARM: at91: dts: sama5d3: add missing pins of isi
ARM: at91: dts: sama5d3: move the isi mck pin to mbQuoted 6 lines
Josh Wu (5):
ARM: at91: dts: sama5d3: add isi clock
ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}
ARM: at91: dts: sama5d3: change name of pinctrl ofISI_MCK
ARM: at91: dts: sama5d3: add ov2640 camera sensor support
ARM: at91: sama5: enable atmel-isi and ov2640 in defconfigJosh,
It seems that this patch doesn't show up in the series: I only received up to 6/8 patches (2 missing?). Can you please send it(them?)?
Bye,
Quoted 5 lines
arch/arm/boot/dts/sama5d3.dtsi | 24 ++++++++++++++++++----- arch/arm/boot/dts/sama5d3xmb.dtsi | 40 +++++++++++++++++++++++++++++++++++---- arch/arm/configs/sama5_defconfig | 6 ++++++ 3 files changed, 61 insertions(+), 9 deletions(-)Signature · 1 line
Nicolas Ferre
Signature · 3 lines
Alexandre Belloni, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH v2 7/8 ARM: at91: dts: sama5d3: add ov2640 camera sensor support
In reply to Josh WuAccording to v4l2 dt document, we add:
a camera host: ISI port.
a i2c camera sensor: ov2640 port.
to sama5d3xmb.dtsi.
The ov2640 node defines the pinctrls, clocks and refer to isi port. The ISI node also has a reference to the ov2640 port.
---
v1 -> v2:
1. move the chip common part of ISI DT node to sama5d3.dtsi.
2. the pck1 pinctrl name is changed.
arch/arm/boot/dts/sama5d3.dtsi | 6 ++++++ arch/arm/boot/dts/sama5d3xmb.dtsi | 31 +++++++++++++++++++++++++++++-- 2 files changed, 35 insertions(+), 2 deletions(-)
arch/arm/boot/dts/sama5d3.dtsi +6 -0
@@ -214,9 +214,15 @@ compatible = "atmel,at91sam9g45-isi"; reg = <0xf0034000 0x4000>; interrupts = <37 IRQ_TYPE_LEVEL_HIGH 5>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_isi_data_0_7>; clocks = <&isi_clk>; clock-names = "isi_clk"; status = "disabled"; + port { + #address-cells = <1>; + #size-cells = <0>; + }; }; mmc1: mmc at f8000000 {
arch/arm/boot/dts/sama5d3xmb.dtsi +29 -2
@@ -52,6 +52,29 @@ }; }; + i2c1: i2c at f0018000 { + ov2640: camera at 0x30 { + compatible = "ovti,ov2640"; + reg = <0x30>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_pck1_as_isi_mck &pinctrl_sensor_power &pinctrl_sensor_reset>; + resetb-gpios = <&pioE 24 GPIO_ACTIVE_LOW>; + pwdn-gpios = <&pioE 29 GPIO_ACTIVE_HIGH>; + /* use pck1 for the master clock of ov2640 */ + clocks = <&pck1>; + clock-names = "xvclk"; + assigned-clocks = <&pck1>; + assigned-clock-rates = <25000000>; + + port { + ov2640_0: endpoint { + remote-endpoint = <&isi_0>; + bus-width = <8>; + }; + }; + }; + }; + usart1: serial at f0020000 { dmas = <0>, <0>; /* Do not use DMA for usart1 */ pinctrl-names = "default";
@@ -60,8 +83,12 @@ }; isi: isi at f0034000 { - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_isi_data_0_7>; + port { + isi_0: endpoint { + remote-endpoint = <&ov2640_0>; + bus-width = <8>; + }; + }; }; mmc1: mmc at f8000000 {
Signature · 1 line
1.9.1
PATCH v2 8/8 ARM: at91: sama5: enable atmel-isi and ov2640 in defconfig
--- arch/arm/configs/sama5_defconfig | 6 ++++++ 1 file changed, 6 insertions(+)
arch/arm/configs/sama5_defconfig +6 -0
@@ -139,6 +139,12 @@ CONFIG_POWER_RESET=y CONFIG_SSB=m CONFIG_REGULATOR=y CONFIG_REGULATOR_ACT8865=y +CONFIG_MEDIA_SUPPORT=y +CONFIG_MEDIA_CAMERA_SUPPORT=y +CONFIG_V4L_PLATFORM_DRIVERS=y +CONFIG_SOC_CAMERA=y +CONFIG_SOC_CAMERA_OV2640=y +CONFIG_VIDEO_ATMEL_ISI=y CONFIG_FB=y CONFIG_BACKLIGHT_LCD_SUPPORT=y # CONFIG_LCD_CLASS_DEVICE is not set
Signature · 1 line
1.9.1
v2 cover ARM: at91: dts: sama5d3: add dt support for atmel isi and ov2640 sensor
In reply to Josh WuLe 04/01/2015 10:02, Josh Wu a ?crit :
Quoted 15 lines
This patch series add ISI and ov2640 support on dts files.
As the ov2640 driver dt is still in review. The patch is in: https://patchwork.linuxtv.org/patch/27554/
So I want to send this dt patch early for a review.v1 -> v2:
1. add one more patch to change the pin name ofISI_MCK
2. rewrite the commit [4/8] ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}.
3. move the common chip parts of ISI node tosama5d3.dtsi.Bo Shen (3):
ARM: at91: dts: sama5d3: split isi pinctrl
ARM: at91: dts: sama5d3: add missing pins of isi
ARM: at91: dts: sama5d3: move the isi mck pin to mb
Quoted 6 lines
Josh Wu (5):
ARM: at91: dts: sama5d3: add isi clock
ARM: at91: dts: sama5d3: change name of pinctrl_isi_{power,reset}
ARM: at91: dts: sama5d3: change name of pinctrl ofISI_MCK
ARM: at91: dts: sama5d3: add ov2640 camera sensor support
ARM: at91: sama5: enable atmel-isi and ov2640 in defconfig
The whole series:
stacked on top of at91-3.20-dt.
The defconfig update on his side on at91-3.20-defconfig
Bye,
Quoted 5 lines
arch/arm/boot/dts/sama5d3.dtsi | 24 ++++++++++++++++++----- arch/arm/boot/dts/sama5d3xmb.dtsi | 40 +++++++++++++++++++++++++++++++++++---- arch/arm/configs/sama5_defconfig | 6 ++++++ 3 files changed, 61 insertions(+), 9 deletions(-)
Signature · 1 line
Nicolas Ferre