diff mbox series

sunxi: Add SPI Flash support for Orange PI R1

Message ID b5615179-cd82-5a71-edc7-d1426dd640cb@lank.me
State New
Headers show
Series sunxi: Add SPI Flash support for Orange PI R1 | expand

Commit Message

Yaroslav Petrov July 9, 2020, 8:09 p.m. UTC

Comments

Peter Robinson July 10, 2020, 11:31 a.m. UTC | #1
On Fri, Jul 10, 2020 at 12:15 PM Yaroslav Petrov <info at lank.me> wrote:
>
> diff --git a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> index 3356f4210d..675d38738d 100644
> --- a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> +++ b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts

These changes should be added to a
sun8i-h2-plus-orangepi-r1-u-boot.dtsi file so that any sync from Linux
doesn't lose the change.

> @@ -65,6 +65,7 @@
>
>          aliases {
>                  ethernet1 = &rtl8189etv;
> +               spi0 = &spi0;
>          };
>   };
>
> @@ -72,6 +73,7 @@
>          status = "okay";
>
>          flash at 0 {
> +               u-boot,dm-pre-reloc;
>                  compatible = "mxicy,mx25l12805d", "jedec,spi-nor";
>          };
>   };
> diff --git a/configs/orangepi_r1_defconfig b/configs/orangepi_r1_defconfig
> index 6f770fa018..a66c41aa3d 100644
> --- a/configs/orangepi_r1_defconfig
> +++ b/configs/orangepi_r1_defconfig
> @@ -11,3 +11,10 @@ CONFIG_DEFAULT_DEVICE_TREE="sun8i-h2-plus-orangepi-r1"
>   CONFIG_SUN8I_EMAC=y
>   CONFIG_USB_EHCI_HCD=y
>   CONFIG_USB_OHCI_HCD=y
> +CONFIG_CMD_SF=y
> +CONFIG_CMD_SPI=y
> +CONFIG_DM_SPI_FLASH=y
> +CONFIG_SPI_FLASH_MACRONIX=y
> +CONFIG_DM_SPI=y
> +CONFIG_SPI=y
> +CONFIG_SPL_SPI_SUNXI=y
> \ No newline at end of file
Yaroslav Petrov July 10, 2020, 2:59 p.m. UTC | #2
Hi,


Thank you very much for your feedback. I try to send it to kernel.org


Mit freundlichen Gr??en,
Yaroslav Petrov


On 10.07.20 13:31, Peter Robinson wrote:
> On Fri, Jul 10, 2020 at 12:15 PM Yaroslav Petrov <info at lank.me> wrote:
>> diff --git a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
>> b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
>> index 3356f4210d..675d38738d 100644
>> --- a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
>> +++ b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> These changes should be added to a
> sun8i-h2-plus-orangepi-r1-u-boot.dtsi file so that any sync from Linux
> doesn't lose the change.
>
>> @@ -65,6 +65,7 @@
>>
>>          aliases {
>>                  ethernet1 = &rtl8189etv;
>> +               spi0 = &spi0;
>>          };
>>   };
>>
>> @@ -72,6 +73,7 @@
>>          status = "okay";
>>
>>          flash at 0 {
>> +               u-boot,dm-pre-reloc;
>>                  compatible = "mxicy,mx25l12805d", "jedec,spi-nor";
>>          };
>>   };
>> diff --git a/configs/orangepi_r1_defconfig b/configs/orangepi_r1_defconfig
>> index 6f770fa018..a66c41aa3d 100644
>> --- a/configs/orangepi_r1_defconfig
>> +++ b/configs/orangepi_r1_defconfig
>> @@ -11,3 +11,10 @@ CONFIG_DEFAULT_DEVICE_TREE="sun8i-h2-plus-orangepi-r1"
>>   CONFIG_SUN8I_EMAC=y
>>   CONFIG_USB_EHCI_HCD=y
>>   CONFIG_USB_OHCI_HCD=y
>> +CONFIG_CMD_SF=y
>> +CONFIG_CMD_SPI=y
>> +CONFIG_DM_SPI_FLASH=y
>> +CONFIG_SPI_FLASH_MACRONIX=y
>> +CONFIG_DM_SPI=y
>> +CONFIG_SPI=y
>> +CONFIG_SPL_SPI_SUNXI=y
>> \ No newline at end of file
Peter Robinson July 10, 2020, 3:09 p.m. UTC | #3
On Fri, Jul 10, 2020 at 3:59 PM Yaroslav Petrov <info at lank.me> wrote:
>
> Hi,
>
>
> Thank you very much for your feedback. I try to send it to kernel.org

The u-boot,dm-pre-reloc; doesn't go upstream to kernel.org as it's
U-Boot specific, look at other examples of *-u-boot.dtsi and the
associated commits for those files for examples of how they're dealt
with.

> Mit freundlichen Gr??en,
> Yaroslav Petrov
>
>
> On 10.07.20 13:31, Peter Robinson wrote:
> > On Fri, Jul 10, 2020 at 12:15 PM Yaroslav Petrov <info at lank.me> wrote:
> >> diff --git a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> >> b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> >> index 3356f4210d..675d38738d 100644
> >> --- a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> >> +++ b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
> > These changes should be added to a
> > sun8i-h2-plus-orangepi-r1-u-boot.dtsi file so that any sync from Linux
> > doesn't lose the change.
> >
> >> @@ -65,6 +65,7 @@
> >>
> >>          aliases {
> >>                  ethernet1 = &rtl8189etv;
> >> +               spi0 = &spi0;
> >>          };
> >>   };
> >>
> >> @@ -72,6 +73,7 @@
> >>          status = "okay";
> >>
> >>          flash at 0 {
> >> +               u-boot,dm-pre-reloc;
> >>                  compatible = "mxicy,mx25l12805d", "jedec,spi-nor";
> >>          };
> >>   };
> >> diff --git a/configs/orangepi_r1_defconfig b/configs/orangepi_r1_defconfig
> >> index 6f770fa018..a66c41aa3d 100644
> >> --- a/configs/orangepi_r1_defconfig
> >> +++ b/configs/orangepi_r1_defconfig
> >> @@ -11,3 +11,10 @@ CONFIG_DEFAULT_DEVICE_TREE="sun8i-h2-plus-orangepi-r1"
> >>   CONFIG_SUN8I_EMAC=y
> >>   CONFIG_USB_EHCI_HCD=y
> >>   CONFIG_USB_OHCI_HCD=y
> >> +CONFIG_CMD_SF=y
> >> +CONFIG_CMD_SPI=y
> >> +CONFIG_DM_SPI_FLASH=y
> >> +CONFIG_SPI_FLASH_MACRONIX=y
> >> +CONFIG_DM_SPI=y
> >> +CONFIG_SPI=y
> >> +CONFIG_SPL_SPI_SUNXI=y
> >> \ No newline at end of file
diff mbox series

Patch

diff --git a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts 
b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
index 3356f4210d..675d38738d 100644
--- a/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
+++ b/arch/arm/dts/sun8i-h2-plus-orangepi-r1.dts
@@ -65,6 +65,7 @@ 

 ??????? aliases {
 ??????????????? ethernet1 = &rtl8189etv;
+?????????????? spi0 = &spi0;
 ??????? };
 ?};

@@ -72,6 +73,7 @@ 
 ??????? status = "okay";

 ??????? flash at 0 {
+?????????????? u-boot,dm-pre-reloc;
 ??????????????? compatible = "mxicy,mx25l12805d", "jedec,spi-nor";
 ??????? };
 ?};
diff --git a/configs/orangepi_r1_defconfig b/configs/orangepi_r1_defconfig
index 6f770fa018..a66c41aa3d 100644
--- a/configs/orangepi_r1_defconfig
+++ b/configs/orangepi_r1_defconfig
@@ -11,3 +11,10 @@  CONFIG_DEFAULT_DEVICE_TREE="sun8i-h2-plus-orangepi-r1"
 ?CONFIG_SUN8I_EMAC=y
 ?CONFIG_USB_EHCI_HCD=y
 ?CONFIG_USB_OHCI_HCD=y
+CONFIG_CMD_SF=y
+CONFIG_CMD_SPI=y
+CONFIG_DM_SPI_FLASH=y
+CONFIG_SPI_FLASH_MACRONIX=y
+CONFIG_DM_SPI=y
+CONFIG_SPI=y
+CONFIG_SPL_SPI_SUNXI=y
\ No newline at end of file