Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [nomadik:gemini-ethernet 18/18] drivers/net//ethernet/cortina/gemini.c:715:22: error: implicit declaration of function 'dma_to_pfn'; did you mean 'dma_max_pfn'?
From: kbuild test robot @ 2017-12-16 20:06 UTC (permalink / raw)
  To: linux-arm-kernel

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-nomadik.git gemini-ethernet
head:   502a2864e5e43c51a3a2689586d9c61d060a3b7d
commit: 502a2864e5e43c51a3a2689586d9c61d060a3b7d [18/18] net: ethernet: Add a driver for Gemini gigabit ethernet
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 502a2864e5e43c51a3a2689586d9c61d060a3b7d
        # save the attached .config to linux build tree
        make.cross ARCH=sh 

All error/warnings (new ones prefixed by >>):

   In file included from arch/sh/include/asm/page.h:188:0,
                    from arch/sh/include/asm/thread_info.h:15,
                    from include/linux/thread_info.h:38,
                    from include/asm-generic/preempt.h:5,
                    from ./arch/sh/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:81,
                    from include/linux/spinlock.h:51,
                    from include/linux/seqlock.h:36,
                    from include/linux/time.h:6,
                    from include/linux/stat.h:19,
                    from include/linux/module.h:10,
                    from drivers/net//ethernet/cortina/gemini.c:16:
   drivers/net//ethernet/cortina/gemini.c: In function 'gmac_cleanup_rxq':
>> drivers/net//ethernet/cortina/gemini.c:715:22: error: implicit declaration of function 'dma_to_pfn'; did you mean 'dma_max_pfn'? [-Werror=implicit-function-declaration]
      page = pfn_to_page(dma_to_pfn(geth->dev, mapping));
                         ^
   include/asm-generic/memory_model.h:69:27: note: in definition of macro '__pfn_to_page'
    ({ unsigned long __pfn = (pfn);   \
                              ^~~
>> drivers/net//ethernet/cortina/gemini.c:715:10: note: in expansion of macro 'pfn_to_page'
      page = pfn_to_page(dma_to_pfn(geth->dev, mapping));
             ^~~~~~~~~~~
   In file included from drivers/net//ethernet/cortina/gemini.c:16:0:
   drivers/net//ethernet/cortina/gemini.c: At top level:
>> include/linux/module.h:129:42: error: redefinition of '__inittest'
     static inline initcall_t __maybe_unused __inittest(void)  \
                                             ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
>> drivers/net//ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:129:42: note: previous definition of '__inittest' was here
     static inline initcall_t __maybe_unused __inittest(void)  \
                                             ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net//ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:131:6: error: redefinition of 'init_module'
     int init_module(void) __attribute__((alias(#initfn)));
         ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
>> drivers/net//ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:131:6: note: previous definition of 'init_module' was here
     int init_module(void) __attribute__((alias(#initfn)));
         ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net//ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:135:42: error: redefinition of '__exittest'
     static inline exitcall_t __maybe_unused __exittest(void)  \
                                             ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
>> drivers/net//ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:135:42: note: previous definition of '__exittest' was here
     static inline exitcall_t __maybe_unused __exittest(void)  \
                                             ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net//ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:137:7: error: redefinition of 'cleanup_module'
     void cleanup_module(void) __attribute__((alias(#exitfn)));
          ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
>> drivers/net//ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:137:7: note: previous definition of 'cleanup_module' was here
     void cleanup_module(void) __attribute__((alias(#exitfn)));
          ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net//ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from arch/sh/include/asm/page.h:188:0,
                    from arch/sh/include/asm/thread_info.h:15,
                    from include/linux/thread_info.h:38,
                    from include/asm-generic/preempt.h:5,
                    from ./arch/sh/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:81,
                    from include/linux/spinlock.h:51,
                    from include/linux/seqlock.h:36,
                    from include/linux/time.h:6,
                    from include/linux/stat.h:19,
                    from include/linux/module.h:10,
                    from drivers/net/ethernet/cortina/gemini.c:16:
   drivers/net/ethernet/cortina/gemini.c: In function 'gmac_cleanup_rxq':
   drivers/net/ethernet/cortina/gemini.c:715:22: error: implicit declaration of function 'dma_to_pfn'; did you mean 'dma_max_pfn'? [-Werror=implicit-function-declaration]
      page = pfn_to_page(dma_to_pfn(geth->dev, mapping));
                         ^
   include/asm-generic/memory_model.h:69:27: note: in definition of macro '__pfn_to_page'
    ({ unsigned long __pfn = (pfn);   \
                              ^~~
   drivers/net/ethernet/cortina/gemini.c:715:10: note: in expansion of macro 'pfn_to_page'
      page = pfn_to_page(dma_to_pfn(geth->dev, mapping));
             ^~~~~~~~~~~
   In file included from drivers/net/ethernet/cortina/gemini.c:16:0:
   drivers/net/ethernet/cortina/gemini.c: At top level:
>> include/linux/module.h:129:42: error: redefinition of '__inittest'
     static inline initcall_t __maybe_unused __inittest(void)  \
                                             ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:129:42: note: previous definition of '__inittest' was here
     static inline initcall_t __maybe_unused __inittest(void)  \
                                             ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:131:6: error: redefinition of 'init_module'
     int init_module(void) __attribute__((alias(#initfn)));
         ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:131:6: note: previous definition of 'init_module' was here
     int init_module(void) __attribute__((alias(#initfn)));
         ^
   include/linux/device.h:1513:1: note: in expansion of macro 'module_init'
    module_init(__driver##_init); \
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:135:42: error: redefinition of '__exittest'
     static inline exitcall_t __maybe_unused __exittest(void)  \
                                             ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:135:42: note: previous definition of '__exittest' was here
     static inline exitcall_t __maybe_unused __exittest(void)  \
                                             ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:137:7: error: redefinition of 'cleanup_module'
     void cleanup_module(void) __attribute__((alias(#exitfn)));
          ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2465:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/module.h:137:7: note: previous definition of 'cleanup_module' was here
     void cleanup_module(void) __attribute__((alias(#exitfn)));
          ^
   include/linux/device.h:1518:1: note: in expansion of macro 'module_exit'
    module_exit(__driver##_exit);
    ^~~~~~~~~~~
>> include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver'
     module_driver(__platform_driver, platform_driver_register, \
     ^~~~~~~~~~~~~
   drivers/net/ethernet/cortina/gemini.c:2393:1: note: in expansion of macro 'module_platform_driver'
    module_platform_driver(gemini_ethernet_port_driver);
    ^~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +715 drivers/net//ethernet/cortina/gemini.c

   681	
   682	static void gmac_cleanup_rxq(struct net_device *netdev)
   683	{
   684		struct gemini_ethernet_port *port = netdev_priv(netdev);
   685		struct gemini_ethernet *geth = port->geth;
   686		struct gmac_rxdesc *rxd = port->rxq_ring;
   687		struct nontoe_qhdr __iomem *qhdr;
   688		void __iomem *dma_reg;
   689		void __iomem *ptr_reg;
   690		dma_addr_t mapping;
   691		union dma_rwptr rw;
   692		unsigned int r, w;
   693		struct page *page;
   694	
   695		qhdr = geth->base +
   696			TOE_DEFAULT_Q_HDR_BASE(netdev->dev_id);
   697		dma_reg = &qhdr->word0;
   698		ptr_reg = &qhdr->word1;
   699	
   700		rw.bits32 = readl(ptr_reg);
   701		r = rw.bits.rptr;
   702		w = rw.bits.wptr;
   703		writew(r, ptr_reg + 2);
   704	
   705		writel(0, dma_reg);
   706	
   707		while (r != w) {
   708			mapping = rxd[r].word2.buf_adr;
   709			r++;
   710			r &= ((1 << port->rxq_order) - 1);
   711	
   712			if (!mapping)
   713				continue;
   714	
 > 715			page = pfn_to_page(dma_to_pfn(geth->dev, mapping));
   716			put_page(page);
   717		}
   718	
   719		dma_free_coherent(geth->dev, sizeof(*port->rxq_ring) << port->rxq_order,
   720				  port->rxq_ring, port->rxq_dma_base);
   721	}
   722	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 47624 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20171217/eca7bf2e/attachment-0001.gz>

^ permalink raw reply

* [PATCH 2/9] ARM: dts: Add generic ti, sysc compatible in addition to the custom ones
From: Tony Lindgren @ 2017-12-16 19:54 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171216183414.24ycqj7q2beehiiq@rob-hp-laptop>

* Rob Herring <robh@kernel.org> [171216 18:36]:
> On Fri, Dec 15, 2017 at 10:08:53AM -0800, Tony Lindgren wrote:
> > Otherwise we cannot use generic OF_DEV_AUXDATA match without listing
> > all the compatibles separately for OF_DEV_AUXDATA. Let's also update the
> > binding accordingly.
> 
> Your subject has a space in "ti,sysc".

Oops thanks for noticing, will fix.

> > Let's also fix omap4.dtsi to use "ti,sysc-omap4-sr" compatible as we
> > have documented in the binding. This was not noticed earlier as we're
> > still probing SmartReflex driver with platform data.
> > 
> > Signed-off-by: Tony Lindgren <tony@atomide.com>
> > ---
> >  Documentation/devicetree/bindings/bus/ti-sysc.txt |  1 +
> >  arch/arm/boot/dts/dra7.dtsi                       |  4 ++--
> >  arch/arm/boot/dts/omap4.dtsi                      | 20 ++++++++++----------
> >  3 files changed, 13 insertions(+), 12 deletions(-)
> 
> Otherwise,
> 
> Reviewed-by: Rob Herring <robh@kernel.org>

Thanks for looking,

Tony

^ permalink raw reply

* [PATCH net-next 1/2 v9] net: ethernet: Add DT bindings for the Gemini ethernet
From: Linus Walleij @ 2017-12-16 19:39 UTC (permalink / raw)
  To: linux-arm-kernel

This adds the device tree bindings for the Gemini ethernet
controller. It is pretty straight-forward, using standard
bindings and modelling the two child ports as child devices
under the parent ethernet controller device.

Cc: devicetree at vger.kernel.org
Cc: Tobias Waldvogel <tobias.waldvogel@gmail.com>
Cc: Micha? Miros?aw <mirq-linux@rere.qmqm.pl>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
ChangeLog v8->v9:
- Collect Rob's ACK.
ChangeLog v7->v8:
- Use ethernet-port at 0 and ethernet-port at 1 with unit names
  and following OF graph requirements.
---
 .../bindings/net/cortina,gemini-ethernet.txt       | 92 ++++++++++++++++++++++
 1 file changed, 92 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/net/cortina,gemini-ethernet.txt

diff --git a/Documentation/devicetree/bindings/net/cortina,gemini-ethernet.txt b/Documentation/devicetree/bindings/net/cortina,gemini-ethernet.txt
new file mode 100644
index 000000000000..6c559981d110
--- /dev/null
+++ b/Documentation/devicetree/bindings/net/cortina,gemini-ethernet.txt
@@ -0,0 +1,92 @@
+Cortina Systems Gemini Ethernet Controller
+==========================================
+
+This ethernet controller is found in the Gemini SoC family:
+StorLink SL3512 and SL3516, also known as Cortina Systems
+CS3512 and CS3516.
+
+Required properties:
+- compatible: must be "cortina,gemini-ethernet"
+- reg: must contain the global registers and the V-bit and A-bit
+  memory areas, in total three register sets.
+- syscon: a phandle to the system controller
+- #address-cells: must be specified, must be <1>
+- #size-cells: must be specified, must be <1>
+- ranges: should be state like this giving a 1:1 address translation
+  for the subnodes
+
+The subnodes represents the two ethernet ports in this device.
+They are not independent of each other since they share resources
+in the parent node, and are thus children.
+
+Required subnodes:
+- port0: contains the resources for ethernet port 0
+- port1: contains the resources for ethernet port 1
+
+Required subnode properties:
+- compatible: must be "cortina,gemini-ethernet-port"
+- reg: must contain two register areas: the DMA/TOE memory and
+  the GMAC memory area of the port
+- interrupts: should contain the interrupt line of the port.
+  this is nominally a level interrupt active high.
+- resets: this must provide an SoC-integrated reset line for
+  the port.
+- clocks: this should contain a handle to the PCLK clock for
+  clocking the silicon in this port
+- clock-names: must be "PCLK"
+
+Optional subnode properties:
+- phy-mode: see ethernet.txt
+- phy-handle: see ethernet.txt
+
+Example:
+
+mdio-bus {
+	(...)
+	phy0: ethernet-phy at 1 {
+		reg = <1>;
+		device_type = "ethernet-phy";
+	};
+	phy1: ethernet-phy at 3 {
+		reg = <3>;
+		device_type = "ethernet-phy";
+	};
+};
+
+
+ethernet at 60000000 {
+	compatible = "cortina,gemini-ethernet";
+	reg = <0x60000000 0x4000>, /* Global registers, queue */
+	      <0x60004000 0x2000>, /* V-bit */
+	      <0x60006000 0x2000>; /* A-bit */
+	syscon = <&syscon>;
+	#address-cells = <1>;
+	#size-cells = <1>;
+	ranges;
+
+	gmac0: ethernet-port at 0 {
+		compatible = "cortina,gemini-ethernet-port";
+		reg = <0x60008000 0x2000>, /* Port 0 DMA/TOE */
+		      <0x6000a000 0x2000>; /* Port 0 GMAC */
+		interrupt-parent = <&intcon>;
+		interrupts = <1 IRQ_TYPE_LEVEL_HIGH>;
+		resets = <&syscon GEMINI_RESET_GMAC0>;
+		clocks = <&syscon GEMINI_CLK_GATE_GMAC0>;
+		clock-names = "PCLK";
+		phy-mode = "rgmii";
+		phy-handle = <&phy0>;
+	};
+
+	gmac1: ethernet-port at 1 {
+		compatible = "cortina,gemini-ethernet-port";
+		reg = <0x6000c000 0x2000>, /* Port 1 DMA/TOE */
+		      <0x6000e000 0x2000>; /* Port 1 GMAC */
+		interrupt-parent = <&intcon>;
+		interrupts = <2 IRQ_TYPE_LEVEL_HIGH>;
+		resets = <&syscon GEMINI_RESET_GMAC1>;
+		clocks = <&syscon GEMINI_CLK_GATE_GMAC1>;
+		clock-names = "PCLK";
+		phy-mode = "rgmii";
+		phy-handle = <&phy1>;
+	};
+};
-- 
2.14.3

^ permalink raw reply related

* [GIT PULL] Gemini DTS updates for v4.16 take one
From: Linus Walleij @ 2017-12-16 19:37 UTC (permalink / raw)
  To: linux-arm-kernel

Hi ARM SoC folks,

I was hoping to send more DTS updates but the drivers are
waiting for review, so might as well get the DTS updates that
are finished upstream for linux-next.

Please pull this to some gemini DTS branch, I'll build more
patches on top of this if need be.

Yours,
Linus Walleij

The following changes since commit 4fbd8d194f06c8a3fd2af1ce560ddb31f7ec8323:

  Linux 4.15-rc1 (2017-11-26 16:01:47 -0800)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-nomadik.git
tags/gemni-dts-1

for you to fetch changes up to dd5c0561db755845f0fd372c9bdb3099dce1a1c8:

  ARM: dts: Add basic devicetree for D-Link DNS-313 (2017-12-16 20:32:22 +0100)

----------------------------------------------------------------
Gemini DTS updates, take one

----------------------------------------------------------------
Linus Walleij (2):
      ARM: dts: Add ethernet PHYs to the a bunch of Geminis
      ARM: dts: Add basic devicetree for D-Link DNS-313

 arch/arm/boot/dts/Makefile                 |   1 +
 arch/arm/boot/dts/gemini-dlink-dns-313.dts | 241 +++++++++++++++++++++++++++++
 arch/arm/boot/dts/gemini-nas4220b.dts      |  13 ++
 arch/arm/boot/dts/gemini-rut1xx.dts        |  13 ++
 arch/arm/boot/dts/gemini-wbd111.dts        |  13 ++
 arch/arm/boot/dts/gemini-wbd222.dts        |  18 +++
 6 files changed, 299 insertions(+)
 create mode 100644 arch/arm/boot/dts/gemini-dlink-dns-313.dts

^ permalink raw reply

* [PATCH 1/9] dt-bindings: ti-sysc: Update binding for timers and capabilities
From: Tony Lindgren @ 2017-12-16 19:22 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171216183059.ipsftfnvsyamv6fd@rob-hp-laptop>

* Rob Herring <robh@kernel.org> [171216 18:33]:
> >  Optional properties:
> >  
> > +- ti,sysc-mask	shall contain mask of supported register bits for the
> > +		SYSCONFIG register as documented in the Technical Reference
> > +		Manual (TRM) for the interconnect target module
> > +
> > +- ti,sysc-midle	list of master idle modes supported by the interconnect
> > +		target module as documented in the TRM for SYSCONFIG
> > +		register MIDLEMODE bits
> > +
> > +- ti,sysc-sidle	list of slave idle modes supported by the interconnect
> > +		target module as documented in the TRM for SYSCONFIG
> > +		register SIDLEMODE bits
> > +
> > +- ti,sysc-delay-us	delay needed after OCP softreset before accssing
> > +			SYSCONFIG register again
> > +
> > +- ti,syss-mask	optional mask of reset done status bits as described in the
> > +		TRM for SYSSTATUS registers, typically 1 with some devices
> > +		having separate reset done bits for children like OHCI and
> > +		EHCI
> > +
> 
> Seems like a lot of this should be implied by specific compatible 
> strings.

Unfortunately that would still explode the permutations to almost
one compatible per module especially for types "ti,sysc-omap2" and
"ti,sysc-omap4". And the features and idle modes supported by the
module are all over the place for "ti,sysc-mask", "ti,sysc-midle",
"ti,sysc-sidle" and "ti,syss-mask"..

I was planning to have "ti,sysc-delay-us" only in the driver, but
the same IP needs it set on dm814x while not on omap4 for OTG
for example. I could add SoC specific quirks to the driver
for that one if you prefer that instead?

I do have a patch also I'm testing to use the revision register
value for handling further quirks, but unfortunately that
register is not populated or updated for many modules. And it's
only usable after the module is already configured to accessible :)

> Are the bits you've defined all of them or there's more?

That's it, with this binding I've allocated the data from dts
for the tests I've done. So that should allow us to replace the
static data to start with as seen with the following command:

$ git grep -A10 "struct omap_hwmod_class_sysconfig" \
	arch/arm/*hwmod*data*.c
...

So that's to configure a big pile of different module
configurations we currently have as can be seen with:

$ git grep "struct omap_hwmod_class_sysconfig" \
	arch/arm/*hwmod*data*.c | wc -l
194

I'm sure there's still few duplicates there though..

The only pending binding change I'm aware of is the optional
extra clocks, but that still pending and just uses the
standard clock binding.

Regards,

Tony

^ permalink raw reply

* [RFC PATCH 2/5] perf jevents: add support for arch recommended events
From: Andi Kleen @ 2017-12-16 18:47 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <5d322353-2785-a99f-bcd8-b948bd6cb09a@huawei.com>

> Won't this all potentially have a big maintainence cost?

No. It's all auto generated.

The only cost is slightly bigger binary size.

I would hope your event files are auto generated too.

> I just don't know how this schema scales with more archs and more platforms
> supported. It's just early days now...

Only perf will get slightly bigger, but memory is not exactly expensive.

In fact, the extra memory won't even be faulted in if it's not used,
so it's only disk space.

-Andi

^ permalink raw reply

* [RFC 2/5] [media] dt: bindings: Update binding documentation for sunxi IR controller
From: Rob Herring @ 2017-12-16 18:36 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171216024914.7550-3-embed3d@gmail.com>

gOn Sat, Dec 16, 2017 at 03:49:11AM +0100, Philipp Rossak wrote:
> This patch updates documentation for Device-Tree bindings for sunxi IR
> controller and adds the new requiered property for the base clock frequency.
> 
> Signed-off-by: Philipp Rossak <embed3d@gmail.com>
> ---
>  Documentation/devicetree/bindings/media/sunxi-ir.txt | 14 ++++++++------
>  1 file changed, 8 insertions(+), 6 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/media/sunxi-ir.txt b/Documentation/devicetree/bindings/media/sunxi-ir.txt
> index 91648c569b1e..5f4960c61245 100644
> --- a/Documentation/devicetree/bindings/media/sunxi-ir.txt
> +++ b/Documentation/devicetree/bindings/media/sunxi-ir.txt
> @@ -1,12 +1,13 @@
>  Device-Tree bindings for SUNXI IR controller found in sunXi SoC family
>  
>  Required properties:
> -- compatible	    : "allwinner,sun4i-a10-ir" or "allwinner,sun5i-a13-ir"
> -- clocks	    : list of clock specifiers, corresponding to
> -		      entries in clock-names property;
> -- clock-names	    : should contain "apb" and "ir" entries;
> -- interrupts	    : should contain IR IRQ number;
> -- reg		    : should contain IO map address for IR.
> +- compatible	      : "allwinner,sun4i-a10-ir" or "allwinner,sun5i-a13-ir"
> +- clocks	      : list of clock specifiers, corresponding to
> +		        entries in clock-names property;
> +- clock-names	      : should contain "apb" and "ir" entries;
> +- interrupts	      : should contain IR IRQ number;
> +- reg		      : should contain IO map address for IR.
> +- base-clk-frequency  : should contain the base clock frequency

Use clock-frequency or assigned-clocks.

Rob

^ permalink raw reply

* [PATCH 2/9] ARM: dts: Add generic ti, sysc compatible in addition to the custom ones
From: Rob Herring @ 2017-12-16 18:34 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215180900.3243-3-tony@atomide.com>

On Fri, Dec 15, 2017 at 10:08:53AM -0800, Tony Lindgren wrote:
> Otherwise we cannot use generic OF_DEV_AUXDATA match without listing
> all the compatibles separately for OF_DEV_AUXDATA. Let's also update the
> binding accordingly.

Your subject has a space in "ti,sysc".

> Let's also fix omap4.dtsi to use "ti,sysc-omap4-sr" compatible as we
> have documented in the binding. This was not noticed earlier as we're
> still probing SmartReflex driver with platform data.
> 
> Signed-off-by: Tony Lindgren <tony@atomide.com>
> ---
>  Documentation/devicetree/bindings/bus/ti-sysc.txt |  1 +
>  arch/arm/boot/dts/dra7.dtsi                       |  4 ++--
>  arch/arm/boot/dts/omap4.dtsi                      | 20 ++++++++++----------
>  3 files changed, 13 insertions(+), 12 deletions(-)

Otherwise,

Reviewed-by: Rob Herring <robh@kernel.org>

^ permalink raw reply

* [PATCH 1/9] dt-bindings: ti-sysc: Update binding for timers and capabilities
From: Rob Herring @ 2017-12-16 18:31 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215180900.3243-2-tony@atomide.com>

On Fri, Dec 15, 2017 at 10:08:52AM -0800, Tony Lindgren wrote:
> The ti-sysc binding does not yet describe the capabilities of the
> interconnect target module. So to make the ti-sysc binding usable
> for configuring the interconnect target module, we need to add few
> more properties:
> 
> 1. To detect between omap2 and omap4 timers, let's add compatibles
>    for them for "ti,sysc-omap2-timer" and,sysc-omap4-timer". This
>    makes it easier to pick up the already initialized system timers
>    later on
> 
> 2. Let's add "ti,sysc-mask" for a mask of features supported by the
>    interconnect target module. This describes what we have available
>    in the various SYSCONFIG registers
> 
> 3. Let's add "ti,sysc-midle" and "ti,sysc-sidle" lists for the master
>    and slave idle modes supported by the interconnect target module.
>    These describe the values available for MIDLE and SIDLE bits in
>    the SYSCONFIG registers
> 
> 4. Some interconnect target modules need a short delay after reset
>    before they can be accessed, let's use "ti,sysc-delay-us" for
>    that
> 
> 5. Let's add "ti,syss-mask" bit to describe the optional SYSSTATUS
>    register bits for reset done bits
> 
> 6. Let's support the two existing custom quirk properties already
>    listed in Documentation/devicetree/bindings/arm/omap/omap.txt for
>    "ti,no-reset-on-init" and "ti,no-idle-on-init"
> 
> 7. And finally, let's add a header for the binding for the dts
>    files and the driver to use
> 
> Cc: Beno?t Cousson <bcousson@baylibre.com>
> Cc: Dave Gerlach <d-gerlach@ti.com>
> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> Cc: Liam Girdwood <lgirdwood@gmail.com>
> Cc: Mark Brown <broonie@kernel.org>
> Cc: Mark Rutland <mark.rutland@arm.com>
> Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
> Cc: Nishanth Menon <nm@ti.com>
> Cc: Matthijs van Duin <matthijsvanduin@gmail.com>
> Cc: Paul Walmsley <paul@pwsan.com>
> Cc: Peter Ujfalusi <peter.ujfalusi@ti.com>
> Cc: Sakari Ailus <sakari.ailus@iki.fi>
> Cc: Suman Anna <s-anna@ti.com>
> Cc: Tero Kristo <t-kristo@ti.com>
> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
> Signed-off-by: Tony Lindgren <tony@atomide.com>
> ---
>  Documentation/devicetree/bindings/bus/ti-sysc.txt | 36 +++++++++++++++++++++++
>  include/dt-bindings/bus/ti-sysc.h                 | 22 ++++++++++++++
>  2 files changed, 58 insertions(+)
>  create mode 100644 include/dt-bindings/bus/ti-sysc.h
> 
> diff --git a/Documentation/devicetree/bindings/bus/ti-sysc.txt b/Documentation/devicetree/bindings/bus/ti-sysc.txt
> --- a/Documentation/devicetree/bindings/bus/ti-sysc.txt
> +++ b/Documentation/devicetree/bindings/bus/ti-sysc.txt
> @@ -26,6 +26,8 @@ Required standard properties:
>  		or one of the following derivative types for hardware
>  		needing special workarounds:
>  
> +		"ti,sysc-omap2-timer"
> +		"ti,sysc-omap4-timer"
>  		"ti,sysc-omap3430-sr"
>  		"ti,sysc-omap3630-sr"
>  		"ti,sysc-omap4-sr"
> @@ -49,6 +51,26 @@ Required standard properties:
>  
>  Optional properties:
>  
> +- ti,sysc-mask	shall contain mask of supported register bits for the
> +		SYSCONFIG register as documented in the Technical Reference
> +		Manual (TRM) for the interconnect target module
> +
> +- ti,sysc-midle	list of master idle modes supported by the interconnect
> +		target module as documented in the TRM for SYSCONFIG
> +		register MIDLEMODE bits
> +
> +- ti,sysc-sidle	list of slave idle modes supported by the interconnect
> +		target module as documented in the TRM for SYSCONFIG
> +		register SIDLEMODE bits
> +
> +- ti,sysc-delay-us	delay needed after OCP softreset before accssing
> +			SYSCONFIG register again
> +
> +- ti,syss-mask	optional mask of reset done status bits as described in the
> +		TRM for SYSSTATUS registers, typically 1 with some devices
> +		having separate reset done bits for children like OHCI and
> +		EHCI
> +

Seems like a lot of this should be implied by specific compatible 
strings.

Are the bits you've defined all of them or there's more?

Rob

^ permalink raw reply

* [PATCH 1/4 v5] drm/bridge: Add bindings for TI THS8134
From: Rob Herring @ 2017-12-16 18:23 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215121047.3650-2-linus.walleij@linaro.org>

On Fri, Dec 15, 2017 at 01:10:44PM +0100, Linus Walleij wrote:
> This adds device tree bindings for the Texas Instruments
> THS8134, THS8134A and THS8134B VGA DACs by extending and
> renaming the existing bindings for THS8135.
> 
> These DACs are used for the VGA outputs on the ARM reference
> designs such as Integrator, Versatile and RealView.
> 
> Cc: devicetree at vger.kernel.org
> Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> Acked-by: Rob Herring <robh@kernel.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> ChangeLog v2->v5:
> - Dropped the "ti,ths813x" as it turns out we need precise info
>   about the sub-variant anyways as they all very in timings.
> - Refine the THS8134 variants, it turns out ths8134, ths8134a
>   and ths8134b are three different variants of ths8134.
> ChangeLog v1->v2:
> - Introduce specific-to-general compatible string:
>   compatible = "ti,ths8134a", "ti,ths813x";
>   so drivers can handle the whole family the same way.
> - Collected Rob's ACK.
> ---
>  .../display/bridge/{ti,ths8135.txt => ti,ths813x.txt}       | 13 +++++++++----
>  1 file changed, 9 insertions(+), 4 deletions(-)
>  rename Documentation/devicetree/bindings/display/bridge/{ti,ths8135.txt => ti,ths813x.txt} (69%)
> 
> diff --git a/Documentation/devicetree/bindings/display/bridge/ti,ths8135.txt b/Documentation/devicetree/bindings/display/bridge/ti,ths813x.txt
> similarity index 69%
> rename from Documentation/devicetree/bindings/display/bridge/ti,ths8135.txt
> rename to Documentation/devicetree/bindings/display/bridge/ti,ths813x.txt
> index 6ec1a880ac18..49f155467f00 100644
> --- a/Documentation/devicetree/bindings/display/bridge/ti,ths8135.txt
> +++ b/Documentation/devicetree/bindings/display/bridge/ti,ths813x.txt
> @@ -1,11 +1,16 @@
> -THS8135 Video DAC
> ------------------
> +THS8134 and THS8135 Video DAC
> +-----------------------------
>  
> -This is the binding for Texas Instruments THS8135 Video DAC bridge.
> +This is the binding for Texas Instruments THS8134, THS8134A, THS8134B and
> +THS8135 Video DAC bridge.
>  
>  Required properties:
>  
> -- compatible: Must be "ti,ths8135"
> +- compatible: Must be one of
> +  "ti,ths8134"
> +  "ti,ths8134", "ti,ths8134a"
> +  "ti,ths8134", "ti,ths8134b"

These should be the opposite order.

> +  "ti,ths8135"
>  
>  Required nodes:
>  
> -- 
> 2.14.3
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply

* [PATCH v2 02/19] dt-bindings: gpio: Add ASPEED constants
From: Rob Herring @ 2017-12-16 18:17 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215062443.23059-3-joel@jms.id.au>

On Fri, Dec 15, 2017 at 04:54:26PM +1030, Joel Stanley wrote:
> These are used to by the device tree to map pin numbers to constants
> required by the GPIO bindings.
> 
> Signed-off-by: Joel Stanley <joel@jms.id.au>
> ---
>  arch/arm/boot/dts/aspeed-g4.dtsi       |  1 +
>  arch/arm/boot/dts/aspeed-g5.dtsi       |  1 +
>  include/dt-bindings/gpio/aspeed-gpio.h | 49 ++++++++++++++++++++++++++++++++++
>  3 files changed, 51 insertions(+)
>  create mode 100644 include/dt-bindings/gpio/aspeed-gpio.h
> 
> diff --git a/arch/arm/boot/dts/aspeed-g4.dtsi b/arch/arm/boot/dts/aspeed-g4.dtsi
> index 45d815a86d42..100d092e6c07 100644
> --- a/arch/arm/boot/dts/aspeed-g4.dtsi
> +++ b/arch/arm/boot/dts/aspeed-g4.dtsi
> @@ -1,5 +1,6 @@
>  // SPDX-License-Identifier: GPL-2.0
>  #include "skeleton.dtsi"
> +#include <dt-bindings/gpio/aspeed-gpio.h>

Don't you need to use the defines? Probably should be a separate patch.

Rob

^ permalink raw reply

* [PATCH v2 01/19] dt-bindings: clock: Add ASPEED constants
From: Rob Herring @ 2017-12-16 18:09 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215062443.23059-2-joel@jms.id.au>

On Fri, Dec 15, 2017 at 04:54:25PM +1030, Joel Stanley wrote:
> These will be merged as part of the clock driver. This commit is
> included so the tree will build without the clock series being applied.
> 
> Signed-off-by: Joel Stanley <joel@jms.id.au>
> ---
>  v2:
>   - remove NUM_CLKS define. There's no need for it to be part of ABI
> ---
>  include/dt-bindings/clock/aspeed-clock.h | 52 ++++++++++++++++++++++++++++++++
>  1 file changed, 52 insertions(+)
>  create mode 100644 include/dt-bindings/clock/aspeed-clock.h

Reviewed-by: Rob Herring <robh@kernel.org>

^ permalink raw reply

* [PATCH v2 3/4] dt-bindings: opp: Introduce ti-opp-supply bindings
From: Rob Herring @ 2017-12-16 18:01 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215042528.28715-4-d-gerlach@ti.com>

On Thu, Dec 14, 2017 at 10:25:27PM -0600, Dave Gerlach wrote:
> Document the devicetree bindings that describe Texas Instruments
> opp-supply which allow a platform to describe multiple regulators and
> additional information, such as registers containing data needed to
> program aforementioned regulators.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> ---
>  .../bindings/opp/ti-omap5-opp-supply.txt           | 63 ++++++++++++++++++++++
>  1 file changed, 63 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/opp/ti-omap5-opp-supply.txt

Acked-by: Rob Herring <robh@kernel.org>

^ permalink raw reply

* [RESEND PATCH v2 13/15] dt-bindings: sound: qcom: Add devicetree bindings for apq8096
From: Rob Herring @ 2017-12-16 17:44 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171214173402.19074-14-srinivas.kandagatla@linaro.org>

On Thu, Dec 14, 2017 at 05:34:00PM +0000, srinivas.kandagatla at linaro.org wrote:
> From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
> 
> Add devicetree bindings documentation file for Qualcomm apq8096 sound card.
> 
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
> ---
>  .../devicetree/bindings/sound/qcom,apq8096.txt     | 22 ++++++++++++++++++++++
>  1 file changed, 22 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/sound/qcom,apq8096.txt
> 
> diff --git a/Documentation/devicetree/bindings/sound/qcom,apq8096.txt b/Documentation/devicetree/bindings/sound/qcom,apq8096.txt
> new file mode 100644
> index 000000000000..27b511dab533
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/sound/qcom,apq8096.txt
> @@ -0,0 +1,22 @@
> +* Qualcomm Technologies APQ8096 ASoC sound card driver
> +
> +This binding describes the APQ8096 sound card, which uses qdsp for audio.
> +
> +- compatible:
> +	Usage: required
> +	Value type: <stringlist>
> +	Definition: must be "qcom,apq8096-sndcard"
> +
> +- qcom,audio-routing:
> +	Usage: Optional
> +	Value type: <stringlist>
> +	Definition:  A list of the connections between audio components.
> +		  Each entry is a pair of strings, the first being the
> +		  connection's sink, the second being the connection's
> +		  source. Valid names could be power supplies, MicBias
> +		  of codec and the jacks on the board:
> +Example:
> +	sound {
> +		compatible	= "qcom,snd-apq8096";
> +		qcom,model = "DB820c";

Not documented, but just use "model".

This doesn't look complete. No codec, etc.?

Rob

^ permalink raw reply

* [RFC 1/5] [media] rc: update sunxi-ir driver to get base frequency from devicetree
From: Philipp Rossak @ 2017-12-16 17:30 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171216071855.0ef43f7b@recife.lan>

Hey Mauro,

Thanks for your fast feedback!

I will rework the driver like you suggested it.

Does somebody have any concerns about the Devicetree property 
(base-clk-frequency = < frequency >;)?


Regards,
Philipp

On 16.12.2017 10:18, Mauro Carvalho Chehab wrote:
> Em Sat, 16 Dec 2017 03:49:10 +0100
> Philipp Rossak <embed3d@gmail.com> escreveu:
> 
> Hi Phillip,
> 
> This is not a full review of this patchset. I just want to point you
> that you should keep supporting existing DT files.
> 
>> This patch updates the sunxi-ir driver to set the ir base clock from
>> devicetree.
>>
>> This is neccessary since there are different ir recievers on the
>> market, that operate with different frequencys. So this value needs to
>> be set depending on the attached receiver.
> 
> Please don't break backward compatibility with old DT files. In this
> specific case, it seems simple enough to be backward-compatible.
> 
>>
>> Signed-off-by: Philipp Rossak <embed3d@gmail.com>
>> ---
>>   drivers/media/rc/sunxi-cir.c | 20 +++++++++++---------
>>   1 file changed, 11 insertions(+), 9 deletions(-)
>>
>> diff --git a/drivers/media/rc/sunxi-cir.c b/drivers/media/rc/sunxi-cir.c
>> index 97f367b446c4..55b53d6463e9 100644
>> --- a/drivers/media/rc/sunxi-cir.c
>> +++ b/drivers/media/rc/sunxi-cir.c
>> @@ -72,12 +72,6 @@
>>   /* CIR_REG register idle threshold */
>>   #define REG_CIR_ITHR(val)    (((val) << 8) & (GENMASK(15, 8)))
>>   
>> -/* Required frequency for IR0 or IR1 clock in CIR mode */
>> -#define SUNXI_IR_BASE_CLK     8000000
>> -/* Frequency after IR internal divider  */
>> -#define SUNXI_IR_CLK          (SUNXI_IR_BASE_CLK / 64)
> 
> Keep those to definitions...
> 
>> -/* Sample period in ns */
>> -#define SUNXI_IR_SAMPLE       (1000000000ul / SUNXI_IR_CLK)
>>   /* Noise threshold in samples  */
>>   #define SUNXI_IR_RXNOISE      1
>>   /* Idle Threshold in samples */
>> @@ -122,7 +116,7 @@ static irqreturn_t sunxi_ir_irq(int irqno, void *dev_id)
>>   			/* for each bit in fifo */
>>   			dt = readb(ir->base + SUNXI_IR_RXFIFO_REG);
>>   			rawir.pulse = (dt & 0x80) != 0;
>> -			rawir.duration = ((dt & 0x7f) + 1) * SUNXI_IR_SAMPLE;
>> +			rawir.duration = ((dt & 0x7f) + 1) * ir->rc->rx_resolution;
>>   			ir_raw_event_store_with_filter(ir->rc, &rawir);
>>   		}
>>   	}
>> @@ -148,6 +142,7 @@ static int sunxi_ir_probe(struct platform_device *pdev)
>>   	struct device_node *dn = dev->of_node;
>>   	struct resource *res;
>>   	struct sunxi_ir *ir;
>> +	u32 b_clk_freq;
>>   
>>   	ir = devm_kzalloc(dev, sizeof(struct sunxi_ir), GFP_KERNEL);
>>   	if (!ir)
>> @@ -172,6 +167,12 @@ static int sunxi_ir_probe(struct platform_device *pdev)
>>   		return PTR_ERR(ir->clk);
>>   	}
>>   
>> +	/* Required frequency for IR0 or IR1 clock in CIR mode */
>> +	if (of_property_read_u32(dn, "base-clk-frequency", &b_clk_freq)) {
>> +		dev_err(dev, "failed to get ir base clock frequency.\n");
>> +		return -ENODATA;
>> +	}
>> +
> 
> And here, instead of returning an error, if the property can't be read,
> it means it is an older DT file. Just default to SUNXI_IR_BASE_CLK.
> This will make it backward-compatible with old DT files that don't have
> such property.
> 
> Regards,
> Mauro
> 
> 
>>   	/* Reset (optional) */
>>   	ir->rst = devm_reset_control_get_optional_exclusive(dev, NULL);
>>   	if (IS_ERR(ir->rst))
>> @@ -180,7 +181,7 @@ static int sunxi_ir_probe(struct platform_device *pdev)
>>   	if (ret)
>>   		return ret;
>>   
>> -	ret = clk_set_rate(ir->clk, SUNXI_IR_BASE_CLK);
>> +	ret = clk_set_rate(ir->clk, b_clk_freq);
>>   	if (ret) {
>>   		dev_err(dev, "set ir base clock failed!\n");
>>   		goto exit_reset_assert;
>> @@ -225,7 +226,8 @@ static int sunxi_ir_probe(struct platform_device *pdev)
>>   	ir->rc->map_name = ir->map_name ?: RC_MAP_EMPTY;
>>   	ir->rc->dev.parent = dev;
>>   	ir->rc->allowed_protocols = RC_PROTO_BIT_ALL_IR_DECODER;
>> -	ir->rc->rx_resolution = SUNXI_IR_SAMPLE;
>> +	/* Frequency after IR internal divider with sample period in ns */
>> +	ir->rc->rx_resolution = (1000000000ul / (b_clk_freq / 64));
>>   	ir->rc->timeout = MS_TO_NS(SUNXI_IR_TIMEOUT);
>>   	ir->rc->driver_name = SUNXI_IR_DEV;
>>   
> 
> Thanks,
> Mauro
> 

^ permalink raw reply

* [RESEND PATCH v2 01/15] dt-bindings: soc: qcom: Add bindings for APR bus
From: Rob Herring @ 2017-12-16 17:27 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171214173402.19074-2-srinivas.kandagatla@linaro.org>

On Thu, Dec 14, 2017 at 05:33:48PM +0000, srinivas.kandagatla at linaro.org wrote:
> From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
> 
> This patch add dt bindings for Qualcomm APR bus driver
> 
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
> ---
>  .../devicetree/bindings/soc/qcom/qcom,apr.txt      | 28 ++++++++++++++++++++++
>  1 file changed, 28 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt
> 
> diff --git a/Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt b/Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt
> new file mode 100644
> index 000000000000..4e93213ae98d
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt
> @@ -0,0 +1,28 @@
> +Qualcomm APR (Asynchronous Packet Router) binding
> +
> +This binding describes the Qualcomm APR. APR is a IPC protocol for
> +communication between Application processor and QDSP. APR is mainly
> +used for audio/voice services on the QDSP.
> +
> +- compatible:
> +	Usage: required
> +	Value type: <stringlist>
> +	Definition: must be "qcom,apr-<SOC-NAME>" example: "qcom,apr-msm8996"

<soc>-apr is the more standard order. With that,

Reviewed-by: Rob Herring <robh@kernel.org>

^ permalink raw reply

* [PATCH] of: build dbts with symbols when CONFIG_OF_OVERLAY is set
From: Andre Heider @ 2017-12-16 17:25 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <aada8c54-2c26-bf37-8782-4edc43195daf@gmail.com>

Hi Frank,

On 15/12/17 22:06, Frank Rowand wrote:
> On 12/14/17 07:12, Andre Heider wrote:
>> The overlay feature requires the base dtb to be built with symbols, so
>> lets build the dtbs with symbols when overlay support was explicitly
>> enabled.
>>
>> With CONFIG_OF_ALL_DTBS on ARCH=arm the 989 dtb files grow about ~38% on
>> average.
>>
>> Totals in bytes with the 3 biggest ones:
>>
>> Before:
>> 	90471	arch/arm/boot/dts/am57xx-beagle-x15-revc.dtb
>> 	90521	arch/arm/boot/dts/am57xx-beagle-x15-revb1.dtb
>> 	92639	arch/arm/boot/dts/dra7-evm.dtb
>> 	25731296	total
>>
>> After:
>> 	133203	arch/arm/boot/dts/am57xx-beagle-x15-revc.dtb
>> 	133237	arch/arm/boot/dts/am57xx-beagle-x15-revb1.dtb
>> 	134545	arch/arm/boot/dts/dra7-evm.dtb
>> 	35464440	total
>>
>> Signed-off-by: Andre Heider <a.heider@gmail.com>
>> ---
>>
>> Hi,
>>
>> while playing around with overlays I noticed that I needed to rebuilt
>> my distro's device trees because they didn't come with symbols.
>>
>> Is that for a reason, maybe the not so minor increase in size?
> 
> Yes, size is the issue.
> 
> 
>>
>> Thanks,
>> Andre
>>
>>   drivers/of/unittest-data/Makefile | 7 -------
>>   scripts/Makefile.lib              | 5 +++++
>>   2 files changed, 5 insertions(+), 7 deletions(-)
>>
>> diff --git a/drivers/of/unittest-data/Makefile b/drivers/of/unittest-data/Makefile
>> index 32389acfa616..b65061013512 100644
>> --- a/drivers/of/unittest-data/Makefile
>> +++ b/drivers/of/unittest-data/Makefile
>> @@ -15,13 +15,6 @@ targets += overlay.dtb overlay.dtb.S
>>   targets += overlay_bad_phandle.dtb overlay_bad_phandle.dtb.S
>>   targets += overlay_bad_symbol.dtb overlay_bad_symbol.dtb.S
>>   targets += overlay_base.dtb overlay_base.dtb.S
>> -
>> -# enable creation of __symbols__ node
>> -DTC_FLAGS_overlay := -@
>> -DTC_FLAGS_overlay_bad_phandle := -@
>> -DTC_FLAGS_overlay_bad_symbol := -@
>> -DTC_FLAGS_overlay_base := -@
>> -
>>   endif
>>   
>>   .PRECIOUS: \
> 
> No.  The unittests require these to be set unconditionally.
> 
> 
>> diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
>> index 1ca4dcd2d500..c7ba4aa8a07a 100644
>> --- a/scripts/Makefile.lib
>> +++ b/scripts/Makefile.lib
>> @@ -278,6 +278,11 @@ DTC_FLAGS += -Wnode_name_chars_strict \
>>   	-Wproperty_name_chars_strict
>>   endif
>>   
>> +ifeq ($(CONFIG_OF_OVERLAY),y)
>> +# enable creation of __symbols__ node
>> +DTC_FLAGS += -@
>> +endif
>> +
>>   DTC_FLAGS += $(DTC_FLAGS_$(basetarget))
>>   
>>   # Generate an assembly file to wrap the output of the device tree compiler
>>
> 
> Not needed.  Instead set DTC_FLAGS in the make command.  For example:
> 
>     DTC_FLAGS=-@ make qcom-apq8074-dragonboard.dtb
> 
> There are a few architecture Makefiles that need to be fixed to not unconditionally
> set DTC_FLAGS.

Rebuilding the dts files manually with symbols isn't the problem. The 
idea was to enable it with a switch which distros simply can flip.

Passing DTC_FLAGS to `make` would work too I guess, but on multi 
platform builds that's still the same issue if there're boards which 
can't handle that because of the size increase.

Would a solution which enables symbols per family work?
E.g. CONFIG_MACH_SUN7I chooses to use -@ because it can handle it.

Thanks,
Andre

^ permalink raw reply

* [PATCH 0/3] arm64: dts: Support Mali450 on rk3328
From: Heiko Stuebner @ 2017-12-16 17:17 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171209000738.32187-1-heiko@sntech.de>

Am Samstag, 9. Dezember 2017, 01:07:35 CET schrieb Heiko Stuebner:
> Pretty standard setup. Tested with the kmscube demo running
> using the lima kernel and gallium driver.
> 
> 
> Heiko Stuebner (3):
>   dt-bindings: gpu: mali-utgard: add rockchip,rk3328-mali compatible
>   arm64: dts: rockchip: add rk3328 mali gpu node
>   arm64: dts: rockchip: enable gpu on rk3328-rock64

applied for 4.16 with Robs review and following his suggestion
of making the gpu simply always-on and thus droppping patch 3.

^ permalink raw reply

* [PATCH v3 1/5] arm64: dts: rockchip: add extcon nodes and enable tcphy.
From: Heiko Stuebner @ 2017-12-16 17:08 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215110005.7564-1-enric.balletbo@collabora.com>

Am Freitag, 15. Dezember 2017, 12:00:01 CET schrieb Enric Balletbo i Serra:
> Enable tcphy and create the cros-ec's extcon node for the USB Type-C port.
> 
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
> Reviewed-by: Brian Norris <briannorris@chromium.org>

applied for 4.16

Thanks
Heiko

^ permalink raw reply

* [PATCH v3 3/5] arm64: dts: rockchip: add usb3-phy otg-port support for rk3399.
From: Heiko Stuebner @ 2017-12-16 17:06 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215110005.7564-3-enric.balletbo@collabora.com>

Am Freitag, 15. Dezember 2017, 12:00:03 CET schrieb Enric Balletbo i Serra:
> Add the usb3 phyter for the USB3.0 OTG controller.
> 
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>

applied for 4.16

^ permalink raw reply

* [PATCH v3 5/5] arm64: dts: rockchip: add reset property for dwc3 controllers on rk3399.
From: Heiko Stuebner @ 2017-12-16 17:01 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215110005.7564-5-enric.balletbo@collabora.com>

Am Freitag, 15. Dezember 2017, 12:00:05 CET schrieb Enric Balletbo i Serra:
> After commit '06c47e6286d usb: dwc3: of-simple: Add support to get resets
> for the device' you can add the reset property to the dwc3 node, the reset
> is required for the controller to work properly, otherwise bind / unbind
> stress testing of the USB controller on rk3399 we'd often end up with lots
> of failures that looked like this:
> 
>   phy phy-ff800000.phy.9: phy poweron failed --> -110
>   dwc3 fe900000.dwc3: failed to initialize core
>   dwc3: probe of fe900000.dwc3 failed with error -110
> 
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>

applied for 4.16

Thanks
Heiko

^ permalink raw reply

* [PATCH v3 2/5] arm64: dts: rockchip: add the aclk_usb3 clocks for USB3.
From: Heiko Stuebner @ 2017-12-16 17:00 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215110005.7564-2-enric.balletbo@collabora.com>

Am Freitag, 15. Dezember 2017, 12:00:02 CET schrieb Enric Balletbo i Serra:
> The aclk_usb3 must be enabled to support USB3 for rk3399.
> 
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>

applied for 4.16

^ permalink raw reply

* [PATCH v3 4/5] arm64: dts: rockchip: add pd_usb3 power-domain node for rk3399.
From: Heiko Stuebner @ 2017-12-16 16:55 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171215110005.7564-4-enric.balletbo@collabora.com>

Am Freitag, 15. Dezember 2017, 12:00:04 CET schrieb Enric Balletbo i Serra:
> Add the usb3 power-domain, its qos area and assign it to the usb device
> node.
> 
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>

applied for 4.16

Thanks
Heiko

^ permalink raw reply

* [PATCH 10/12] dt-bindings: sdhci-omap: Add K2G specific binding
From: Rob Herring @ 2017-12-16 16:49 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171214130941.26666-11-kishon@ti.com>

On Thu, Dec 14, 2017 at 06:39:39PM +0530, Kishon Vijay Abraham I wrote:
> Add binding for the TI's sdhci-omap controller present in K2G.
> 
> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
> ---
>  Documentation/devicetree/bindings/mmc/sdhci-omap.txt | 2 ++
>  1 file changed, 2 insertions(+)

Reviewed-by: Rob Herring <robh@kernel.org>

^ permalink raw reply

* [PATCH v2 1/4] dt-bindings: usb: add DT binding for RK3328 dwc3 controller
From: Heiko Stuebner @ 2017-12-16 15:52 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20171204094041.25439-1-heiko@sntech.de>

Hi Greg, Felipe,

Am Montag, 4. Dezember 2017, 10:40:38 CET schrieb Heiko Stuebner:
> From: William Wu <william.wu@rock-chips.com>
> 
> Adds the device tree bindings description for RK3328 and
> compatible USB DWC3 controller.
> 
> Signed-off-by: William Wu <william.wu@rock-chips.com>
> Acked-by: Rob Herring <robh@kernel.org>
> Signed-off-by: Heiko Stuebner <heiko@sntech.de>

do you want to pick this patch with only the small dt-binding
change or Ack it for me to pick up together with the actual
devicetree changes in the other patches?


Thanks
Heiko

> ---
> changes in v2:
> - add Rob's Ack
> 
> Ideally usb maintainers would pick up this patch to the binding
> document and I'll take the devicetree changes after that.
> 
> But if so desired, I can also pick up the binding change myself
> but would need an Ack for that.
> 
>  Documentation/devicetree/bindings/usb/rockchip,dwc3.txt | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/usb/rockchip,dwc3.txt b/Documentation/devicetree/bindings/usb/rockchip,dwc3.txt
> index 50a31536e975..2c3f6a467fda 100644
> --- a/Documentation/devicetree/bindings/usb/rockchip,dwc3.txt
> +++ b/Documentation/devicetree/bindings/usb/rockchip,dwc3.txt
> @@ -1,7 +1,9 @@
>  Rockchip SuperSpeed DWC3 USB SoC controller
>  
>  Required properties:
> -- compatible:	should contain "rockchip,rk3399-dwc3" for rk3399 SoC
> +- compatible:	should be one of the following:
> +  - "rockchip,rk3399-dwc3": for rk3399 SoC
> +  - "rockchip,rk3328-dwc3", "rockchip,rk3399-dwc3": for rk3328 SoC
>  - clocks:	A list of phandle + clock-specifier pairs for the
>  		clocks listed in clock-names
>  - clock-names:	Should contain the following:
> 

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox