[linux-sunxi] Re: Stability Issues with A33 & Mainline

2015-12-08 Thread Maxime Ripard
Hi,

On Tue, Dec 01, 2015 at 10:11:51PM +0800, wens Tsai wrote:
> Hi,
> 
> I'm having some weird stability issues with my SinA33.
> 
> After idling a while (a few hours ~ a day) it becomes non-responsive
> and just keeps outputting the same message:
> 
> [53418.712180] Task dump for CPU 0:
> [53418.715403] cronR running  0  1131  1 0x0003
> [53418.721780] [] (__schedule) from [<2013>] (0x2013)
> [53496.741465] INFO: rcu_sched detected stalls on CPUs/tasks:
> [53496.746963]  0-...: (2 GPs behind) idle=ba3/141/0
> softirq=127599/127600 fqs=369299
> [53496.755646]  (detected by 1, t=369437 jiffies, g=78644, c=78643, q=67)
> 
> Maybe something is not getting enough power.
> 
> Wondering if anyone else has seen similar problems?

Last time I used mine, I couldn't see anything like this.

Have you tried bisecting it?

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


Re: [linux-sunxi] [PATCH 01/23] mtd: kill the ecclayout->oobavail field

2015-12-08 Thread Boris Brezillon
Hi Priit,

On Tue, 08 Dec 2015 08:43:05 +0200
Priit Laes  wrote:

> On Mon, 2015-12-07 at 23:25 +0100, Boris Brezillon wrote:
> > ecclayout->oobavail is just redundant with the mtd->oobavail field.
> > Moreover, it prevents static const definition of ecc layouts since
> > the
> > NAND framework is calculating this value based on the ecclayout-
> > >oobfree
> > field.
> > 
> > Signed-off-by: Boris Brezillon 
> > ---
> >  drivers/mtd/devices/docg3.c   |  5 ++-
> >  drivers/mtd/mtdswap.c | 16 -
> >  drivers/mtd/nand/brcmnand/brcmnand.c  |  3 --
> >  drivers/mtd/nand/docg4.c  |  1 -
> >  drivers/mtd/nand/hisi504_nand.c   |  1 -
> >  drivers/mtd/nand/nand_base.c  | 12 +++
> >  drivers/mtd/onenand/onenand_base.c| 16 -
> >  drivers/mtd/tests/oobtest.c   | 49 +--
> > 
> >  drivers/staging/mt29f_spinand/mt29f_spinand.c |  1 -
> >  fs/jffs2/wbuf.c   |  6 ++--
> >  include/linux/mtd/mtd.h   |  1 -
> >  11 files changed, 48 insertions(+), 63 deletions(-)
> > 
> [..]
> >  
> > diff --git a/drivers/mtd/nand/brcmnand/brcmnand.c
> > b/drivers/mtd/nand/brcmnand/brcmnand.c
> > index 35d78f7..a906ec2 100644
> > --- a/drivers/mtd/nand/brcmnand/brcmnand.c
> > +++ b/drivers/mtd/nand/brcmnand/brcmnand.c
> > @@ -845,9 +845,6 @@ static struct nand_ecclayout 
> > *brcmnand_create_layout(int ecc_level,
> >     break;
> >     }
> >  out:
> > -   /* Sum available OOB */
> > -   for (i = 0; i < MTD_MAX_OOBFREE_ENTRIES_LARGE; i++)
> > -   layout->oobavail += layout->oobfree[i].length;
> >     return layout;
> >  }
> 
> You can get rid of the 'out' label and replace the single goto in this
> function with 'return layout'.

Yep, I'll fix that.

> 
> [...]
> >  
> > diff --git a/drivers/mtd/nand/nand_base.c
> > b/drivers/mtd/nand/nand_base.c
> > index 0748a13..1107f5c1 100644
> > --- a/drivers/mtd/nand/nand_base.c
> > +++ b/drivers/mtd/nand/nand_base.c
> > @@ -2037,7 +2037,7 @@ static int nand_do_read_oob(struct mtd_info
> > *mtd, loff_t from,
> >     stats = mtd->ecc_stats;
> >  
> >     if (ops->mode == MTD_OPS_AUTO_OOB)
> > -   len = chip->ecc.layout->oobavail;
> > +   len = mtd->oobavail;
> >     else
> >     len = mtd->oobsize;
> >  
> > @@ -2728,7 +2728,7 @@ static int nand_do_write_oob(struct mtd_info
> > *mtd, loff_t to,
> >      __func__, (unsigned int)to, (int)ops-
> > >ooblen);
> >  
> >     if (ops->mode == MTD_OPS_AUTO_OOB)
> > -   len = chip->ecc.layout->oobavail;
> > +   len = mtd->oobavail;
> >     else
> >     len = mtd->oobsize;
> >  
> [...]
> > diff --git a/drivers/mtd/onenand/onenand_base.c
> > b/drivers/mtd/onenand/onenand_base.c
> > index 43b3392..d70bbfd 100644
> > --- a/drivers/mtd/onenand/onenand_base.c
> > +++ b/drivers/mtd/onenand/onenand_base.c
> > @@ -1125,7 +1125,7 @@ static int onenand_mlc_read_ops_nolock(struct
> > mtd_info *mtd, loff_t from,
> >     (int)len);
> >  
> >     if (ops->mode == MTD_OPS_AUTO_OOB)
> > -   oobsize = this->ecclayout->oobavail;
> > +   oobsize = mtd->oobavail;
> >     else
> >     oobsize = mtd->oobsize;
> >  
> > @@ -1230,7 +1230,7 @@ static int onenand_read_ops_nolock(struct
> > mtd_info *mtd, loff_t from,
> >     (int)len);
> >  
> >     if (ops->mode == MTD_OPS_AUTO_OOB)
> > -   oobsize = this->ecclayout->oobavail;
> > +   oobsize = mtd->oobavail;
> >     else
> >     oobsize = mtd->oobsize;
> >  
> > @@ -1365,7 +1365,7 @@ static int onenand_read_oob_nolock(struct
> > mtd_info *mtd, loff_t from,
> >     ops->oobretlen = 0;
> >  
> >     if (mode == MTD_OPS_AUTO_OOB)
> > -   oobsize = this->ecclayout->oobavail;
> > +   oobsize = mtd->oobavail;
> >     else
> >     oobsize = mtd->oobsize;
> >  
> > @@ -1887,7 +1887,7 @@ static int onenand_write_ops_nolock(struct
> > mtd_info *mtd, loff_t to,
> >     return 0;
> >  
> >     if (ops->mode == MTD_OPS_AUTO_OOB)
> > -   oobsize = this->ecclayout->oobavail;
> > +   oobsize = mtd->oobavail;
> >     else
> >     oobsize = mtd->oobsize;
> >  
> > @@ -2063,7 +2063,7 @@ static int onenand_write_oob_nolock(struct
> > mtd_info *mtd, loff_t to,
> >     ops->oobretlen = 0;
> >  
> >     if (mode == MTD_OPS_AUTO_OOB)
> > -   oobsize = this->ecclayout->oobavail;
> > +   oobsize = mtd->oobavail;
> >     else
> >     oobsize = mtd->oobsize;
> 
> This identical construction seems to occur multiple times in multiple
> files. Would it make sense to create a macro for it?

Right, I'll make another patch move this logic into an inline function.

Thanks for the review.

Boris


-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel 

[linux-sunxi] Re: [PATCH v5 3/4] ARM: dts: sunxi: Add Allwinner H3 DTSI

2015-12-08 Thread Maxime Ripard
On Fri, Dec 04, 2015 at 10:24:42PM +0100, Jens Kuske wrote:
> The Allwinner H3 is a home entertainment system oriented SoC with
> four Cortex-A7 cores and a Mali-400MP2 GPU.
> 
> Signed-off-by: Jens Kuske 

Applied, thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


[linux-sunxi] Re: [PATCH v5 1/4] clk: sunxi: Add H3 clocks support

2015-12-08 Thread Maxime Ripard
Hi Jens,

On Fri, Dec 04, 2015 at 10:24:40PM +0100, Jens Kuske wrote:
> The H3 clock control unit is similar to the those of other sun8i family
> members like the A23.
> 
> It adds a new bus gates clock similar to the simple gates, but with a
> different parent clock for each single gate.
> Some of the gates use the new AHB2 clock as parent, whose clock source
> is muxable between AHB1 and PLL6/2. The documentation isn't totally clear
> about which devices belong to AHB2 now, especially USB EHIC/OHIC, so it
> is mostly based on Allwinner kernel source code.
> 
> Signed-off-by: Jens Kuske 

Applied, thanks!

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


[linux-sunxi] Re: [PATCH 09/23] mtd: nand: vf610: remove useless mtd->ecclayout assignment

2015-12-08 Thread Stefan Agner
On 2015-12-07 14:26, Boris Brezillon wrote:
> The NAND core layer is already taking care of ecclayout propagation. Remove
> this useless assignment.

Thx! I see, nand_scan_tail takes care of that...

Acked-by: Stefan Agner 

> 
> Signed-off-by: Boris Brezillon 
> ---
>  drivers/mtd/nand/vf610_nfc.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/mtd/nand/vf610_nfc.c b/drivers/mtd/nand/vf610_nfc.c
> index 1c86c6b..0413e24 100644
> --- a/drivers/mtd/nand/vf610_nfc.c
> +++ b/drivers/mtd/nand/vf610_nfc.c
> @@ -794,8 +794,6 @@ static int vf610_nfc_probe(struct platform_device *pdev)
>   goto error;
>   }
>  
> - /* propagate ecc.layout to mtd_info */
> - mtd->ecclayout = chip->ecc.layout;
>   chip->ecc.read_page = vf610_nfc_read_page;
>   chip->ecc.write_page = vf610_nfc_write_page;

-- 
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 18/25] cris: nand: remove useless mtd->priv = chip assignments

2015-12-08 Thread Jesper Nilsson
On Tue, Dec 01, 2015 at 12:03:15PM +0100, Boris Brezillon wrote:
> mtd_to_nand() now uses the container_of() approach to transform an
> mtd_info pointer into a nand_chip one. Drop useless mtd->priv
> assignments from NAND controller drivers.
> 
> Signed-off-by: Boris Brezillon 

Acked-by: Jesper Nilsson 

/^JN - Jesper Nilsson
-- 
   Jesper Nilsson -- jesper.nils...@axis.com

-- 
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] clk: sunxi: Extend the simple gates and handle the Allwinner H3

2015-12-08 Thread Jean-Francois Moine
On Tue, 8 Dec 2015 08:53:54 +0100
Maxime Ripard  wrote:

> Look, we all agreed on a solution that raised all objections, but
> yours.
> 
> I'm going to take Jens patch.

OK. Good luck for the next SoCs!

-- 
Ken ar c'hentañ | ** Breizh ha Linux atav! **
Jef |   http://moinejf.free.fr/

-- 
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 21/23] staging: mt29f_spinand: switch to mtd_ooblayout_ops

2015-12-08 Thread Boris Brezillon
Hi Julian,

On Tue, 8 Dec 2015 10:59:53 +1100
Julian Calaby  wrote:

> Hi Boris,
> 
> On Tue, Dec 8, 2015 at 9:26 AM, Boris Brezillon
>  wrote:
> > Signed-off-by: Boris Brezillon 
> > ---
> >  drivers/staging/mt29f_spinand/mt29f_spinand.c | 44 
> > ---
> >  1 file changed, 26 insertions(+), 18 deletions(-)
> >
> > diff --git a/drivers/staging/mt29f_spinand/mt29f_spinand.c 
> > b/drivers/staging/mt29f_spinand/mt29f_spinand.c
> > index cb9d5ab..967d50a 100644
> > --- a/drivers/staging/mt29f_spinand/mt29f_spinand.c
> > +++ b/drivers/staging/mt29f_spinand/mt29f_spinand.c
> > @@ -42,23 +42,29 @@ static inline struct spinand_state *mtd_to_state(struct 
> > mtd_info *mtd)
> >  static int enable_hw_ecc;
> >  static int enable_read_hw_ecc;
> >
> > -static struct nand_ecclayout spinand_oob_64 = {
> > -   .eccbytes = 24,
> > -   .eccpos = {
> > -   1, 2, 3, 4, 5, 6,
> > -   17, 18, 19, 20, 21, 22,
> > -   33, 34, 35, 36, 37, 38,
> > -   49, 50, 51, 52, 53, 54, },
> > -   .oobfree = {
> > -   {.offset = 8,
> > -   .length = 8},
> > -   {.offset = 24,
> > -   .length = 8},
> > -   {.offset = 40,
> > -   .length = 8},
> > -   {.offset = 56,
> > -   .length = 8},
> > -   }
> > +static int spinand_oob_64_eccpos(struct mtd_info *mtd, int eccbyte)
> > +{
> > +   if (eccbyte > 23)
> > +   return -ERANGE;
> > +
> > +   return ((eccbyte / 6) * 16) + 1;
> 
> Are you sure this is correct? My reading of this is that we'd get 1
> for eccbytes 0 through 5.
> 
> Would
> 
> ((eccbyte / 6) * 16) + (eccbyte % 6) + 1
> 
> be more correct?

Absolutely. I'll fix that.

Thanks,

Boris

-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

-- 
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 4/4] ARM: dts: sun8i: Add Orange Pi Plus support

2015-12-08 Thread Maxime Ripard
On Fri, Dec 04, 2015 at 10:24:43PM +0100, Jens Kuske wrote:
> The Orange Pi Plus is a SBC based on the Allwinner H3 SoC
> with 8GB eMMC, multiple USB ports through a USB hub chip, SATA through
> a USB-SATA bridge, one uSD slot, a 10/100/1000M ethernet port,
> WiFi, HDMI, headphone jack, IR receiver, a microphone, a CSI connector
> and a 40-pin GPIO header.
> 
> Signed-off-by: Jens Kuske 

Applied, thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


[linux-sunxi] Re: [PATCH v5 3/4] ARM: dts: sunxi: Add Allwinner H3 DTSI

2015-12-08 Thread Maxime Ripard
On Tue, Dec 08, 2015 at 09:06:58AM +0100, Jean-Francois Moine wrote:
> On Mon, 7 Dec 2015 19:44:30 +0100
> Jens Kuske  wrote:
> 
> > >> + "bus_lcd0", "bus_lcd1", 
> > >> "bus_deint",
> > 
> > >   "bus_tcon0", "bus_tcon1", "bus_deint",
> > > 
> > > (the tcon1 clock is used by both lcd0 and lcd1, while
> > >  the tcon0 clock is used for TV output from lcd1)
> > 
> > Hi,
> > 
> > These are only the ahb bus gates, not the module clocks.
> > Naming them lcd might be a bit confusing, but it follows the naming we
> > used since sun4i. And the tcon modules are still called lcd0 and lcd1
> > module in the manual too.
> 
> There is no reference to TCON0 in the LCDs registers (H3 V1.1 pages 428
> and 435), only TCON1.
> 
> > Interestingly there is only a tcon0 module clock in the manual and no
> > tcon1, but that is not part of this patch.
> 
> Well, I looked again in the 3.4 kernel and, for the LCD0/HDMI, there is
> no clock setting for TCON1: it just receives the AHB1 clock.
> 
> This means that its gate ("bus_lcd1" or "ahb1_tcon1") must be enabled
> when streaming on LCD0 or LCD1.
> 
> The role of tcon0 is not yet clear to me, but it seems that its clock
> is the streaming clock for LCD1/TV, as the HDMI clock is for LCD0/HDMI.

If the H3 display block is done the same way than the A10 (and later)
one on this aspect, then the TCON has two channels with two different
streaming (or functional, you pick the name) clocks. The channel 0 is
usually used for RGB, the channel 1 for HDMI, composite and VGA.

Maybe they just added different bus gates for those two different
channels, and moved HDMI to the channel 0.

Anyway, that can always be changed later on if we have more clue on
what's going on.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


[linux-sunxi] Re: [PATCH v5 3/4] ARM: dts: sunxi: Add Allwinner H3 DTSI

2015-12-08 Thread Jean-Francois Moine
On Mon, 7 Dec 2015 19:44:30 +0100
Jens Kuske  wrote:

> >> +   "bus_lcd0", "bus_lcd1", 
> >> "bus_deint",
> 
> > "bus_tcon0", "bus_tcon1", "bus_deint",
> > 
> > (the tcon1 clock is used by both lcd0 and lcd1, while
> >  the tcon0 clock is used for TV output from lcd1)
> 
> Hi,
> 
> These are only the ahb bus gates, not the module clocks.
> Naming them lcd might be a bit confusing, but it follows the naming we
> used since sun4i. And the tcon modules are still called lcd0 and lcd1
> module in the manual too.

There is no reference to TCON0 in the LCDs registers (H3 V1.1 pages 428
and 435), only TCON1.

> Interestingly there is only a tcon0 module clock in the manual and no
> tcon1, but that is not part of this patch.

Well, I looked again in the 3.4 kernel and, for the LCD0/HDMI, there is
no clock setting for TCON1: it just receives the AHB1 clock.

This means that its gate ("bus_lcd1" or "ahb1_tcon1") must be enabled
when streaming on LCD0 or LCD1.

The role of tcon0 is not yet clear to me, but it seems that its clock
is the streaming clock for LCD1/TV, as the HDMI clock is for LCD0/HDMI.

-- 
Ken ar c'hentañ | ** Breizh ha Linux atav! **
Jef |   http://moinejf.free.fr/

-- 
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 3/4] ARM: dts: sunxi: Add Allwinner H3 DTSI

2015-12-08 Thread Jean-Francois Moine
On Tue, 8 Dec 2015 09:32:24 +0100
Maxime Ripard  wrote:

> If the H3 display block is done the same way than the A10 (and later)
> one on this aspect, then the TCON has two channels with two different
> streaming (or functional, you pick the name) clocks. The channel 0 is
> usually used for RGB, the channel 1 for HDMI, composite and VGA.
> 
> Maybe they just added different bus gates for those two different
> channels, and moved HDMI to the channel 0.
> 
> Anyway, that can always be changed later on if we have more clue on
> what's going on.

I don't know about the other Allwinner chips, and your DRM driver for
these ones cannot be reused for the H3 because its display engine
(DE.2) is completely different.

The DE2 runs at 432MHz and treats both LCDs. The TCON1 runs at a fixed
rate, 200MHz, and the streaming rates are defined by the HDMI (LCD0) and
TCON0 (LCD1) clocks.

BTW, I hope to submit a H3 DRM driver before new year.

-- 
Ken ar c'hentañ | ** Breizh ha Linux atav! **
Jef |   http://moinejf.free.fr/

-- 
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: Need some help to configure ft5x on an A13 tablet.

2015-12-08 Thread l_faillie via linux-sunxi
Hello,

Removing IRQF_TRIGGER_FALLING did help :(

Can someone tell me how to move ahead ?

Thanks

Laurent

-- 
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 15/25] cris: nand: use the mtd instance embedded in struct nand_chip

2015-12-08 Thread Jesper Nilsson
On Tue, Dec 01, 2015 at 12:03:12PM +0100, Boris Brezillon wrote:
> struct nand_chip now embeds an mtd device. Patch all drivers to make use
> of this mtd instance instead of using the instance embedded in their
> private struct or dynamically allocated.
> 
> Signed-off-by: Boris Brezillon 

Acked-by: Jesper Nilsson 

/^JN - Jesper Nilsson
-- 
   Jesper Nilsson -- jesper.nils...@axis.com

-- 
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 19/23] mtd: nand: switch all drivers to mtd_ooblayout_ops

2015-12-08 Thread Ralf Baechle
On Mon, Dec 07, 2015 at 11:26:14PM +0100, Boris Brezillon wrote:

Looking good,

Acked-by: Ralf Baechle 

  Ralf

-- 
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 resend 4/6] ARM: dts: sun4i: Add VE (Video Engine) module clock node

2015-12-08 Thread Maxime Ripard
On Sat, Dec 05, 2015 at 09:16:45PM +0800, Chen-Yu Tsai wrote:
> The video engine has its own module clock, which also includes a
> reset control for it.
> 
> Signed-off-by: Chen-Yu Tsai 

Applied, thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


[linux-sunxi] Re: [PATCH resend 6/6] ARM: dts: sun7i: Add VE (Video Engine) module clock node

2015-12-08 Thread Maxime Ripard
On Sat, Dec 05, 2015 at 09:16:47PM +0800, Chen-Yu Tsai wrote:
> The video engine has its own module clock, which also includes a
> reset control for it.
> 
> Signed-off-by: Chen-Yu Tsai 

Applied, thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-- 
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.


signature.asc
Description: Digital signature


Re: [linux-sunxi] [PATCH v4] sun4i-codec: add inputs

2015-12-08 Thread Danny Milosavljevic
Hi Maxime,

On Tue, 8 Dec 2015 10:09:50 +0100
Maxime Ripard  wrote:

> > Now I added an ugly hack to make Mic Gain work on A10 as well - but I don't 
> > have 
> > A10 hardware. Let's see what they say.
> 
> That I really prefer having nothing over an "ugly hack" :)

I figured you'd say that :)

But for these kind of architectural decisions should I send the question to all 
the people get_maintainers tells me in advance? Or pick one?
Or should I include it in the patch E-Mail above the "---"?

Like this:

PREG1 is the Mic1-In Pre-Amplifier gain control.
PREG2 is the Mic2-In Pre-Amplifier gain control.

The A10 has PREG1 and PREG2 in the ADC control register.
The A20 has PREG1 and PREG2 in the (new) PHONE_CAL control register.

Right now my (v5) probe function modifies the global variable 
"sun4i_codec_widgets" depending on the compatible string.
I think it's safe for the time being since the codec is on-die and it's not 
possible to suddenly need both sun4i widgets and sun7i widgets in the same 
kernel at the same time.
(I don't have A10 hardware. So I wrote it in a way that in the A10 case 
it doesn't have to do anything and in the A20 case it does the modifications.
That way, I could test the modifications (I do have A20 hardware))

The alternatives would be to either
1) split the driver up into kernel modules "sun4i-codec" and "sun7i-codec". 
   Maybe add a common object file to reduce duplicate work.
   This would be an user-visible change. Is that even allowed?
2) make the "sun4i-codec" kernel module register two different codecs 
   with two different compatibles and two different "sun4i"_codec_widget 
   variables. Is that even possible?
3) make ALSA dynamically add two different widgets at run time depending on 
   the compatible (not added to the "sun4i_codec_widget" array). 
   Is that even possible?

Which do we prefer?

(All that because someone just had to move those bits. Sigh.
The space where they were in A10 is empty in A20, so it's not like they 
needed the space or anything)

Regards,
   Danny

-- 
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: Rotated video playback on A20

2015-12-08 Thread Stefan Monnier
> Can you give advice on how to approach this? Is it at all possible to do
> rotation with the CedarX driver?

I'd recommend you try it with the libvdpau-sunxi since it's at least
a code base that is amenable to improvements.


Stefan

-- 
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 0/2] input: Driver for Goodix GT801 2+1 touchscreen

2015-12-08 Thread Bastien Nocera
On Mon, 2015-12-07 at 09:25 +0200, Priit Laes wrote:
> This series adds support for Goodix GT801 2+1 touchscreen controller
> and hooks it up on Gemei G9 tablet.
> 
> Now about GT801 2+1 - I initially tried to implement this inside the
> existing Goodix driver, but unfortunately there are too many small
> bits and pieces that would make the otherwise simple driver a
> complicated mess:
>   - endianness differences of coordinate readouts
>   - totally different touch protocol
>   - configuration layout and version information
>   - I2C register differences (2 bytes vs single byte)

The goodix driver will get more complicated after we merge Irina's
patchset. Instead of looking at the differences between the protocols,
which don't look insurmountable (a switch statement in a few places,
right?), you should look at the code you could share:
- power management
- ESD support
- ACPI support
- the support for variants in goodix.c (911-variants, and 967-variants)
- ability to read and write config data to the device

Taking this into account (and the fact that I can't read Chinese that
well, so my reading of the specs is cursory), would it make sense to
merge the 2 drivers?

CC'ing Irina about this.

Cheers

-- 
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 resend 2/6] clk: sunxi: Add VE (Video Engine) module clock driver for sun[457]i

2015-12-08 Thread Maxime Ripard
Hi,

On Sat, Dec 05, 2015 at 09:16:43PM +0800, Chen-Yu Tsai wrote:
> The video engine has its own special module clock, consisting of a clock
> gate, configurable dividers, and a reset control.
> 
> On later (sun[68]i) families, the reset control is moved out of this
> piece of hardware and grouped with reset controls of other peripherals.
> 
> Signed-off-by: Chen-Yu Tsai 
> ---
>  Documentation/devicetree/bindings/clock/sunxi.txt |   4 +
>  drivers/clk/sunxi/Makefile|   1 +
>  drivers/clk/sunxi/clk-a10-ve.c| 171 
> ++
>  3 files changed, 176 insertions(+)
>  create mode 100644 drivers/clk/sunxi/clk-a10-ve.c
> 
> diff --git a/Documentation/devicetree/bindings/clock/sunxi.txt 
> b/Documentation/devicetree/bindings/clock/sunxi.txt
> index ef0b452806b1..14496056319f 100644
> --- a/Documentation/devicetree/bindings/clock/sunxi.txt
> +++ b/Documentation/devicetree/bindings/clock/sunxi.txt
> @@ -74,6 +74,7 @@ Required properties:
>   "allwinner,sun8i-h3-usb-clk" - for usb gates + resets on H3
>   "allwinner,sun9i-a80-usb-mod-clk" - for usb gates + resets on A80
>   "allwinner,sun9i-a80-usb-phy-clk" - for usb phy gates + resets on A80
> + "allwinner,sun4i-a10-ve-clk" - for the Video Engine clock
>  
>  Required properties for all clocks:
>  - reg : shall be the control register address for the clock.
> @@ -93,6 +94,9 @@ Required properties for all clocks:
>  And "allwinner,*-usb-clk" clocks also require:
>  - reset-cells : shall be set to 1
>  
> +The "allwinner,sun4i-a10-ve-clk" clock also requires:
> +- reset-cells : shall be set to 0
> +
>  The "allwinner,sun9i-a80-mmc-config-clk" clock also requires:
>  - #reset-cells : shall be set to 1
>  - resets : shall be the reset control phandle for the mmc block.
> diff --git a/drivers/clk/sunxi/Makefile b/drivers/clk/sunxi/Makefile
> index 103efab05ca8..78db91ad5af6 100644
> --- a/drivers/clk/sunxi/Makefile
> +++ b/drivers/clk/sunxi/Makefile
> @@ -7,6 +7,7 @@ obj-y += clk-a10-codec.o
>  obj-y += clk-a10-hosc.o
>  obj-y += clk-a10-mod1.o
>  obj-y += clk-a10-pll2.o
> +obj-y += clk-a10-ve.o
>  obj-y += clk-a20-gmac.o
>  obj-y += clk-mod0.o
>  obj-y += clk-simple-gates.o
> diff --git a/drivers/clk/sunxi/clk-a10-ve.c b/drivers/clk/sunxi/clk-a10-ve.c
> new file mode 100644
> index ..de0fdb656150
> --- /dev/null
> +++ b/drivers/clk/sunxi/clk-a10-ve.c
> @@ -0,0 +1,171 @@
> +/*
> + * Copyright 2015 Chen-Yu Tsai
> + *
> + * Chen-Yu Tsai 
> + *
> + * This program 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 program 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.
> + */
> +
> +#include 
> +#include 
> +#include 
> +#include 
> +#include 
> +#include 
> +
> +static DEFINE_SPINLOCK(ve_lock);
> +
> +#define SUN4I_VE_ENABLE  31
> +#define SUN4I_VE_DIVIDER_SHIFT   16
> +#define SUN4I_VE_DIVIDER_WIDTH   3
> +#define SUN4I_VE_RESET   0
> +
> +/**
> + * sunxi_ve_reset... - reset bit in ve clk registers handling
> + */
> +
> +struct ve_reset_data {
> + void __iomem*reg;
> + spinlock_t  *lock;
> + struct reset_controller_dev rcdev;
> +};
> +
> +static int sunxi_ve_reset_assert(struct reset_controller_dev *rcdev,
> +  unsigned long id)
> +{
> + struct ve_reset_data *data = container_of(rcdev,
> +   struct ve_reset_data,
> +   rcdev);
> + unsigned long flags;
> + u32 reg;
> +
> + spin_lock_irqsave(data->lock, flags);
> +
> + reg = readl(data->reg);
> + writel(reg & ~BIT(SUN4I_VE_RESET), data->reg);
> +
> + spin_unlock_irqrestore(data->lock, flags);
> +
> + return 0;
> +}
> +
> +static int sunxi_ve_reset_deassert(struct reset_controller_dev *rcdev,
> +unsigned long id)
> +{
> + struct ve_reset_data *data = container_of(rcdev,
> +   struct ve_reset_data,
> +   rcdev);
> + unsigned long flags;
> + u32 reg;
> +
> + spin_lock_irqsave(data->lock, flags);
> +
> + reg = readl(data->reg);
> + writel(reg | BIT(SUN4I_VE_RESET), data->reg);
> +
> + spin_unlock_irqrestore(data->lock, flags);
> +
> + return 0;
> +}

Is it me, or do we have this code duplicated everywhere now?

Maybe we should turn this into a small library.

> +static int sunxi_ve_of_xlate(struct reset_controller_dev *rcdev,
> + 

[linux-sunxi] Re: [PATCH 2/2] input: gt801_2plus1 - Add initial support for Goodix GT801 2+1

2015-12-08 Thread Bastien Nocera
Hey Priit,

On Mon, 2015-12-07 at 09:26 +0200, Priit Laes wrote:
> This patch adds Goodix GT801 2+1 touchscreen controller support.
> 
> GT801 2+1 is a 10-finger touch controller consisting of
> ARM controller interfacing two GT801 5-finger controllers.

This would implement support for the "Guitar" protocol used by a few
more variants of the GT80x devices. Can you rename the driver/docs to that 
effect?

> +
> +static const struct i2c_device_id gt801x_ts_id[] = {
> + { "GDIX1001:00", 0 },

This clashes with the ID used in the goodix.c driver.

Cheers

-- 
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 05/23] mtd: nand: jz4770: kill the ->ecc_layout field

2015-12-08 Thread Boris Brezillon
On Tue, 8 Dec 2015 10:30:40 +
Harvey Hunt  wrote:

> Hi Boris,
> 
> On 07/12/15 22:26, Boris Brezillon wrote:
> > ->ecc_layout is not used by any board file. Kill this field to avoid any
> > confusion. New boards are encouraged to use the default ECC layout defined
> > in NAND core.
> >
> > Signed-off-by: Boris Brezillon 
> > ---
> >   arch/mips/include/asm/mach-jz4740/jz4740_nand.h | 2 --
> >   drivers/mtd/nand/jz4740_nand.c  | 3 ---
> >   2 files changed, 5 deletions(-)
> >
> > diff --git a/arch/mips/include/asm/mach-jz4740/jz4740_nand.h 
> > b/arch/mips/include/asm/mach-jz4740/jz4740_nand.h
> > index 79cff26..398733e 100644
> > --- a/arch/mips/include/asm/mach-jz4740/jz4740_nand.h
> > +++ b/arch/mips/include/asm/mach-jz4740/jz4740_nand.h
> > @@ -25,8 +25,6 @@ struct jz_nand_platform_data {
> > int num_partitions;
> > struct mtd_partition*partitions;
> >
> > -   struct nand_ecclayout   *ecc_layout;
> > -
> > unsigned char banks[JZ_NAND_NUM_BANKS];
> >
> > void (*ident_callback)(struct platform_device *, struct nand_chip *,
> > diff --git a/drivers/mtd/nand/jz4740_nand.c b/drivers/mtd/nand/jz4740_nand.c
> > index 5a99a93..c4fe446 100644
> > --- a/drivers/mtd/nand/jz4740_nand.c
> > +++ b/drivers/mtd/nand/jz4740_nand.c
> > @@ -446,9 +446,6 @@ static int jz_nand_probe(struct platform_device *pdev)
> > chip->ecc.bytes = 9;
> > chip->ecc.strength  = 4;
> >
> > -   if (pdata)
> > -   chip->ecc.layout = pdata->ecc_layout;
> > -
> > chip->chip_delay = 50;
> > chip->cmd_ctrl = jz_nand_cmd_ctrl;
> > chip->select_chip = jz_nand_select_chip;
> >
> 
> Is there a typo in this commit title? The JZ4740 and JZ4770 have quite 
> different NAND controller interfaces, so I don't think that the JZ4740 
> driver will support the JZ4770.

Yes, it's a typo, I meant jz4740, I'll fix my commit message
accordingly.

Thanks,

Boris

-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

-- 
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: Rotated video playback on A20

2015-12-08 Thread András Ács
Thanks!
It's actually the libvdpau-sunxi, I got confused by the naming (the 
libvdpau-sunxi github page links to https://linux-sunxi.org/Cedrus which 
refers to CedarX)

On Tuesday, December 8, 2015 at 2:16:17 PM UTC+1, Stefan Monnier wrote:
>
> > Can you give advice on how to approach this? Is it at all possible to do 
> > rotation with the CedarX driver? 
>
> I'd recommend you try it with the libvdpau-sunxi since it's at least 
> a code base that is amenable to improvements. 
>
>
> Stefan 
>
>

-- 
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: Rotated video playback on A20

2015-12-08 Thread Andreas Baierl

If you refer to libvdpau-sunxi, rotating is not implemented atm.
-> https://github.com/linux-sunxi/libvdpau-sunxi/blob/master/rgba.c#L189

Regards
Andreas

Am 08.12.2015 um 15:02 schrieb András Ács:

Thanks!
It's actually the libvdpau-sunxi, I got confused by the naming (the 
libvdpau-sunxi github page links to https://linux-sunxi.org/Cedrus 
which refers to CedarX)


On Tuesday, December 8, 2015 at 2:16:17 PM UTC+1, Stefan Monnier wrote:

> Can you give advice on how to approach this? Is it at all
possible to do
> rotation with the CedarX driver?

I'd recommend you try it with the libvdpau-sunxi since it's at least
a code base that is amenable to improvements.


Stefan

--
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.


--
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 2/2] input: gt801_2plus1 - Add initial support for Goodix GT801 2+1

2015-12-08 Thread Rob Herring
On Mon, Dec 07, 2015 at 09:26:01AM +0200, Priit Laes wrote:
> This patch adds Goodix GT801 2+1 touchscreen controller support.
> 
> GT801 2+1 is a 10-finger touch controller consisting of
> ARM controller interfacing two GT801 5-finger controllers.
> 
> Signed-off-by: Priit Laes 
> ---
>  .../bindings/input/touchscreen/gt801_2plus1.txt|  23 ++

For the binding:

Acked-by: Rob Herring 

>  MAINTAINERS|   6 +
>  drivers/input/touchscreen/Kconfig  |  19 +-
>  drivers/input/touchscreen/Makefile |   1 +
>  drivers/input/touchscreen/gt801_2plus1.c   | 375 
> +
>  5 files changed, 421 insertions(+), 3 deletions(-)
>  create mode 100644 
> Documentation/devicetree/bindings/input/touchscreen/gt801_2plus1.txt
>  create mode 100644 drivers/input/touchscreen/gt801_2plus1.c
> 
> diff --git 
> a/Documentation/devicetree/bindings/input/touchscreen/gt801_2plus1.txt 
> b/Documentation/devicetree/bindings/input/touchscreen/gt801_2plus1.txt
> new file mode 100644
> index 000..070ff5b
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/input/touchscreen/gt801_2plus1.txt
> @@ -0,0 +1,23 @@
> +Device tree bindings for Goodix GT801 2+1 series touchscreen controller
> +
> +Required properties:
> +
> + - compatible: Should be "goodix,gt801_2plus1"
> + - reg   : I2C address of the chip. Should be 0x55
> + - interrupt-parent  : Interrupt controller to which the chip is connected
> + - interrupts: Interrupt to which the chip is connected
> +
> +Example:
> +
> + i2c@ {
> + /* ... */
> +
> + touchscreen@55 {
> + compatible = "goodix,gt801_2plus1";
> + reg = <0x55>;
> + interrupt-parent = <>;
> + interrupts = <0 0>;
> + };
> +
> + /* ... */
> + };
> diff --git a/MAINTAINERS b/MAINTAINERS
> index cba790b..e292126 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -4743,6 +4743,12 @@ L: linux-in...@vger.kernel.org
>  S:   Maintained
>  F:   drivers/input/touchscreen/goodix.c
>  
> +GOODIX GT801 2PLUS1 TOUCHSCREEN
> +M:   Priit Laes 
> +L:   linux-in...@vger.kernel.org
> +S:   Maintained
> +F:   drivers/input/touchscreen/gt801_2plus1.c
> +
>  GPIO SUBSYSTEM
>  M:   Linus Walleij 
>  M:   Alexandre Courbot 
> diff --git a/drivers/input/touchscreen/Kconfig 
> b/drivers/input/touchscreen/Kconfig
> index ae33da7..c7c3324 100644
> --- a/drivers/input/touchscreen/Kconfig
> +++ b/drivers/input/touchscreen/Kconfig
> @@ -322,11 +322,11 @@ config TOUCHSCREEN_FUJITSU
> module will be called fujitsu-ts.
>  
>  config TOUCHSCREEN_GOODIX
> - tristate "Goodix I2C touchscreen"
> + tristate "Goodix GT9xx I2C touchscreen"
>   depends on I2C
>   help
> -   Say Y here if you have the Goodix touchscreen (such as one
> -   installed in Onda v975w tablets) connected to your
> +   Say Y here if you have one of the Goodix GT9xx touchscreens
> +   (such as one installed in Onda v975w tablet) connected to your
> system. It also supports 5-finger chip models, which can be
> found on ARM tablets, like Wexler TAB7200 and MSI Primo73.
>  
> @@ -335,6 +335,19 @@ config TOUCHSCREEN_GOODIX
> To compile this driver as a module, choose M here: the
> module will be called goodix.
>  
> +config TOUCHSCREEN_GT801_2PLUS1
> + tristate "Goodix GT801 2+1 I2C touchscreen"
> + depends on I2C
> + help
> +   Say Y here if you have the Goodix GT801 2+1 touchscreen.
> +   This controller is found on some older ARM tablets like
> +   (Gemei G9 and Zareason Zatab).
> +
> +   If unsure, say N.
> +
> +   To compile this driver as a module, choose M here: the
> +   module will be called gt801_2plus1.
> +
>  config TOUCHSCREEN_ILI210X
>   tristate "Ilitek ILI210X based touchscreen"
>   depends on I2C
> diff --git a/drivers/input/touchscreen/Makefile 
> b/drivers/input/touchscreen/Makefile
> index cbaa6ab..ff25d1b4 100644
> --- a/drivers/input/touchscreen/Makefile
> +++ b/drivers/input/touchscreen/Makefile
> @@ -38,6 +38,7 @@ obj-$(CONFIG_TOUCHSCREEN_EGALAX)+= egalax_ts.o
>  obj-$(CONFIG_TOUCHSCREEN_FT6236) += ft6236.o
>  obj-$(CONFIG_TOUCHSCREEN_FUJITSU)+= fujitsu_ts.o
>  obj-$(CONFIG_TOUCHSCREEN_GOODIX) += goodix.o
> +obj-$(CONFIG_TOUCHSCREEN_GT801_2PLUS1)   += gt801_2plus1.o
>  obj-$(CONFIG_TOUCHSCREEN_ILI210X)+= ili210x.o
>  obj-$(CONFIG_TOUCHSCREEN_IMX6UL_TSC) += imx6ul_tsc.o
>  obj-$(CONFIG_TOUCHSCREEN_INEXIO) += inexio.o
> diff --git a/drivers/input/touchscreen/gt801_2plus1.c 
> b/drivers/input/touchscreen/gt801_2plus1.c
> new file mode 100644
> index 000..e2be479
> --- /dev/null
> +++ b/drivers/input/touchscreen/gt801_2plus1.c
> @@ -0,0 

Re: [linux-sunxi] Re: Rotated video playback on A20

2015-12-08 Thread Jens Kuske
On 08/12/15 15:02, András Ács wrote:
> Thanks!
> It's actually the libvdpau-sunxi, I got confused by the naming (the 
> libvdpau-sunxi github page links to https://linux-sunxi.org/Cedrus which 
> refers to CedarX)

Hi,

the video engine is able to rotate the video while decoding, but its not
possible to export this feature with vdpau.

vdpau doesn't provide the information that it needs a rotated video at
decoding time, but only later at render time. You would have to look
into the future to do rotate at decoding time.
G2D is the only other part that can do rotation afterwards, but g2d
can't read the tiled video engine output, so it can't be used too.

Regards,
Jens


> 
> On Tuesday, December 8, 2015 at 2:16:17 PM UTC+1, Stefan Monnier wrote:
>>
>>> Can you give advice on how to approach this? Is it at all possible to do 
>>> rotation with the CedarX driver? 
>>
>> I'd recommend you try it with the libvdpau-sunxi since it's at least 
>> a code base that is amenable to improvements. 
>>
>>
>> Stefan 
>>
>>
> 

-- 
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: Rotated video playback on A20

2015-12-08 Thread Andreas Baierl

Am 08.12.2015 um 16:02 schrieb Jens Kuske:

On 08/12/15 15:02, András Ács wrote:

Thanks!
It's actually the libvdpau-sunxi, I got confused by the naming (the
libvdpau-sunxi github page links to https://linux-sunxi.org/Cedrus which
refers to CedarX)

Hi,

the video engine is able to rotate the video while decoding, but its not
possible to export this feature with vdpau.

vdpau doesn't provide the information that it needs a rotated video at
decoding time, but only later at render time. You would have to look
into the future to do rotate at decoding time.
G2D is the only other part that can do rotation afterwards, but g2d
can't read the tiled video engine output, so it can't be used too.
Damn. Thank you Jens. I mixed up sunxi special OSD and Video 
implementation once again ...

Regards
Andreas

Regards,
Jens



On Tuesday, December 8, 2015 at 2:16:17 PM UTC+1, Stefan Monnier wrote:

Can you give advice on how to approach this? Is it at all possible to do
rotation with the CedarX driver?

I'd recommend you try it with the libvdpau-sunxi since it's at least
a code base that is amenable to improvements.


 Stefan




--
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: Rotated video playback on A20

2015-12-08 Thread András Ács
That's definite. Bummer.

Pre-rotation it is, then.

Thank you all!

Regards,
Andras

On Tuesday, December 8, 2015 at 4:03:02 PM UTC+1, Jens Kuske wrote:
>
> On 08/12/15 15:02, András Ács wrote: 
> > Thanks! 
> > It's actually the libvdpau-sunxi, I got confused by the naming (the 
> > libvdpau-sunxi github page links to https://linux-sunxi.org/Cedrus 
> which 
> > refers to CedarX) 
>
> Hi, 
>
> the video engine is able to rotate the video while decoding, but its not 
> possible to export this feature with vdpau. 
>
> vdpau doesn't provide the information that it needs a rotated video at 
> decoding time, but only later at render time. You would have to look 
> into the future to do rotate at decoding time. 
> G2D is the only other part that can do rotation afterwards, but g2d 
> can't read the tiled video engine output, so it can't be used too. 
>
> Regards, 
> Jens 
>
>
> > 
> > On Tuesday, December 8, 2015 at 2:16:17 PM UTC+1, Stefan Monnier wrote: 
> >> 
> >>> Can you give advice on how to approach this? Is it at all possible to 
> do 
> >>> rotation with the CedarX driver? 
> >> 
> >> I'd recommend you try it with the libvdpau-sunxi since it's at least 
> >> a code base that is amenable to improvements. 
> >> 
> >> 
> >> Stefan 
> >> 
> >> 
> > 
>

-- 
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 2/2] ARM: dts: sun7i: Add audio codec to Itead Ibox

2015-12-08 Thread codekipper
From: Marcus Cooper 

Signed-off-by: Marcus Cooper 
---
 arch/arm/boot/dts/sun7i-a20-itead-ibox.dts | 4 
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/sun7i-a20-itead-ibox.dts 
b/arch/arm/boot/dts/sun7i-a20-itead-ibox.dts
index 90ff677..0950b59 100644
--- a/arch/arm/boot/dts/sun7i-a20-itead-ibox.dts
+++ b/arch/arm/boot/dts/sun7i-a20-itead-ibox.dts
@@ -70,6 +70,10 @@
status = "okay";
 };
 
+ {
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_pins_mii_a>;
-- 
2.6.3

-- 
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/2] ARM: dts: sun7i: Add Itead Ibox support

2015-12-08 Thread codekipper
From: Marcus Cooper 

The Itead Ibox is a multi board device based on the Allwinner A20 SoC.
It contains the A20 Itead Core module and a base board for the external
interfaces.

The core module comes with 4GB NAND and 1GB DDR RAM.

The base board to which the core board is connected provides 3 USB 2.0 Host
ports, 1 USB 2.0 OTG, 1 uSD slot, 10/100 Ethernet port, HDMI, IR receiver,
SPDIF and a 32-pin GPIO header. This header expands the features of core
board by exposing the VGA pins, audio In/Out pins, SATA, SPI, I2C, UARTS,
USB-OTG and power.

As there is an A10 version of the Itead Core Module and at least one other
base board to support then this patch partitions the device tree files with
some consideration that these variants may be added later.

Signed-off-by: Marcus Cooper 
---
 arch/arm/boot/dts/Makefile |   1 +
 arch/arm/boot/dts/sun7i-a20-itead-core.dtsi|  83 ++
 arch/arm/boot/dts/sun7i-a20-itead-ibox.dts |  98 ++
 arch/arm/boot/dts/sunxi-itead-core-common.dtsi | 111 +
 4 files changed, 293 insertions(+)
 create mode 100644 arch/arm/boot/dts/sun7i-a20-itead-core.dtsi
 create mode 100644 arch/arm/boot/dts/sun7i-a20-itead-ibox.dts
 create mode 100644 arch/arm/boot/dts/sunxi-itead-core-common.dtsi

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index cc7309b..ee8a1dc 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -637,6 +637,7 @@ dtb-$(CONFIG_MACH_SUN7I) += \
sun7i-a20-cubieboard2.dtb \
sun7i-a20-cubietruck.dtb \
sun7i-a20-hummingbird.dtb \
+   sun7i-a20-itead-ibox.dtb \
sun7i-a20-i12-tvbox.dtb \
sun7i-a20-icnova-swac.dtb \
sun7i-a20-m3.dtb \
diff --git a/arch/arm/boot/dts/sun7i-a20-itead-core.dtsi 
b/arch/arm/boot/dts/sun7i-a20-itead-core.dtsi
new file mode 100644
index 000..b50be89
--- /dev/null
+++ b/arch/arm/boot/dts/sun7i-a20-itead-core.dtsi
@@ -0,0 +1,83 @@
+/*
+ * Copyright 2015 - Marcus Cooper 
+ *
+ * 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 "sun7i-a20.dtsi"
+#include "sunxi-itead-core-common.dtsi"
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>;
+   status = "okay";
+
+   axp209: pmic@34 {
+   reg = <0x34>;
+   interrupt-parent = <_intc>;
+   interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
+   };
+};
+
+#include "axp209.dtsi"
+
+_dcdc2 {
+   regulator-always-on;
+   regulator-min-microvolt = <100>;
+   regulator-max-microvolt = <140>;
+   regulator-name = "vdd-cpu";
+};
+
+_dcdc3 {
+   regulator-always-on;
+   regulator-min-microvolt = <100>;
+   regulator-max-microvolt = <140>;
+   regulator-name = "vdd-int-dll";
+};
+
+_ldo1 {
+   regulator-name = "vdd-rtc";
+};
+
+_ldo2 {
+   regulator-always-on;
+   regulator-min-microvolt = <300>;
+   regulator-max-microvolt = <300>;
+   regulator-name = "avcc";

[linux-sunxi][PATCH 0/2] ARM: dts: sun4i: mk802 variant patches

2015-12-08 Thread codekipper
From: Marcus Cooper 

This patch series splits the mk802 dts into common include file which
can be shared with the mk802+ device. The only difference that I can
see between this and the original device is that it has an internal
microphone.

With that in mind we can either leave things as they are and enable
the capture to the original mk802 dts or apply this patch to distinguish
between the two devices.

CK

Marcus Cooper (2):
  ARM: dts: sun4i: Create common dtsi for mk802
  ARM: dts: sun4i: Add rikomagic mk802+ board

 arch/arm/boot/dts/Makefile|   1 +
 arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts |  50 ++
 arch/arm/boot/dts/sun4i-a10-mk802.dts |  64 +-
 arch/arm/boot/dts/sun4i-a10-mk802.dtsi| 108 ++
 4 files changed, 160 insertions(+), 63 deletions(-)
 create mode 100644 arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts
 create mode 100644 arch/arm/boot/dts/sun4i-a10-mk802.dtsi

-- 
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 1/2] ARM: dts: sun4i: Create common dtsi for mk802

2015-12-08 Thread codekipper
From: Marcus Cooper 

There are a few variants of the mk802 boards. This commit adds a
dtsi for the mk802 and modifies the original dts to reference it.

Signed-off-by: Marcus Cooper 
---
 arch/arm/boot/dts/sun4i-a10-mk802.dts  |  64 +--
 arch/arm/boot/dts/sun4i-a10-mk802.dtsi | 108 +
 2 files changed, 109 insertions(+), 63 deletions(-)
 create mode 100644 arch/arm/boot/dts/sun4i-a10-mk802.dtsi

diff --git a/arch/arm/boot/dts/sun4i-a10-mk802.dts 
b/arch/arm/boot/dts/sun4i-a10-mk802.dts
index 3c7eebe..fd2f7fb 100644
--- a/arch/arm/boot/dts/sun4i-a10-mk802.dts
+++ b/arch/arm/boot/dts/sun4i-a10-mk802.dts
@@ -41,72 +41,10 @@
  */
 
 /dts-v1/;
-#include "sun4i-a10.dtsi"
-#include "sunxi-common-regulators.dtsi"
-#include 
+#include "sun4i-a10-mk802.dtsi"
 
 / {
model = "MK802";
compatible = "allwinner,mk802", "allwinner,sun4i-a10";
 
-   aliases {
-   serial0 = 
-   };
-
-   chosen {
-   stdout-path = "serial0:115200n8";
-   };
-};
-
- {
-   status = "okay";
-};
-
- {
-   status = "okay";
-};
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_pins_a>, <_cd_pin_reference_design>;
-   vmmc-supply = <_vcc3v3>;
-   bus-width = <4>;
-   cd-gpios = < 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */
-   cd-inverted;
-   status = "okay";
-};
-
- {
-   status = "okay";
-};
-
- {
-   usb2_vbus_pin_mk802: usb2_vbus_pin@0 {
-   allwinner,pins = "PH12";
-   allwinner,function = "gpio_out";
-   allwinner,drive = ;
-   allwinner,pull = ;
-   };
-};
-
-_usb1_vbus {
-   status = "okay";
-};
-
-_usb2_vbus {
-   pinctrl-0 = <_vbus_pin_mk802>;
-   gpio = < 7 12 GPIO_ACTIVE_HIGH>; /* PH12 */
-   status = "okay";
-};
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_pins_a>;
-   status = "okay";
-};
-
- {
-   usb1_vbus-supply = <_usb1_vbus>;
-   usb2_vbus-supply = <_usb2_vbus>;
-   status = "okay";
 };
diff --git a/arch/arm/boot/dts/sun4i-a10-mk802.dtsi 
b/arch/arm/boot/dts/sun4i-a10-mk802.dtsi
new file mode 100644
index 000..422ef9c
--- /dev/null
+++ b/arch/arm/boot/dts/sun4i-a10-mk802.dtsi
@@ -0,0 +1,108 @@
+/*
+ * Copyright 2015 Hans de Goede 
+ *
+ * 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 "sun4i-a10.dtsi"
+#include "sunxi-common-regulators.dtsi"
+#include 
+
+/ {
+   aliases {
+   serial0 = 
+   };
+
+   chosen {
+   stdout-path = "serial0:115200n8";
+   };
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin_reference_design>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */
+   cd-inverted;
+   status = "okay";
+};
+
+ {
+   status = "okay";
+};
+
+ {
+   usb2_vbus_pin_mk802: usb2_vbus_pin@0 {
+   

[linux-sunxi] [PATCH RFC 2/2] ARM: dts: sun7i: Olimex A20-SOM-EVB: Enable mmc3 (baseboard SD socket)

2015-12-08 Thread Karsten Merker
The Olimex A20-SOM-EVB is an evaluation board for the Olimex
A20-SOM system-on-module. The baseboard provides a full-size SD
socket (connected to mmc3) in addition to the micro-SD socket on
the SOM itself (which is connected to mmc0).

Enable the mmc3 controller in the dts.

Signed-off-by: Karsten Merker 
---
 arch/arm/boot/dts/sun7i-a20-olimex-som-evb.dts | 17 +
 1 file changed, 17 insertions(+)

diff --git a/arch/arm/boot/dts/sun7i-a20-olimex-som-evb.dts 
b/arch/arm/boot/dts/sun7i-a20-olimex-som-evb.dts
index 6562a6bc..6a3d95d 100644
--- a/arch/arm/boot/dts/sun7i-a20-olimex-som-evb.dts
+++ b/arch/arm/boot/dts/sun7i-a20-olimex-som-evb.dts
@@ -176,6 +176,16 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins_a>, <_cd_pin_olimex_som_evb>;
+   vmmc-supply = <_vcc3v3>;
+   bus-width = <4>;
+   cd-gpios = < 7 0 GPIO_ACTIVE_HIGH>; /* PH0 */
+   cd-inverted;
+   status = "okay";
+};
+
  {
status = "okay";
 };
@@ -198,6 +208,13 @@
allwinner,drive = ;
allwinner,pull = ;
};
+
+   mmc3_cd_pin_olimex_som_evb: mmc3_cd_pin@0 {
+   allwinner,pins = "PH0";
+   allwinner,function = "gpio_in";
+   allwinner,drive = ;
+   allwinner,pull = ;
+   };
 };
 
 _ahci_5v {
-- 
2.1.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.


Re: [linux-sunxi][PATCH 2/2] ARM: dts: sun4i: Add rikomagic mk802+ board

2015-12-08 Thread Julian Calaby
Hi Marcus,

On Wed, Dec 9, 2015 at 5:48 AM,   wrote:
> From: Marcus Cooper 
>
> The Rikomagic mk802+ is an Allwinner A10 based hdmi tv-stick, it features
> 1G RAM, 4G nand, a mini-hdmi female connector, USB-A receptacle, mini-usb
> receptacle (OTG), USB-wifi and an internal microphone. Like the original
> mk802, it does not use any pmic.
>
> Signed-off-by: Marcus Cooper 
> ---
>  arch/arm/boot/dts/Makefile|  1 +
>  arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts | 50 
> +++
>  2 files changed, 51 insertions(+)
>  create mode 100644 arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts
>
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index ee8a1dc..f1cb0f8 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -600,6 +600,7 @@ dtb-$(CONFIG_MACH_SUN4I) += \
> sun4i-a10-marsboard.dtb \
> sun4i-a10-mini-xplus.dtb \
> sun4i-a10-mk802.dtb \
> +   sun4i-a10-mk802-1gb.dtb \
> sun4i-a10-mk802ii.dtb \
> sun4i-a10-olinuxino-lime.dtb \
> sun4i-a10-pcduino.dtb \
> diff --git a/arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts 
> b/arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts
> new file mode 100644
> index 000..eb77633
> --- /dev/null
> +++ b/arch/arm/boot/dts/sun4i-a10-mk802-1gb.dts
> @@ -0,0 +1,50 @@
> +/*
> + * Copyright 2015 Marcus Cooper 
> + *
> + * 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 "sun4i-a10-mk802.dtsi"
> +
> +/ {
> +   model = "Rikomagic MK802+";
> +   compatible = "rikomagic,mk802-1gb", "allwinner,sun4i-a10";
> +
> +};

Are there any differences between the Rikomagic and the generic MK802?

You could just add another compatible to the original MK802 dts if there aren't.

Thanks,

-- 
Julian Calaby

Email: julian.cal...@gmail.com
Profile: http://www.google.com/profiles/julian.calaby/

-- 
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: Rotated video playback on A20

2015-12-08 Thread Stefan Monnier
> the video engine is able to rotate the video while decoding, but its not
> possible to export this feature with vdpau.
> vdpau doesn't provide the information that it needs a rotated video at
> decoding time, but only later at render time. You would have to look
> into the future to do rotate at decoding time.

Hmm... that sucks.  I think it deserves a bug report to "the vdpau
designers/maintainers"?
In the mean time, is there some way to hack around this problem by
retro-feeding the "rotate" request to the decoder when the render
gets it?
Obviously, that means applying the rotation request to the wrong frames
But if the same rotation is applied for the duration of a complete movie
(which is rather likely), it means just the first few frames would
be incorrect.
Obviously, a "major ugly hack", but if it can be made to work, it might
just be good enough in practice, while we wait for vdpau to fix
this problem.


Stefan

-- 
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 bis 12/25] mtd: nand: use the mtd instance embedded in struct nand_chip

2015-12-08 Thread Brian Norris
Hi Boris,

On Wed, Dec 02, 2015 at 09:50:01AM +0100, Boris Brezillon wrote:
> struct nand_chip now embeds an mtd device. Patch all drivers to make use
> of this mtd instance instead of using the instance embedded in their
> private struct or dynamically allocated.
> 
> Signed-off-by: Boris Brezillon 
> Cc: Julia Lawall 
> ---
> Most of those changes were generated with the coccinelle script added
> in commit c671312 "coccinelle: nand: detect and correct drivers embedding
> an mtd_info object"
> ---
> Changes since v2:
> - fix several compilation errors/warnings
> 
>  drivers/mtd/nand/ams-delta.c   | 13 ++--
>  drivers/mtd/nand/atmel_nand.c  | 13 ++--
>  drivers/mtd/nand/au1550nd.c| 19 ++---
>  drivers/mtd/nand/bcm47xxnflash/bcm47xxnflash.h |  1 -
>  drivers/mtd/nand/bcm47xxnflash/main.c  |  8 ++-
>  drivers/mtd/nand/bcm47xxnflash/ops_bcm4706.c   |  2 +-
>  drivers/mtd/nand/bf5xx_nand.c  | 12 ++--
>  drivers/mtd/nand/brcmnand/brcmnand.c   | 13 ++--
>  drivers/mtd/nand/cafe_nand.c   |  8 +--
>  drivers/mtd/nand/cmx270_nand.c | 11 ++-

There's another error here, I think ^^^

>  drivers/mtd/nand/cs553x_nand.c | 13 ++--
>  drivers/mtd/nand/davinci_nand.c| 30 
>  drivers/mtd/nand/denali.c  | 68 ++
>  drivers/mtd/nand/denali.h  |  1 -
>  drivers/mtd/nand/diskonchip.c  | 11 ++-
>  drivers/mtd/nand/docg4.c   | 23 +++---
>  drivers/mtd/nand/fsl_elbc_nand.c   | 26 ---
>  drivers/mtd/nand/fsl_ifc_nand.c| 28 
>  drivers/mtd/nand/fsl_upm.c | 28 
>  drivers/mtd/nand/fsmc_nand.c   | 56 ---
>  drivers/mtd/nand/gpio.c| 20 +++---
>  drivers/mtd/nand/gpmi-nand/gpmi-lib.c  |  2 +-
>  drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 23 +++---
>  drivers/mtd/nand/gpmi-nand/gpmi-nand.h |  1 -
>  drivers/mtd/nand/hisi504_nand.c| 13 ++--
>  drivers/mtd/nand/jz4740_nand.c |  9 ++-
>  drivers/mtd/nand/lpc32xx_mlc.c |  7 +-
>  drivers/mtd/nand/lpc32xx_slc.c |  7 +-
>  drivers/mtd/nand/mpc5121_nfc.c |  3 +-
>  drivers/mtd/nand/mxc_nand.c|  5 +-
>  drivers/mtd/nand/nandsim.c | 12 ++--
>  drivers/mtd/nand/ndfc.c| 24 ---
>  drivers/mtd/nand/nuc900_nand.c | 24 +++
>  drivers/mtd/nand/omap2.c   | 98 
> +++---
>  drivers/mtd/nand/orion_nand.c  |  4 +-
>  drivers/mtd/nand/pasemi_nand.c | 12 ++--
>  drivers/mtd/nand/plat_nand.c   | 15 ++--
>  drivers/mtd/nand/pxa3xx_nand.c | 33 -
>  drivers/mtd/nand/r852.c| 34 -
>  drivers/mtd/nand/r852.h|  1 -
>  drivers/mtd/nand/s3c2410.c | 23 +++---
>  drivers/mtd/nand/sh_flctl.c|  8 +--
>  drivers/mtd/nand/sharpsl.c | 22 +++---
>  drivers/mtd/nand/socrates_nand.c   |  5 +-
>  drivers/mtd/nand/sunxi_nand.c  | 13 ++--
>  drivers/mtd/nand/tmio_nand.c   | 10 +--
>  drivers/mtd/nand/txx9ndfmc.c   |  3 +-
>  drivers/mtd/nand/vf610_nfc.c   |  8 ++-
>  include/linux/mtd/sh_flctl.h   |  3 +-
>  49 files changed, 432 insertions(+), 394 deletions(-)
> 

...

> diff --git a/drivers/mtd/nand/cmx270_nand.c b/drivers/mtd/nand/cmx270_nand.c
> index 43bded6..84d027e 100644
> --- a/drivers/mtd/nand/cmx270_nand.c
> +++ b/drivers/mtd/nand/cmx270_nand.c
> @@ -160,10 +160,8 @@ static int __init cmx270_init(void)
>   gpio_direction_input(GPIO_NAND_RB);
>  
>   /* Allocate memory for MTD device structure and private data */
> - cmx270_nand_mtd = kzalloc(sizeof(struct mtd_info) +
> -   sizeof(struct nand_chip),
> -   GFP_KERNEL);
> - if (!cmx270_nand_mtd) {
> + this = kzalloc(sizeof(struct nand_chip), GFP_KERNEL);
> + if (!this) {
>   ret = -ENOMEM;
>   goto err_kzalloc;
>   }
> @@ -175,8 +173,7 @@ static int __init cmx270_init(void)
>   goto err_ioremap;
>   }
>  
> - /* Get pointer to private data */
> - this = (struct nand_chip *)(_nand_mtd[1]);
> + cmx270_nand_mtd = nand_to_mtd(this);

So, you make cmx270_nand_mtd no longer kzalloc()'d, but I still see the
cmx270_init() function end with:

err_scan:
iounmap(cmx270_nand_io);
err_ioremap:
kfree(cmx270_nand_mtd);  <- *** this! ***
err_kzalloc:
gpio_free(GPIO_NAND_RB);
err_gpio_request:

[linux-sunxi] Re: Stability Issues with A33 & Mainline

2015-12-08 Thread wens Tsai
On Tue, Dec 8, 2015 at 4:01 PM, Maxime Ripard
 wrote:
> Hi,
>
> On Tue, Dec 01, 2015 at 10:11:51PM +0800, wens Tsai wrote:
>> Hi,
>>
>> I'm having some weird stability issues with my SinA33.
>>
>> After idling a while (a few hours ~ a day) it becomes non-responsive
>> and just keeps outputting the same message:
>>
>> [53418.712180] Task dump for CPU 0:
>> [53418.715403] cronR running  0  1131  1 0x0003
>> [53418.721780] [] (__schedule) from [<2013>] (0x2013)
>> [53496.741465] INFO: rcu_sched detected stalls on CPUs/tasks:
>> [53496.746963]  0-...: (2 GPs behind) idle=ba3/141/0
>> softirq=127599/127600 fqs=369299
>> [53496.755646]  (detected by 1, t=369437 jiffies, g=78644, c=78643, q=67)
>>
>> Maybe something is not getting enough power.
>>
>> Wondering if anyone else has seen similar problems?
>
> Last time I used mine, I couldn't see anything like this.
>
> Have you tried bisecting it?

Not really.

It's been running nicely for 3 days now. I only rearranged my wiring.
Seems I'm the only one with this problem. I guess it's a hardware issue,
a combination of my power supply and very loose UART pins.


ChenYu

-- 
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/2] ARM: dts: sun4i: Add rikomagic mk802+ board

2015-12-08 Thread Code Kipper
>
> Are there any differences between the Rikomagic and the generic MK802?

Hi Julian,

In the covering letter I mention this
https://groups.google.com/d/msg/linux-sunxi/Az9Dy6tPfqQ/ZMYwKWznAAAJ
and also that we could always use the original mk802 dts for the
differences.

BR,
CK

>
> You could just add another compatible to the original MK802 dts if there 
> aren't.
>
> Thanks,
>
> --
> Julian Calaby
>
> Email: julian.cal...@gmail.com
> Profile: http://www.google.com/profiles/julian.calaby/

-- 
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-boards 3/3] h3: Update cpufreq and cooling state tables on Orange Pi PC

2015-12-08 Thread Siarhei Siamashka
The current FEX file does not allow the CPU frequencies higher
than 1.2GHz and also sets the VDD_CPUX voltage to 1.3V (the
cooling states table overrides the questionable 1536MHz @1.5V
cpufreq operating point).

The comments in FEX files from H3 SDK sources are describing
the cpufreq operating points and looks like the information
provided by Allwinner (the same comments are also present
in the Draco H3 SDK). So use these operating points instead.
Also the H3 datasheet specifies 1.5V as the absolute maximum
for the VDD_CPUX voltage and 1.4V as the recommended maximum.
The datasheet says that "Absolute Maximum Ratings are those
values beyond which damage to the device may occur" and
"Functional operation of the device *at these* or any other
conditions beyond those indicated in the operational sections
of this standard may damage to the device". Basically, the
recommended voltage limit is 1.4V while the range between
1.4V and 1.5V is a buffer zone for extra safety. For this
reason, the 1536MHz operating point is removed. Tests with
libjpeg-turbo decoding show that there is at least some
safety headroom (no corruption detected until these voltages
are reduced by more than 0.07V).

Regarding the cooling states, the old FEX file was instructing
the kernel to disable CPU cores as the temperature increases
while keeping the CPU clock speed limit at all the same 1.2GHz.
Probably the intention was to ensure that the single-threaded
performance remains good. But the problem with this approach is
that once a CPU core is disabled, it does not  come back anymore
when using the Allwinner's 3.4 SDK kernel. An alternative
solution is to keep all the CPU cores operational as long as
possible, but reduce the CPU clock speed limit at higher
temperatures. Such adjustment is also done by this patch.

Signed-off-by: Siarhei Siamashka 
---
 sys_config/h3/xunlong_orange_pi_pc.fex | 86 --
 1 file changed, 52 insertions(+), 34 deletions(-)

diff --git a/sys_config/h3/xunlong_orange_pi_pc.fex 
b/sys_config/h3/xunlong_orange_pi_pc.fex
index 56a9b60..88ee928 100644
--- a/sys_config/h3/xunlong_orange_pi_pc.fex
+++ b/sys_config/h3/xunlong_orange_pi_pc.fex
@@ -263,13 +263,13 @@ red_led_active_low = 0
 
 [ths_para]
 ths_used = 1
-ths_trip1_count = 5
+ths_trip1_count = 6
 ths_trip1_0 = 70
 ths_trip1_1 = 80
-ths_trip1_2 = 90
-ths_trip1_3 = 100
-ths_trip1_4 = 105
-ths_trip1_5 = 0
+ths_trip1_2 = 85
+ths_trip1_3 = 90
+ths_trip1_4 = 95
+ths_trip1_5 = 100
 ths_trip1_6 = 0
 ths_trip1_7 = 0
 ths_trip1_0_min = 0
@@ -281,21 +281,22 @@ ths_trip1_2_max = 3
 ths_trip1_3_min = 3
 ths_trip1_3_max = 4
 ths_trip1_4_min = 4
-ths_trip1_4_max = 4
-ths_trip1_5_min = 0
-ths_trip1_5_max = 0
+ths_trip1_4_max = 5
+ths_trip1_5_min = 5
+ths_trip1_5_max = 5
 ths_trip1_6_min = 0
 ths_trip1_6_max = 0
 ths_trip2_count = 1
 ths_trip2_0 = 105
 
 [cooler_table]
-cooler_count = 5
-cooler0 = "120 4 4294967295 0"
-cooler1 = "120 3 4294967295 0"
-cooler2 = "120 2 4294967295 0"
-cooler3 = "120 1 4294967295 0"
-cooler4 = "504000 1 4294967295 0"
+cooler_count = 6
+cooler0 = "1296000 4 4294967295 0"
+cooler1 = "120 4 4294967295 0"
+cooler2 = "1008000 4 4294967295 0"
+cooler3 =  "816000 4 4294967295 0"
+cooler4 =  "648000 4 4294967295 0"
+cooler5 =  "48 1 4294967295 0"
 
 [nand0_para]
 nand_support_2ch = 0
@@ -709,37 +710,54 @@ ir_addr_code12 = 65344
 ir_used = 1
 ir_tx = port:PH07<2>
 
+;--
+; dvfs voltage-frequency table configuration
+;
+; pmuic_type:0:none, 1:gpio, 2:i2c
+; pmu_gpio0: gpio config.
+; pmu_levelx: 0~: voltage(mV), 1~9:gpio0 state. voltage form high 
to low.
+;
+; extremity_freq(Hz): cpu extremity frequency when run benckmark or demo apk
+; 1536MHz@1500mV with radiator, 1296MHz@1340mV without 
radiator
+; max_freq: cpu maximum frequency, based on Hz, can not be more than 1200MHz
+; min_freq: cpu minimum frequency, based on Hz, can not be less than 60MHz
+;
+; LV_count: count of LV_freq/LV_volt, must be < 16
+;
+; LV1: core vdd is 1.50v if cpu frequency is (1296Mhz,  1536Mhz]
+; LV2: core vdd is 1.34v if cpu frequency is (1200Mhz,  1296Mhz]
+; LV3: core vdd is 1.32v if cpu frequency is (1008Mhz,  1200Mhz]
+; LV4: core vdd is 1.20v if cpu frequency is (816Mhz,   1008Mhz]
+; LV5: core vdd is 1.10v if cpu frequency is (648Mhz,816Mhz]
+; LV6: core vdd is 1.04v if cpu frequency is (0Mhz,  648Mhz]
+; LV7: core vdd is 1.04v if cpu frequency is (0Mhz,  648Mhz]
+; LV8: core vdd is 1.04v if cpu frequency is (0Mhz,  648Mhz]
+;
+;--
 [dvfs_table]
 pmuic_type = 2
 pmu_gpio0 = port:PL06<1><1><2><1>
 pmu_level0 = 11300
 pmu_level1 = 1100
-#max_freq = 12
-max_freq = 153600
-min_freq = 48000
+max_freq = 129600
+min_freq = 64800
 LV_count = 8
-#LV1_freq = 12

[linux-sunxi] [PATCH sunxi-boards 1/3] h3: Add fex file for Orange Pi PC

2015-12-08 Thread Siarhei Siamashka
Extracted from the Lubuntu_1404_For_OrangePiPC_v0_8_0_.img.xz image:
http://www.orangepi.org/downloadresources/orangepipc/oragepipc_4a0e8d960f7f0a52606dfaba58.html

Not necessarily the best one, but at least it comes from the
board manufacturer and may be used as a starting point for
further improvements.

Signed-off-by: Siarhei Siamashka 
---
 sys_config/h3/xunlong_orange_pi_pc.fex | 814 +
 1 file changed, 814 insertions(+)
 create mode 100644 sys_config/h3/xunlong_orange_pi_pc.fex

diff --git a/sys_config/h3/xunlong_orange_pi_pc.fex 
b/sys_config/h3/xunlong_orange_pi_pc.fex
new file mode 100644
index 000..93e8c4c
--- /dev/null
+++ b/sys_config/h3/xunlong_orange_pi_pc.fex
@@ -0,0 +1,814 @@
+[product]
+version = "100"
+machine = "orangepi-plus"
+
+[platform]
+debug_mode = 1
+eraseflag = 1
+next_work = 2
+
+[target]
+#boot_clock = 1008
+boot_clock = 1200
+storage_type = -1
+
+[key_detect_en]
+keyen_flag = 0
+
+[fel_key]
+fel_key_max = 7
+fel_key_min = 2
+
+[card_boot]
+logical_start = 40960
+sprite_work_delay = 500
+sprite_err_delay = 200
+sprite_gpio0 = port:PA15<1>
+next_work = 3
+
+[box_start_os]
+used = 1
+start_type = 1
+irkey_used = 1
+pmukey_used = 1
+pmukey_num = 3
+led_power = 0
+led_state = 0
+
+[boot_init_gpio]
+used = 1
+gpio0 = port:PA15<1><1>
+gpio1 = port:PG11<1><1>
+
+[recovery_para]
+used = 1
+mode = 2
+recovery_key = port:PL04<0>
+
+[pm_para]
+standby_mode = 1
+
+[card0_boot_para]
+card_ctrl = 0
+card_high_speed = 1
+card_line = 4
+sdc_d1 = port:PF00<2><1><2>
+sdc_d0 = port:PF01<2><1><2>
+sdc_clk = port:PF02<2><1><2>
+sdc_cmd = port:PF03<2><1><2>
+sdc_d3 = port:PF04<2><1><2>
+sdc_d2 = port:PF05<2><1><2>
+
+[card2_boot_para]
+card_ctrl = 2
+card_high_speed = 1
+card_line = 8
+sdc_cmd = port:PC06<3><1><2>
+sdc_clk = port:PC05<3><1><2>
+sdc_d0 = port:PC08<3><1><2>
+sdc_d1 = port:PC09<3><1><2>
+sdc_d2 = port:PC10<3><1><2>
+sdc_d3 = port:PC11<3><1><2>
+sdc_d4 = port:PC12<3><1><2>
+sdc_d5 = port:PC13<3><1><2>
+sdc_d6 = port:PC14<3><1><2>
+sdc_d7 = port:PC15<3><1><2>
+sdc_2xmode = 1
+sdc_ddrmode = 1
+
+[twi_para]
+twi_port = 0
+twi_scl = port:PA11<2>
+twi_sda = port:PA12<2>
+
+[uart_para]
+uart_debug_port = 0
+uart_debug_tx = port:PA04<2><1>
+uart_debug_rx = port:PA05<2><1>
+
+[force_uart_para]
+force_uart_port = 0
+force_uart_tx = port:PF02<3><1>
+force_uart_rx = port:PF04<3><1>
+
+[jtag_para]
+jtag_enable = 0
+jtag_ms = port:PA00<3>
+jtag_ck = port:PA01<3>
+jtag_do = port:PA02<3>
+jtag_di = port:PA03<3>
+
+[clock]
+pll_video = 297
+pll_ve = 402
+pll_periph0 = 600
+pll_gpu = 576
+pll_periph1 = 600
+pll_de = 864
+
+[dram_para]
+dram_clk = 672
+dram_type = 3
+dram_zq = 0x3b3bfb
+dram_odt_en = 1
+dram_para1 = 283377664
+dram_para2 = 0
+dram_mr0 = 6208
+dram_mr1 = 64
+dram_mr2 = 24
+dram_mr3 = 2
+dram_tpr0 = 0x48a192
+dram_tpr1 = 0x1c2418d
+dram_tpr2 = 0x76051
+dram_tpr3 = 0x0
+dram_tpr4 = 0x0
+dram_tpr5 = 0x0
+dram_tpr6 = 0x64
+dram_tpr7 = 0x0
+dram_tpr8 = 0x0
+dram_tpr9 = 0x0
+dram_tpr10 = 0x0
+dram_tpr11 = 0x6aaa
+dram_tpr12 = 0x7979
+dram_tpr13 = 0x800800
+
+[wakeup_src_para]
+cpu_en = 0
+cpu_freq = 48
+pll_ratio = 273
+dram_selfresh_en = 1
+dram_freq = 36
+wakeup_src0 =
+wakeup_src_wl = port:PG10<4><0>
+
+[twi0]
+twi_used = 1
+twi_scl = port:PA11<2>
+twi_sda = port:PA12<2>
+
+[twi1]
+twi_used = 0
+twi_scl = port:PA18<3>
+twi_sda = port:PA19<3>
+
+[twi2]
+twi_used = 0
+twi_scl = port:PE12<3>
+twi_sda = port:PE13<3>
+
+[uart0]
+uart_used = 1
+uart_port = 0
+uart_type = 2
+uart_tx = port:PA04<2><1>
+uart_rx = port:PA05<2><1>
+
+[uart1]
+uart_used = 0
+uart_port = 1
+uart_type = 4
+uart_tx = port:PG06<2><1>
+uart_rx = port:PG07<2><1>
+uart_rts = port:PG08<2><1>
+uart_cts = port:PG09<2><1>
+
+[uart2]
+uart_used = 0
+uart_port = 2
+uart_type = 4
+uart_tx = port:PA00<2><1>
+uart_rx = port:PA01<2><1>
+uart_rts = port:PA02<2><1>
+uart_cts = port:PA03<2><1>
+
+[uart3]
+uart_used = 0
+uart_port = 3
+uart_type = 4
+uart_tx = port:PA13<3><1>
+uart_rx = port:PA14<3><1>
+uart_rts = port:PA15<3><1>
+uart_cts = port:PA16<3><1>
+
+[spi0]
+spi_used = 0
+spi_cs_bitmap = 1
+spi_mosi = port:PC00<3>
+spi_miso = port:PC01<3>
+spi_sclk = port:PC02<3>
+spi_cs0 = port:PC03<3><1>
+
+[spi1]
+spi_used = 0
+spi_cs_bitmap = 1
+spi_cs0 = port:PA13<2><1>
+spi_sclk = port:PA14<2>
+spi_mosi = port:PA15<2>
+spi_miso = port:PA16<2>
+
+[spi_devices]
+spi_dev_num = 1
+
+[spi_board0]
+modalias = "m25p32"
+max_speed_hz = 3300
+bus_num = 0
+chip_select = 0
+mode = 0
+
+[gpio_para]
+gpio_used = 1
+gpio_num = 30
+gpio_pin_1 = port:PL10<1><1>
+gpio_pin_2 = port:PA15<1><0>
+gpio_pin_3 = port:PA12<1><0>
+gpio_pin_4 = port:PA11<1><0>
+gpio_pin_5 = port:PA06<1><0>
+gpio_pin_6 = port:PA13<1><0>
+gpio_pin_7 = port:PA14<1><0>
+gpio_pin_8 = port:PA01<1><0>
+gpio_pin_9 = port:PD14<1><0>
+gpio_pin_10 = port:PA00<1><0>
+gpio_pin_11 = port:PA03<1><0>
+gpio_pin_12 = port:PC04<1><0>
+gpio_pin_13 = port:PC07<1><0>
+gpio_pin_14 = port:PC00<1><0>
+gpio_pin_15 = port:PC01<1><0>

[linux-sunxi] [PATCH sunxi-boards 2/3] h3: Make LEDs available in /sys/class/leds on Orange Pi PC

2015-12-08 Thread Siarhei Siamashka
This patch makes both red and green LEDs available in /sys/class/leds
instead of probably having them reserved for some special purposes
(such as a standby mode indicator?). Being able to control the state
of LEDs from applications and scripts is quite useful.

Signed-off-by: Siarhei Siamashka 
---
 sys_config/h3/xunlong_orange_pi_pc.fex | 17 -
 1 file changed, 12 insertions(+), 5 deletions(-)

diff --git a/sys_config/h3/xunlong_orange_pi_pc.fex 
b/sys_config/h3/xunlong_orange_pi_pc.fex
index 93e8c4c..56a9b60 100644
--- a/sys_config/h3/xunlong_orange_pi_pc.fex
+++ b/sys_config/h3/xunlong_orange_pi_pc.fex
@@ -219,8 +219,8 @@ mode = 0
 [gpio_para]
 gpio_used = 1
 gpio_num = 30
-gpio_pin_1 = port:PL10<1><1>
-gpio_pin_2 = port:PA15<1><0>
+; gpio_pin_1 = port:PL10<1><1>
+; gpio_pin_2 = port:PA15<1><0>
 gpio_pin_3 = port:PA12<1><0>
 gpio_pin_4 = port:PA11<1><0>
 gpio_pin_5 = port:PA06<1><0>
@@ -250,9 +250,16 @@ gpio_pin_28 = port:PA20<1><0>
 gpio_pin_29 = port:PG06<1><0>
 gpio_pin_30 = port:PG07<1><0>
 
-[led_assign]
-normal_led = "gpio_pin_2"
-standby_led = "gpio_pin_1"
+;[led_assign]
+;normal_led = "gpio_pin_2"
+;standby_led = "gpio_pin_1"
+
+[leds_para]
+leds_used = 1
+green_led = port:PL10<1><0>
+green_led_active_low = 0
+red_led = port:PA15<1><0>
+red_led_active_low = 0
 
 [ths_para]
 ths_used = 1
-- 
2.4.10

-- 
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.