[linux-sunxi] Re: [PATCH v5 2/4] arm64: dts: add Allwinner A64 SoC .dtsi

2016-10-23 Thread André Przywara
On 20/10/16 19:00, Maxime Ripard wrote:

Hi Maxime,

> From: Andre Przywara 
> 
> The Allwinner A64 SoC is a low-cost chip with 4 ARM Cortex-A53 cores
> and the typical tablet / TV box peripherals.
> The SoC is based on the (32-bit) Allwinner H3 chip, sharing most of
> the peripherals and the memory map.
> Although the cores are proper 64-bit ones, the whole SoC is actually
> limited to 4GB (including all the supported DRAM), so we use 32-bit
> address and size cells. This has the nice feature of us being able to
> reuse the DT for 32-bit kernels as well.
> This .dtsi lists the hardware that we support so far.
> 
> Signed-off-by: Andre Przywara 
> Acked-by: Rob Herring 
> Acked-by: Chen-Yu Tsai 
> [Maxime: Convert to CCU binding, drop the MMC support for now]
> Signed-off-by: Maxime Ripard 
> ---
>  Documentation/devicetree/bindings/arm/sunxi.txt |   1 +-
>  MAINTAINERS |   1 +-
>  arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi   | 263 +-
>  3 files changed, 265 insertions(+), 0 deletions(-)
>  create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> 
> diff --git a/Documentation/devicetree/bindings/arm/sunxi.txt 
> b/Documentation/devicetree/bindings/arm/sunxi.txt
> index 3975d0a0e4c2..4d6467cc2aa2 100644
> --- a/Documentation/devicetree/bindings/arm/sunxi.txt
> +++ b/Documentation/devicetree/bindings/arm/sunxi.txt
> @@ -14,4 +14,5 @@ using one of the following compatible strings:
>allwinner,sun8i-a83t
>allwinner,sun8i-h3
>allwinner,sun9i-a80
> +  allwinner,sun50i-a64
>nextthing,gr8
> diff --git a/MAINTAINERS b/MAINTAINERS
> index 1cd38a7e0064..86488e92655f 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -1019,6 +1019,7 @@ L:  linux-arm-ker...@lists.infradead.org (moderated 
> for non-subscribers)
>  S:   Maintained
>  N:   sun[x456789]i
>  F:   arch/arm/boot/dts/ntc-gr8*
> +F:   arch/arm64/boot/dts/allwinner/
>  
>  ARM/Allwinner SoC Clock Support
>  M:   Emilio López 
> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi 
> b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> new file mode 100644
> index ..be51024743b4
> --- /dev/null
> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> @@ -0,0 +1,263 @@
> +/*
> + * Copyright (C) 2016 ARM Ltd.
> + * based on the Allwinner H3 dtsi:
> + *Copyright (C) 2015 Jens Kuske 
> + *
> + * 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 
> +#include 
> +#include 
> +#include 
> +
> +/ {
> + interrupt-parent = <>;
> + #address-cells = <1>;
> + #size-cells = <1>;
> +
> + cpus {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + cpu0: cpu@0 {
> + compatible = "arm,cortex-a53", "arm,armv8";
> + device_type = "cpu";
> + reg = 

[linux-sunxi] Re: [PATCH 01/14] dma: sun6i-dma: Add burst case of 4

2016-10-23 Thread Jean-Francois Moine
On Tue, 4 Oct 2016 18:55:54 +0200
Maxime Ripard  wrote:

> On Tue, Oct 04, 2016 at 12:40:11PM +0200, Jean-Francois Moine wrote:
> > On Tue,  4 Oct 2016 11:46:14 +0200
> > Mylène Josserand  wrote:
> > 
> > > Add the case of a burst of 4 which is handled by the SoC.
> > > 
> > > Signed-off-by: Mylène Josserand 
> > > ---
> > >  drivers/dma/sun6i-dma.c | 2 ++
> > >  1 file changed, 2 insertions(+)
> > > 
> > > diff --git a/drivers/dma/sun6i-dma.c b/drivers/dma/sun6i-dma.c
> > > index 8346199..0485204 100644
> > > --- a/drivers/dma/sun6i-dma.c
> > > +++ b/drivers/dma/sun6i-dma.c
> > > @@ -240,6 +240,8 @@ static inline s8 convert_burst(u32 maxburst)
> > >   switch (maxburst) {
> > >   case 1:
> > >   return 0;
> > > + case 4:
> > > + return 1;
> > >   case 8:
> > >   return 2;
> > >   default:
> > > -- 
> > > 2.9.3
> > 
> > This patch has already been rejected by Maxime in the threads
> > http://www.spinics.net/lists/dmaengine/msg08610.html
> > and
> > http://www.spinics.net/lists/dmaengine/msg08719.html
> > 
> > I hope you will find the way he wants for this maxburst to be added.
> 
> I was talking about something along these lines (not tested):

I wonder why you don't submit this yourself.

> ---8<-
> diff --git a/drivers/dma/sun6i-dma.c b/drivers/dma/sun6i-dma.c
> index 83461994e418..573ac4608293 100644
> --- a/drivers/dma/sun6i-dma.c
> +++ b/drivers/dma/sun6i-dma.c
> @@ -240,6 +240,8 @@ static inline s8 convert_burst(u32 maxburst)
>   switch (maxburst) {
>   case 1:
>   return 0;
> + case 4:
> + return 1;
>   case 8:
>   return 2;
>   default:
> @@ -1110,11 +1112,19 @@ static int sun6i_dma_probe(struct platform_device 
> *pdev)
>   sdc->slave.dst_addr_widths  = 
> BIT(DMA_SLAVE_BUSWIDTH_1_BYTE) |
> 
> BIT(DMA_SLAVE_BUSWIDTH_2_BYTES) |
> 
> BIT(DMA_SLAVE_BUSWIDTH_4_BYTES);
> + sdc->slave.dst_bursts   = BIT(1) | BIT(8);
> + sdc->slave.src_bursts   = BIT(1) | BIT(8);
>   sdc->slave.directions   = BIT(DMA_DEV_TO_MEM) |
> BIT(DMA_MEM_TO_DEV);
>   sdc->slave.residue_granularity  = DMA_RESIDUE_GRANULARITY_BURST;
>   sdc->slave.dev = >dev;
>  
> + if (of_device_is_compatible(pdev->dev.of_node,
> + "allwinner,sun8i-h3-dma")) {
> + sdc->slave.dst_bursts |= BIT(4);
> + sdc->slave.src_bursts |= BIT(4);
> + }
> +
>   sdc->pchans = devm_kcalloc(>dev, sdc->cfg->nr_max_channels,
>  sizeof(struct sun6i_pchan), GFP_KERNEL);
>   if (!sdc->pchans)
> diff --git a/include/linux/dmaengine.h b/include/linux/dmaengine.h
> index cc535a478bae..f7bbec24bb58 100644
> --- a/include/linux/dmaengine.h
> +++ b/include/linux/dmaengine.h
> @@ -673,6 +673,8 @@ struct dma_filter {
>   *   each type of direction, the dma controller should fill (1 <<
>   *   ) and same should be checked by controller as well
>   * @max_burst: max burst capability per-transfer
> + * @dst_bursts: bitfield of the available burst sizes for the destination
> + * @src_bursts: bitfield of the available burst sizes for the source

You did not define dst_bursts nor src_bursts.

>   * @residue_granularity: granularity of the transfer residue reported
>   *   by tx_status
>   * @device_alloc_chan_resources: allocate resources and return the
> @@ -800,6 +802,14 @@ struct dma_device {
>  static inline int dmaengine_slave_config(struct dma_chan *chan,
> struct dma_slave_config *config)
>  {
> + if (config->src_maxburst && config->device->src_bursts &&
> + !(BIT(config->src_maxburst) & config->device->src_bursts))

The maxburst may be as big as 4Kibytes, then, I am not sure that this
code will work!

> + return -EINVAL;
> +
> + if (config->dst_maxburst && config->device->dst_bursts &&
> + !(BIT(config->dst_maxburst) & config->device->dst_bursts))
> + return -EINVAL;
> +
>   if (chan->device->device_config)
>   return chan->device->device_config(chan, config);
> ---8< 

Yes, I know that the burst size is always a power of 2.
The best way to check it would be to change the {src,dts}_maxburst to a
bitmap of the possible bursts as 0x0d for 1,4 and 8 bytes. But this
asks for a lot of changes...

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

Re: [linux-sunxi] [PATCH v5 0/7] ARM: ASoC: drm: sun8i: Add DE2 HDMI audio and video

2016-10-23 Thread Jean-François Moine
Hi Ondřej,

I don't use the sunxi-ng driver which is too complicated and asks for a 
complete rewrite
for the A83T (you may find my own driver in my site - bug fixes to come).
Especially, in my ccu clk driver, the resets and bus gates functions are 
included in the main
clocks and I forgot to add the gates in the sun8i-h3.dtsi.

About audio, there are some problems:
- I discovered a bug with set_rate_parent in the clock driver: it does not 
work when the parent
  clock has a rate close enough to the wanted rate, It did work for me with 
the H3 but not with
  the A83T. I fixed it in my ccu clk, but this bug also exists in sunxi-ng.
- the burst width is 4 for the H3 and this value is refused by the DMA 
driver. I will submit a
  new patch soon.

Otherwise, I am using the legacy u-boot which sets most clocks. With the 
official u-boot, setting
some clocks by the kernel may be wrong, as you point to by adding more 
set_rate_parent.
I will fix this in my ccu driver, thanks.

On Sunday, October 23, 2016 at 11:57:03 AM UTC+2, Ondřej Jirman wrote:
>
> Dne 22.10.2016 v 15:28 Jean-Francois Moine napsal(a): 
> > This patchset series adds HDMI audio and video support to the Allwinner 
> > sun8i SoCs which include the display engine 2 (DE2). 
>
> Hi, 
>
> I've tested your patches on top of my 4.9-rc1 changes on Orange Pi PC, 
> and HDMI display output works well -- with some changes to sunxi-ng H3 
> clock driver. I've put those changes here: 
>
>   https://github.com/megous/linux/commits/orange-pi-4.9-hdmi 
>
> When I run firefox, it feels faster and less laggy than armbian 3.4 
> desktop. Very nice! 
>
> The only issue that I've found, is that clk setup for ASoC driver fails 
> with EINVAL. 
>
> When I run pulseaudio, dmesg is filled with this: 
>
> [   29.951468] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw 
> params: -22 
> [   29.969184] Setting sysclk rate failed -22 
> [   29.982440] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw 
> params: -22 
> [   30.000148] Setting sysclk rate failed -22 
> [   30.013398] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw 
> params: -22 
> [   30.032790] Setting sysclk rate failed -22 
> [   30.044411] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw 
> params: -22 
> [   30.062252] Setting sysclk rate failed -22 
>
> What do you base your patches on? Do you have some patches for the 
> sunxi-ng H3 clock driver that are required for this to work? 
>
> thank you and regards, 
>   o. 
>
>

-- 
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 v5 0/7] ARM: ASoC: drm: sun8i: Add DE2 HDMI audio and video

2016-10-23 Thread Ondřej Jirman
Dne 22.10.2016 v 15:28 Jean-Francois Moine napsal(a):
> This patchset series adds HDMI audio and video support to the Allwinner
> sun8i SoCs which include the display engine 2 (DE2).

Hi,

I've tested your patches on top of my 4.9-rc1 changes on Orange Pi PC,
and HDMI display output works well -- with some changes to sunxi-ng H3
clock driver. I've put those changes here:

  https://github.com/megous/linux/commits/orange-pi-4.9-hdmi

When I run firefox, it feels faster and less laggy than armbian 3.4
desktop. Very nice!

The only issue that I've found, is that clk setup for ASoC driver fails
with EINVAL.

When I run pulseaudio, dmesg is filled with this:

[   29.951468] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw
params: -22
[   29.969184] Setting sysclk rate failed -22
[   29.982440] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw
params: -22
[   30.000148] Setting sysclk rate failed -22
[   30.013398] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw
params: -22
[   30.032790] Setting sysclk rate failed -22
[   30.044411] sun8i-audio 1c22800.i2s: ASoC: can't set 1c22800.i2s hw
params: -22
[   30.062252] Setting sysclk rate failed -22

What do you base your patches on? Do you have some patches for the
sunxi-ng H3 clock driver that are required for this to work?

thank you and regards,
  o.

> A first submission in January for video on the H3 could not enter into
> the mainline kernel due to the lack of license headers in Allwinner's
> sources.
> 
> Recently, an announce about Tina OS for the R series
>   https://www.youtube.com/watch?v=h7KD-6HblAU
> was followed by the upload of a new linux-3.4 source tree
>   https://github.com/tinalinux/linux-3.4
> with files containing GPL headers.
> 
> Well, I don't know if these sources are really from Allwinner, but
> anyway, this is the opportunity to propose a new version of my DRM
> HDMI driver.
> 
> v5:
>   - add overlay plane
>   - add audio support
>   - add support for the A83T
>   - add back the HDMI driver
>   - many bug fixes
> v4: 
>   - drivers/clk/sunxi/Makefile was missing (Emil Velikov)
> v3:
>   - add the hardware cursor
>   - simplify and fix the DE2 init sequences
>   - generation for all SUNXI SoCs (Andre Przywara)
> v2:
>   - remove the HDMI driver
>   - remarks from Chen-Yu Tsai and Russell King
>   - DT documentation added
> 
> Jean-Francois Moine (7):
>   drm: sunxi: Add a basic DRM driver for Allwinner DE2
>   ASoC: sunxi: Add a simple HDMI CODEC
>   drm: sunxi: add DE2 HDMI support
>   ASoC: sunxi: Add sun8i I2S driver
>   ARM: dts: sun8i-h3: add HDMI audio and video nodes
>   ARM: dts: sun8i-h3: Add HDMI audio and video to the Banana Pi M2+
>   ARM: dts: sun8i-h3: Add HDMI audio and video to the Orange PI 2
> 
>  .../devicetree/bindings/display/sunxi/hdmi.txt |  52 ++
>  .../bindings/display/sunxi/sunxi-de2.txt   |  83 ++
>  .../devicetree/bindings/sound/sun4i-i2s.txt|  38 +-
>  arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts|  17 +
>  arch/arm/boot/dts/sun8i-h3-orangepi-2.dts  |  17 +
>  arch/arm/boot/dts/sun8i-h3.dtsi|  67 ++
>  drivers/gpu/drm/Kconfig|   2 +
>  drivers/gpu/drm/Makefile   |   1 +
>  drivers/gpu/drm/sunxi/Kconfig  |  29 +
>  drivers/gpu/drm/sunxi/Makefile |   9 +
>  drivers/gpu/drm/sunxi/de2_crtc.c   | 475 +++
>  drivers/gpu/drm/sunxi/de2_crtc.h   |  63 ++
>  drivers/gpu/drm/sunxi/de2_de.c | 591 +
>  drivers/gpu/drm/sunxi/de2_drm.h|  47 ++
>  drivers/gpu/drm/sunxi/de2_drv.c| 378 +
>  drivers/gpu/drm/sunxi/de2_hdmi.c   | 396 +
>  drivers/gpu/drm/sunxi/de2_hdmi.h   |  40 +
>  drivers/gpu/drm/sunxi/de2_hdmi_io.c| 927 
> +
>  drivers/gpu/drm/sunxi/de2_hdmi_io.h|  25 +
>  drivers/gpu/drm/sunxi/de2_plane.c  | 119 +++
>  include/sound/sunxi_hdmi.h |  23 +
>  sound/soc/codecs/Kconfig   |   9 +
>  sound/soc/codecs/Makefile  |   2 +
>  sound/soc/codecs/sunxi-hdmi.c  | 106 +++
>  sound/soc/sunxi/Kconfig|   8 +
>  sound/soc/sunxi/Makefile   |   3 +
>  sound/soc/sunxi/sun8i-i2s.c| 700 
>  27 files changed, 4222 insertions(+), 5 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/display/sunxi/hdmi.txt
>  create mode 100644 
> Documentation/devicetree/bindings/display/sunxi/sunxi-de2.txt
>  create mode 100644 drivers/gpu/drm/sunxi/Kconfig
>  create mode 100644 drivers/gpu/drm/sunxi/Makefile
>  create mode 100644 drivers/gpu/drm/sunxi/de2_crtc.c
>  create mode 100644 

[linux-sunxi] Re: [PATCH] ARM: dt: sun8i-h3: Add sunxi-sid to dts for sun8i-h3

2016-10-23 Thread LABBE Corentin
On Thu, Oct 20, 2016 at 10:36:54PM +0200, Maxime Ripard wrote:
> On Wed, Oct 19, 2016 at 09:40:16AM +0200, LABBE Corentin wrote:
> > On Wed, Oct 05, 2016 at 12:21:30PM +0200, Jean-Francois Moine wrote:
> > > On Wed,  5 Oct 2016 11:48:24 +0200
> > > Corentin Labbe  wrote:
> > > 
> > > > This patch add support for the sunxi-sid driver to the device tree for 
> > > > sun8i-h3.
> > > > 
> > > > Signed-off-by: Corentin Labbe 
> > > > ---
> > > >  arch/arm/boot/dts/sun8i-h3.dtsi | 5 +
> > > >  1 file changed, 5 insertions(+)
> > > > 
> > > > diff --git a/arch/arm/boot/dts/sun8i-h3.dtsi 
> > > > b/arch/arm/boot/dts/sun8i-h3.dtsi
> > > > index 9f58bb4..abfd29c 100644
> > > > --- a/arch/arm/boot/dts/sun8i-h3.dtsi
> > > > +++ b/arch/arm/boot/dts/sun8i-h3.dtsi
> > > > @@ -211,6 +211,11 @@
> > > > #size-cells = <0>;
> > > > };
> > > >  
> > > > +   sid: eeprom@01c14200 {
> > > > +   compatible = "allwinner,sun7i-a20-sid";
> > > > +   reg = <0x01c14200 0x200>;
> > > 
> > > The datasheet says 1Kb starting at 0x01c14000.
> > > Is there any reason to reduce the area and to shift the offset?
> > > 
> > 
> > According to http://linux-sunxi.org/SID_Register_Guide "For
> > Allwinner A83T and H3 the SID address space starts at 0x01c14000,
> > and the e-fuses are at offset 0x200".
> >
> > So I use this offset, since the sunxi_sid driver need the base
> > address of e-fuses.
> > 
> > The easiest solution is to use 0x01c14200 since the other part of
> > sid is not used and not known (A83T/H3 user manual doesnt give any
> > information on all sid space, worse for A64 which reference SID only
> > in memory map).
> > 
> > So probably for H3/A64/A83T, there will never any usage of the rest
> > of the SID address space.
> 
> And since we can't know that, and we have to maintain the DT ABI,
> using the whole address map and an offset, with a new compatible, is
> definetely the safest thing to do.
> 

I have two way of doing it, which one do you prefer ?

- Adding two optionnal properties: efuses-offset and efuses-size defaulting to 
0 and resourcesize.
- Adding a subnode called efuses with its own reg=<>

The first one is easy and didnt need any work on previous DT entries.

Regards
Corentin Labbe

-- 
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 v5 4/7] ASoC: sunxi: Add sun8i I2S driver

2016-10-23 Thread Jean-Francois Moine
On Sun, 23 Oct 2016 09:33:16 +0800
Chen-Yu Tsai  wrote:

> > Note: This driver is closed to the sun4i-i2s except that:
> > - it handles the H3
> 
> If it's close to sun4i-i2s, you should probably rework that one to support
> the newer SoCs.
> 
> > - it creates the sound card (with sun4i-i2s, the sound card is created
> >   by the CODECs)
> 
> I think this is wrong. I2S is only the DAI. You typically have a separate
> platform driver for the whole card, or just use simple-card.

An other device is not needed. The layout is simple:
I2S_controller (CPU DAI) <-> HDMI_CODEC (CODEC DAI)
The HDMI CODEC is supported by the HDMI video driver (only one device),
so, it cannot be the card device.
ASoC does not use the CPU DAI device (I2S_controller), so, it is
natural to use it to handle the card.
Otherwise, the simple-card asks for a node definition in the DT and
this node is a pure Linux software entity. On the other side, the
simple-graph-card from Kuninori is not useful for this simple case.

-- 
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 v5 0/7] ARM: ASoC: drm: sun8i: Add DE2 HDMI audio and video

2016-10-23 Thread Jean-Francois Moine
On Sun, 23 Oct 2016 09:38:04 +0800
Chen-Yu Tsai  wrote:

> > Recently, an announce about Tina OS for the R series
> > https://www.youtube.com/watch?v=h7KD-6HblAU
> > was followed by the upload of a new linux-3.4 source tree
> > https://github.com/tinalinux/linux-3.4
> > with files containing GPL headers.
> >
> > Well, I don't know if these sources are really from Allwinner, but
> > anyway, this is the opportunity to propose a new version of my DRM
> > HDMI driver.
> 
> Could you clarify about this bit? Did you just clean up Allwinner's
> existing drivers? Or just use them as reference? Either way I think
> this deserves some mention in all your copyright headers.
> 
> Otherwise what difference does the new release make?

- Allwinner's video driver is not DRM.
- their driver has no hardware cursor nor video overlay.
- I wrote the video DRM driver from the document
Allwinner_H3_Datasheet_V1.2.pdf
  and the structures defined in
linux-3.4/drivers/video/sunxi/disp2/disp/de/lowlevel_sun8iw7/de_rtmx.h
  Reading Allwinner's code helped me to understand how the DE2
  is working.
- my lowlevel HDMI is just a cleanup of theirs with explanations
  about the registers. Magic constants remain due to the lack of
  knowledge about the PHYs.
- the mention of Allwinner in the copyright headers is needed to
  indicate the source of the structures (DE2) and code (HDMI).

The main difference is the DRM interface and the use of the EDID,
permitting dynamic video resolution change with xrandr.

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