[linux-sunxi] Re: [U-Boot] [PATCH v3 01/13] sunxi: fix ACTLR.SMP assembly routine

2017-02-02 Thread Jagan Teki
n Wed, Feb 1, 2017 at 2:35 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> If we take the liberty to use register r0 to perform our bit set, we
> should be nice enough to tell the compiler about it.
> Add r0 to the clobber list to avoid potential mayhem.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Acked-by: Jagan Teki <ja...@openedev.com>

-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 02/13] ARM: rename CONFIG_TIMER_CLK_FREQ to COUNTER_FREQUENCY

2017-02-02 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:35 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Many ARMv8 boards define a constant COUNTER_FREQUENCY to specify the
> frequency of the ARM Generic Timer (aka. arch timer).
> ARMv7 boards traditionally used CONFIG_TIMER_CLK_FREQ for the same
> purpose. It seems useful to unify them.
> Since there are less occurences of the latter version, lets convert all
> users over to COUNTER_FREQUENCY.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Reviewed-by: York Sun <york@nxp.com>

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [linux-sunxi] Re: Sunxi FOSDEM dinner, sat 4 Feb @ 8PM

2017-02-04 Thread Jagan Teki
What time this will start?

On Sat, Feb 4, 2017 at 3:18 PM, Benjamin Henrion <zoo...@gmail.com> wrote:
> No problems, still 5 seats left.
>
> On Feb 4, 2017 14:14, "Mihai Bujanca" <mihaibuja...@gmail.com> wrote:
>>
>> Looks like we can't stay long after all. We might be able to drop by and
>> say hi, but please cancel the two seats for me.
>>
>> Mihai
>>
>> On Tuesday, 10 January 2017 16:01:38 UTC, Benjamin Henrion wrote:
>>>
>>> Hi,
>>>
>>> Like previous years, I have booked the Amadeo restaurant for the Sunxi
>>> FOSDEM dinner:
>>>
>>> http://amadeus-resto.be/en/amadeo-brussel/
>>>
>>> Please reply to this mail so that I can book a place for you.
>>>
>>> We will leave FOSDEM around 7PM at the O'Reilly booth, if you are
>>> bored the last hour I will be speaking at 6PM:
>>>
>>> https://fosdem.org/2017/schedule/event/pieter_hintjens/
>>>
>>> Best,
>>>
>>> --
>>> Benjamin Henrion 
>>> FFII Brussels - +32-484-566109 - +32-2-3500762
>>> "In July 2005, after several failed attempts to legalise software
>>> patents in Europe, the patent establishment changed its strategy.
>>> Instead of explicitly seeking to sanction the patentability of
>>> software, they are now seeking to create a central European patent
>>> court, which would establish and enforce patentability rules in their
>>> favor, without any possibility of correction by competing courts or
>>> democratically elected legislators."
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "linux-sunxi" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/linux-sunxi/afFMBIR2m_o/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> linux-sunxi+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 12/13] sunxi: dts: add basic OrangePi PC 2 device tree file

2017-02-03 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:36 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> The OrangePi PC 2 is a typical SBC with the 64-bit Allwinner H5 SoC.
> Create a new .dts file for it by including the (32-bit) H3 SoC .dtsi
> and changing the differing components accordingly.
> This is a preliminary device tree mostly for U-Boot's own sake, it
> is expected to be updated once the official DT gets accepted upstream.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> ---
>  arch/arm/dts/Makefile   |   2 +
>  arch/arm/dts/sun50i-h5-orangepi-pc2.dts | 147 
> 

Please squash 13/13 with this, I would see a single patch for initial support.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 05/13] sunxi: configs: merge sun9i and sun50i SPL memory definitions

2017-02-03 Thread Jagan Teki
On Thu, Feb 2, 2017 at 1:25 PM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Wed, Feb 01, 2017 at 01:36:02AM +, Andre Przywara wrote:
>> For some reason we were pretty conservative when defining the maximum
>> SPL size for the Allwinner A80(sun9i) SoC.
>> According to the manual the SRAM A1 is even 40KB, but the BROM
>> probably still has the 32 KiB load limit. For the sake of simplicity,
>> merge the SPL memory definitions for the A64 and A80 SoCs, since both
>> SoC share the BROM/SRAM A1 memory layout.
>> This helps to further simplify this is in the next patch.
>>
>> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 03/13] fsl: ls102x: remove redundant GENERIC_TIMER_CLK

2017-02-03 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:36 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Some Freescale boards used an extra version of the constant to hold the
> Generic Timer frequency. This can easily be covered by the now unified
> COUNTER_FREQUENCY constant, so remove this extra variable from those
> boards.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Reviewed-by: York Sun <york....@nxp.com>

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 07/13] sunxi: provide ARMv8 mem_map for every ARM64 board

2017-02-03 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:36 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Every armv8 board needs the memory map, so change the #ifdef to
> ARM64 to avoid enumerating every single board or SoC.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>
> ---
>  arch/arm/mach-sunxi/board.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 06/13] sunxi: Kconfig: introduce CONFIG_SUNXI_HIGH_SRAM

2017-02-03 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:36 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Traditionally Allwinner SoCs have their boot ROM mapped just below 4GB,
> while the first SRAM region is mapped at address 0.
> With the extended physical memory support of the A80 this was changed,
> so the BROM is now at address 0 and the SRAM region starts right behind
> this at 64KB. This configuration seems to be called "high SRAM".
> Instead of enumerating the SoCs which have copied this configuration,
> let's call a spade a spade and introduce a Kconfig option for this setup.
> SoCs implementing this (A80, A64 and H5, so far), can then select this
> configuration.
> Simplify the config header definition on the way.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>
> ---
>  arch/arm/include/asm/arch-sunxi/spl.h |  2 +-
>  board/sunxi/Kconfig   |  6 ++
>  include/configs/sunxi-common.h| 19 +++
>  3 files changed, 14 insertions(+), 13 deletions(-)
>
> diff --git a/arch/arm/include/asm/arch-sunxi/spl.h 
> b/arch/arm/include/asm/arch-sunxi/spl.h
> index 5d7ab55..831d0c0 100644
> --- a/arch/arm/include/asm/arch-sunxi/spl.h
> +++ b/arch/arm/include/asm/arch-sunxi/spl.h
> @@ -12,7 +12,7 @@
>  #define SPL_SIGNATURE  "SPL" /* marks "sunxi" SPL header */
>  #define SPL_HEADER_VERSION 1
>
> -#if defined(CONFIG_MACH_SUN9I) || defined(CONFIG_MACH_SUN50I)
> +#ifdef CONFIG_SUNXI_HIGH_SRAM
>  #define SPL_ADDR   0x1
>  #else
>  #define SPL_ADDR   0x0
> diff --git a/board/sunxi/Kconfig b/board/sunxi/Kconfig
> index ea0d658..688cb12 100644
> --- a/board/sunxi/Kconfig
> +++ b/board/sunxi/Kconfig
> @@ -27,6 +27,10 @@ config SPL_POWER_SUPPORT
>  config SPL_SERIAL_SUPPORT
> default y
>
> +config SUNXI_HIGH_SRAM
> +   bool
> +   default n

Write some help text, once written

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 08/13] SPI: SPL: sunxi: fix 64-bit build

2017-02-03 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:36 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Addresses passed on to readl and writel are expected to be of the same
> size as a pointer. Change the parameter types of sunxi_spi0_read_data()
> to make the compiler happy and allow a warning-free aarch64 compile.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Reviewed-by: Simon Glass <s...@chromium.org>
> Reviewed-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 04/13] sunxi: simplify ACTLR.SMP bit set #ifdef

2017-02-03 Thread Jagan Teki
On Wed, Feb 1, 2017 at 2:36 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Instead of enumerating all SoC families that need that bit set, let's
> just express this more clearly: The SMP bits needs to be set on
> SMP capable ARMv7 CPUs. It's much easier in Kconfig to express it the
> other way round, so we use ! CPU_IS_UP and ! ARM64.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>
> ---
>  arch/arm/Kconfig| 4 
>  arch/arm/mach-sunxi/board.c | 5 +
>  board/sunxi/Kconfig | 2 ++
>  3 files changed, 7 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> index fc36723..98791c0 100644
> --- a/arch/arm/Kconfig
> +++ b/arch/arm/Kconfig
> @@ -126,6 +126,10 @@ config ENABLE_ARM_SOC_BOOT0_HOOK
>   ARM_SOC_BOOT0_HOOK which contains the required assembler
>   preprocessor code.
>
> +config ARM_CORTEX_CPU_IS_UP
> +   bool
> +   default n

Better to place this in sunxi, since no other code using this expect
sunxi and the name CORTEX may also refer arm64 use something 32
related.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 09/13] sunxi: DRAM: add Allwinner H5 support

2017-02-03 Thread Jagan Teki
On Feb 1, 2017 2:37 AM, "Andre Przywara"  wrote:

The DRAM controller in the Allwinner H5 SoC is again very similar to
the one in the H3 and A64.
Based on the existing socid parameter, add support for this controller
by reusing the bulk of the code and only deviating where needed.
These new bits set or cleared here and there have been mostly found by
looking at DRAM register dumps after using the H5 boot0 and comparing
them to what we set in the code. So for now it's mostly unclear what
those bits actually mean - hence the missing names and comments.
Also add the delay line parameters taken from the boot0 and libdram
disassembly.


Can you split this patch with delay line params as separate patch.


Register setup differences between H5 and H3 are courtesy of Jens Kuske.

Signed-off-by: Andre Przywara 
Acked-by: Maxime Ripard 
---
 arch/arm/include/asm/arch-sunxi/cpu.h |  1 +
 arch/arm/mach-sunxi/dram_sun8i_h3.c   | 97 +-
-
 2 files changed, 82 insertions(+), 16 deletions(-)

diff --git a/arch/arm/include/asm/arch-sunxi/cpu.h
b/arch/arm/include/asm/arch-sunxi/cpu.h
index 6f96a97..e8e670e 100644
--- a/arch/arm/include/asm/arch-sunxi/cpu.h
+++ b/arch/arm/include/asm/arch-sunxi/cpu.h
@@ -15,5 +15,6 @@

 #define SOCID_A64  0x1689
 #define SOCID_H3   0x1680
+#define SOCID_H5   0x1718

 #endif /* _SUNXI_CPU_H */
diff --git a/arch/arm/mach-sunxi/dram_sun8i_h3.c b/arch/arm/mach-sunxi/dram_
sun8i_h3.c
index 9f7cc7f..d681a9d 100644
--- a/arch/arm/mach-sunxi/dram_sun8i_h3.c
+++ b/arch/arm/mach-sunxi/dram_sun8i_h3.c
@@ -177,6 +177,34 @@ static void mctl_set_master_priority_a64(void)
writel(0x8104, _com->mdfs_bwlr[2]);
 }

+static void mctl_set_master_priority_h5(void)
+{
+   struct sunxi_mctl_com_reg * const mctl_com =
+   (struct sunxi_mctl_com_reg *)SUNXI_DRAM_COM_BASE;
+
+   /* enable bandwidth limit windows and set windows size 1us */
+   writel(399, _com->tmr);
+   writel((1 << 16), _com->bwcr);


I'm not fond of using direct numerical values make code unhealthy please
use macros with bitops. Note that this comment will apply rest of the code
where it applies.

+
+   /* set cpu high priority */
+   writel(0x0001, _com->mapr);
+
+   /* Port 2 is reserved per Allwinner's linux-3.10 source, yet
+* they initialise it */
+   MBUS_CONF(   CPU, true, HIGHEST, 0,  300,  260,  150);
+   MBUS_CONF(   GPU, true, HIGHEST, 0,  600,  400,  200);
+   MBUS_CONF(UNUSED, true, HIGHEST, 0,  512,  256,   96);
+   MBUS_CONF(   DMA, true, HIGHEST, 0,  256,  128,   32);
+   MBUS_CONF(VE, true, HIGHEST, 0, 1900, 1500, 1000);
+   MBUS_CONF(   CSI, true, HIGHEST, 0,  150,  120,  100);
+   MBUS_CONF(  NAND, true,HIGH, 0,  256,  128,   64);
+   MBUS_CONF(SS, true, HIGHEST, 0,  256,  128,   64);
+   MBUS_CONF(TS, true, HIGHEST, 0,  256,  128,   64);
+   MBUS_CONF(DI, true,HIGH, 0, 1024,  256,   64);
+   MBUS_CONF(DE, true, HIGHEST, 3, 3400, 2400, 1024);
+   MBUS_CONF(DE_CFD, true, HIGHEST, 0,  600,  400,  200);
+}
+
 static void mctl_set_master_priority(uint16_t socid)
 {
switch (socid) {
@@ -186,6 +214,9 @@ static void mctl_set_master_priority(uint16_t socid)
case SOCID_A64:
mctl_set_master_priority_a64();
return;
+   case SOCID_H5:
+   mctl_set_master_priority_h5();
+   return;
}
 }

@@ -256,7 +287,7 @@ static void mctl_set_timing_params(uint16_t socid,
struct dram_para *para)

/* set two rank timing */
clrsetbits_le32(_ctl->dramtmg[8], (0xff << 8) | (0xff << 0),
-   (0x66 << 8) | (0x10 << 0));
+   ((socid == SOCID_H5 ? 0x33 : 0x66) << 8) | (0x10 <<
0));

/* set PHY interface timing, write latency and read latency
configure */
writel((0x2 << 24) | (t_rdata_en << 16) | (0x1 << 8) |
@@ -391,7 +422,7 @@ static void mctl_sys_init(uint16_t socid, struct
dram_para *para)
CCM_DRAMCLK_CFG_DIV(1) |
CCM_DRAMCLK_CFG_SRC_PLL11 |
CCM_DRAMCLK_CFG_UPD);
-   } else if (socid == SOCID_H3) {
+   } else if (socid == SOCID_H3 || socid == SOCID_H5) {
clock_set_pll5(CONFIG_DRAM_CLK * 2 * 100, false);
clrsetbits_le32(>dram_clk_cfg,
CCM_DRAMCLK_CFG_DIV_MASK |
@@ -410,7 +441,7 @@ static void mctl_sys_init(uint16_t socid, struct
dram_para *para)
setbits_le32(>dram_clk_cfg, CCM_DRAMCLK_CFG_RST);
udelay(10);

-   writel(0xc00e, _ctl->clken);
+   writel(socid == SOCID_H5 ? 0x8000 : 0xc00e, _ctl->clken);
udelay(500);
 }

@@ -434,7 +465,10 @@ static int mctl_channel_init(uint16_t socid, struct
dram_para *para)

/* setting VTC, default 

[linux-sunxi] Re: Sunxi FOSDEM dinner, sat 4 Feb @ 8PM

2017-01-25 Thread Jagan Teki
Please reserve 2 dinner spots for me, 

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux |  Upstream Maintainer
Hyderabad, India.

On Wednesday, 18 January 2017 23:08:40 UTC+1, Vit wrote:
>
> Please, book me one place.
>
> Thank you,
> Vit
>
> On Tuesday, January 10, 2017 at 5:01:38 PM UTC+1, Benjamin Henrion wrote:
>>
>> Hi, 
>>
>> Like previous years, I have booked the Amadeo restaurant for the Sunxi 
>> FOSDEM dinner: 
>>
>> http://amadeus-resto.be/en/amadeo-brussel/ 
>>
>> Please reply to this mail so that I can book a place for you. 
>>
>> We will leave FOSDEM around 7PM at the O'Reilly booth, if you are 
>> bored the last hour I will be speaking at 6PM: 
>>
>> https://fosdem.org/2017/schedule/event/pieter_hintjens/ 
>>
>> Best, 
>>
>> -- 
>> Benjamin Henrion  
>> FFII Brussels - +32-484-566109 - +32-2-3500762 
>> "In July 2005, after several failed attempts to legalise software 
>> patents in Europe, the patent establishment changed its strategy. 
>> Instead of explicitly seeking to sanction the patentability of 
>> software, they are now seeking to create a central European patent 
>> court, which would establish and enforce patentability rules in their 
>> favor, without any possibility of correction by competing courts or 
>> democratically elected legislators." 
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v2] sunxi: add NanoPi NEO Air defconfig

2017-02-25 Thread Jagan Teki
On Mon, Feb 13, 2017 at 1:22 PM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Sun, Feb 12, 2017 at 04:21:40PM +0100, Jelle van der Waa wrote:
>> Add support for the NanoPi NEO Air H3 board from friendlyarm.com . This
>> board contains WiFi, Bluetooth, 8GB eMMC storage and 512 MB DDR3 ram.
>>
>> Signed-off-by: Jelle van der Waa <je...@vdwaa.nl>
>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Fixed, error while 'git am' and

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v4 00/13] sunxi: Allwinner H5 and OrangePi PC2 support

2017-02-25 Thread Jagan Teki
On Thu, Feb 16, 2017 at 6:50 AM, Andre Przywara <andre.przyw...@arm.com> wrote:
> Hi,
>
> thanks for all the reviews and ACKs!
>
> Only minor changes this time, see the Changelog below.
>
> Cheers,
> Andre.
>
> --
> This series introduces support for the Allwinner H5 SoC with four
> Cortex-A53 cores. The SoC's peripherals are very similar to the H3,
> although the cores and the BROM/SRAM layout resembles the A64.
> The first 8 patches contain some fixes and refactoring, to make code
> sharing between the three mentioned SoCs easier.
> Patch 09/13 adds support for the H5 DRAM controller, by extending
> the already existing combined H3/A64 DRAM code.
> Patch 10/13 renames the existing CONFIG_MACH_SUN8I_H3 config symbol to
> let it be used by all peripheral code that can be shared between the
> H3 and H5. Patch 11/13 introduces the H5 SoC config option into Kconfig,
> which defines this shared symbol as well.
> Patch 12/13 adds an easy device tree, which actually uses the H3 .dtsi
> and overwrites nodes which are different. This is good enough for U-Boot,
> the DT will be changed anyway once we get the DT merged into the Linux
> kernel.
> The final patch then adds the defconfig for the OrangePi PC2 board.
> Since this board comes with soldered SPI flash, we enable support for
> it in the SPL. This has been tested by writing the SPI flash with some
> special sunxi-fel version. The BROM loaded and executed the SPL, which
> in turn loaded and executed U-Boot proper. Both parts are 64-bit only
> for now.
> Ethernet support is enabled, but fails at the moment since the EMAC
> driver does not support setting a GPIO to enable the external Gigabit PHY.
>
> At the moment this build suffers from the same problem as the A64: the
> ATF is missing, so Linux won't boot easily. With the RFC version of the
> SPL FIT extension series on the list, applied on top of this one this
> should now be solved.
>
> This series is on top of v2017.03-rc2.
>
> Please have a look and let me know your opinion!
>
> Cheers,
> Andre.
>
> Changelog v3..v4:
> - Adding ACKs and RBs
> - adding help text for CONFIG_SUNXI_HIGH_SRAM option
> - adapting _defconfig to upstream changes
>
> Changelog v2..v3:
> - Adding ACKs and RBs
> - remove not needed CONFIG_MACH_SUN50I_H5_64
> - move ARM_CORTEX_CPU_IS_UP to arch/arm/Kconfig
>
> Changelog v1..v2:
> - Adding Maxime's ACKs
> - new patch 2 and 3 to rename CONFIG_TIMER_CLK_FREQ to COUNTER_FREQUENCY
> - renaming CONFIG symbol name for single core SoCs
> - fixing one checkpatch issue (some are left, though)
> - mentioning methodology and reason for missing data in DRAM driver
> - renaming shared config symbol to CONFIG_MACH_SUNXI_H3_H5
> - updated to lastest origin/master
>
> Andre Przywara (13):
>   sunxi: fix ACTLR.SMP assembly routine
>   ARM: rename CONFIG_TIMER_CLK_FREQ to COUNTER_FREQUENCY
>   fsl: ls102x: remove redundant GENERIC_TIMER_CLK
>   sunxi: simplify ACTLR.SMP bit set #ifdef
>   sunxi: configs: merge sun9i and sun50i SPL memory definitions
>   sunxi: Kconfig: introduce CONFIG_SUNXI_HIGH_SRAM
>   sunxi: provide ARMv8 mem_map for every ARM64 board
>   SPI: SPL: sunxi: fix 64-bit build
>   sunxi: DRAM: add Allwinner H5 support
>   sunxi: prepare for sharing MACH_SUN8I_H3 config symbol
>   sunxi: introduce Allwinner H5 config option
>   sunxi: dts: add basic OrangePi PC 2 device tree file
>   sunxi: configs: add basic OrangePi PC 2 defconfig

squash above two commits.

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 1/3] sunxi: add basic V3s support

2017-02-28 Thread Jagan Teki
On Mon, Feb 13, 2017 at 12:44 PM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Sat, Feb 11, 2017 at 07:11:00PM +0800, Icenowy Zheng wrote:
>> Basic U-Boot support is now present for V3s.
>>
>> Some memory addresses are changed specially for V3s, as the original
>> address map cannot fit into a so small DRAM.
>>
>> As the DRAM controller code needs a big refactor, the SPL support is
>> disabled in this version.
>>
>> Signed-off-by: Icenowy Zheng <icen...@aosc.xyz>
>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>


Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3 3/3] sunxi: add support for Lichee Pi Zero

2017-02-28 Thread Jagan Teki
On Sat, Feb 11, 2017 at 4:41 PM, Icenowy Zheng <icen...@aosc.xyz> wrote:
> Lichee Pi Zero is a development board with a V3s SoC.
>
> Add support for it.

Add some details about board/features ?

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: Add boards/sunxi and arch/arm/mach-sunxi to sunxi MAINTAINERS entry

2017-03-01 Thread Jagan Teki
On Wed, Mar 1, 2017 at 11:33 AM, Chen-Yu Tsai <w...@csie.org> wrote:
> Recently some sunxi related code was moved to arch/arm/mach-sunxi, but
> the MAINTAINERS entry was not updated to reflect this. Add this, and
> the board level boards/sunxi directory to our entry.
>
> While at it, also update its status, to reflect the current active
> maintainership.
>
> Signed-off-by: Chen-Yu Tsai <w...@csie.org>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: makes an invisible option for H3-like DRAM controllers

2017-03-01 Thread Jagan Teki
On Tue, Feb 14, 2017 at 7:19 PM, Icenowy Zheng <icen...@aosc.xyz> wrote:
> Allwinner SoCs after H3 (e.g. A64, H5, R40, V3s) uses a H3-like
> DesignWare DRAM controller, which do not have official free DRAM
> initialization code, but can use modified dram_sun8i_h3.c.
>
> Add a invisible option for easier DRAM initialization code reuse.
>
> Signed-off-by: Icenowy Zheng <icen...@aosc.xyz>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>
> ---
>  arch/arm/include/asm/arch-sunxi/dram.h   | 4 ++--
>  .../include/asm/arch-sunxi/{dram_sun8i_h3.h => dram_sunxi_dw.h}  | 0
>  arch/arm/mach-sunxi/Makefile | 2 +-
>  arch/arm/mach-sunxi/{dram_sun8i_h3.c => dram_sunxi_dw.c} | 0
>  board/sunxi/Kconfig  | 9 
> +
>  5 files changed, 12 insertions(+), 3 deletions(-)
>  rename arch/arm/include/asm/arch-sunxi/{dram_sun8i_h3.h => dram_sunxi_dw.h} 
> (100%)
>  rename arch/arm/mach-sunxi/{dram_sun8i_h3.c => dram_sunxi_dw.c} (100%)
>
> diff --git a/arch/arm/include/asm/arch-sunxi/dram.h 
> b/arch/arm/include/asm/arch-sunxi/dram.h
> index 53e6d471d2..6f0131ab16 100644
> --- a/arch/arm/include/asm/arch-sunxi/dram.h
> +++ b/arch/arm/include/asm/arch-sunxi/dram.h
> @@ -24,8 +24,8 @@
>  #include 
>  #elif defined(CONFIG_MACH_SUN8I_A83T)
>  #include 
> -#elif defined(CONFIG_MACH_SUN8I_H3) || defined(CONFIG_MACH_SUN50I)
> -#include 
> +#elif defined(CONFIG_SUNXI_DW_DRAM)
> +#include 
>  #elif defined(CONFIG_MACH_SUN9I)
>  #include 
>  #else
> diff --git a/arch/arm/include/asm/arch-sunxi/dram_sun8i_h3.h 
> b/arch/arm/include/asm/arch-sunxi/dram_sunxi_dw.h
> similarity index 100%
> rename from arch/arm/include/asm/arch-sunxi/dram_sun8i_h3.h
> rename to arch/arm/include/asm/arch-sunxi/dram_sunxi_dw.h
> diff --git a/arch/arm/mach-sunxi/Makefile b/arch/arm/mach-sunxi/Makefile
> index 7daba1169c..25d896a14e 100644
> --- a/arch/arm/mach-sunxi/Makefile
> +++ b/arch/arm/mach-sunxi/Makefile
> @@ -48,7 +48,7 @@ obj-$(CONFIG_MACH_SUN7I)  += dram_sun4i.o
>  obj-$(CONFIG_MACH_SUN8I_A23)   += dram_sun8i_a23.o
>  obj-$(CONFIG_MACH_SUN8I_A33)   += dram_sun8i_a33.o
>  obj-$(CONFIG_MACH_SUN8I_A83T)  += dram_sun8i_a83t.o
> -obj-$(CONFIG_MACH_SUN8I_H3)+= dram_sun8i_h3.o
> +obj-$(CONFIG_SUNXI_DW_DRAM)+= dram_sunxi_dw.o
>  obj-$(CONFIG_MACH_SUN9I)   += dram_sun9i.o
>  obj-$(CONFIG_MACH_SUN50I)  += dram_sun8i_h3.o
>  endif
> diff --git a/arch/arm/mach-sunxi/dram_sun8i_h3.c 
> b/arch/arm/mach-sunxi/dram_sunxi_dw.c
> similarity index 100%
> rename from arch/arm/mach-sunxi/dram_sun8i_h3.c
> rename to arch/arm/mach-sunxi/dram_sunxi_dw.c
> diff --git a/board/sunxi/Kconfig b/board/sunxi/Kconfig
> index 018bdd12dd..d09ae6067e 100644
> --- a/board/sunxi/Kconfig
> +++ b/board/sunxi/Kconfig
> @@ -42,6 +42,13 @@ config SUNXI_GEN_SUN6I
> separate ahb reset control registers, custom pmic bus, new style
> watchdog, etc.
>
> +config SUNXI_DW_DRAM

I prefer SUNXI_DRAM_DW since config start with SUNXI which is OS and
DRAM which is peripheral and DW from the vendor, this notation quite
relevant if there is any new DRAM the tail should be changed.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v2 1/6] sunxi: add invisible options for PRCM and RSB support

2017-03-01 Thread Jagan Teki
On Sun, Feb 26, 2017 at 5:22 AM, Icenowy Zheng <icen...@aosc.xyz> wrote:
> The Makefile of mach-sunxi used to build PRCM and RSB according to the
> SoC's MACH_SUNxI macro, which makes it needed to add lines for new SoC
> generation.
>
> Change this behavior to invisible options in sunxi Kconfig, so that new
> lines are not needed for new SoC. Also it allows more accurate control
> of the build of the related sources, for example, V3s (sun8iw8) and R40
> (sun8iw11) do not have PRCM at all, and H3 (sun8iw7) do not have RSB,
> but these functions are built with the old code.

Since H3 doesn't have RSB how should it implement or use the RCB
functionalities? what do you mean by old code here?

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v2 3/6] sunxi: add AXP_PMIC_BUS invisible options for AXP PMICs access

2017-03-01 Thread Jagan Teki
On Sun, Feb 26, 2017 at 5:22 AM, Icenowy Zheng <icen...@aosc.xyz> wrote:
> For AXP PMICs' drivers some functions are needed to provide I/O access
> for the PMIC.
>
> The source file used to be controlled by different AXPxxx_POWER config
> option.
>
> Control the file's compliation via a generic AXP_PMIC_BUS option, and
> make all AXPxxx_POWER select this option, to prevent furtherly more and
> more AXP PMIC names are added to the Makefile of mach-sunxi.
>
> Signed-off-by: Icenowy Zheng <icen...@aosc.xyz>
> ---
>  arch/arm/mach-sunxi/Makefile |  6 +-
>  drivers/power/Kconfig| 10 ++
>  2 files changed, 11 insertions(+), 5 deletions(-)
>
> diff --git a/arch/arm/mach-sunxi/Makefile b/arch/arm/mach-sunxi/Makefile
> index a8bf3a6c64..5767f7643f 100644
> --- a/arch/arm/mach-sunxi/Makefile
> +++ b/arch/arm/mach-sunxi/Makefile
> @@ -31,11 +31,7 @@ obj-$(CONFIG_MACH_SUN8I) += clock_sun6i.o
>  endif
>  obj-$(CONFIG_MACH_SUN9I)   += clock_sun9i.o gtbus_sun9i.o
>
> -obj-$(CONFIG_AXP152_POWER) += pmic_bus.o
> -obj-$(CONFIG_AXP209_POWER) += pmic_bus.o
> -obj-$(CONFIG_AXP221_POWER) += pmic_bus.o
> -obj-$(CONFIG_AXP809_POWER) += pmic_bus.o
> -obj-$(CONFIG_AXP818_POWER) += pmic_bus.o
> +obj-$(CONFIG_AXP_PMIC_BUS) += pmic_bus.o
>
>  ifdef CONFIG_SPL_BUILD
>  obj-$(CONFIG_MACH_SUN4I)   += dram_sun4i.o
> diff --git a/drivers/power/Kconfig b/drivers/power/Kconfig
> index f2c5629be2..442e33ea30 100644
> --- a/drivers/power/Kconfig
> +++ b/drivers/power/Kconfig
> @@ -6,6 +6,11 @@ source "drivers/power/pmic/Kconfig"
>
>  source "drivers/power/regulator/Kconfig"
>
> +config AXP_PMIC_BUS
> +   bool
> +   ---help---
> +   Select this for code providing PMIC access code for AXP PMICs.

No, better to move this pmic driver to drivers/power or if possible
use the existing drivers/power/axp*.c

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v5 2/2] sun50i: a64: Add initial NanoPi A64 support

2017-08-16 Thread Jagan Teki
On Tue, Aug 15, 2017 at 11:38 AM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> NanoPi A64 is a new board of high performance with low cost
> designed by FriendlyElec., using the Allwinner A64 SOC.
>
> Nanopi A64 features
> - Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
> - 1GB DDR3 RAM
> - MicroSD
> - Gigabit Ethernet (RTL8211E)
> - Wi-Fi 802.11b/g/n
> - IR receiver
> - Audio In/Out
> - Video In/Out
> - Serial Debug Port
> - microUSB 5V 2A DC power-supply
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: defaultly enable SPL for Lichee Pi Zero

2017-08-16 Thread Jagan Teki
On Mon, Aug 14, 2017 at 9:16 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> On Mon, Aug 14, 2017 at 8:30 PM, Icenowy Zheng <icen...@aosc.io> wrote:
>> As we have already DRAM initialization code for V3s SoC, we can
>> defaultly enable SPL now on Lichee Pi Zero.
>>
>> Add CONFIG_SPL in Lichee Pi Zero defconfig.
>>
>> Signed-off-by: Icenowy Zheng <icen...@aosc.io>
>
> Reviewed-by: Jagan Teki <ja...@openedev.com>

Applied to u-boot-sunxi/next

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v2] sun50i: a64: Add A64-OLinuXino initial support

2017-08-16 Thread Jagan Teki
On Tue, Aug 15, 2017 at 11:38 AM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> OLimex A64-OLinuXino is an open-source hardware board
> using the Allwinner A64 SOC.
>
> OLimex A64-OLinuXino has
> - A64 Quad-core Cortex-A53 64bit
> - 1GB or 2GB RAM DDR3L @ 672Mhz
> - microSD slot and 4/8/16GB eMMC
> - Debug TTL UART
> - HDMI
> - LCD
> - IR receiver
> - 5V DC power supply
>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v5 1/2] sun50i: a64: Sync Linux [oe]hci0 nodes

2017-08-16 Thread Jagan Teki
On Tue, Aug 15, 2017 at 11:38 AM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> Synced ohci0 and ehci0 nodes from Linux for sun50i-a64.dtsi
>
> Here is the Linux last merge tag details:
> Merge: 0e91f43d e5770b7
> Author: Stephen Rothwell <s...@canb.auug.org.au>
> Date:   Fri Jun 9 14:59:55 2017 +1000
>
> Merge remote-tracking branch 'staging/staging-next'
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v4] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-08-11 Thread Jagan Teki
On Fri, Aug 11, 2017 at 6:01 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> NanoPi A64 is a new board of high performance with low cost
> designed by FriendlyElec., using the Allwinner A64 SOC.
>
> Nanopi A64 features
> - Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
> - 1GB DDR3 RAM
> - MicroSD
> - Gigabit Ethernet (RTL8211E)
> - Wi-Fi 802.11b/g/n
> - IR receiver
> - Audio In/Out
> - Video In/Out
> - Serial Debug Port
> - microUSB 5V 2A DC power-supply
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
> ---
> Changes for v4:
> - Rebased and droped wi-fi related nodes, since it require
>   other changes to taken care.
> Changes for v3:
> - Fix to use mmc1 for SDIO instead of mmc2
> - Replace buswidth by 4 instead of 8 mmc1
> - Drop cap-mmc-hw-reset for mmc1
> Changes for v2:
> - Added ohci0, ehci0, ohic1, ehci1, usbphy.
> - Tested on A64
>
>  arch/arm64/boot/dts/allwinner/Makefile |   1 +
>  .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 114 
> +
>  2 files changed, 115 insertions(+)
>  create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
>
> diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
> b/arch/arm64/boot/dts/allwinner/Makefile
> index 108f12c..c997b5c 100644
> --- a/arch/arm64/boot/dts/allwinner/Makefile
> +++ b/arch/arm64/boot/dts/allwinner/Makefile
> @@ -1,4 +1,5 @@
>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
> +dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
> b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
> new file mode 100644
> index 000..e4c121a
> --- /dev/null
> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
> @@ -0,0 +1,114 @@
> +/*
> + * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
> + *
> + * This file is dual-licensed: you can use it either under the terms
> + * of the GPL or the X11 license, at your option. Note that this dual
> + * licensing only applies to this file, and not this project as a
> + * whole.
> + *
> + *  a) This library is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU General Public License as
> + * published by the Free Software Foundation; either version 2 of the
> + * License, or (at your option) any later version.
> + *
> + * This library is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> + * GNU General Public License for more details.
> + *
> + * Or, alternatively,
> + *
> + *  b) Permission is hereby granted, free of charge, to any person
> + * obtaining a copy of this software and associated documentation
> + * files (the "Software"), to deal in the Software without
> + * restriction, including without limitation the rights to use,
> + * copy, modify, merge, publish, distribute, sublicense, and/or
> + * sell copies of the Software, and to permit persons to whom the
> + * Software is furnished to do so, subject to the following
> + * conditions:
> + *
> + * The above copyright notice and this permission notice shall be
> + * included in all copies or substantial portions of the Software.
> + *
> + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
> + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
> + * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
> + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
> + * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
> + * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
> + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
> + * OTHER DEALINGS IN THE SOFTWARE.
> + */
> +
> +/dts-v1/;
> +
> +#include "sun50i-a64.dtsi"
> +
> +#include 
> +
> +/ {
> +   model = "FriendlyARM NanoPi A64";
> +   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
> +
> +   aliases {
> +   serial0 = 
> +   };
> +
> +   chosen {
> +   stdout-path = "serial0:115200n8";
> +   };
> +
> +   reg_vcc3v3: vcc3v3 {
> +   

Re: [linux-sunxi] [PATCH v6] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-08-14 Thread Jagan Teki
On Tue, Aug 15, 2017 at 9:14 AM, Chen-Yu Tsai <w...@csie.org> wrote:
> On Mon, Aug 14, 2017 at 6:36 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> NanoPi A64 is a new board of high performance with low cost
>> designed by FriendlyElec., using the Allwinner A64 SOC.
>>
>> Nanopi A64 features
>> - Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
>> - 1GB DDR3 RAM
>> - MicroSD
>> - Gigabit Ethernet (RTL8211E)
>> - Wi-Fi 802.11b/g/n
>> - IR receiver
>> - Audio In/Out
>> - Video In/Out
>> - Serial Debug Port
>> - microUSB 5V 2A DC power-supply
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>> ---
>> Changes for v6:
>> - Moved uart0 below regulators
>> - Add comment for i2c1
>> - Update vdd-cpux volt range 1.04 ~ 1.3 V
>> - ehci0 detection https://paste.ubuntu.com/25311593/
>
> Thanks. This confirms the hardware default is OK for host-only
> usage.
>
>> - Remove space before usbphy
>> - Removed unused DLD02
>> - Add comment for DLD01 regulator-name to vcc-dsi since
>>   it's connected along with vcc-hdmi
>> - Add regulator node for DLD04 for vcc-pg
>> Changes for v5:
>> - Add AXP803 PMIC regulator support.
>> Changes for v4:
>> - Rebased and droped wi-fi related nodes, since it require
>>   other changes to taken care.
>> Changes for v3:
>> - Fix to use mmc1 for SDIO instead of mmc2
>> - Replace buswidth by 4 instead of 8 mmc1
>> - Drop cap-mmc-hw-reset for mmc1
>> Changes for v2:
>> - Added ohci0, ehci0, ohic1, ehci1, usbphy.
>> - Tested on A64
>>
>>  arch/arm64/boot/dts/allwinner/Makefile |   1 +
>>  .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 209 
>> +
>>  2 files changed, 210 insertions(+)
>>  create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
>>
>> diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
>> b/arch/arm64/boot/dts/allwinner/Makefile
>> index 108f12c..c997b5c 100644
>> --- a/arch/arm64/boot/dts/allwinner/Makefile
>> +++ b/arch/arm64/boot/dts/allwinner/Makefile
>> @@ -1,4 +1,5 @@
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
>> +dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
>> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
>> b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
>> new file mode 100644
>> index 000..c2bbc75
>> --- /dev/null
>> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
>> @@ -0,0 +1,209 @@
>> +/*
>> + * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
>> + *
>> + * This file is dual-licensed: you can use it either under the terms
>> + * of the GPL or the X11 license, at your option. Note that this dual
>> + * licensing only applies to this file, and not this project as a
>> + * whole.
>> + *
>> + *  a) This library is free software; you can redistribute it and/or
>> + * modify it under the terms of the GNU General Public License as
>> + * published by the Free Software Foundation; either version 2 of the
>> + * License, or (at your option) any later version.
>> + *
>> + * This library is distributed in the hope that it will be useful,
>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>> + * GNU General Public License for more details.
>> + *
>> + * Or, alternatively,
>> + *
>> + *  b) Permission is hereby granted, free of charge, to any person
>> + * obtaining a copy of this software and associated documentation
>> + * files (the "Software"), to deal in the Software without
>> + * restriction, including without limitation the rights to use,
>> + * copy, modify, merge, publish, distribute, sublicense, and/or
>> + * sell copies of the Software, and to permit persons to whom the
>> + * Software is furnished to do so, subject to the following
>> + * conditions:
>> + *
>> + * The above copyright notice and this permission notice shall be
>> + * included in all copies or substantial portions of the Software.
>> + *
>> + * THE SOFTWARE IS PROVIDED &

[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: add MACPWR in Orange Pi PC2 defconfig

2017-08-11 Thread Jagan Teki
On Fri, Aug 11, 2017 at 3:30 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> On Tue, Jul 4, 2017 at 4:13 PM, Icenowy Zheng <icen...@aosc.io> wrote:
>> The Ethernet function is enabled in the Orange Pi PC2 device tree and
>> defconfig, however, CONFIG_MACPWR is not properly set, which left the
>> PHY being disabled when booting, which makes the Ethernet function not
>> usable.
>>
>> Add the proper value of this option in the PC2 defconfig.
>>
>> Fixes: e7bd15ea156f ("sunxi: Add OrangePi PC 2 initial support")
>> Signed-off-by: Icenowy Zheng <icen...@aosc.io>
>
> Reviewed-by: Jagan Teki <ja...@openedev.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCHv6 00/28] Retrieve MAC address from EEPROM

2017-08-11 Thread Jagan Teki
On Mon, May 15, 2017 at 6:17 PM, Tom Rini <tr...@konsulko.com> wrote:
> On Mon, May 15, 2017 at 10:09:02AM +0200, Olliver Schinagl wrote:
>> Hey all,
>>
>> On 15-05-17 10:02, Olliver Schinagl wrote:
>> >This patch-series introduces methods to retrieve the MAC address from an
>> >onboard EEPROM. The series does a few small cleanups at the start, as either
>> >I ran into them while doing this series and fixed them along the way or
>> >actually depended on them.
>> >
>> >A manufacturer wants to produce boards and may even have MAC addresses for
>> >boards. Maintaining unique environments on a per-board basis however is
>> >horrible. Also this data should be very persistent, and not easily deletable
>> >by simply wiping the environment or device tree. Finally there are
>> >chips available on the market with a pre-programmed MAC address chips
>> >(proms)
>> >that a board manufacturer wants to use. Because of this, the MAC needs to be
>> >stored be able to read from such an 'external' source.
>> >
>> >The current idea of the eeprom layout, is to skip the first 8 bytes, so that
>> >other information can be stored there if needed, for example a header
>> >with some magic to identify the EEPROM. Or equivalent purposes.
>> >
>> >After those 8 bytes the MAC address follows the first macaddress. The
>> >macaddress is appended by a CRC8 byte and then padded to make for nice 8 
>> >bytes.
>> >Following the first macaddress one can store a second, or a third etc etc
>> >macaddress.
>> >
>> >The CRC8 is optional (via a define) but is strongly recommended to have. It
>> >helps preventing user error and more importantly, checks if the bytes
>> >read are actually a user inserted address. E.g. only writing 1 macaddress 
>> >into
>> >the eeprom but trying to consume 2.
>> >
>> >These patches where tested on Olimex OLinuXino Lime1 (A10/A20), Lime2 (NAND
>> >and eMMC) and A20-OLinuXino-MICRO-4G variants and have been in use
>> >internally on our production systems since v2 of this patch set.
>> >
>> >TODO in a follow up series:
>> >* Replace the I2C specific read function to a generic function using
>> >Maxime Ripard's EEPROM uclass once merged.
>> >* Upgrade to use the EERPOM layout functionality as suggested by Igor 
>> >Grinberg
>> >* Add EEPROM/Mac commands suggested by York Sun
>> >
>> >The series was initially based ontop of Joe's u-boot_net/next branches, but 
>> >I
>> >rebased it ontop of u-boot/master to get the latest sunxi changes, 
>> >including:
>> >sun7i: Add support for Olimex A20-OLinuXino-LIME2-eMMC
>> >ARM: dts: sunxi: Change node name for pwrseq pin on Olinuxino-lime2-emmc
>> >
>> >Which are on their way to being merged in master. So once those land into 
>> >master
>> >this all should apply cleanly. Sorry Joe!
>>
>> So I accidentally added those too to this patch series as well
>> (first two patches). Which are technically not part of this series
>> and are on their way as it is. Does patchwork figure out this
>> automatically, or do you prefer a resend with the 2 patches removed?
>
> I've made patchwork reflect things correctly.

Few of the patches need re-work, so updated patchwork status as
"Changes Requested" for the series.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v4 00/26] sunxi: Allwinner A64: SPL support

2017-08-11 Thread Jagan Teki
On Wed, Jan 4, 2017 at 9:20 PM, Jagan Teki <ja...@openedev.com> wrote:
> On Mon, Jan 2, 2017 at 12:48 PM, Andre Przywara <andre.przyw...@arm.com> 
> wrote:
>> Hi,
>>
>> hopefully the final version of the SPL support series for the Allwinner A64
>> SoC. Actually no real code changes this time, just rebased on top of recent
>> master, adding some comments in patches 16/26 and 19/26 following Maxime's
>> suggestions and adding Acked-by:s and Reviewed-by:s.
>> I left the final patch 26/26 in for the sake of completeness, but don't 
>> expect
>> it to be merged. We need a clever solution to unify 32-bit and 64-bit board
>> configurations, but that shouldn't hold back this series for now.
>> Merging everything until and including patch 21/26 (sunxi: A64: enable SPL)
>> would be great, the other patches until 25/26 can go in as well, I think.
>>
>> -
>> As the previous versions this one includes support for both AArch64 and
>> AArch32 SPL builds. The FIT support is still missing, which means the
>> functionality is limited. Due to the missing ARM Trusted Firmware (ATF)
>> in this firmware chain we lose Ethernet and SMP, among other minor things.
>> A full 64-bit build can be written to an SD card as expected and will
>> boot the U-Boot proper prompt. However Linux will crash on boot, as
>> PSCI is missing.
>> Building the 32-bit version of the SPL and combining this with an ATF
>> build and the 64-bit U-Boot proper allows to use FEL booting now:
>> # sunxi-fel spl sunxi-spl.bin write 0x4a00 u-boot-dtb.bin \
>>   write 0x44000 bl31.bin reset64 0x44000
>> This way of booting the board gives full functionality.
>>
>> The first patch is a rather simple fix (with no changes to v2).
>> Patches 2-8 prepare the SPL code to be compiled for 64-bit in general and
>> AArch64 in particular.
>> Patches 9-11 refactor the existing boot0 header functionality to be used
>> by patch 12, which introduces the 64-bit switch in the first SPL
>> instructions.
>> Patches 13-20 then introduce the actual core of the SPL support: the DRAM
>> initialization, courtesy of Jens. This piggy backs on the existing
>> H3 DRAM code, deviating where needed. This has been reworked compared to
>> v2: I added a patch from Philipp to replace the rather uninspired
>> register writes in the MBUS priority setup function with some meaningful
>> code, explaining the various bits. Also the actual A64 DRAM code is no
>> longer #ifdef'ed into the H3 driver, but uses parameters to (static)
>> functions. The compiler detects this and removes the dead code from
>> the other variant, resulting in the same binary size for the H3.
>>
>> Patch 21 finally enables the 64-bit SPL support. So now building the
>> existing pine64_plus_defconfig will generate a sunxi-spl.bin, which
>> can be prepended to the U-Boot proper image (not .bin) to boot from
>> an SD card. Due to the missing ATF support this is of limited usability
>> at the moment, though. Also FEL support requires more love - to switch
>> back to AArch32 before returning to FEL (without crashing, that is ;-),
>> so this is disabled.
>> On my setup this results in a 26KB SPL binary, which is close to the
>> 28K limit mksunxiboot imposes at the moment. Adding anything (like
>> FIT support or DEBUG) will exceed this, and although I have patches
>> to let mksunxiboot get close to 32KB, this is the ulimate frontier.
>>
>> So patches 22-25 then teach the SPL how to detect an U-Boot image file
>> of a different bitness and do the RMR switch from AArch32 to AArch64,
>> if needed.
>> This is used by the final patch 26, which creates another _defconfig
>> to let the SPL compile for AArch32 using the Thumb2 encoding. This
>> results in a binary of less than 17KB in my case, so has plenty of
>> room for extensions.
>>
>> Cheers,
>> Andre.
>>
>> Changelog v3 .. v4:
>> - rebased on top of latest HEAD
>> - add various Reviewed-by: and Acked-by: tags
>> - add comments about register bit meanings in non-ODT-setting fix
>> - clarify meaning of delay values in single bit delay support patch
>> - removing stray semicolons from boot0.h header
>>
>> Changelog v2 .. v3:
>> - add various Reviewed-by: and Acked-by: tags
>> - split tiny-printf fix to handle "-" separately
>> - add various comments and extend commit messages
>> - add assembly file to re-create the embedded RMR switch code
>> - add patch 14/26 to explain the MBUS priority setup
>> - move DRAM r/w delay values into #defines to simplify re-usablity
>> -

[linux-sunxi] [PATCH v4] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-08-11 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v4:
- Rebased and droped wi-fi related nodes, since it require 
  other changes to taken care.
Changes for v3:
- Fix to use mmc1 for SDIO instead of mmc2
- Replace buswidth by 4 instead of 8 mmc1
- Drop cap-mmc-hw-reset for mmc1
Changes for v2:
- Added ohci0, ehci0, ohic1, ehci1, usbphy.
- Tested on A64

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 114 +
 2 files changed, 115 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index 108f12c..c997b5c 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,4 +1,5 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..e4c121a
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,114 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HI

[linux-sunxi] [PATCH 2/3] arm64: defconfig: Enable CONFIG_MFD_AXP20X_RSB

2017-08-11 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

X-Powers AXP series PMICs with RSB is need for sunxi a64
so make it default in defconfig.

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 arch/arm64/configs/defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index 33d2d62..a11fce7 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -313,6 +313,7 @@ CONFIG_MESON_GXBB_WATCHDOG=m
 CONFIG_MESON_WATCHDOG=m
 CONFIG_RENESAS_WDT=y
 CONFIG_BCM2835_WDT=y
+CONFIG_MFD_AXP20X_RSB=y
 CONFIG_MFD_CROS_EC=y
 CONFIG_MFD_CROS_EC_I2C=y
 CONFIG_MFD_CROS_EC_SPI=y
-- 
2.7.4

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH 1/3] bus: kconfig: Enable SUNXI RSB for arm64

2017-08-11 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Sunxi arm64 doesn't have separate configs for
h5 and a64 so enable SUNXI_RSB bus for ARM64.

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 drivers/bus/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/bus/Kconfig b/drivers/bus/Kconfig
index 2408ea3..ae3d8f3 100644
--- a/drivers/bus/Kconfig
+++ b/drivers/bus/Kconfig
@@ -132,7 +132,7 @@ config SIMPLE_PM_BUS
 
 config SUNXI_RSB
tristate "Allwinner sunXi Reduced Serial Bus Driver"
- default MACH_SUN8I || MACH_SUN9I
+ default MACH_SUN8I || MACH_SUN9I || ARM64
  depends on ARCH_SUNXI
  select REGMAP
  help
-- 
2.7.4

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH 3/3] arm64: defconfig: Enable CONFIG_REGULATOR_AXP20X

2017-08-11 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

X-POWERS AXP20X PMIC Regulators is need for sunxi a64
so make it default in defconfig.

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 arch/arm64/configs/defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index a11fce7..d8f23c5 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -323,6 +323,7 @@ CONFIG_MFD_MAX77620=y
 CONFIG_MFD_SPMI_PMIC=y
 CONFIG_MFD_RK808=y
 CONFIG_MFD_SEC_CORE=y
+CONFIG_REGULATOR_AXP20X=y
 CONFIG_REGULATOR_FAN53555=y
 CONFIG_REGULATOR_FIXED_VOLTAGE=y
 CONFIG_REGULATOR_GPIO=y
-- 
2.7.4

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH] arm64: allwinner: a64: pine64: Use dcdc1 regulator for mmc0

2017-08-11 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Since current tree support AXP803 regulators, replace
fixed regulator with AXP803 dcdc1 regulator.

Tested on pine64.

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts | 9 +
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
index 122b5d8..604cdae 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
@@ -62,13 +62,6 @@
chosen {
stdout-path = "serial0:115200n8";
};
-
-   reg_vcc3v3: vcc3v3 {
-   compatible = "regulator-fixed";
-   regulator-name = "vcc3v3";
-   regulator-min-microvolt = <330>;
-   regulator-max-microvolt = <330>;
-   };
 };
 
  {
@@ -109,7 +102,7 @@
  {
pinctrl-names = "default";
pinctrl-0 = <_pins>;
-   vmmc-supply = <_vcc3v3>;
+   vmmc-supply = <_dcdc1>;
cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
cd-inverted;
disable-wp;
-- 
2.7.4

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v5] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-08-11 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v5:
- Add AXP803 PMIC regulator support. 
Changes for v4:
- Rebased and droped wi-fi related nodes, since it require
  other changes to taken care.
Changes for v3:
- Fix to use mmc1 for SDIO instead of mmc2
- Replace buswidth by 4 instead of 8 mmc1
- Drop cap-mmc-hw-reset for mmc1
Changes for v2:
- Added ohci0, ehci0, ohic1, ehci1, usbphy.
- Tested on A64

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 205 +
 2 files changed, 206 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index 108f12c..c997b5c 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,4 +1,5 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..de98da1
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,205 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_dcdc1>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "ok

Re: [linux-sunxi] [PATCH v4] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-08-11 Thread Jagan Teki
On Fri, Aug 11, 2017 at 6:04 PM, Icenowy Zheng <icen...@aosc.io> wrote:
>
>
> 于 2017年8月11日 GMT+08:00 下午8:31:43, Jagan Teki <jagannadh.t...@gmail.com> 写到:
>>From: Jagan Teki <ja...@amarulasolutions.com>
>>
>>NanoPi A64 is a new board of high performance with low cost
>>designed by FriendlyElec., using the Allwinner A64 SOC.
>
> As AXP803 regulators support now entered linux-next, please
> add proper AXP803 support when supporting new boards.

OK, but how do I need to verify it? I've booted pine64 but unable to verify it.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v2] arm64: allwinner: a64: Add A64-OLinuXino initial support

2017-08-12 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

OLimex A64-OLinuXino is an open-source hardware board
using the Allwinner A64 SOC.

OLimex A64-OLinuXino has
- A64 Quad-core Cortex-A53 64bit
- 1GB or 2GB RAM DDR3L @ 672Mhz
- microSD slot and 4/8/16GB eMMC
- Debug TTL UART
- HDMI
- LCD
- IR receiver
- 5V DC power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Tested on board
- Added AXP803 regulator 

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-olinuxino.dts| 221 +
 2 files changed, 222 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index c997b5c..19c3fbd 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,5 +1,6 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-olinuxino.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
new file mode 100644
index 000..0b9e742
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
@@ -0,0 +1,221 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "Olimex A64-Olinuxino";
+   compatible = "olimex,a64-olinuxino", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc1v8: vcc1v8 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc1v8";
+   regulator-min-microvolt = <180>;
+   regulator-max-microvolt = <180>;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_dcdc1>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+_rsb {
+   status = "okay";
+
+   axp803: pmic@3a3 {
+   compatible = "x-powers,axp803";
+   reg = <0x3a3>;
+   interrupt-parent = <_intc>;
+   interrupts = <0 IRQ_TYPE_LEVEL_LOW>

[linux-sunxi] [PATCH v3] arm64: allwinner: a64: Add A64-OLinuXino initial support

2017-08-14 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

OLimex A64-OLinuXino is an open-source hardware board
using the Allwinner A64 SOC.

OLimex A64-OLinuXino has
- A64 Quad-core Cortex-A53 64bit
- 1GB or 2GB RAM DDR3L @ 672Mhz
- microSD slot and 4/8/16GB eMMC
- Debug TTL UART
- HDMI
- LCD
- IR receiver
- 5V DC power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Droped i2c1, not found on schmatic
- Updated vddfb-cpux regulator volt range 1.04 ~ 1.3 V
- Removed poly-phased DCDC3 regulator node and added comment
- Update DLDO4 regulator name as vcc-wifi-io
- Moved uart0 below regulators
Changes for v2:
- Tested on board
- Added AXP803 regulator

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-olinuxino.dts| 199 +
 2 files changed, 200 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index c997b5c..19c3fbd 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,5 +1,6 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-olinuxino.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
new file mode 100644
index 000..b86ac1a
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
@@ -0,0 +1,199 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "Olimex A64-Olinuxino";
+   compatible = "olimex,a64-olinuxino", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_dcdc1>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+_rsb {
+   status = "okay";
+
+   axp803: pmic@3a3 {
+   compatible = "x-powers,axp803";
+   reg = <0x3a3>;
+   interrupt-parent = <_intc>;
+   interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
+   };
+};
+
+#include "axp803.dtsi"
+
+_aldo1 {
+   regulator-always-on;
+   regulator-min-microvolt = <280>;
+   regulator-max-microvolt = <280>;
+   re

[linux-sunxi] [PATCH v6] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-08-14 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v6:
- Moved uart0 below regulators
- Add comment for i2c1
- Update vdd-cpux volt range 1.04 ~ 1.3 V
- ehci0 detection https://paste.ubuntu.com/25311593/
- Remove space before usbphy
- Removed unused DLD02
- Add comment for DLD01 regulator-name to vcc-dsi since
  it's connected along with vcc-hdmi
- Add regulator node for DLD04 for vcc-pg
Changes for v5:
- Add AXP803 PMIC regulator support.
Changes for v4:
- Rebased and droped wi-fi related nodes, since it require
  other changes to taken care.
Changes for v3:
- Fix to use mmc1 for SDIO instead of mmc2
- Replace buswidth by 4 instead of 8 mmc1
- Drop cap-mmc-hw-reset for mmc1
Changes for v2:
- Added ohci0, ehci0, ohic1, ehci1, usbphy.
- Tested on A64

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 209 +
 2 files changed, 210 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index 108f12c..c997b5c 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,4 +1,5 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..c2bbc75
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,209 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+/* i2c1 connected with gpio headers like pine64, bananapi */
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+

Re: [linux-sunxi] [PATCH v2] arm64: allwinner: a64: Add A64-OLinuXino initial support

2017-08-14 Thread Jagan Teki
On Mon, Aug 14, 2017 at 1:26 PM, Chen-Yu Tsai <w...@csie.org> wrote:
> On Mon, Aug 14, 2017 at 3:34 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
>> On Mon, Aug 14, 2017 at 12:38 PM, Chen-Yu Tsai <w...@csie.org> wrote:
>>> Hi,
>>>
>>> On Sun, Aug 13, 2017 at 1:54 AM, Jagan Teki <jagannadh.t...@gmail.com> 
>>> wrote:
>>>> From: Jagan Teki <ja...@amarulasolutions.com>
>>>>
>>>> OLimex A64-OLinuXino is an open-source hardware board
>>>> using the Allwinner A64 SOC.
>>>>
>>>> OLimex A64-OLinuXino has
>>>> - A64 Quad-core Cortex-A53 64bit
>>>> - 1GB or 2GB RAM DDR3L @ 672Mhz
>>>> - microSD slot and 4/8/16GB eMMC
>>>> - Debug TTL UART
>>>> - HDMI
>>>> - LCD
>>>> - IR receiver
>>>> - 5V DC power supply
>>>
>>> Have you tried out Ethernet?
>>
>> Not, tested yet. Will send separate patch.
>
> OK.
>
> [...]
>
>>>> +
>>>> +_aldo2 {
>>>> +   regulator-always-on;
>>>> +   regulator-min-microvolt = <330>;
>>>> +   regulator-max-microvolt = <330>;
>>>
>>> Schematic says 1.8V?
>>
>> I saw ALD02 VCC-PL=3.3v on schematic.
>
> Ah. I see they changed it in a rev. B. Lets use 3.3V then.
>
>>>
>>>> +   regulator-name = "vcc-pl";
>>>> +};
>>>> +
>>>> +_aldo3 {
>>>> +   regulator-always-on;
>>>> +   regulator-min-microvolt = <300>;
>>>> +   regulator-max-microvolt = <300>;
>>>> +   regulator-name = "vcc-pll-avcc";
>>>> +};
>>>> +
>>>> +_dcdc1 {
>>>> +   regulator-always-on;
>>>> +   regulator-min-microvolt = <330>;
>>>> +   regulator-max-microvolt = <330>;
>>>> +   regulator-name = "vcc-3v3";
>>>> +};
>>>> +
>>>> +_dcdc2 {
>>>> +   regulator-always-on;
>>>> +   regulator-min-microvolt = <110>;
>>>> +   regulator-max-microvolt = <110>;
>>>
>>> The SoC has a wider range than a fixed voltage for the CPUs.
>>
>> So, max 1.1v can't enough CPUs? thought similar behavior with pine64?
>
> The recommended operating conditions says 1.04 ~ 1.3 V for CPUx,
> while the typical voltage is 1.1V. The regulator constraints should
> match the datasheet, especially for power rails that are involved in
> DVFS.

power rails from datasheet[1] shows 0.5v ~ 1.3v am I not looking
updated details?

[1] http://files.pine64.org/doc/datasheet/pine64/AXP803_Datasheet_V1.0.pdf

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [linux-sunxi] [PATCH v2] arm64: allwinner: a64: Add A64-OLinuXino initial support

2017-08-14 Thread Jagan Teki
On Mon, Aug 14, 2017 at 12:38 PM, Chen-Yu Tsai <w...@csie.org> wrote:
> Hi,
>
> On Sun, Aug 13, 2017 at 1:54 AM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> OLimex A64-OLinuXino is an open-source hardware board
>> using the Allwinner A64 SOC.
>>
>> OLimex A64-OLinuXino has
>> - A64 Quad-core Cortex-A53 64bit
>> - 1GB or 2GB RAM DDR3L @ 672Mhz
>> - microSD slot and 4/8/16GB eMMC
>> - Debug TTL UART
>> - HDMI
>> - LCD
>> - IR receiver
>> - 5V DC power supply
>
> Have you tried out Ethernet?

Not, tested yet. Will send separate patch.

>
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>> ---
>> Changes for v2:
>> - Tested on board
>> - Added AXP803 regulator
>>
>>  arch/arm64/boot/dts/allwinner/Makefile |   1 +
>>  .../boot/dts/allwinner/sun50i-a64-olinuxino.dts| 221 
>> +
>>  2 files changed, 222 insertions(+)
>>  create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
>>
>> diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
>> b/arch/arm64/boot/dts/allwinner/Makefile
>> index c997b5c..19c3fbd 100644
>> --- a/arch/arm64/boot/dts/allwinner/Makefile
>> +++ b/arch/arm64/boot/dts/allwinner/Makefile
>> @@ -1,5 +1,6 @@
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
>> +dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-olinuxino.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
>> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts 
>> b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
>> new file mode 100644
>> index 000..0b9e742
>> --- /dev/null
>> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
>> @@ -0,0 +1,221 @@
>> +/*
>> + * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
>> + *
>> + * This file is dual-licensed: you can use it either under the terms
>> + * of the GPL or the X11 license, at your option. Note that this dual
>> + * licensing only applies to this file, and not this project as a
>> + * whole.
>> + *
>> + *  a) This library is free software; you can redistribute it and/or
>> + * modify it under the terms of the GNU General Public License as
>> + * published by the Free Software Foundation; either version 2 of the
>> + * License, or (at your option) any later version.
>> + *
>> + * This library is distributed in the hope that it will be useful,
>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>> + * GNU General Public License for more details.
>> + *
>> + * Or, alternatively,
>> + *
>> + *  b) Permission is hereby granted, free of charge, to any person
>> + * obtaining a copy of this software and associated documentation
>> + * files (the "Software"), to deal in the Software without
>> + * restriction, including without limitation the rights to use,
>> + * copy, modify, merge, publish, distribute, sublicense, and/or
>> + * sell copies of the Software, and to permit persons to whom the
>> + * Software is furnished to do so, subject to the following
>> + * conditions:
>> + *
>> + * The above copyright notice and this permission notice shall be
>> + * included in all copies or substantial portions of the Software.
>> + *
>> + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
>> + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
>> + * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
>> + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
>> + * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
>> + * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
>> + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
>> + * OTHER DEALINGS IN THE SOFTWARE.
>> + */
>> +
>> +/dts-v1/;
>> +
>> +#include "sun50i-a64.dtsi"
>> +
>> +#include 
>> +
>> +/ {
>> +   model = "Olimex A64-Olinuxino";
>> +   compatible = "olimex,a64-olinuxino", "allwinner,sun50i-a64";
>> +
>> +   

[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: defaultly enable SPL for Lichee Pi Zero

2017-08-14 Thread Jagan Teki
On Mon, Aug 14, 2017 at 8:30 PM, Icenowy Zheng <icen...@aosc.io> wrote:
> As we have already DRAM initialization code for V3s SoC, we can
> defaultly enable SPL now on Lichee Pi Zero.
>
> Add CONFIG_SPL in Lichee Pi Zero defconfig.
>
> Signed-off-by: Icenowy Zheng <icen...@aosc.io>

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v2 1/3] board: Add Bananapi M64 support

2017-07-15 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for bananapi M64 board with below features:
- U-Boot 2017.07
- Linux 4.11.5
- Default packages from buildroot

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Update .gitlab-ci.yml
- Remove board/bananapi/post-build.sh
- Add BR2_TARGET_UBOOT_BOOT_SCRIPT
- Update firmware custom version as commit hash instead of branch
- Add HOST_DOSFSTOOLS and HOST_MTOOLS

 .gitlab-ci.yml   |  1 +
 DEVELOPERS   |  2 ++
 board/bananapi/bananapi-m64/boot.cmd |  6 +
 board/bananapi/bananapi-m64/genimage.cfg | 38 ++
 board/bananapi/bananapi-m64/readme.txt   | 34 +++
 configs/bananapi_m64_defconfig   | 46 
 6 files changed, 127 insertions(+)
 create mode 100644 board/bananapi/bananapi-m64/boot.cmd
 create mode 100644 board/bananapi/bananapi-m64/genimage.cfg
 create mode 100644 board/bananapi/bananapi-m64/readme.txt
 create mode 100644 configs/bananapi_m64_defconfig

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4e494ff..fb741c9 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -83,6 +83,7 @@ atmel_sama5d4_xplained_defconfig: *defconfig
 atmel_sama5d4_xplained_dev_defconfig: *defconfig
 atmel_sama5d4_xplained_mmc_defconfig: *defconfig
 atmel_sama5d4_xplained_mmc_dev_defconfig: *defconfig
+bananapi_m64_defconfig: *defconfig
 bananapro_defconfig: *defconfig
 beagleboardx15_defconfig: *defconfig
 beaglebone_defconfig: *defconfig
diff --git a/DEVELOPERS b/DEVELOPERS
index f392838..e528aef 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -858,7 +858,9 @@ N:  Ilias Apalodimas <apa...@gmail.com>
 F: package/keepalived/
 
 N: Jagan Teki <ja...@amarulasolutions.com>
+F: board/bananapi/
 F: board/engicam/
+F: configs/bananapi_m64_defconfig
 F: configs/engicam_imx6qdl_icore_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_defconfig
 F: configs/engicam_imx6ul_geam_defconfig
diff --git a/board/bananapi/bananapi-m64/boot.cmd 
b/board/bananapi/bananapi-m64/boot.cmd
new file mode 100644
index 000..d35c9b0
--- /dev/null
+++ b/board/bananapi/bananapi-m64/boot.cmd
@@ -0,0 +1,6 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+fatload mmc 0 $kernel_addr_r Image
+fatload mmc 0 $fdt_addr_r sun50i-a64-bananapi-m64.dtb
+
+booti $kernel_addr_r - $fdt_addr_r
diff --git a/board/bananapi/bananapi-m64/genimage.cfg 
b/board/bananapi/bananapi-m64/genimage.cfg
new file mode 100644
index 000..891217c
--- /dev/null
+++ b/board/bananapi/bananapi-m64/genimage.cfg
@@ -0,0 +1,38 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "Image",
+   "sun50i-a64-bananapi-m64.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition spl {
+   in-partition-table = "no"
+   image = "sunxi-spl.bin"
+   offset = 8192
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot.itb"
+   offset = 40K
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/bananapi/bananapi-m64/readme.txt 
b/board/bananapi/bananapi-m64/readme.txt
new file mode 100644
index 000..389ffbe
--- /dev/null
+++ b/board/bananapi/bananapi-m64/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Bananapi M64. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Bananapi M64 link:
+http://www.banana-pi.org/m64.html
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make bananapi_m64_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Bananapi M64 and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/configs/bananapi_m64_defconfig b/configs/bananapi_m64_defconfig
new file mode 100644
index 000..6f22b23
--- /dev/null
++

[linux-sunxi] [PATCH v2 2/3] board: Add Bananapi M1 support

2017-07-15 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for bananapi M1 board with below features:
- U-Boot 2017.07
- Linux 4.11.5
- Default packages from buildroot

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Newly added patch

 .gitlab-ci.yml  |  1 +
 DEVELOPERS  |  1 +
 board/bananapi/bananapi-m1/boot.cmd |  7 +++
 board/bananapi/bananapi-m1/genimage.cfg | 33 +
 board/bananapi/bananapi-m1/readme.txt   | 34 ++
 configs/bananapi_m1_defconfig   | 37 +
 6 files changed, 113 insertions(+)
 create mode 100644 board/bananapi/bananapi-m1/boot.cmd
 create mode 100644 board/bananapi/bananapi-m1/genimage.cfg
 create mode 100644 board/bananapi/bananapi-m1/readme.txt
 create mode 100644 configs/bananapi_m1_defconfig

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index fb741c9..88034bc 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -83,6 +83,7 @@ atmel_sama5d4_xplained_defconfig: *defconfig
 atmel_sama5d4_xplained_dev_defconfig: *defconfig
 atmel_sama5d4_xplained_mmc_defconfig: *defconfig
 atmel_sama5d4_xplained_mmc_dev_defconfig: *defconfig
+bananapi_m1_defconfig: *defconfig
 bananapi_m64_defconfig: *defconfig
 bananapro_defconfig: *defconfig
 beagleboardx15_defconfig: *defconfig
diff --git a/DEVELOPERS b/DEVELOPERS
index e528aef..9c18990 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -860,6 +860,7 @@ F:  package/keepalived/
 N:     Jagan Teki <ja...@amarulasolutions.com>
 F: board/bananapi/
 F: board/engicam/
+F: configs/bananapi_m1_defconfig
 F: configs/bananapi_m64_defconfig
 F: configs/engicam_imx6qdl_icore_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_defconfig
diff --git a/board/bananapi/bananapi-m1/boot.cmd 
b/board/bananapi/bananapi-m1/boot.cmd
new file mode 100644
index 000..fb7de1d
--- /dev/null
+++ b/board/bananapi/bananapi-m1/boot.cmd
@@ -0,0 +1,7 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+mmc dev 0
+fatload mmc 0 $kernel_addr_r zImage
+fatload mmc 0 $fdt_addr_r sun7i-a20-bananapi.dts
+
+bootz $kernel_addr_r - $fdt_addr_r
diff --git a/board/bananapi/bananapi-m1/genimage.cfg 
b/board/bananapi/bananapi-m1/genimage.cfg
new file mode 100644
index 000..e2e1311
--- /dev/null
+++ b/board/bananapi/bananapi-m1/genimage.cfg
@@ -0,0 +1,33 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "zImage",
+   "sun7i-a20-bananapi.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot-sunxi-with-spl.bin"
+   offset = 8192
+   size = 1040384 # 1MB - 8192
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/bananapi/bananapi-m1/readme.txt 
b/board/bananapi/bananapi-m1/readme.txt
new file mode 100644
index 000..d266dfb
--- /dev/null
+++ b/board/bananapi/bananapi-m1/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Bananapi M1. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Bananapi M1 link:
+http://www.banana-pi.org/m1.html
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make bananapi_m1_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Bananapi M1 and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/configs/bananapi_m1_defconfig b/configs/bananapi_m1_defconfig
new file mode 100644
index 000..5c90492
--- /dev/null
+++ b/configs/bananapi_m1_defconfig
@@ -0,0 +1,37 @@
+BR2_arm=y
+BR2_cortex_a7=y
+BR2_ARM_EABIHF=y
+
+# Linux headers same as kernel, a 4.11 series
+BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_11=y
+
+# Bootloader
+BR2_TARGET_UBOOT=y
+BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
+BR2_TARGET_UBOOT_CUSTOM_VERSION=y
+BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2017.07"
+BR2_TARGET_UBOOT_BOARD_DE

[linux-sunxi] [PATCH v2 3/3] board: Add Bananapi M2 Plus support

2017-07-15 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for bananapi M2 Plus board with below features:
- U-Boot 2017.07
- Linux 4.11.5
- Default packages from buildroot

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Update .gitlab-ci.yml
- Remove board/bananapi/post-build.sh
- Add BR2_TARGET_UBOOT_BOOT_SCRIPT
- Add HOST_DOSFSTOOLS and HOST_MTOOLS

 .gitlab-ci.yml   |  1 +
 DEVELOPERS   |  1 +
 board/bananapi/bananapi-m2-plus/boot.cmd |  7 ++
 board/bananapi/bananapi-m2-plus/genimage.cfg | 33 +
 board/bananapi/bananapi-m2-plus/readme.txt   | 34 +
 configs/bananapi_m2_plus_defconfig   | 37 
 6 files changed, 113 insertions(+)
 create mode 100644 board/bananapi/bananapi-m2-plus/boot.cmd
 create mode 100644 board/bananapi/bananapi-m2-plus/genimage.cfg
 create mode 100644 board/bananapi/bananapi-m2-plus/readme.txt
 create mode 100644 configs/bananapi_m2_plus_defconfig

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 88034bc..658dd34 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -84,6 +84,7 @@ atmel_sama5d4_xplained_dev_defconfig: *defconfig
 atmel_sama5d4_xplained_mmc_defconfig: *defconfig
 atmel_sama5d4_xplained_mmc_dev_defconfig: *defconfig
 bananapi_m1_defconfig: *defconfig
+bananapi_m2_plus_defconfig: *defconfig
 bananapi_m64_defconfig: *defconfig
 bananapro_defconfig: *defconfig
 beagleboardx15_defconfig: *defconfig
diff --git a/DEVELOPERS b/DEVELOPERS
index 9c18990..a5335f6 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -861,6 +861,7 @@ N:  Jagan Teki <ja...@amarulasolutions.com>
 F: board/bananapi/
 F: board/engicam/
 F: configs/bananapi_m1_defconfig
+F: configs/bananapi_m2_plus_defconfig
 F: configs/bananapi_m64_defconfig
 F: configs/engicam_imx6qdl_icore_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_defconfig
diff --git a/board/bananapi/bananapi-m2-plus/boot.cmd 
b/board/bananapi/bananapi-m2-plus/boot.cmd
new file mode 100644
index 000..d22464a
--- /dev/null
+++ b/board/bananapi/bananapi-m2-plus/boot.cmd
@@ -0,0 +1,7 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+mmc dev 0
+fatload mmc 0 $kernel_addr_r zImage
+fatload mmc 0 $fdt_addr_r sun8i-h3-bananapi-m2-plus.dtb
+
+bootz $kernel_addr_r - $fdt_addr_r
diff --git a/board/bananapi/bananapi-m2-plus/genimage.cfg 
b/board/bananapi/bananapi-m2-plus/genimage.cfg
new file mode 100644
index 000..cde0669
--- /dev/null
+++ b/board/bananapi/bananapi-m2-plus/genimage.cfg
@@ -0,0 +1,33 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "zImage",
+   "sun8i-h3-bananapi-m2-plus.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot-sunxi-with-spl.bin"
+   offset = 8192
+   size = 1040384 # 1MB - 8192
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/bananapi/bananapi-m2-plus/readme.txt 
b/board/bananapi/bananapi-m2-plus/readme.txt
new file mode 100644
index 000..f699727
--- /dev/null
+++ b/board/bananapi/bananapi-m2-plus/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Bananapi M2 Plus. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Bananapi M2 Plus link:
+http://www.banana-pi.org/m2plus.html
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make bananapi_m2_plus_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Bananapi M2 Plus and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/configs/bananapi_m2_plus_defconfig 
b/configs/bananapi_m2_plus_defconfig
new file mode 100644
index 000..ef08a68
--- /dev/null
+++ b/configs/bananapi_m2_plus_defconfig
@@ -0,0 +1,37 @@
+BR2_arm=y
+BR2_cortex_a7=y
+BR2_ARM_EABIHF=y
+

[linux-sunxi] Re: [U-Boot] [PATCHv4 0/2] ARM: sunxi: Add support for OLinuXino Lime2 eMMC

2017-08-07 Thread Jagan Teki
On Fri, May 12, 2017 at 10:22 PM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Fri, May 12, 2017 at 11:38:52AM +0200, Olliver Schinagl wrote:
>> This patch series adds support for the Olimex OLinuXino Lime2 eMMC. This
>> assembly variant uses eMMC flash instead of NAND (or no flash) on the other
>> Lime2's. Additionally, we sync the dts with upstream as we now use this dts
>> from the new defconfig.
>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH] sun7i: Add support for Olimex A20-OLinuXino-LIME2-eMMC

2017-05-03 Thread Jagan Teki
On Wed, May 3, 2017 at 5:48 PM, Olliver Schinagl <oli...@schinagl.nl> wrote:
> This patch adds support for the Olimex OLinuXino Lime2 with eMMC flash
> storage.
> https://www.olimex.com/Products/OLinuXino/A20/A20-OLinuXino-LIME2-eMMC/
>
> It is a assembly variant of the regular Lime2 but featuring eMMC for
> storage.
>
> Signed-off-by: Olliver Schinagl <oli...@schinagl.nl>
> ---
>
> Note: for the board to work properly, the updated eMMC dts variant needs to
> be updated from upstream.
>
>  board/sunxi/MAINTAINERS|  5 +
>  configs/A20-OLinuXino-Lime2-eMMC_defconfig | 33 
> ++
>  2 files changed, 38 insertions(+)
>  create mode 100644 configs/A20-OLinuXino-Lime2-eMMC_defconfig
>
> diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
> index 2321b8b08f..84f91fd10b 100644
> --- a/board/sunxi/MAINTAINERS
> +++ b/board/sunxi/MAINTAINERS
> @@ -89,6 +89,11 @@ M:   Iain Paton <ipat...@gmail.com>
>  S: Maintained
>  F: configs/A20-OLinuXino-Lime2_defconfig
>
> +A20-OLINUXINO-LIME2-EMMC BOARD
> +M: Olliver Schinagl <oli...@schinagl.nl>
> +S: Maintained
> +F: configs/A20-OLinuXino-Lime2-eMMC_defconfig
> +
>  A33-OLINUXINO BOARD
>  M: Stefan Mavrodiev <stefan.mavrod...@gmail.com>
>  S: Maintained
> diff --git a/configs/A20-OLinuXino-Lime2-eMMC_defconfig 
> b/configs/A20-OLinuXino-Lime2-eMMC_defconfig
> new file mode 100644
> index 00..1369d2d90b
> --- /dev/null
> +++ b/configs/A20-OLinuXino-Lime2-eMMC_defconfig
> @@ -0,0 +1,33 @@
> +CONFIG_ARM=y
> +CONFIG_ARCH_SUNXI=y
> +CONFIG_MACH_SUN7I=y
> +CONFIG_DRAM_CLK=384
> +CONFIG_MMC0_CD_PIN="PH1"
> +CONFIG_MMC_SUNXI_SLOT_EXTRA=2
> +CONFIG_USB0_VBUS_PIN="PC17"
> +CONFIG_USB0_VBUS_DET="PH5"
> +CONFIG_DEFAULT_DEVICE_TREE="sun7i-a20-olinuxino-lime2-emmc"
> +CONFIG_AHCI=y
> +# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
> +CONFIG_SYS_EXTRA_OPTIONS="SUNXI_GMAC,RGMII,SATAPWR=SUNXI_GPC(3)"
> +CONFIG_SPL=y

These were moved to Kconfig, please sync with latest.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: add support for Banana Pi M2 Plus board

2017-05-03 Thread Jagan Teki
On Wed, May 3, 2017 at 9:15 PM, Icenowy Zheng <icen...@aosc.io> wrote:
> Banana Pi M2 Plus is an Allwinner H3-based SBC by Sinovoip, which has
> already mainline device tree file that have landed into U-Boot source
> tree.
>
> Add a defconfig file for it and add the MAINTAINERS items.
>
> Signed-off-by: Icenowy Zheng <icen...@aosc.io>

Reviewed-by: Jagan Teki <ja...@openedev.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH] sun7i: Add support for Olimex A20-OLinuXino-LIME2-eMMC

2017-05-03 Thread Jagan Teki

On Wednesday 03 May 2017 05:48 PM, Olliver Schinagl wrote:

This patch adds support for the Olimex OLinuXino Lime2 with eMMC flash
storage.
https://www.olimex.com/Products/OLinuXino/A20/A20-OLinuXino-LIME2-eMMC/

It is a assembly variant of the regular Lime2 but featuring eMMC for
storage.

Signed-off-by: Olliver Schinagl <oli...@schinagl.nl>
---

Note: for the board to work properly, the updated eMMC dts variant needs to
be updated from upstream.

 board/sunxi/MAINTAINERS|  5 +
 configs/A20-OLinuXino-Lime2-eMMC_defconfig | 33 ++
 2 files changed, 38 insertions(+)
 create mode 100644 configs/A20-OLinuXino-Lime2-eMMC_defconfig

diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index 2321b8b08f..84f91fd10b 100644
--- a/board/sunxi/MAINTAINERS
+++ b/board/sunxi/MAINTAINERS
@@ -89,6 +89,11 @@ M:   Iain Paton <ipat...@gmail.com>
 S: Maintained
 F: configs/A20-OLinuXino-Lime2_defconfig

+A20-OLINUXINO-LIME2-EMMC BOARD
+M: Olliver Schinagl <oli...@schinagl.nl>
+S: Maintained
+F: configs/A20-OLinuXino-Lime2-eMMC_defconfig
+
 A33-OLINUXINO BOARD
 M: Stefan Mavrodiev <stefan.mavrod...@gmail.com>
 S: Maintained
diff --git a/configs/A20-OLinuXino-Lime2-eMMC_defconfig 
b/configs/A20-OLinuXino-Lime2-eMMC_defconfig


I guess you used the latest, right? I got the below error with 4.7.1 and 
even buildman does.


arm-linux-gnueabi-ld.bfd: u-boot-spl section `.u_boot_list' will not fit 
in region `.sram'

arm-linux-gnueabi-ld.bfd: region `.sram' overflowed by 88 bytes
arm-linux-gnueabi-ld.bfd: u-boot-spl: Not enough room for program 
headers, try linking with -N

arm-linux-gnueabi-ld.bfd: final link failed: Bad value

thanks!
--
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

--
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [linux-sunxi] [PATCH 2/3] arm64: allwinner: h5: Add initial Orangepi Prime support

2017-05-26 Thread Jagan Teki
On Fri, May 26, 2017 at 10:10 PM,  <icen...@aosc.io> wrote:
> 在 2017-05-26 03:26,Jagan Teki 写道:
>>
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> Orangepi Prime is an open-source single-board computer
>> using the Allwinner h5 SOC.
>
>
> Sorry but I have already added this board and it's
> scheduled at 4.13.

Ohh, unfortunately I missed to find it on ML, can you point?

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3] sunxi: A64/Pine64: update device tree from Linux

2017-05-29 Thread Jagan Teki
On Wed, May 24, 2017 at 3:04 PM, Andre Przywara <andre.przyw...@arm.com> wrote:
> The Linux device tree for the Allwinner A64 SoC has changed a lot since
> the U-Boot version was merged.
> Let's replace the current DT with a exact copy of the Linux one as of:
> commit c6778ff813d2ca3e3c8733c87dc8b6831a64578b
> Merge: 0ff4c01 3c0e3abd
> Author: Linus Torvalds <torva...@linux-foundation.org>
> Date:   Tue May 9 10:07:33 2017 -0700
>
> This is the DT used in Linux 4.12-rc1.
>
> Since U-Boot has an Ethernet driver (while Linux does not yet), we
> provide the required DT nodes for it in an ...-u-boot.dtsi file, to both
> mark them as U-Boot specific and to allow easier upgrading once Linux gets
> the driver and its own binding later.
> Compared to the existing Ethernet DT nodes we just slightly tweak the clock
> and reset nodes in there to match the new bindings used by Linux for those.
>
> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
> ---
>  arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi|  50 ++

Yeah, may be this need to be named something like
sun50i-a64-u-boot.dtsi as of now? since it may share the similar dt on
other a64 board that we initiate the discussion about orangepi, and
BPI.

All fine expect this name.

Reviewed-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH] sunxi: sinovoip: Use proper naming convention for BPI boards

2017-05-29 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

- Rename Sinovoip BPI defconfigs to use small letter
- To avoid naming conflict with 'LeMaker' add sinovoip
  prefix to BPI M2 Ultra defconfig since bananapi is
  also name used by 'LeMaker'
- Add 'SINOVOIP' prefix 'BANANAPI M2 ULTRA BOARD' under
  board/sunxi/MAINTAINERS file.

Cc: Icenowy Zheng <icen...@aosc.io>
Cc: Chen-Yu Tsai <w...@csie.org>
Cc: VishnuPatekar <vishnupatekar0...@gmail.com>
Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 board/sunxi/MAINTAINERS| 10 +-
 .../{Sinovoip_BPI_M2_defconfig => sinovoip_bpi_m2_defconfig}   |  0
 ...ip_BPI_M2_Plus_defconfig => sinovoip_bpi_m2_plus_defconfig} |  0
 ...napi_M2_Ultra_defconfig => sinovoip_bpi_m2_ultra_defconfig} |  0
 .../{Sinovoip_BPI_M3_defconfig => sinovoip_bpi_m3_defconfig}   |  0
 5 files changed, 5 insertions(+), 5 deletions(-)
 rename configs/{Sinovoip_BPI_M2_defconfig => sinovoip_bpi_m2_defconfig} (100%)
 rename configs/{Sinovoip_BPI_M2_Plus_defconfig => 
sinovoip_bpi_m2_plus_defconfig} (100%)
 rename configs/{Bananapi_M2_Ultra_defconfig => 
sinovoip_bpi_m2_ultra_defconfig} (100%)
 rename configs/{Sinovoip_BPI_M3_defconfig => sinovoip_bpi_m3_defconfig} (100%)

diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index a512a20..61d1479 100644
--- a/board/sunxi/MAINTAINERS
+++ b/board/sunxi/MAINTAINERS
@@ -41,7 +41,7 @@ F:configs/CSQ_CS908_defconfig
 F: configs/inet_q972_defconfig
 F: configs/Mele_A1000G_quad_defconfig
 F: configs/Mele_M9_defconfig
-F: configs/Sinovoip_BPI_M2_defconfig
+F: configs/sinovoip_bpi_m2_defconfig
 F: include/configs/sun7i.h
 F: configs/A20-OLinuXino_MICRO_defconfig
 F: configs/Bananapi_defconfig
@@ -108,10 +108,10 @@ M:Paul Kocialkowski <cont...@paulk.fr>
 S: Maintained
 F: configs/Ampe_A76_defconfig
 
-BANANAPI M2 ULTRA BOARD
+SINOVOIP BANANAPI M2 ULTRA BOARD
 M: Chen-Yu Tsai <w...@csie.org>
 S: Maintained
-F: configs/Bananapi_M2_Ultra_defconfig
+F: configs/sinovoip_bpi_m2_ultra_defconfig
 F: arch/arm/dts/sun8i-r40-bananapi-m2-ultra.dts
 
 COLOMBUS BOARD
@@ -287,12 +287,12 @@ W:http://linux-sunxi.org/Sinlinx_SinA33
 SINOVOIP BPI M2 PLUS H3 BOARD
 M: Icenowy Zheng <icen...@aosc.io>
 S: Maintained
-F: configs/Sinovoip_BPI_M2_Plus_defconfig
+F: configs/sinovoip_bpi_m2_Plus_defconfig
 
 SINOVOIP BPI M3 A83T BOARD
 M: VishnuPatekar <vishnupatekar0...@gmail.com>
 S: Maintained
-F: configs/Sinovoip_BPI_M3_defconfig
+F: configs/sinovoip_bpi_m3_defconfig
 
 SUNCHIP CX-A99 BOARD
 M: Rask Ingemann Lambertsen <r...@formelder.dk>
diff --git a/configs/Sinovoip_BPI_M2_defconfig 
b/configs/sinovoip_bpi_m2_defconfig
similarity index 100%
rename from configs/Sinovoip_BPI_M2_defconfig
rename to configs/sinovoip_bpi_m2_defconfig
diff --git a/configs/Sinovoip_BPI_M2_Plus_defconfig 
b/configs/sinovoip_bpi_m2_plus_defconfig
similarity index 100%
rename from configs/Sinovoip_BPI_M2_Plus_defconfig
rename to configs/sinovoip_bpi_m2_plus_defconfig
diff --git a/configs/Bananapi_M2_Ultra_defconfig 
b/configs/sinovoip_bpi_m2_ultra_defconfig
similarity index 100%
rename from configs/Bananapi_M2_Ultra_defconfig
rename to configs/sinovoip_bpi_m2_ultra_defconfig
diff --git a/configs/Sinovoip_BPI_M3_defconfig 
b/configs/sinovoip_bpi_m3_defconfig
similarity index 100%
rename from configs/Sinovoip_BPI_M3_defconfig
rename to configs/sinovoip_bpi_m3_defconfig
-- 
1.9.1

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH] sunxi: sinovoip: Use proper naming convention for BPI boards

2017-05-29 Thread Jagan Teki
On Mon, May 29, 2017 at 8:27 PM, Chen-Yu Tsai <w...@csie.org> wrote:
> On Mon, May 29, 2017 at 10:24 PM, Jagan Teki <ja...@openedev.com> wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> - Rename Sinovoip BPI defconfigs to use small letter
>> - To avoid naming conflict with 'LeMaker' add sinovoip
>>   prefix to BPI M2 Ultra defconfig since bananapi is
>>   also name used by 'LeMaker'
>> - Add 'SINOVOIP' prefix 'BANANAPI M2 ULTRA BOARD' under
>>   board/sunxi/MAINTAINERS file.
>
> No. The proper solution is to just get rid of the Sinovoip and
> LeMaker bullshit. The brand name has been and will continue to be
> "Banana Pi". Apart from the trademark legal drama between LeMaker,
> Sinovoip, and Foxconn, the boards are now consistently named
> "BPI-xyz". The original "Banana Pi" is now the "BPI-M1". The only
> incompatible outlier is the LeMaker made BananaPro.

But there is one board Bananapi_defconfig which is from LeMaker, which
will conflict if we skip these and use binanapi for rest.

>
> LeMaker and Sinovoip are distributors. Maybe they manufacture(d)
> as well, but I'm not so sure.
>
> Also, see https://www.spinics.net/lists/devicetree/msg176001.html
>
> Note that "BIPAI KEJI LIMITED" is just a translation for BPI
> Technologies limited. BIPAI is the phonetics for B-PI in English.
> KEJI is the phonetics for "technology" in Chinese.

Thanks for the info.

>
> Finally, is there a preference for all lowercase defconfig file names?

Yes, for newly supported and/or longer stable defconfigs/boards follow
lower-case defconfig file names in U-Boot.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH 1/3] ARM: dts: sun7i-a20: Rename bananapi as bananapi m1

2017-05-29 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

from BPI(BIPAI KEJI LIMITED) products the Bananapi board
is named as 'Bananapi M1' and this is the starting
bananapi board from M1 series.

So rename dts and suffix 'M1' on model for the same,
so-that next sequence on bananapi starts like M1 Plus, M2 and so..on

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Note: Bananapi BPI product site
http://www.banana-pi.org/product.html

 arch/arm/boot/dts/Makefile  |   2 +-
 arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts | 286 
 arch/arm/boot/dts/sun7i-a20-bananapi.dts| 286 
 3 files changed, 287 insertions(+), 287 deletions(-)
 create mode 100644 arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
 delete mode 100644 arch/arm/boot/dts/sun7i-a20-bananapi.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 45c6e65..1b086f0 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -851,7 +851,7 @@ dtb-$(CONFIG_MACH_SUN6I) += \
sun6i-a31s-sinovoip-bpi-m2.dtb \
sun6i-a31s-yones-toptech-bs1078-v2.dtb
 dtb-$(CONFIG_MACH_SUN7I) += \
-   sun7i-a20-bananapi.dtb \
+   sun7i-a20-bananapi-m1.dtb \
sun7i-a20-bananapi-m1-plus.dtb \
sun7i-a20-bananapro.dtb \
sun7i-a20-cubieboard2.dtb \
diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts 
b/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
new file mode 100644
index 000..8b97b89
--- /dev/null
+++ b/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
@@ -0,0 +1,286 @@
+/*
+ * Copyright 2014 Hans de Goede <hdego...@redhat.com>
+ *
+ * Hans de Goede <hdego...@redhat.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This file is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+#include "sun7i-a20.dtsi"
+#include "sunxi-common-regulators.dtsi"
+
+#include 
+#include 
+
+/ {
+   model = "LeMaker Banana Pi M1";
+   compatible = "lemaker,bananapi", "allwinner,sun7i-a20";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   serial2 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_bananapi>;
+
+   green {
+   label = "bananapi:green:usr";
+   gpios = < 7 24 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
+   reg_gmac_3v3: gmac-3v3 {
+   compatible = "regulator-fixed";
+   pinctrl-names = "default";
+   pinctrl-0 = <_power_pin_bananapi>;
+   regulator-name = "gmac-3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   startup-delay-us = <10>;
+   enable-active-h

[linux-sunxi] [PATCH 2/3] ARM: dts: sunxi: Update model and compatible for bananapi

2017-05-29 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Since Bananapi brand is owned by BIPAI KEJI(BPI), the previous
Lemaker and Sinovoip no longer use the bananapi brand, hence
Updated the model and compatible for existing bananapi boards
which is denoted same like in binanapi site.

Example: for Bananapi M64 board as

model = "Banana Pi BPI-M64";
compatible = "bananapi,bpi-m64", "allwinner,sun50i-a64";

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Note: Bananapi BPI product site
http://www.banana-pi.org/product.html

 arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts  | 4 ++--
 arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts  | 4 ++--
 arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts   | 4 ++--
 arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts   | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 4 ++--
 5 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts 
b/arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts
index bdfdce8..265f79d 100644
--- a/arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts
+++ b/arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts
@@ -46,8 +46,8 @@
 #include 
 
 / {
-   model = "Sinovoip BPI-M2";
-   compatible = "sinovoip,bpi-m2", "allwinner,sun6i-a31s";
+   model = "Banana PI BPI-M2";
+   compatible = "bananapi,bpi-m2", "allwinner,sun6i-a31s";
 
aliases {
serial0 = 
diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts 
b/arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts
index 08e776a..2c87236 100644
--- a/arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts
+++ b/arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts
@@ -49,8 +49,8 @@
 #include 
 
 / {
-   model = "Banana Pi BPI-M1-Plus";
-   compatible = "sinovoip,bpi-m1-plus", "allwinner,sun7i-a20";
+   model = "Banana Pi BPI-M1+";
+   compatible = "bananapi,bpi-m1-plus", "allwinner,sun7i-a20";
 
aliases {
serial0 = 
diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts 
b/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
index 8b97b89..3d2597e 100644
--- a/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
+++ b/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
@@ -50,8 +50,8 @@
 #include 
 
 / {
-   model = "LeMaker Banana Pi M1";
-   compatible = "lemaker,bananapi", "allwinner,sun7i-a20";
+   model = "Banana Pi BPI-M1";
+   compatible = "bananapi,bpi-m1", "allwinner,sun7i-a20";
 
aliases {
serial0 = 
diff --git a/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts 
b/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts
index 52acbe1..643b8ec 100644
--- a/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts
+++ b/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts
@@ -49,7 +49,7 @@
 
 / {
model = "Banana Pi BPI-M2-Plus";
-   compatible = "sinovoip,bpi-m2-plus", "allwinner,sun8i-h3";
+   compatible = "bananapi,bpi-m2-plus", "allwinner,sun8i-h3";
 
aliases {
serial0 = 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
index 6872135..949edba 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
@@ -47,8 +47,8 @@
 #include 
 
 / {
-   model = "BananaPi-M64";
-   compatible = "sinovoip,bananapi-m64", "allwinner,sun50i-a64";
+   model = "Banana Pi BPI-M64";
+   compatible = "bananapi,bpi-m64", "allwinner,sun50i-a64";
 
aliases {
serial0 = 
-- 
1.9.1

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH 3/3] ARM: dts: sun6i-a31s: Rename sun6i-a31s-sinovoip-bpi-m2

2017-05-29 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Since Bananapi brand is owned by BIPAI KEJI(BPI),
the previous Sinovoip no longer use the bananapi brand,
hence rename sun6i-a31s-sinovoip-bpi-m2.dts to
sun6i-a31s-bananapi-m2.dts

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Note: Bananapi BPI product site
http://www.banana-pi.org/product.html

 arch/arm/boot/dts/Makefile   |   2 +-
 arch/arm/boot/dts/sun6i-a31s-bananapi-m2.dts | 244 +++
 arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts | 244 ---
 3 files changed, 245 insertions(+), 245 deletions(-)
 create mode 100644 arch/arm/boot/dts/sun6i-a31s-bananapi-m2.dts
 delete mode 100644 arch/arm/boot/dts/sun6i-a31s-sinovoip-bpi-m2.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 1b086f0..e588721 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -848,7 +848,7 @@ dtb-$(CONFIG_MACH_SUN6I) += \
sun6i-a31s-inet-q972.dtb \
sun6i-a31s-primo81.dtb \
sun6i-a31s-sina31s.dtb \
-   sun6i-a31s-sinovoip-bpi-m2.dtb \
+   sun6i-a31s-bananapi-m2.dtb \
sun6i-a31s-yones-toptech-bs1078-v2.dtb
 dtb-$(CONFIG_MACH_SUN7I) += \
sun7i-a20-bananapi-m1.dtb \
diff --git a/arch/arm/boot/dts/sun6i-a31s-bananapi-m2.dts 
b/arch/arm/boot/dts/sun6i-a31s-bananapi-m2.dts
new file mode 100644
index 000..265f79d
--- /dev/null
+++ b/arch/arm/boot/dts/sun6i-a31s-bananapi-m2.dts
@@ -0,0 +1,244 @@
+/*
+ * Copyright 2015 Hans de Goede <hdego...@redhat.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+#include "sun6i-a31s.dtsi"
+#include "sunxi-common-regulators.dtsi"
+#include 
+
+/ {
+   model = "Banana PI BPI-M2";
+   compatible = "bananapi,bpi-m2", "allwinner,sun6i-a31s";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_bpi_m2>;
+
+   blue {
+   label = "bpi-m2:blue:usr";
+   gpios = < 6 11 GPIO_ACTIVE_HIGH>; /* PG11 */
+   };
+
+   green {
+   label = "bpi-m2:green:usr";
+   gpios = < 6 10 GPIO_ACTIVE_HIGH>; /* PG10 */
+   };
+
+   red {
+   label = "bpi-m2:red:usr";
+   gpios = < 6 5 GPIO_ACTIVE_HIGH>; /* PG5 */
+   };
+   };
+
+   mmc2_pwrseq: mmc2_pwrseq {
+   compatible = "mmc-pwrseq-simple";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwrseq_pin_bpi_m2>;
+   reset-gpios = <_pio 0 8 GPIO_ACTIVE_LOW>; /* PL8 WIFI_EN */
+

[linux-sunxi] [PATCH v2 1/2] sunxi: Rename bananapi board as bananapi m1

2017-05-29 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

from BPI(BIPAI KEJI LIMITED) products the Bananapi board
is named as 'Bananapi M1' and this is the starting
bananapi board from M1 series.

So rename the board defconfig, dts and suffix 'M1' on
model for the same  so-that next sequence on bananapi starts
like M1 Plus, M2 and so.on

Cc: Icenowy Zheng <icen...@aosc.io>
Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Newly added patch

 arch/arm/dts/sun7i-a20-bananapi-m1.dts | 293 +
 arch/arm/dts/sun7i-a20-bananapi.dts| 293 -
 board/sunxi/MAINTAINERS|   2 +-
 configs/Bananapi_M1_defconfig  |  23 +++
 configs/Bananapi_defconfig |  23 ---
 5 files changed, 317 insertions(+), 317 deletions(-)
 create mode 100644 arch/arm/dts/sun7i-a20-bananapi-m1.dts
 delete mode 100644 arch/arm/dts/sun7i-a20-bananapi.dts
 create mode 100644 configs/Bananapi_M1_defconfig
 delete mode 100644 configs/Bananapi_defconfig

diff --git a/arch/arm/dts/sun7i-a20-bananapi-m1.dts 
b/arch/arm/dts/sun7i-a20-bananapi-m1.dts
new file mode 100644
index 000..4a1d7d7
--- /dev/null
+++ b/arch/arm/dts/sun7i-a20-bananapi-m1.dts
@@ -0,0 +1,293 @@
+/*
+ * Copyright 2014 Hans de Goede <hdego...@redhat.com>
+ *
+ * Hans de Goede <hdego...@redhat.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This file is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+#include "sun7i-a20.dtsi"
+#include "sunxi-common-regulators.dtsi"
+
+#include 
+#include 
+#include 
+
+/ {
+   model = "LeMaker Banana Pi M1";
+   compatible = "lemaker,bananapi", "allwinner,sun7i-a20";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   serial2 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_bananapi>;
+
+   green {
+   label = "bananapi:green:usr";
+   gpios = < 7 24 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
+   reg_gmac_3v3: gmac-3v3 {
+   compatible = "regulator-fixed";
+   pinctrl-names = "default";
+   pinctrl-0 = <_power_pin_bananapi>;
+   regulator-name = "gmac-3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   startup-delay-us = <10>;
+   enable-active-high;
+   gpio = < 7 23 GPIO_ACTIVE_HIGH>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   cpu-supply = <_dcdc2>;
+   operating-points = <
+   /* kHzuV */
+   96  140
+ 

[linux-sunxi] [PATCH v2 2/2] sunxi: Use proper naming convention for Bananapi boards

2017-05-29 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Since Bananapi brand is owned by BIPAI KEJI(BPI)
- Drop vendor prefix 'Sinovoip' for defconfig names
- Drop Board name 'SINOVOIP' in MAINTAINERS file
- Use small letters for defconfig files, since
  newly supported and/or longer stable defconfigs
  follow lower-case letters.

Cc: Icenowy Zheng <icen...@aosc.io>
Cc: Chen-Yu Tsai <w...@csie.org>
Cc: VishnuPatekar <vishnupatekar0...@gmail.com>
Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Drop Sinovoip and SINOVOIP vendor prefix since bananapi
  brand no longer used.

 board/sunxi/MAINTAINERS| 14 +++---
 configs/Bananapi_M1_defconfig  | 23 ---
 configs/Bananapi_M2_Ultra_defconfig| 18 --
 configs/Sinovoip_BPI_M2_Plus_defconfig | 20 
 configs/Sinovoip_BPI_M2_defconfig  | 22 --
 configs/Sinovoip_BPI_M3_defconfig  | 29 -
 configs/bananapi_m1_defconfig  | 23 +++
 configs/bananapi_m2_defconfig  | 22 ++
 configs/bananapi_m2_plus_defconfig | 20 
 configs/bananapi_m2_ultra_defconfig| 18 ++
 configs/bananapi_m3_defconfig  | 29 +
 11 files changed, 119 insertions(+), 119 deletions(-)
 delete mode 100644 configs/Bananapi_M1_defconfig
 delete mode 100644 configs/Bananapi_M2_Ultra_defconfig
 delete mode 100644 configs/Sinovoip_BPI_M2_Plus_defconfig
 delete mode 100644 configs/Sinovoip_BPI_M2_defconfig
 delete mode 100644 configs/Sinovoip_BPI_M3_defconfig
 create mode 100644 configs/bananapi_m1_defconfig
 create mode 100644 configs/bananapi_m2_defconfig
 create mode 100644 configs/bananapi_m2_plus_defconfig
 create mode 100644 configs/bananapi_m2_ultra_defconfig
 create mode 100644 configs/bananapi_m3_defconfig

diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index c2f0227..5f60a4d 100644
--- a/board/sunxi/MAINTAINERS
+++ b/board/sunxi/MAINTAINERS
@@ -41,10 +41,10 @@ F:  configs/CSQ_CS908_defconfig
 F: configs/inet_q972_defconfig
 F: configs/Mele_A1000G_quad_defconfig
 F: configs/Mele_M9_defconfig
-F: configs/Sinovoip_BPI_M2_defconfig
+F: configs/bananapi_m2_defconfig
 F: include/configs/sun7i.h
 F: configs/A20-OLinuXino_MICRO_defconfig
-F: configs/Bananapi_M1_defconfig
+F: configs/bananapi_m1_defconfig
 F: configs/Bananapro_defconfig
 F: configs/i12-tvbox_defconfig
 F: configs/Linksprite_pcDuino3_defconfig
@@ -111,7 +111,7 @@ F:  configs/Ampe_A76_defconfig
 BANANAPI M2 ULTRA BOARD
 M: Chen-Yu Tsai <w...@csie.org>
 S: Maintained
-F: configs/Bananapi_M2_Ultra_defconfig
+F: configs/bananapi_m2_ultra_defconfig
 F: arch/arm/dts/sun8i-r40-bananapi-m2-ultra.dts
 
 COLOMBUS BOARD
@@ -284,15 +284,15 @@ S:Maintained
 F: configs/Sinlinx_SinA33_defconfig
 W: http://linux-sunxi.org/Sinlinx_SinA33
 
-SINOVOIP BPI M2 PLUS H3 BOARD
+BPI M2 PLUS H3 BOARD
 M: Icenowy Zheng <icen...@aosc.io>
 S: Maintained
-F: configs/Sinovoip_BPI_M2_Plus_defconfig
+F: configs/bananapi_m2_plus_defconfig
 
-SINOVOIP BPI M3 A83T BOARD
+BPI M3 A83T BOARD
 M: VishnuPatekar <vishnupatekar0...@gmail.com>
 S: Maintained
-F: configs/Sinovoip_BPI_M3_defconfig
+F: configs/bananapi_m3_defconfig
 
 SUNCHIP CX-A99 BOARD
 M: Rask Ingemann Lambertsen <r...@formelder.dk>
diff --git a/configs/Bananapi_M1_defconfig b/configs/Bananapi_M1_defconfig
deleted file mode 100644
index 1f8e37b..000
--- a/configs/Bananapi_M1_defconfig
+++ /dev/null
@@ -1,23 +0,0 @@
-CONFIG_ARM=y
-CONFIG_ARCH_SUNXI=y
-CONFIG_MACH_SUN7I=y
-CONFIG_DRAM_CLK=432
-CONFIG_MACPWR="PH23"
-CONFIG_VIDEO_COMPOSITE=y
-CONFIG_GMAC_TX_DELAY=3
-CONFIG_DEFAULT_DEVICE_TREE="sun7i-a20-bananapi-m1"
-CONFIG_AHCI=y
-# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
-CONFIG_SPL=y
-CONFIG_SPL_I2C_SUPPORT=y
-# CONFIG_CMD_IMLS is not set
-# CONFIG_CMD_FLASH is not set
-# CONFIG_CMD_FPGA is not set
-# CONFIG_SPL_DOS_PARTITION is not set
-# CONFIG_SPL_ISO_PARTITION is not set
-# CONFIG_SPL_EFI_PARTITION is not set
-CONFIG_NETCONSOLE=y
-CONFIG_ETH_DESIGNWARE=y
-CONFIG_RGMII=y
-CONFIG_SUN7I_GMAC=y
-CONFIG_USB_EHCI_HCD=y
diff --git a/configs/Bananapi_M2_Ultra_defconfig 
b/configs/Bananapi_M2_Ultra_defconfig
deleted file mode 100644
index 4332eca..000
--- a/configs/Bananapi_M2_Ultra_defconfig
+++ /dev/null
@@ -1,18 +0,0 @@
-CONFIG_ARM=y
-CONFIG_ARCH_SUNXI=y
-CONFIG_MACH_SUN8I_R40=y
-CONFIG_DRAM_CLK=576
-CONFIG_DRAM_ZQ=3881979
-CONFIG_DRAM_ODT_EN=y
-CONFIG_MMC0_CD_PIN="PH13"
-CONFIG_MMC_SUNXI_SLOT_EXTRA=2
-CONFIG_DEFAULT_DEVICE_TREE="sun8i-r40-bananapi-m2-ultra"
-CONFIG_AHCI=y
-# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
-CONFIG_SPL=y
-CONFIG_SPL_I2C_SUPPORT=y
-# CONFIG_CMD_IMLS is no

Re: [linux-sunxi] [PATCH 1/3] ARM: dts: sun7i-a20: Rename bananapi as bananapi m1

2017-05-29 Thread Jagan Teki
On Tue, May 30, 2017 at 3:15 AM, Karsten Merker <mer...@debian.org> wrote:
> On Mon, May 29, 2017 at 07:30:26PM +0000, Jagan Teki wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> from BPI(BIPAI KEJI LIMITED) products the Bananapi board
>> is named as 'Bananapi M1' and this is the starting
>> bananapi board from M1 series.
>>
>> So rename dts and suffix 'M1' on model for the same,
>> so-that next sequence on bananapi starts like M1 Plus, M2 and so..on
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>> ---
>> Note: Bananapi BPI product site
>> http://www.banana-pi.org/product.html
>>
>>  arch/arm/boot/dts/Makefile  |   2 +-
>>  arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts | 286 
>> 
>>  arch/arm/boot/dts/sun7i-a20-bananapi.dts| 286 
>> 
>>  3 files changed, 287 insertions(+), 287 deletions(-)
>>  create mode 100644 arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
>>  delete mode 100644 arch/arm/boot/dts/sun7i-a20-bananapi.dts
>>
>> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
>> index 45c6e65..1b086f0 100644
>> --- a/arch/arm/boot/dts/Makefile
>> +++ b/arch/arm/boot/dts/Makefile
>> @@ -851,7 +851,7 @@ dtb-$(CONFIG_MACH_SUN6I) += \
>>   sun6i-a31s-sinovoip-bpi-m2.dtb \
>>   sun6i-a31s-yones-toptech-bs1078-v2.dtb
>>  dtb-$(CONFIG_MACH_SUN7I) += \
>> - sun7i-a20-bananapi.dtb \
>> + sun7i-a20-bananapi-m1.dtb \
>>   sun7i-a20-bananapi-m1-plus.dtb \
>>   sun7i-a20-bananapro.dtb \
>>   sun7i-a20-cubieboard2.dtb \
>> diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts 
>> b/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
>> new file mode 100644
>> index 000..8b97b89
>> --- /dev/null
>> +++ b/arch/arm/boot/dts/sun7i-a20-bananapi-m1.dts
>> @@ -0,0 +1,286 @@
>> +/*
>> + * Copyright 2014 Hans de Goede <hdego...@redhat.com>
>> + *
>> + * Hans de Goede <hdego...@redhat.com>
> [...]
>> +/dts-v1/;
>> +#include "sun7i-a20.dtsi"
>> +#include "sunxi-common-regulators.dtsi"
>> +
>> +#include 
>> +#include 
>> +
>> +/ {
>> + model = "LeMaker Banana Pi M1";
>> + compatible = "lemaker,bananapi", "allwinner,sun7i-a20";
> [...]
>> diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi.dts 
>> b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
>> deleted file mode 100644
>> index ed2f35a..000
>> --- a/arch/arm/boot/dts/sun7i-a20-bananapi.dts
>> +++ /dev/null
>
> NACK!
>
> Please neither rename the dts nor change the model string. Such a
> change would make newer kernels unusable on many existing
> installations without manual fixups by the end user.  Linux
> distributions use databases with model-specific setup information
> (such as the dtb file name, the platform-specific bootscript to
> use, usable kernel flavours (lpae or non-lpae), etc.) on kernel
> installations and kernel upgrades, and those use the model string
> as their key for finding the relevant information.  If you change
> either the dts file name or the model string inside the dts,
> you'll effectively break the proper installation of newer kernel
> versions on existing end user systems.

I understand your concerns about distribution change, but with new
change in 'bananapi' brand owned by BIPAI KEJI(BPI) the model must
need to update and this is not technically as Bananapi board it is
Bananapi  M1 [1]

These are generic changes based on the hardware vendor info.

[1] http://www.banana-pi.org/m1.html

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-05-30 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Note: Not tested yet, board is on-the-way to reach.

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 101 +
 2 files changed, 102 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index 1648700..c1dd6e4 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,4 +1,5 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-pc2.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..56fc932
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,101 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>, <

[linux-sunxi] [PATCH 2/2] sun50i: h5: Add initial NanoPi NEO2 support

2017-05-30 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi M1 Plus is designed and developed by FriendlyElec
using the Allwinner 64-bit H5 SOC.

NanoPi Neo2 key features
- Allwinner H5, Quad-core 64-bit Cortex-A53
- 512MB DDR3 RAM
- microSD slot
- 10/100/1000M Ethernet
- Serial Debug Port
- 5V 2A DC MicroUSB power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 arch/arm/dts/Makefile  |  1 +
 arch/arm/dts/sun50i-h5-nanopi-neo2.dts | 92 ++
 board/sunxi/MAINTAINERS|  5 ++
 configs/nanopi_neo2_defconfig  | 17 +++
 4 files changed, 115 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-h5-nanopi-neo2.dts
 create mode 100644 configs/nanopi_neo2_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index bf16563..ec5221d 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -317,6 +317,7 @@ dtb-$(CONFIG_MACH_SUN8I_R40) += \
 dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
+   sun50i-h5-nanopi-neo2.dtb \
sun50i-h5-orangepi-pc2.dtb \
sun50i-h5-orangepi-prime.dtb \
sun50i-h5-orangepi-zero-plus2.dtb
diff --git a/arch/arm/dts/sun50i-h5-nanopi-neo2.dts 
b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
new file mode 100644
index 000..c28779f
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
@@ -0,0 +1,92 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi NEO2";
+   compatible = "friendlyarm,nanopi-neo2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   memory {
+   reg = <0x4000 0x2000>;
+   };
+
+   soc {
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>;
+   status = "okay";
+};
diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index 531e6e0..b765853 100644
--- a/board/su

[linux-sunxi] [PATCH 1/2] sun8i: h3: Add initial NanoPi M1 Plus support

2017-05-30 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi M1 Plus is designed and developed by FriendlyElec
for professionals, enterprise users, makers and hobbyists
using the Allwinner H3 SOC.

NanoPi M1 Plus key features
- Allwinner H3, Quad-core Cortex-A7@1.2GHz
- 1GB DDR3 RAM
- 8GB eMMC
- microSD slot
- 10/100/1000M Ethernet
- Serial Debug Port
- 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Note: Need to add mmc node for eMMC, will add it on
next version once tested

 arch/arm/dts/Makefile|  1 +
 arch/arm/dts/sun8i-h3-nanopi-m1-plus.dts | 64 
 board/sunxi/MAINTAINERS  |  5 +++
 configs/nanopi_m1_plus_defconfig | 18 +
 4 files changed, 88 insertions(+)
 create mode 100644 arch/arm/dts/sun8i-h3-nanopi-m1-plus.dts
 create mode 100644 configs/nanopi_m1_plus_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index eaf9ada..bf16563 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -309,6 +309,7 @@ dtb-$(CONFIG_MACH_SUN8I_H3) += \
sun8i-h3-orangepi-plus.dtb \
sun8i-h3-orangepi-plus2e.dtb \
sun8i-h3-nanopi-m1.dtb \
+   sun8i-h3-nanopi-m1-plus.dtb \
sun8i-h3-nanopi-neo.dtb \
sun8i-h3-nanopi-neo-air.dtb
 dtb-$(CONFIG_MACH_SUN8I_R40) += \
diff --git a/arch/arm/dts/sun8i-h3-nanopi-m1-plus.dts 
b/arch/arm/dts/sun8i-h3-nanopi-m1-plus.dts
new file mode 100644
index 000..8ddd1b2
--- /dev/null
+++ b/arch/arm/dts/sun8i-h3-nanopi-m1-plus.dts
@@ -0,0 +1,64 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This file is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#include "sun8i-h3-nanopi.dtsi"
+
+/ {
+   model = "FriendlyArm NanoPi M1 Plus";
+   compatible = "friendlyarm,nanopi-m1-plus", "allwinner,sun8i-h3";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index 010e87c..531e6e0 100644
--- a/board/sunxi/MAINTAINERS
+++ b/board/sunxi/MAINTAINERS
@@ -252,6 +252,11 @@ M: Mylène Josserand <mylene.josser...@free-electrons.com>
 S: Maintained
 F: configs/nanopi_m1_defconfig
 
+NANOPI-M1 PLUS BOARD
+M: Jagan Teki <ja...@amarulasolutions.com>
+S: Maintained
+F: configs/nanopi_m1_plus_defconfig
+
 NANOPI-NEO BOARD
 M: Jelle van der Waa <je...@vdwaa.nl>
 S: Maintained
diff --git a/configs/nanopi_m1_plus_defconfig b/configs/nanopi_m1_plus_defconfig
new file mode 100644
index 000..d7a908d
--- /dev/null
+++ b/configs/nanopi_m1_plus_defconfig
@@ -0,0 +1,18 @@
+CONFIG_ARM=y
+CONFIG_ARCH_SUNXI=y
+CONFIG_MACH_SUN8I_H3=y
+CONFIG_DRAM_CLK=408
+CONFIG_DRAM_ZQ=3881979
+CONFIG_DRAM_ODT_EN=y
+CONFIG_MMC0_CD_PIN="PH13"
+CONFIG_MMC_SUNXI_SLOT_EXTRA=2
+CONFIG_DEFAULT_DEVICE_TREE="sun8i-h3-nanopi-m1-plus&

[linux-sunxi] [PATCH 1/2] arm64: allwinner: h5: Add initial NanoPi NEO2 support

2017-05-30 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi M1 Plus is designed and developed by FriendlyElec
using the Allwinner 64-bit H5 SOC.

NanoPi Neo2 key features
- Allwinner H5, Quad-core 64-bit Cortex-A53
- 512MB DDR3 RAM
- microSD slot
- 10/100/1000M Ethernet
- Serial Debug Port
- 5V 2A DC MicroUSB power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 arch/arm64/boot/dts/allwinner/Makefile |  1 +
 .../boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts   | 92 ++
 2 files changed, 93 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index c1dd6e4..8d50907 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -2,6 +2,7 @@ dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-orangepi-win.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-nanopi-neo2.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-pc2.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-prime.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-zero-plus2.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts
new file mode 100644
index 000..c28779f
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts
@@ -0,0 +1,92 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi NEO2";
+   compatible = "friendlyarm,nanopi-neo2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   memory {
+   reg = <0x4000 0x2000>;
+   };
+
+   soc {
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pin

[linux-sunxi] [PATCH v3] sun50i: a64: Add initial Banana Pi M64 support

2017-05-31 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

BPI-M64 is a 64-bit quad-core mini single board computer
using the Allwinner A64 SOC.

BPI-M64 features
- 1.2 Ghz Quad-Core ARM Cortex A53
- 2GB DDR3 SDRAM with 733MHz
- MicroSD/eMMC(8GB)
- 10/100/1000Mbps ethernet (Realtek RTL8211E/D)
- Wifi + BT
- IR receiver
- Audio In/Out
- Video In/Out
- 5V 2A DC power-supply

For dts file,
Sync with Linux commit 4879b7ae("Merge tag 'dmaengine-4.12-rc1'").

Boot from MMC:
-
U-Boot SPL 2017.05-00667-g85dd258-dirty (May 29 2017 - 13:07:31)
DRAM: 2048 MiB
Trying to boot from MMC1
NOTICE:  BL3-1: Running on A64/H64 (1689) in SRAM A2 (@0x44000)
NOTICE:  Configuring SPC Controller
NOTICE:  BL3-1: v1.0(debug):aa75c8d
NOTICE:  BL3-1: Built : 18:28:27, May 24 2017
NOTICE:  Configuring AXP PMIC
NOTICE:  PMIC: setup successful
INFO:BL3-1: Initializing runtime services
INFO:BL3-1: Preparing for EL3 exit to normal world
INFO:BL3-1: Next image address: 0x4a00, SPSR: 0x3c9

U-Boot 2017.05-00667-g85dd258-dirty (May 29 2017 - 13:07:31 +) Allwinner 
Technology

CPU:   Allwinner A64 (SUN50I)
Model: BananaPi-M64
DRAM:  2 GiB
MMC:   SUNXI SD/MMC: 0, SUNXI SD/MMC: 1
*** Warning - bad CRC, using default environment

In:serial
Out:   serial
Err:   serial
Net:   No ethernet found.
starting USB...
No controllers found
Hit any key to stop autoboot:  0

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Droped CONSOLE_MUX, bcz it is enabled by default
- Sync with Linux dts file
Changes for v2:
- Update email-id
- Tested on BPI-M64
- Added MMC Slot 2 CONFIG_

 arch/arm/dts/Makefile|   1 +
 arch/arm/dts/sun50i-a64-bananapi-m64.dts | 121 +++
 board/sunxi/MAINTAINERS  |   5 ++
 configs/bananapi_m64_defconfig   |  17 +
 4 files changed, 144 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-a64-bananapi-m64.dts
 create mode 100644 configs/bananapi_m64_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index d121a62..de54481 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -318,6 +318,7 @@ dtb-$(CONFIG_MACH_SUN50I_H5) += \
sun50i-h5-orangepi-prime.dtb \
sun50i-h5-orangepi-zero-plus2.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
+   sun50i-a64-bananapi-m64.dtb \
sun50i-a64-orangepi-win.dtb \
sun50i-a64-pine64-plus.dtb \
sun50i-a64-pine64.dtb
diff --git a/arch/arm/dts/sun50i-a64-bananapi-m64.dts 
b/arch/arm/dts/sun50i-a64-bananapi-m64.dts
new file mode 100644
index 000..02db114
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-bananapi-m64.dts
@@ -0,0 +1,121 @@
+/*
+ * Copyright (c) 2016 ARM Ltd.
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "BananaPi-M64";
+   compatible = "sinovoip,bananapi-m64", "allwinner,sun50i-a64";
+
+   ali

[linux-sunxi] Re: [U-Boot] [PATCH v2] sun50i: h5: Add initial Orangepi Prime support

2017-06-02 Thread Jagan Teki
On Fri, Jun 2, 2017 at 6:53 PM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Thu, Jun 01, 2017 at 03:25:32PM +0000, Jagan Teki wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> Orangepi Prime is an open-source single-board computer
>> using the Allwinner h5 SOC.
>>
>> H5 Orangepi Prime has
>> - Quad-core Cortex-A53
>> - 2GB DDR3
>> - Debug TTL UART
>> - 1000M/100M Ethernet RJ45
>> - Three USB 2.0
>> - HDMI
>> - Audio and MIC
>> - Wifi + BT
>> - IR receiver
>> - HDMI
>> - Wifi + BT
>>
>> Boot from MMC:
>> -
>> U-Boot SPL 2017.05-00662-ga3f4c05-dirty (May 25 2017 - 13:30:14)
>> DRAM: 2048 MiB
>> Trying to boot from MMC1
>> NOTICE:  BL3-1: Running on H5 (1718) in SRAM A2 (@0x44000)
>> NOTICE:  Configuring SPC Controller
>> NOTICE:  BL3-1: v1.0(debug):aa75c8d
>> NOTICE:  BL3-1: Built : 18:28:27, May 24 2017
>> INFO:BL3-1: Initializing runtime services
>> INFO:BL3-1: Preparing for EL3 exit to normal world
>> INFO:BL3-1: Next image address: 0x4a00, SPSR: 0x3c9
>>
>> U-Boot 2017.05-00662-ga3f4c05-dirty (May 25 2017 - 13:30:14 +) Allwinner 
>> Technology
>>
>> CPU:   Allwinner H5 (SUN50I)
>> Model: OrangePi Prime
>> DRAM:  2 GiB
>> MMC:   SUNXI SD/MMC: 0
>> *** Warning - bad CRC, using default environment
>>
>> In:serial
>> Out:   serial
>> Err:   serial
>> Net:   phy interface7
>> eth0: ethernet@1c3
>> starting USB...
>> USB0:   USB EHCI 1.00
>> USB1:   USB OHCI 1.0
>> scanning bus 0 for devices... 1 USB Device(s) found
>>scanning usb for storage devices... 0 Storage Device(s) found
>> Hit any key to stop autoboot:  0
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH 00/12] Big work on sunxi DW DRAM controllers and some new DDR type support

2017-06-02 Thread Jagan Teki
On Wed, Apr 26, 2017 at 8:19 PM, Icenowy Zheng <icen...@aosc.io> wrote:
> This patchset contains several works on the sunxi DesignWare DRAM
> controllers.
>
> The 1st patch made an option for H3-like DRAM controllers
> (DesignWare ones), which can ease further import of alike controllers.
>
> The 2nd and 3rd patches are for supporting 16-bit DW DRAM controllers,
> in order to add V3s DRAM support (The controller on V3s is 16-bit).
>
> The 4th patch adds bank detection code, in order to support some DDR2
> chips.
>
> The 5th patch adds a framework for select DRAM type and timing -- it's
> needed for boards that use DRAM chips rather than DDR3.
>
> The 6th patch enables dual rank detection in the DW DRAM code on SoCs
> except R40. For R40 the dual rank facility is still not so clear, so it's
> temporarily disabled.
>
> The 7th~9th patches enables support for DRAM initialization and SPL for
> the V3s SoC, which integrates a DDR2 chip.
>
> The 10th and 11th patches adds support for LPDDR3, with the stock boot0
> timing. (Seen in A83T boot0 source and some leaked H5/R40 libdram source)
>
> The 12th patches adds a defconfig for SoPine w/ official baseboard, which
> utilizes LPDDR3.
>
> Icenowy Zheng (12):
>   sunxi: makes an invisible option for H3-like DRAM controllers
>   sunxi: Rename bus-width related macros in H3 DRAM code
>   sunxi: add option for 16-bit DW DRAM controller
>   sunxi: add bank detection code to H3 DRAM initialization code
>   sunxi: Add selective DRAM type and timing
>   sunxi: enable dual rank detection in DesignWare-like DRAM code
>   sunxi: add support for the DDR2 in V3s SoC
>   sunxi: add support for V3s DRAM controller
>   sunxi: enable DRAM initialization and SPL for V3s SoC
>   sunxi: add LPDDR3 DRAM type support for DesignWare-like DRAM
> controller
>   sunxi: add LPDDR3 timing from stock boot0
>   sunxi: add a defconfig for SoPine w/ official baseboard

Can you rebase on master and sen it again, difficult to fix the things
while applying.

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH 12/12] sunxi: add a defconfig for SoPine w/ official baseboard

2017-06-02 Thread Jagan Teki
On Wed, Apr 26, 2017 at 8:20 PM, Icenowy Zheng <icen...@aosc.io> wrote:
> The SoPine is a SoM by Pine64, with an Allwinner A64 SoC, a LPDDR3 DRAM
> chip, an AXP803 PMIC, a SPI NOR Flash and a MicroSD slot. The card
> detect pin of the MicroSD slot is broken, however, it doesn't matter as
> the design of SoPine didn't allow hot-swapping the MicroSD card (The
> MicroSD slot is at the back of the SoM, and when the SoM is installed on
> the baseboard, it's nearly impossible to remove the MicroSD).
>
> The official baseboard of it is a board with nearly the same connectors
> with the original Pine64+, with the MicroUSB power jack replaced, and
> at the position of MicroSD slot a eMMC module slot is added.
>
> Add support for SoPine with the official baseboard by adding its
> defconfig file. It still uses the device tree of Pine64, however, it
> will change after a proper device tree of SoPine with baseboard is
> accepted by Linux mainline.
>
> Signed-off-by: Icenowy Zheng <icen...@aosc.io>
> ---
>  configs/sopine_baseboard_defconfig | 22 ++
>  1 file changed, 22 insertions(+)
>  create mode 100644 configs/sopine_baseboard_defconfig
>
> diff --git a/configs/sopine_baseboard_defconfig

Can't this be simply sopine_defconfig

Please add MAINTAINERS entry as well

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v2] sun50i: h5: Add initial Orangepi Prime support

2017-06-01 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Orangepi Prime is an open-source single-board computer
using the Allwinner h5 SOC.

H5 Orangepi Prime has
- Quad-core Cortex-A53
- 2GB DDR3
- Debug TTL UART
- 1000M/100M Ethernet RJ45
- Three USB 2.0
- HDMI
- Audio and MIC
- Wifi + BT
- IR receiver
- HDMI
- Wifi + BT

Boot from MMC:
-
U-Boot SPL 2017.05-00662-ga3f4c05-dirty (May 25 2017 - 13:30:14)
DRAM: 2048 MiB
Trying to boot from MMC1
NOTICE:  BL3-1: Running on H5 (1718) in SRAM A2 (@0x44000)
NOTICE:  Configuring SPC Controller
NOTICE:  BL3-1: v1.0(debug):aa75c8d
NOTICE:  BL3-1: Built : 18:28:27, May 24 2017
INFO:BL3-1: Initializing runtime services
INFO:BL3-1: Preparing for EL3 exit to normal world
INFO:BL3-1: Next image address: 0x4a00, SPSR: 0x3c9

U-Boot 2017.05-00662-ga3f4c05-dirty (May 25 2017 - 13:30:14 +) Allwinner 
Technology

CPU:   Allwinner H5 (SUN50I)
Model: OrangePi Prime
DRAM:  2 GiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment

In:serial
Out:   serial
Err:   serial
Net:   phy interface7
eth0: ethernet@1c3
starting USB...
USB0:   USB EHCI 1.00
USB1:   USB OHCI 1.0
scanning bus 0 for devices... 1 USB Device(s) found
   scanning usb for storage devices... 0 Storage Device(s) found
Hit any key to stop autoboot:  0

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Drop http link from commit message
- Drop CONFIG_CONSOLE_MUX

 arch/arm/dts/Makefile |   3 +-
 arch/arm/dts/sun50i-h5-orangepi-prime.dts | 104 ++
 board/sunxi/MAINTAINERS   |   5 ++
 configs/orangepi_prime_defconfig  |  16 +
 4 files changed, 127 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/dts/sun50i-h5-orangepi-prime.dts
 create mode 100644 configs/orangepi_prime_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 82671b3..b8ebd6e 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -315,7 +315,8 @@ dtb-$(CONFIG_MACH_SUN8I_R40) += \
 dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
-   sun50i-h5-orangepi-pc2.dtb
+   sun50i-h5-orangepi-pc2.dtb \
+   sun50i-h5-orangepi-prime.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
sun50i-a64-pine64-plus.dtb \
diff --git a/arch/arm/dts/sun50i-h5-orangepi-prime.dts 
b/arch/arm/dts/sun50i-h5-orangepi-prime.dts
new file mode 100644
index 000..67eade7
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-orangepi-prime.dts
@@ -0,0 +1,104 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "OrangePi Prime";
+   compatible = "xunlong,orangepi-prime", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdou

[linux-sunxi] Re: [U-Boot] [PATCH v3] sunxi: A64/Pine64: update device tree from Linux

2017-06-01 Thread Jagan Teki
On Mon, May 29, 2017 at 6:01 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> On Wed, May 24, 2017 at 3:04 PM, Andre Przywara <andre.przyw...@arm.com> 
> wrote:
>> The Linux device tree for the Allwinner A64 SoC has changed a lot since
>> the U-Boot version was merged.
>> Let's replace the current DT with a exact copy of the Linux one as of:
>> commit c6778ff813d2ca3e3c8733c87dc8b6831a64578b
>> Merge: 0ff4c01 3c0e3abd
>> Author: Linus Torvalds <torva...@linux-foundation.org>
>> Date:   Tue May 9 10:07:33 2017 -0700
>>
>> This is the DT used in Linux 4.12-rc1.
>>
>> Since U-Boot has an Ethernet driver (while Linux does not yet), we
>> provide the required DT nodes for it in an ...-u-boot.dtsi file, to both
>> mark them as U-Boot specific and to allow easier upgrading once Linux gets
>> the driver and its own binding later.
>> Compared to the existing Ethernet DT nodes we just slightly tweak the clock
>> and reset nodes in there to match the new bindings used by Linux for those.
>>
>> Signed-off-by: Andre Przywara <andre.przyw...@arm.com>
>> ---
>>  arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi|  50 ++
>
> Yeah, may be this need to be named something like
> sun50i-a64-u-boot.dtsi as of now? since it may share the similar dt on
> other a64 board that we initiate the discussion about orangepi, and
> BPI.
>
> All fine expect this name.
>
> Reviewed-by: Jagan Teki <ja...@amarulasolutions.com>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v3] sun50i: a64: Add initial Banana Pi M64 support

2017-06-01 Thread Jagan Teki
On Thu, Jun 1, 2017 at 2:23 AM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Wed, May 31, 2017 at 12:13:45PM +0000, Jagan Teki wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> BPI-M64 is a 64-bit quad-core mini single board computer
>> using the Allwinner A64 SOC.
>>
>> BPI-M64 features
>> - 1.2 Ghz Quad-Core ARM Cortex A53
>> - 2GB DDR3 SDRAM with 733MHz
>> - MicroSD/eMMC(8GB)
>> - 10/100/1000Mbps ethernet (Realtek RTL8211E/D)
>> - Wifi + BT
>> - IR receiver
>> - Audio In/Out
>> - Video In/Out
>> - 5V 2A DC power-supply
>>
>> For dts file,
>> Sync with Linux commit 4879b7ae("Merge tag 'dmaengine-4.12-rc1'").
>>
>> Boot from MMC:
>> -
>> U-Boot SPL 2017.05-00667-g85dd258-dirty (May 29 2017 - 13:07:31)
>> DRAM: 2048 MiB
>> Trying to boot from MMC1
>> NOTICE:  BL3-1: Running on A64/H64 (1689) in SRAM A2 (@0x44000)
>> NOTICE:  Configuring SPC Controller
>> NOTICE:  BL3-1: v1.0(debug):aa75c8d
>> NOTICE:  BL3-1: Built : 18:28:27, May 24 2017
>> NOTICE:  Configuring AXP PMIC
>> NOTICE:  PMIC: setup successful
>> INFO:BL3-1: Initializing runtime services
>> INFO:BL3-1: Preparing for EL3 exit to normal world
>> INFO:BL3-1: Next image address: 0x4a00, SPSR: 0x3c9
>>
>> U-Boot 2017.05-00667-g85dd258-dirty (May 29 2017 - 13:07:31 +) Allwinner 
>> Technology
>>
>> CPU:   Allwinner A64 (SUN50I)
>> Model: BananaPi-M64
>> DRAM:  2 GiB
>> MMC:   SUNXI SD/MMC: 0, SUNXI SD/MMC: 1
>> *** Warning - bad CRC, using default environment
>>
>> In:serial
>> Out:   serial
>> Err:   serial
>> Net:   No ethernet found.
>> starting USB...
>> No controllers found
>> Hit any key to stop autoboot:  0
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>
> Acked-by: Maxime Ripard <maxime.rip...@free-electrons.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v2 00/12] Big work on sunxi DW DRAM controllers and some new DDR type support

2017-06-08 Thread Jagan Teki
On Sat, Jun 3, 2017 at 2:40 PM, Icenowy Zheng <icen...@aosc.io> wrote:
> This patchset contains several works on the sunxi DesignWare DRAM
> controllers.
>
> The 1st patch made an option for H3-like DRAM controllers
> (DesignWare ones), which can ease further import of alike controllers.
>
> The 2nd and 3rd patches are for supporting 16-bit DW DRAM controllers,
> in order to add V3s DRAM support (The controller on V3s is 16-bit).
>
> The 4th patch adds bank detection code, in order to support some DDR2
> chips.
>
> The 5th patch adds a framework for select DRAM type and timing -- it's
> needed for boards that use DRAM chips rather than DDR3.
>
> The 6th patch enables dual rank detection in the DW DRAM code on SoCs
> except R40. For R40 the dual rank facility is still not so clear, so it's
> temporarily disabled.
>
> The 7th~9th patches enables support for DRAM initialization and SPL for
> the V3s SoC, which integrates a DDR2 chip.
>
> The 10th and 11th patches adds support for LPDDR3, with the stock boot0
> timing. (Seen in A83T boot0 source and some leaked H5/R40 libdram source)
>
> The 12th patches adds a defconfig for SoPine w/ official baseboard, which
> utilizes LPDDR3.
>
> Icenowy Zheng (12):
>   sunxi: makes an invisible option for H3-like DRAM controllers
>   sunxi: Rename bus-width related macros in H3 DRAM code
>   sunxi: add option for 16-bit DW DRAM controller
>   sunxi: add bank detection code to H3 DRAM initialization code
>   sunxi: Add selective DRAM type and timing
>   sunxi: enable dual rank detection in DesignWare-like DRAM code
>   sunxi: add support for the DDR2 in V3s SoC
>   sunxi: add support for V3s DRAM controller
>   sunxi: enable DRAM initialization and SPL for V3s SoC
>   sunxi: add LPDDR3 DRAM type support for DesignWare-like DRAM
> controller
>   sunxi: add LPDDR3 timing from stock boot0
>   sunxi: add a defconfig for SoPine w/ official baseboard

I think you forgot to add MAINTAINERS update which I commented
previous, anyway if you're OK I will add and apply the series?

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH 1/2] sun8i: h3: Add initial NanoPi M1 Plus support

2017-06-08 Thread Jagan Teki
On Thu, Jun 8, 2017 at 9:53 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> On Tue, May 30, 2017 at 11:11 PM, Jagan Teki <ja...@openedev.com> wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> NanoPi M1 Plus is designed and developed by FriendlyElec
>> for professionals, enterprise users, makers and hobbyists
>> using the Allwinner H3 SOC.
>>
>> NanoPi M1 Plus key features
>> - Allwinner H3, Quad-core Cortex-A7@1.2GHz
>> - 1GB DDR3 RAM
>> - 8GB eMMC
>> - microSD slot
>> - 10/100/1000M Ethernet
>> - Serial Debug Port
>> - 5V 2A DC power-supply
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCHi v2] sun50i: h5: Add initial NanoPi NEO2 support

2017-06-08 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi M1 Plus is designed and developed by FriendlyElec
using the Allwinner 64-bit H5 SOC.

NanoPi Neo2 key features
- Allwinner H5, Quad-core 64-bit Cortex-A53
- 512MB DDR3 RAM
- microSD slot
- 10/100/1000M Ethernet
- Serial Debug Port
- 5V 2A DC MicroUSB power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Drop CONSOLE_MUX
- Basci sync of Linux nanopi-neo2, since sun50i-h3.dtsi need 
  to sync from Linux
- Tested on Neo2

 arch/arm/dts/Makefile  |  1 +
 arch/arm/dts/sun50i-h5-nanopi-neo2.dts | 92 ++
 board/sunxi/MAINTAINERS|  5 ++
 configs/nanopi_neo2_defconfig  | 16 ++
 4 files changed, 114 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-h5-nanopi-neo2.dts
 create mode 100644 configs/nanopi_neo2_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 427cbab..f450baf 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -319,6 +319,7 @@ dtb-$(CONFIG_MACH_SUN8I_R40) += \
 dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
+   sun50i-h5-nanopi-neo2.dtb \
sun50i-h5-orangepi-pc2.dtb \
sun50i-h5-orangepi-prime.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
diff --git a/arch/arm/dts/sun50i-h5-nanopi-neo2.dts 
b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
new file mode 100644
index 000..727a3e6
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
@@ -0,0 +1,92 @@
+/*
+ * Copyright (C) 2017 Icenowy Zheng <icen...@aosc.io>
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi NEO 2";
+   compatible = "friendlyarm,nanopi-neo2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   memory {
+   reg = <0x4000 0x2000>;
+   };
+
+   soc {
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
+   status = "okay";
+};
+
+ {
+

[linux-sunxi] Re: [PATCH 1/2] sun8i: h3: Add initial NanoPi M1 Plus support

2017-06-08 Thread Jagan Teki
On Tue, May 30, 2017 at 11:11 PM, Jagan Teki <ja...@openedev.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> NanoPi M1 Plus is designed and developed by FriendlyElec
> for professionals, enterprise users, makers and hobbyists
> using the Allwinner H3 SOC.
>
> NanoPi M1 Plus key features
> - Allwinner H3, Quad-core Cortex-A7@1.2GHz
> - 1GB DDR3 RAM
> - 8GB eMMC
> - microSD slot
> - 10/100/1000M Ethernet
> - Serial Debug Port
> - 5V 2A DC power-supply
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>

Tested-by: Jagan Teki <ja...@amarulasolutions.com>

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [U-Boot] [PATCH v2 00/12] Big work on sunxi DW DRAM controllers and some new DDR type support

2017-06-08 Thread Jagan Teki
On Sat, Jun 3, 2017 at 2:40 PM, Icenowy Zheng <icen...@aosc.io> wrote:
> This patchset contains several works on the sunxi DesignWare DRAM
> controllers.
>
> The 1st patch made an option for H3-like DRAM controllers
> (DesignWare ones), which can ease further import of alike controllers.
>
> The 2nd and 3rd patches are for supporting 16-bit DW DRAM controllers,
> in order to add V3s DRAM support (The controller on V3s is 16-bit).
>
> The 4th patch adds bank detection code, in order to support some DDR2
> chips.
>
> The 5th patch adds a framework for select DRAM type and timing -- it's
> needed for boards that use DRAM chips rather than DDR3.
>
> The 6th patch enables dual rank detection in the DW DRAM code on SoCs
> except R40. For R40 the dual rank facility is still not so clear, so it's
> temporarily disabled.
>
> The 7th~9th patches enables support for DRAM initialization and SPL for
> the V3s SoC, which integrates a DDR2 chip.
>
> The 10th and 11th patches adds support for LPDDR3, with the stock boot0
> timing. (Seen in A83T boot0 source and some leaked H5/R40 libdram source)
>
> The 12th patches adds a defconfig for SoPine w/ official baseboard, which
> utilizes LPDDR3.
>
> Icenowy Zheng (12):
>   sunxi: makes an invisible option for H3-like DRAM controllers
>   sunxi: Rename bus-width related macros in H3 DRAM code
>   sunxi: add option for 16-bit DW DRAM controller
>   sunxi: add bank detection code to H3 DRAM initialization code
>   sunxi: Add selective DRAM type and timing
>   sunxi: enable dual rank detection in DesignWare-like DRAM code

Reviewed-by: Jagan Teki <ja...@amarulasolutions.com>

>   sunxi: add support for the DDR2 in V3s SoC

Acked-by: Jagan Teki <ja...@amarulasolutions.com>

>   sunxi: add support for V3s DRAM controller
>   sunxi: enable DRAM initialization and SPL for V3s SoC
>   sunxi: add LPDDR3 DRAM type support for DesignWare-like DRAM
> controller

Reviewed-by: Jagan Teki <ja...@amarulasolutions.com>

>   sunxi: add LPDDR3 timing from stock boot0

Acked-by: Jagan Teki <ja...@amarulasolutions.com>

>   sunxi: add a defconfig for SoPine w/ official baseboard

Reviewed-by: Jagan Teki <ja...@amarulasolutions.com>

Tested MMC boot in SoPine.

Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [linux-sunxi] Re: [PATCH] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-06-09 Thread Jagan Teki

On Friday 09 June 2017 08:22 PM, Maxime Ripard wrote:

On Fri, Jun 09, 2017 at 01:03:56PM +, Jagan Teki wrote:

From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>


Hmmm, I'm confused, didn't you just send that DT already?

Sorry, I forgot to add version number this is v3

Jagan.

--
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [linux-sunxi] Re: [PATCH v2] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-06-09 Thread Jagan Teki

On Friday 09 June 2017 08:21 PM, Maxime Ripard wrote:

Hi Jagan,

On Fri, Jun 09, 2017 at 12:40:52PM +, Jagan Teki wrote:

+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};


What is connected on that bus?


i2c1 connected with gpio/i2s




+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>, <_rts_cts_pins>;
+   status = "okay";
+};


And on that UART?


uart1 for SDIO (Wifi connector, with RTS/CTS), this along with mmc1

Jagan.

--
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v3 2/2] sun50i: a64: Add initial Orangepi Win/WinPlus support

2017-06-13 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Orangepi Win/WinPlus is an open-source single-board computer
using the Allwinner A64 SOC.

A64 Orangepi Win/WinPlus has
- A64 Quad-core Cortex-A53 64bit
- 1GB(Win)/2GB(Win Plus) DDR3 SDRAM
- Debug TTL UART
- Four USB 2.0
- HDMI
- LCD
- Audio and MIC
- Wifi + BT
- IR receiver
- 5V DC power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Drop memory node
- Remove /soc under regulator 
- Tested on board
Changes for v2:
- Drop CONSOLE_MUX
- Add SPL_SPI

 arch/arm/dts/Makefile|  1 +
 arch/arm/dts/sun50i-a64-orangepi-win.dts | 95 
 board/sunxi/MAINTAINERS  |  5 ++
 configs/orangepi_win_defconfig   | 16 ++
 4 files changed, 117 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-a64-orangepi-win.dts
 create mode 100644 configs/orangepi_win_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index a0b3704..a6eab75 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -324,6 +324,7 @@ dtb-$(CONFIG_MACH_SUN50I_H5) += \
sun50i-h5-orangepi-zero-plus2.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
+   sun50i-a64-orangepi-win.dtb \
sun50i-a64-pine64-plus.dtb \
sun50i-a64-pine64.dtb
 dtb-$(CONFIG_MACH_SUN9I) += \
diff --git a/arch/arm/dts/sun50i-a64-orangepi-win.dts 
b/arch/arm/dts/sun50i-a64-orangepi-win.dts
new file mode 100644
index 000..1f39e1c
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-orangepi-win.dts
@@ -0,0 +1,95 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "OrangePi Win/Win Plus";
+   compatible = "xunlong,orangepi-win", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>;
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index 314aee3..77d8d17 100644
--- a/board/sunxi/MAINTAINERS
+++ b/board/sunxi/

[linux-sunxi] [PATCH v2] sun50i: h5: Add initial NanoPi NEO2 support

2017-06-13 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi M1 Plus is designed and developed by FriendlyElec
using the Allwinner 64-bit H5 SOC.

NanoPi Neo2 key features
- Allwinner H5, Quad-core 64-bit Cortex-A53
- 512MB DDR3 RAM
- microSD slot
- 10/100/1000M Ethernet
- Serial Debug Port
- 5V 2A DC MicroUSB power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Droped memory node
- Remove /soc under regulator
- Tested on neo2

 arch/arm/dts/Makefile  |  1 +
 arch/arm/dts/sun50i-h5-nanopi-neo2.dts | 86 ++
 board/sunxi/MAINTAINERS|  5 ++
 configs/nanopi_neo2_defconfig  | 16 +++
 4 files changed, 108 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-h5-nanopi-neo2.dts
 create mode 100644 configs/nanopi_neo2_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index a6eab75..5d7432f 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -319,6 +319,7 @@ dtb-$(CONFIG_MACH_SUN8I_R40) += \
 dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
+   sun50i-h5-nanopi-neo2.dtb \
sun50i-h5-orangepi-pc2.dtb \
sun50i-h5-orangepi-prime.dtb \
sun50i-h5-orangepi-zero-plus2.dtb
diff --git a/arch/arm/dts/sun50i-h5-nanopi-neo2.dts 
b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
new file mode 100644
index 000..c08af78
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
@@ -0,0 +1,86 @@
+/*
+ * Copyright (C) 2017 Icenowy Zheng <icen...@aosc.io>
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi NEO 2";
+   compatible = "friendlyarm,nanopi-neo2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>;
+   status = "okay";
+};
diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index 77d8

[linux-sunxi] [PATCH v3 1/2] sun50i: h5: Add initial Orangepi Zero Plus 2 support

2017-06-13 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Orangepi Zero Plus 2 is an open-source single-board computer
using the Allwinner h5 SOC.

H5 Orangepi Zero Plus 2 has
- Quad-core Cortex-A53
- 512MB DDR3
- micrSD slot and 8GB eMMC
- Debug TTL UART
- HDMI
- Wifi + BT
- OTG+power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Drop memory node
- Remove /soc under regulator 
- Tested on board
Changes for v2:
- Drop CONSOLE_MUX
- Add emmc node

 arch/arm/dts/Makefile  |  3 +-
 arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts | 97 ++
 board/sunxi/MAINTAINERS|  5 ++
 configs/orangepi_zero_plus2_defconfig  | 18 +
 4 files changed, 122 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts
 create mode 100644 configs/orangepi_zero_plus2_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index ae55f78..a0b3704 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -320,7 +320,8 @@ dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
sun50i-h5-orangepi-pc2.dtb \
-   sun50i-h5-orangepi-prime.dtb
+   sun50i-h5-orangepi-prime.dtb \
+   sun50i-h5-orangepi-zero-plus2.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
sun50i-a64-pine64-plus.dtb \
diff --git a/arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts 
b/arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts
new file mode 100644
index 000..3f4baba
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts
@@ -0,0 +1,97 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+
+/ {
+   model = "OrangePi Zero Plus2";
+   compatible = "xunlong,orangepi-zero-plus2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <

[linux-sunxi] [PATCH 2/3] Board: Add Bananapi M2 Plus support

2017-06-17 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for bananapi M2 Plus board with below features:
- U-Boot 2017.07-rc1
- Linux 4.11.5
- Default packages from buildroot

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 DEVELOPERS   |  1 +
 board/bananapi/bananapi-m2-plus/boot.cmd |  7 ++
 board/bananapi/bananapi-m2-plus/genimage.cfg | 33 +
 board/bananapi/bananapi-m2-plus/readme.txt   | 34 ++
 configs/bananapi_m2_plus_defconfig   | 36 
 5 files changed, 111 insertions(+)
 create mode 100644 board/bananapi/bananapi-m2-plus/boot.cmd
 create mode 100644 board/bananapi/bananapi-m2-plus/genimage.cfg
 create mode 100644 board/bananapi/bananapi-m2-plus/readme.txt
 create mode 100644 configs/bananapi_m2_plus_defconfig

diff --git a/DEVELOPERS b/DEVELOPERS
index 341933f..4ccdc26 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -830,6 +830,7 @@ F:  package/keepalived/
 N:     Jagan Teki <ja...@amarulasolutions.com>
 F: board/bananapi/
 F: board/engicam/
+F: configs/bananapi_m2_plus_defconfig
 F: configs/bananapi_m64_defconfig
 F: configs/engicam_imx6qdl_icore_mmc_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_mmc_defconfig
diff --git a/board/bananapi/bananapi-m2-plus/boot.cmd 
b/board/bananapi/bananapi-m2-plus/boot.cmd
new file mode 100644
index 000..d22464a
--- /dev/null
+++ b/board/bananapi/bananapi-m2-plus/boot.cmd
@@ -0,0 +1,7 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+mmc dev 0
+fatload mmc 0 $kernel_addr_r zImage
+fatload mmc 0 $fdt_addr_r sun8i-h3-bananapi-m2-plus.dtb
+
+bootz $kernel_addr_r - $fdt_addr_r
diff --git a/board/bananapi/bananapi-m2-plus/genimage.cfg 
b/board/bananapi/bananapi-m2-plus/genimage.cfg
new file mode 100644
index 000..cde0669
--- /dev/null
+++ b/board/bananapi/bananapi-m2-plus/genimage.cfg
@@ -0,0 +1,33 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "zImage",
+   "sun8i-h3-bananapi-m2-plus.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot-sunxi-with-spl.bin"
+   offset = 8192
+   size = 1040384 # 1MB - 8192
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/bananapi/bananapi-m2-plus/readme.txt 
b/board/bananapi/bananapi-m2-plus/readme.txt
new file mode 100644
index 000..f699727
--- /dev/null
+++ b/board/bananapi/bananapi-m2-plus/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Bananapi M2 Plus. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Bananapi M2 Plus link:
+http://www.banana-pi.org/m2plus.html
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make bananapi_m2_plus_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Bananapi M2 Plus and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/configs/bananapi_m2_plus_defconfig 
b/configs/bananapi_m2_plus_defconfig
new file mode 100644
index 000..7d8baa9
--- /dev/null
+++ b/configs/bananapi_m2_plus_defconfig
@@ -0,0 +1,36 @@
+BR2_aarch64=y
+BR2_arm=y
+BR2_cortex_a7=y
+BR2_ARM_EABIHF=y
+
+# Linux headers same as kernel, a 4.11 series
+BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_11=y
+
+# Bootloader
+BR2_TARGET_UBOOT=y
+BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
+BR2_TARGET_UBOOT_CUSTOM_VERSION=y
+BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2017.07-rc1"
+BR2_TARGET_UBOOT_BOARD_DEFCONFIG="Sinovoip_BPI_M2_Plus"
+BR2_TARGET_UBOOT_NEEDS_DTC=y
+BR2_TARGET_UBOOT_FORMAT_BIN=y
+BR2_TARGET_UBOOT_SPL=y
+BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin"
+
+# Kernel
+BR2_LINUX_KERNEL=y
+BR2_LINUX_KERNEL_CUSTOM_VERSION=y
+BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.11.5"
+BR2_LINUX_KERNEL_DEFCONFIG="sunxi"
+BR2_LINUX_KE

[linux-sunxi] [PATCH 3/3] board: Add Pine64 support

2017-06-17 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for Pine64 board with below features:
- U-Boot 2017.07-rc1
- Linux 4.11.5
- Default packages from buildroot

Cc: Andre Przywara <andre.przyw...@arm.com>
Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 DEVELOPERS |  2 ++
 board/pine64/boot.cmd  |  6 ++
 board/pine64/genimage.cfg  | 38 ++
 board/pine64/post-build.sh | 10 ++
 board/pine64/readme.txt| 34 ++
 configs/pine64_defconfig   | 45 +
 6 files changed, 135 insertions(+)
 create mode 100644 board/pine64/boot.cmd
 create mode 100644 board/pine64/genimage.cfg
 create mode 100755 board/pine64/post-build.sh
 create mode 100644 board/pine64/readme.txt
 create mode 100644 configs/pine64_defconfig

diff --git a/DEVELOPERS b/DEVELOPERS
index 4ccdc26..54e9fb9 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -830,8 +830,10 @@ F: package/keepalived/
 N: Jagan Teki <ja...@amarulasolutions.com>
 F: board/bananapi/
 F: board/engicam/
+F: board/pine64/
 F: configs/bananapi_m2_plus_defconfig
 F: configs/bananapi_m64_defconfig
+F: configs/pine64_defconfig
 F: configs/engicam_imx6qdl_icore_mmc_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_mmc_defconfig
 F: configs/engicam_imx6ul_geam_mmc_defconfig
diff --git a/board/pine64/boot.cmd b/board/pine64/boot.cmd
new file mode 100644
index 000..14f5610
--- /dev/null
+++ b/board/pine64/boot.cmd
@@ -0,0 +1,6 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+fatload mmc 0 $kernel_addr_r Image
+fatload mmc 0 $fdt_addr_r sun50i-a64-pine64.dtb
+
+booti $kernel_addr_r - $fdt_addr_r
diff --git a/board/pine64/genimage.cfg b/board/pine64/genimage.cfg
new file mode 100644
index 000..8e12308
--- /dev/null
+++ b/board/pine64/genimage.cfg
@@ -0,0 +1,38 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "Image",
+   "sun50i-a64-pine64.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition spl {
+   in-partition-table = "no"
+   image = "sunxi-spl.bin"
+   offset = 8192
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot.itb"
+   offset = 40K
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/pine64/post-build.sh b/board/pine64/post-build.sh
new file mode 100755
index 000..d22bc3d
--- /dev/null
+++ b/board/pine64/post-build.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+# args from BR2_ROOTFS_POST_SCRIPT_ARGS
+# $4 path of boot.cmd
+
+MKIMAGE=${HOST_DIR}/usr/bin/mkimage
+BOOT_CMD="${4}"
+BOOT_CMD_H="${BINARIES_DIR}/boot.scr"
+
+# U-Boot script
+"${MKIMAGE}" -C none -A arm -T script -d "${BOOT_CMD}" "${BOOT_CMD_H}"
diff --git a/board/pine64/readme.txt b/board/pine64/readme.txt
new file mode 100644
index 000..e41f9ca
--- /dev/null
+++ b/board/pine64/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Pine64. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Pine64 link:
+https://www.pine64.org/?page_id=1194
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make pine64_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Pine64 and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/configs/pine64_defconfig b/configs/pine64_defconfig
new file mode 100644
index 000..43437fb
--- /dev/null
+++ b/configs/pine64_defconfig
@@ -0,0 +1,45 @@
+BR2_aarch64=y
+BR2_cortex_a53=y
+BR2_ARM_FPU_VFPV4=y
+BR2_TOOLCHAIN_BUILDROOT_CXX=y
+
+# Linux headers same as kernel, a 4.11 series
+BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_11=y
+
+# Firmware
+BR2_TARGET_ARM_TRUSTED_FIRMWARE=y
+BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_GIT=y
+BR2_TARGET_ARM_TR

[linux-sunxi] [PATCH v2] arm64: allwinner: h5: Add initial Orangepi Zero Plus 2 support

2017-06-10 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Orangepi Zero Plus 2 is an open-source single-board computer
using the Allwinner h5 SOC.

H5 Orangepi Zero Plus 2 has
- Quad-core Cortex-A53
- 512MB DDR3
- micrSD slot and 8GB eMMC
- Debug TTL UART
- HDMI
- Wifi + BT
- OTG+power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Add emmc node

 arch/arm64/boot/dts/allwinner/Makefile |  1 +
 .../allwinner/sun50i-h5-orangepi-zero-plus2.dts| 98 ++
 2 files changed, 99 insertions(+)
 create mode 100644 
arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index 1ea7709..8adba9c 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -4,6 +4,7 @@ dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb 
sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-pc2.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-prime.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-zero-plus2.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-nanopi-neo2.dtb
 
 always := $(dtb-y)
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts
new file mode 100644
index 000..6136a3f
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts
@@ -0,0 +1,98 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "OrangePi Zero Plus2";
+   compatible = "xunlong,orangepi-zero-plus2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   memory {
+   reg = <0x4000 0x2000>;
+   };
+
+   soc {
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_8bit_pins>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <8>;
+   non-removable;
+   cap-mmc-hw-reset;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   

[linux-sunxi] [PATCH v2] sun50i: h5: Add initial Orangepi Zero Plus 2 support

2017-06-10 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Orangepi Zero Plus 2 is an open-source single-board computer
using the Allwinner h5 SOC.

H5 Orangepi Zero Plus 2 has
- Quad-core Cortex-A53
- 512MB DDR3
- micrSD slot and 8GB eMMC
- Debug TTL UART
- HDMI
- Wifi + BT
- OTG+power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Drop CONSOLE_MUX
- Add emmc node

 arch/arm/dts/Makefile  |   3 +-
 arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts | 103 +
 board/sunxi/MAINTAINERS|   5 ++
 configs/orangepi_zero_plus2_defconfig  |  18 +
 4 files changed, 128 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts
 create mode 100644 configs/orangepi_zero_plus2_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 427cbab..f7ad613 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -320,7 +320,8 @@ dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
sun50i-h5-orangepi-pc2.dtb \
-   sun50i-h5-orangepi-prime.dtb
+   sun50i-h5-orangepi-prime.dtb \
+   sun50i-h5-orangepi-zero-plus2.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
sun50i-a64-nanopi-a64.dtb \
diff --git a/arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts 
b/arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts
new file mode 100644
index 000..109afdf
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-orangepi-zero-plus2.dts
@@ -0,0 +1,103 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+
+/ {
+   model = "OrangePi Zero Plus2";
+   compatible = "xunlong,orangepi-zero-plus2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   memory {
+   reg = <0x4000 0x2000>;
+   };
+
+   soc {
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinc

[linux-sunxi] [PATCH v3 2/2] sun50i: a64: Add initial NanoPi A64 support

2017-06-09 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Added ohci0, ehci0, ohic1, ehci1, usbphy, mmc1 and uart1 nodes
 
 arch/arm/dts/Makefile  |   1 +
 arch/arm/dts/sun50i-a64-nanopi-a64.dts | 130 +
 board/sunxi/MAINTAINERS|   5 ++
 configs/nanopi_a64_defconfig   |  15 
 4 files changed, 151 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-a64-nanopi-a64.dts
 create mode 100644 configs/nanopi_a64_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index ae55f78..427cbab 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -323,6 +323,7 @@ dtb-$(CONFIG_MACH_SUN50I_H5) += \
sun50i-h5-orangepi-prime.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
+   sun50i-a64-nanopi-a64.dtb \
sun50i-a64-pine64-plus.dtb \
sun50i-a64-pine64.dtb
 dtb-$(CONFIG_MACH_SUN9I) += \
diff --git a/arch/arm/dts/sun50i-a64-nanopi-a64.dts 
b/arch/arm/dts/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..fd643da
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,130 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+

[linux-sunxi] [PATCH v3 1/2] sun50i: a64: Sync Linux [oe]hci0 nodes

2017-06-09 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Synced ohci0 and ehci0 nodes from Linux for sun50i-a64.dtsi

Here is the Linux last merge tag details:
Merge: 0e91f43d e5770b7
Author: Stephen Rothwell <s...@canb.auug.org.au>
Date:   Fri Jun 9 14:59:55 2017 +1000

Merge remote-tracking branch 'staging/staging-next'

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- new patch

 arch/arm/dts/sun50i-a64.dtsi | 22 ++
 1 file changed, 22 insertions(+)

diff --git a/arch/arm/dts/sun50i-a64.dtsi b/arch/arm/dts/sun50i-a64.dtsi
index c7f669f..65a344d 100644
--- a/arch/arm/dts/sun50i-a64.dtsi
+++ b/arch/arm/dts/sun50i-a64.dtsi
@@ -204,6 +204,28 @@
#phy-cells = <1>;
};
 
+   ehci0: usb@01c1a000 {
+   compatible = "allwinner,sun50i-a64-ehci", 
"generic-ehci";
+   reg = <0x01c1a000 0x100>;
+   interrupts = ;
+   clocks = < CLK_BUS_OHCI0>,
+< CLK_BUS_EHCI0>,
+< CLK_USB_OHCI0>;
+   resets = < RST_BUS_OHCI0>,
+< RST_BUS_EHCI0>;
+   status = "disabled";
+   };
+
+   ohci0: usb@01c1a400 {
+   compatible = "allwinner,sun50i-a64-ohci", 
"generic-ohci";
+   reg = <0x01c1a400 0x100>;
+   interrupts = ;
+   clocks = < CLK_BUS_OHCI0>,
+< CLK_USB_OHCI0>;
+   resets = < RST_BUS_OHCI0>;
+   status = "disabled";
+   };
+
ehci1: usb@01c1b000 {
compatible = "allwinner,sun50i-a64-ehci", 
"generic-ehci";
reg = <0x01c1b000 0x100>;
-- 
2.7.4

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v4 2/2] sun50i: a64: Add initial NanoPi A64 support

2017-06-09 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v4:
- Added serial1 alias
- Fix to use mmc1 for SDIO instead of mmc2
- Replace buswidth by 4 instead of 8 mmc1
- Drop cap-mmc-hw-reset for mmc1
Changes for v3:
- Added ohci0, ehci0, ohic1, ehci1, usbphy, mmc1 and uart1 nodes

 arch/arm/dts/Makefile  |   1 +
 arch/arm/dts/sun50i-a64-nanopi-a64.dts | 130 +
 board/sunxi/MAINTAINERS|   5 ++
 configs/nanopi_a64_defconfig   |  15 
 4 files changed, 151 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-a64-nanopi-a64.dts
 create mode 100644 configs/nanopi_a64_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index ae55f78..427cbab 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -323,6 +323,7 @@ dtb-$(CONFIG_MACH_SUN50I_H5) += \
sun50i-h5-orangepi-prime.dtb
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
+   sun50i-a64-nanopi-a64.dtb \
sun50i-a64-pine64-plus.dtb \
sun50i-a64-pine64.dtb
 dtb-$(CONFIG_MACH_SUN9I) += \
diff --git a/arch/arm/dts/sun50i-a64-nanopi-a64.dts 
b/arch/arm/dts/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..d56736d
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,130 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;

[linux-sunxi] [PATCH] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-06-09 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Fix to use mmc1 for SDIO instead of mmc2
- Replace buswidth by 4 instead of 8 mmc1
- Drop cap-mmc-hw-reset for mmc1
Changes for v2:
- Added ohci0, ehci0, ohic1, ehci1, usbphy.
- Tested on A64

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 130 +
 2 files changed, 131 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index e7d5490..1ea7709 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,4 +1,5 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-pc2.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..d56736d
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,130 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+ 

[linux-sunxi] [PATCH] arm64: allwinner: sun50i-a64: Remove duplicate ethernet@1c30000

2017-06-09 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Remove duplicate ethernet@1c3 from allwinner/sun50i-a64.dtsi

Build error:
arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dtb:
ERROR (duplicate_node_names): Duplicate node name /soc/ethernet@1c3
ERROR: Input tree has errors, aborting (use -f to force output)

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 20 
 1 file changed, 20 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi 
b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index 1b36aab..9d00622 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -469,26 +469,6 @@
};
};
 
-   emac: ethernet@1c3 {
-   compatible = "allwinner,sun50i-a64-emac";
-   syscon = <>;
-   reg = <0x01c3 0x100>;
-   interrupts = ;
-   interrupt-names = "macirq";
-   resets = < RST_BUS_EMAC>;
-   reset-names = "stmmaceth";
-   clocks = < CLK_BUS_EMAC>;
-   clock-names = "stmmaceth";
-   status = "disabled";
-   #address-cells = <1>;
-   #size-cells = <0>;
-
-   mdio: mdio {
-   #address-cells = <1>;
-   #size-cells = <0>;
-   };
-   };
-
gic: interrupt-controller@1c81000 {
compatible = "arm,gic-400";
reg = <0x01c81000 0x1000>,
-- 
1.9.1

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v2] arm64: allwinner: a64: Add initial NanoPi A64 support

2017-06-09 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi A64 is a new board of high performance with low cost
designed by FriendlyElec., using the Allwinner A64 SOC.

Nanopi A64 features
- Allwinner A64, 64-bit Quad-core Cortex-A53@648MHz to 1.152GHz, DVFS
- 1GB DDR3 RAM
- MicroSD
- Gigabit Ethernet (RTL8211E)
- Wi-Fi 802.11b/g/n
- IR receiver
- Audio In/Out
- Video In/Out
- Serial Debug Port
- microUSB 5V 2A DC power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- Added ohci0, ehci0, ohic1, ehci1, usbphy.
- Tested on A64

 arch/arm64/boot/dts/allwinner/Makefile |   1 +
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts   | 131 +
 2 files changed, 132 insertions(+)
 create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
b/arch/arm64/boot/dts/allwinner/Makefile
index e7d5490..1ea7709 100644
--- a/arch/arm64/boot/dts/allwinner/Makefile
+++ b/arch/arm64/boot/dts/allwinner/Makefile
@@ -1,4 +1,5 @@
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-bananapi-m64.dtb
+dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-nanopi-a64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb sun50i-a64-pine64.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-pc2.dtb
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts 
b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
new file mode 100644
index 000..aa0b17c
--- /dev/null
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -0,0 +1,131 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi A64";
+   compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+  

Re: [linux-sunxi] [PATCH RFC] sun50i: a64: Add A64-OLinuXino initial support

2017-06-12 Thread Jagan Teki



On Monday 12 June 2017 01:21 PM, Vincent Legoll wrote:

Hello,

On Mon, Jun 12, 2017 at 9:23 AM, Jagan Teki <jagannadh.t...@gmail.com> wrote:

From: Jagan Teki <ja...@amarulasolutions.com>

OLimex A64-OLinuXino is an open-source hardware board
using the Allwinner A64 SOC.

A64 Orangepi Win/WinPlus has


Cut'n'pasted ? This does not look like $SUBJECT, or are those boards related ?


Bad paste :) will fix.

--
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH RFC] sun50i: a64: Add A64-OLinuXino initial support

2017-06-12 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

OLimex A64-OLinuXino is an open-source hardware board
using the Allwinner A64 SOC.

A64 Orangepi Win/WinPlus has
- A64 Quad-core Cortex-A53 64bit
- 1GB or 2GB RAM DDR3L @ 672Mhz
- microSD slot and 16GB eMMC
- Debug TTL UART
- HDMI
- LCD
- IR receiver
- 5V DC power supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Note:
- Need to test on hardware.

 arch/arm/dts/Makefile |   1 +
 arch/arm/dts/sun50i-a64-olinuxino.dts | 120 ++
 board/sunxi/MAINTAINERS   |   5 ++
 configs/a64-olinuxino_defconfig   |  17 +
 4 files changed, 143 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-a64-olinuxino.dts
 create mode 100644 configs/a64-olinuxino_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index e945640..1360e81 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -325,6 +325,7 @@ dtb-$(CONFIG_MACH_SUN50I_H5) += \
 dtb-$(CONFIG_MACH_SUN50I) += \
sun50i-a64-bananapi-m64.dtb \
sun50i-a64-nanopi-a64.dtb \
+   sun50i-a64-olinuxino.dtb \
sun50i-a64-orangepi-win.dtb \
sun50i-a64-pine64-plus.dtb \
sun50i-a64-pine64.dtb
diff --git a/arch/arm/dts/sun50i-a64-olinuxino.dts 
b/arch/arm/dts/sun50i-a64-olinuxino.dts
new file mode 100644
index 000..bd6d676
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-olinuxino.dts
@@ -0,0 +1,120 @@
+/*
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-a64.dtsi"
+
+#include 
+
+/ {
+   model = "Olimex A64-Olinuxino";
+   compatible = "olimex,a64-olinuxino", "allwinner,sun50i-a64";
+
+   aliases {
+   serial0 = 
+   serial1 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "okay";
+};
+
+_pins {
+   bias-pull-up;
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_HIGH>;
+   cd-inverted;
+   disable-wp;
+   bus-width = <4>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   non-removable;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = &

Re: [linux-sunxi] Re: [PATCH 2/2] ARM: sunxi: add support for Sinlinx SinA83T

2017-06-11 Thread Jagan Teki

On Friday 09 June 2017 11:07 PM, Ziping Chen wrote:
Previously I did not submit the patch to linux because of the missing 
a83t's DT support of Linux...

And I saw Bananapi M3 haven't been supported for Linux, but for U-Boot.


U-Boot has BPI M3, configs/Sinovoip_BPI_M3_defconfig



Well, now I will try to fix up the a83t's DT support for Linux, and then 
submitted it to uboot.


BTW, I found that the U-Boot's DT is a little different from the Linux's 
DT. Sometime I should adjust the DT file slightly to make it compatible 
for each other. For exmaple, Linux now uses "sun8i-h3-h5.dtsi" and 
"sun8i-h3.dtsi" for a h3 device, while U-Boot only uses "sun8i-h3.dtsi".


Yes, we did some recent addition sun50i-h5.dtsi ie in-line with Linux. 
So more can add anytime to sync with Linux.


Jagan.

--
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v2] arm64: allwinner: h5: Add initial Orangepi Zero Plus 2 support

2017-06-12 Thread Jagan Teki
On Mon, Jun 12, 2017 at 2:08 PM, Maxime Ripard
<maxime.rip...@free-electrons.com> wrote:
> On Sat, Jun 10, 2017 at 06:27:54PM +0530, Jagan Teki wrote:
>> From: Jagan Teki <ja...@amarulasolutions.com>
>>
>> Orangepi Zero Plus 2 is an open-source single-board computer
>> using the Allwinner h5 SOC.
>>
>> H5 Orangepi Zero Plus 2 has
>> - Quad-core Cortex-A53
>> - 512MB DDR3
>> - micrSD slot and 8GB eMMC
>> - Debug TTL UART
>> - HDMI
>> - Wifi + BT
>> - OTG+power supply
>>
>> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
>> ---
>> Changes for v2:
>> - Add emmc node
>>
>>  arch/arm64/boot/dts/allwinner/Makefile |  1 +
>>  .../allwinner/sun50i-h5-orangepi-zero-plus2.dts| 98 
>> ++
>>  2 files changed, 99 insertions(+)
>>  create mode 100644 
>> arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts
>>
>> diff --git a/arch/arm64/boot/dts/allwinner/Makefile 
>> b/arch/arm64/boot/dts/allwinner/Makefile
>> index 1ea7709..8adba9c 100644
>> --- a/arch/arm64/boot/dts/allwinner/Makefile
>> +++ b/arch/arm64/boot/dts/allwinner/Makefile
>> @@ -4,6 +4,7 @@ dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-pine64-plus.dtb 
>> sun50i-a64-pine64.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-sopine-baseboard.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-pc2.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-prime.dtb
>> +dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-orangepi-zero-plus2.dtb
>>  dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-nanopi-neo2.dtb
>>
>>  always   := $(dtb-y)
>> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts 
>> b/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts
>> new file mode 100644
>> index 000..6136a3f
>> --- /dev/null
>> +++ b/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-zero-plus2.dts
>> @@ -0,0 +1,98 @@
>> +/*
>> + * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
>> + *
>> + * This file is dual-licensed: you can use it either under the terms
>> + * of the GPL or the X11 license, at your option. Note that this dual
>> + * licensing only applies to this file, and not this project as a
>> + * whole.
>> + *
>> + *  a) This library is free software; you can redistribute it and/or
>> + * modify it under the terms of the GNU General Public License as
>> + * published by the Free Software Foundation; either version 2 of the
>> + * License, or (at your option) any later version.
>> + *
>> + * This library is distributed in the hope that it will be useful,
>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>> + * GNU General Public License for more details.
>> + *
>> + * Or, alternatively,
>> + *
>> + *  b) Permission is hereby granted, free of charge, to any person
>> + * obtaining a copy of this software and associated documentation
>> + * files (the "Software"), to deal in the Software without
>> + * restriction, including without limitation the rights to use,
>> + * copy, modify, merge, publish, distribute, sublicense, and/or
>> + * sell copies of the Software, and to permit persons to whom the
>> + * Software is furnished to do so, subject to the following
>> + * conditions:
>> + *
>> + * The above copyright notice and this permission notice shall be
>> + * included in all copies or substantial portions of the Software.
>> + *
>> + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
>> + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
>> + * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
>> + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
>> + * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
>> + * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
>> + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
>> + * OTHER DEALINGS IN THE SOFTWARE.
>> + */
>> +
>> +/dts-v1/;
>> +
>> +#include "sun50i-h5.dtsi"
>> +
>> +#include 
>> +
>> +/ {
>> + model = "OrangePi Zero Plus2";
>> + compatible = "xunlong,orangepi-zero-plus2", "allwinner,sun50i-h5";
>> +
>> + aliases {
>> + serial0 = 
>> + };
>> +
>> +

[linux-sunxi] [PATCH v3] sun50i: h5: Add initial NanoPi NEO2 support

2017-06-14 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

NanoPi NEO2 is designed and developed by FriendlyElec
using the Allwinner 64-bit H5 SOC.

NanoPi Neo2 key features
- Allwinner H5, Quad-core 64-bit Cortex-A53
- 512MB DDR3 RAM
- microSD slot
- 10/100/1000M Ethernet
- Serial Debug Port
- 5V 2A DC MicroUSB power-supply

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
Tested-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v3:
- Fix Copy'n'paste error in commit message
Changes for v2:
- Droped memory node
- Remove /soc under regulator
- Tested on neo2 

 arch/arm/dts/Makefile  |  1 +
 arch/arm/dts/sun50i-h5-nanopi-neo2.dts | 86 ++
 board/sunxi/MAINTAINERS|  5 ++
 configs/nanopi_neo2_defconfig  | 16 +++
 4 files changed, 108 insertions(+)
 create mode 100644 arch/arm/dts/sun50i-h5-nanopi-neo2.dts
 create mode 100644 configs/nanopi_neo2_defconfig

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index a6eab75..5d7432f 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -319,6 +319,7 @@ dtb-$(CONFIG_MACH_SUN8I_R40) += \
 dtb-$(CONFIG_MACH_SUN8I_V3S) += \
sun8i-v3s-licheepi-zero.dtb
 dtb-$(CONFIG_MACH_SUN50I_H5) += \
+   sun50i-h5-nanopi-neo2.dtb \
sun50i-h5-orangepi-pc2.dtb \
sun50i-h5-orangepi-prime.dtb \
sun50i-h5-orangepi-zero-plus2.dtb
diff --git a/arch/arm/dts/sun50i-h5-nanopi-neo2.dts 
b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
new file mode 100644
index 000..c08af78
--- /dev/null
+++ b/arch/arm/dts/sun50i-h5-nanopi-neo2.dts
@@ -0,0 +1,86 @@
+/*
+ * Copyright (C) 2017 Icenowy Zheng <icen...@aosc.io>
+ * Copyright (C) 2017 Jagan Teki <jt...@openedev.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include "sun50i-h5.dtsi"
+
+#include 
+
+/ {
+   model = "FriendlyARM NanoPi NEO 2";
+   compatible = "friendlyarm,nanopi-neo2", "allwinner,sun50i-h5";
+
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+
+   reg_vcc3v3: vcc3v3 {
+   compatible = "regulator-fixed";
+   regulator-name = "vcc3v3";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   };
+};
+
+ {
+   compatible = "allwinner,sun50i-h5-mmc",
+"allwinner,sun50i-a64-mmc",
+"allwinner,sun5i-a13-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>;
+   status = "okay";
+};
diff --g

[linux-sunxi] Re: [PATCH v3 1/2] sun50i: h5: Add initial Orangepi Zero Plus 2 support

2017-06-16 Thread Jagan Teki
On Tue, Jun 13, 2017 at 3:38 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> Orangepi Zero Plus 2 is an open-source single-board computer
> using the Allwinner h5 SOC.
>
> H5 Orangepi Zero Plus 2 has
> - Quad-core Cortex-A53
> - 512MB DDR3
> - micrSD slot and 8GB eMMC
> - Debug TTL UART
> - HDMI
> - Wifi + BT
> - OTG+power supply
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v3] sun50i: h5: Add initial NanoPi NEO2 support

2017-06-16 Thread Jagan Teki
On Wed, Jun 14, 2017 at 8:30 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> NanoPi NEO2 is designed and developed by FriendlyElec
> using the Allwinner 64-bit H5 SOC.
>
> NanoPi Neo2 key features
> - Allwinner H5, Quad-core 64-bit Cortex-A53
> - 512MB DDR3 RAM
> - microSD slot
> - 10/100/1000M Ethernet
> - Serial Debug Port
> - 5V 2A DC MicroUSB power-supply
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] Re: [PATCH v3 2/2] sun50i: a64: Add initial Orangepi Win/WinPlus support

2017-06-16 Thread Jagan Teki
On Tue, Jun 13, 2017 at 3:38 PM, Jagan Teki <jagannadh.t...@gmail.com> wrote:
> From: Jagan Teki <ja...@amarulasolutions.com>
>
> Orangepi Win/WinPlus is an open-source single-board computer
> using the Allwinner A64 SOC.
>
> A64 Orangepi Win/WinPlus has
> - A64 Quad-core Cortex-A53 64bit
> - 1GB(Win)/2GB(Win Plus) DDR3 SDRAM
> - Debug TTL UART
> - Four USB 2.0
> - HDMI
> - LCD
> - Audio and MIC
> - Wifi + BT
> - IR receiver
> - 5V DC power supply
>
> Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
> Tested-by: Jagan Teki <ja...@amarulasolutions.com>

Applied to u-boot-sunxi/master

thanks!
-- 
Jagan Teki
Free Software Engineer | www.openedev.com
U-Boot, Linux | Upstream Maintainer
Hyderabad, India.

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[linux-sunxi] [PATCH v2 3/3] board: Add Pine64 support

2017-06-18 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for Pine64 board with below features:
- U-Boot 2017.07-rc1
- Linux 4.11.5
- Default packages from buildroot

Cc: Andre Przywara <andre.przyw...@arm.com>
Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- none

 DEVELOPERS |  2 ++
 board/pine64/boot.cmd  |  6 ++
 board/pine64/genimage.cfg  | 38 ++
 board/pine64/post-build.sh | 10 ++
 board/pine64/readme.txt| 34 ++
 configs/pine64_defconfig   | 45 +
 6 files changed, 135 insertions(+)
 create mode 100644 board/pine64/boot.cmd
 create mode 100644 board/pine64/genimage.cfg
 create mode 100755 board/pine64/post-build.sh
 create mode 100644 board/pine64/readme.txt
 create mode 100644 configs/pine64_defconfig

diff --git a/DEVELOPERS b/DEVELOPERS
index 4ccdc26..54e9fb9 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -830,8 +830,10 @@ F: package/keepalived/
 N: Jagan Teki <ja...@amarulasolutions.com>
 F: board/bananapi/
 F: board/engicam/
+F: board/pine64/
 F: configs/bananapi_m2_plus_defconfig
 F: configs/bananapi_m64_defconfig
+F: configs/pine64_defconfig
 F: configs/engicam_imx6qdl_icore_mmc_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_mmc_defconfig
 F: configs/engicam_imx6ul_geam_mmc_defconfig
diff --git a/board/pine64/boot.cmd b/board/pine64/boot.cmd
new file mode 100644
index 000..14f5610
--- /dev/null
+++ b/board/pine64/boot.cmd
@@ -0,0 +1,6 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+fatload mmc 0 $kernel_addr_r Image
+fatload mmc 0 $fdt_addr_r sun50i-a64-pine64.dtb
+
+booti $kernel_addr_r - $fdt_addr_r
diff --git a/board/pine64/genimage.cfg b/board/pine64/genimage.cfg
new file mode 100644
index 000..8e12308
--- /dev/null
+++ b/board/pine64/genimage.cfg
@@ -0,0 +1,38 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "Image",
+   "sun50i-a64-pine64.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition spl {
+   in-partition-table = "no"
+   image = "sunxi-spl.bin"
+   offset = 8192
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot.itb"
+   offset = 40K
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/pine64/post-build.sh b/board/pine64/post-build.sh
new file mode 100755
index 000..d22bc3d
--- /dev/null
+++ b/board/pine64/post-build.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+# args from BR2_ROOTFS_POST_SCRIPT_ARGS
+# $4 path of boot.cmd
+
+MKIMAGE=${HOST_DIR}/usr/bin/mkimage
+BOOT_CMD="${4}"
+BOOT_CMD_H="${BINARIES_DIR}/boot.scr"
+
+# U-Boot script
+"${MKIMAGE}" -C none -A arm -T script -d "${BOOT_CMD}" "${BOOT_CMD_H}"
diff --git a/board/pine64/readme.txt b/board/pine64/readme.txt
new file mode 100644
index 000..e41f9ca
--- /dev/null
+++ b/board/pine64/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Pine64. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Pine64 link:
+https://www.pine64.org/?page_id=1194
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make pine64_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Pine64 and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/configs/pine64_defconfig b/configs/pine64_defconfig
new file mode 100644
index 000..43437fb
--- /dev/null
+++ b/configs/pine64_defconfig
@@ -0,0 +1,45 @@
+BR2_aarch64=y
+BR2_cortex_a53=y
+BR2_ARM_FPU_VFPV4=y
+BR2_TOOLCHAIN_BUILDROOT_CXX=y
+
+# Linux headers same as kernel, a 4.11 series
+BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_11=y
+
+# Firmware
+BR2_TARGET_ARM_TRUSTED_FIRMWARE=y
+BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_GIT=y
+BR2_TA

[linux-sunxi] [PATCH v2 1/3] Board: Add Bananapi M64 support

2017-06-18 Thread Jagan Teki
From: Jagan Teki <ja...@amarulasolutions.com>

Add initial support for bananapi M64 board with below features:
- U-Boot 2017.07-rc1
- Linux 4.11.5
- Default packages from buildroot

Signed-off-by: Jagan Teki <ja...@amarulasolutions.com>
---
Changes for v2:
- none

 DEVELOPERS   |  2 ++
 board/bananapi/bananapi-m64/boot.cmd |  6 +
 board/bananapi/bananapi-m64/genimage.cfg | 38 +++
 board/bananapi/bananapi-m64/readme.txt   | 34 
 board/bananapi/post-build.sh | 10 +++
 configs/bananapi_m64_defconfig   | 45 
 6 files changed, 135 insertions(+)
 create mode 100644 board/bananapi/bananapi-m64/boot.cmd
 create mode 100644 board/bananapi/bananapi-m64/genimage.cfg
 create mode 100644 board/bananapi/bananapi-m64/readme.txt
 create mode 100755 board/bananapi/post-build.sh
 create mode 100644 configs/bananapi_m64_defconfig

diff --git a/DEVELOPERS b/DEVELOPERS
index b4ffb6f..341933f 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -828,7 +828,9 @@ N:  Ilias Apalodimas <apa...@gmail.com>
 F: package/keepalived/
 
 N: Jagan Teki <ja...@amarulasolutions.com>
+F: board/bananapi/
 F: board/engicam/
+F: configs/bananapi_m64_defconfig
 F: configs/engicam_imx6qdl_icore_mmc_defconfig
 F: configs/engicam_imx6qdl_icore_rqs_mmc_defconfig
 F: configs/engicam_imx6ul_geam_mmc_defconfig
diff --git a/board/bananapi/bananapi-m64/boot.cmd 
b/board/bananapi/bananapi-m64/boot.cmd
new file mode 100644
index 000..d35c9b0
--- /dev/null
+++ b/board/bananapi/bananapi-m64/boot.cmd
@@ -0,0 +1,6 @@
+setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
+
+fatload mmc 0 $kernel_addr_r Image
+fatload mmc 0 $fdt_addr_r sun50i-a64-bananapi-m64.dtb
+
+booti $kernel_addr_r - $fdt_addr_r
diff --git a/board/bananapi/bananapi-m64/genimage.cfg 
b/board/bananapi/bananapi-m64/genimage.cfg
new file mode 100644
index 000..891217c
--- /dev/null
+++ b/board/bananapi/bananapi-m64/genimage.cfg
@@ -0,0 +1,38 @@
+image boot.vfat {
+   vfat {
+   files = {
+   "Image",
+   "sun50i-a64-bananapi-m64.dtb",
+   "boot.scr"
+   }
+   }
+   size = 64M
+}
+
+image sdcard.img {
+   hdimage {
+   }
+
+   partition spl {
+   in-partition-table = "no"
+   image = "sunxi-spl.bin"
+   offset = 8192
+   }
+
+   partition u-boot {
+   in-partition-table = "no"
+   image = "u-boot.itb"
+   offset = 40K
+   }
+
+   partition boot {
+   partition-type = 0xC
+   bootable = "true"
+   image = "boot.vfat"
+   }
+
+   partition rootfs {
+   partition-type = 0x83
+   image = "rootfs.ext4"
+   }
+}
diff --git a/board/bananapi/bananapi-m64/readme.txt 
b/board/bananapi/bananapi-m64/readme.txt
new file mode 100644
index 000..389ffbe
--- /dev/null
+++ b/board/bananapi/bananapi-m64/readme.txt
@@ -0,0 +1,34 @@
+Intro
+=
+
+This default configuration will allow you to start experimenting with the
+buildroot environment for the Bananapi M64. With the current configuration
+it will bring-up the board, and allow access through the serial console.
+
+Bananapi M64 link:
+http://www.banana-pi.org/m64.html
+
+This configuration uses U-Boot mainline and kernel mainline.
+
+How to build
+
+
+$ make bananapi_m64_defconfig
+$ make
+
+Note: you will need access to the internet to download the required
+sources.
+
+How to write the SD card
+
+
+Once the build process is finished you will have an image called "sdcard.img"
+in the output/images/ directory.
+
+Copy the bootable "sdcard.img" onto an SD card with "dd":
+
+  $ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
+  $ sudo sync
+
+Insert the micro SDcard in your Bananapi M64 and power it up. The console
+is on the serial line, 115200 8N1.
diff --git a/board/bananapi/post-build.sh b/board/bananapi/post-build.sh
new file mode 100755
index 000..d22bc3d
--- /dev/null
+++ b/board/bananapi/post-build.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+# args from BR2_ROOTFS_POST_SCRIPT_ARGS
+# $4 path of boot.cmd
+
+MKIMAGE=${HOST_DIR}/usr/bin/mkimage
+BOOT_CMD="${4}"
+BOOT_CMD_H="${BINARIES_DIR}/boot.scr"
+
+# U-Boot script
+"${MKIMAGE}" -C none -A arm -T script -d "${BOOT_CMD}" "${BOOT_CMD_H}"
diff --git a/configs/bananapi_m64_defconfig b/configs/bananapi_m64_defconfig
new file mode 100644
index 000..c1e876e
--- /dev/null
+++ b/configs/bananapi_m64_defconfig
@@ -0,0 +1,45 @@
+BR2_aarch64=y
+BR2_cortex_a53=y
+BR2_ARM_FPU_VFPV4=y
+BR2_TOOLCHAIN_B

  1   2   3   4   5   6   7   8   9   10   >