LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST
@ 2018-05-15 23:48 Florian Fainelli
  2018-05-15 23:48 ` [PATCH net-next 1/3] net: ethernet: ti: Allow most " Florian Fainelli
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Florian Fainelli @ 2018-05-15 23:48 UTC (permalink / raw)
  To: netdev; +Cc: Florian Fainelli, David S. Miller, Andrew Lunn, open list

Hi David,

This patch series includes more drivers to be build tested with COMPILE_TEST
enabled. This helps cover some of the issues I just ran into with missing
a driver *sigh*.

Florian Fainelli (3):
  net: ethernet: ti: Allow most drivers with COMPILE_TEST
  net: ethernet: freescale: Allow FEC with COMPILE_TEST
  net: phy: Allow MDIO_MOXART and MDIO_SUN4I with COMPILE_TEST

 drivers/net/ethernet/freescale/Kconfig |  2 +-
 drivers/net/ethernet/ti/Kconfig        | 14 +++++++-------
 drivers/net/phy/Kconfig                |  4 ++--
 3 files changed, 10 insertions(+), 10 deletions(-)

-- 
2.14.1

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH net-next 1/3] net: ethernet: ti: Allow most drivers with COMPILE_TEST
  2018-05-15 23:48 [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST Florian Fainelli
@ 2018-05-15 23:48 ` Florian Fainelli
  2018-05-17  3:02   ` kbuild test robot
  2018-05-17  4:25   ` kbuild test robot
  2018-05-15 23:48 ` [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC " Florian Fainelli
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 12+ messages in thread
From: Florian Fainelli @ 2018-05-15 23:48 UTC (permalink / raw)
  To: netdev; +Cc: Florian Fainelli, David S. Miller, Andrew Lunn, open list

Most of the TI drivers build just fine with COMPILE_TEST, cpmac (AR7) is
the exception because it uses a header file from
arch/mips/include/asm/mach-ar7/ar7.h.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
 drivers/net/ethernet/ti/Kconfig | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/drivers/net/ethernet/ti/Kconfig b/drivers/net/ethernet/ti/Kconfig
index 48a541eb0af2..1f8626999ac6 100644
--- a/drivers/net/ethernet/ti/Kconfig
+++ b/drivers/net/ethernet/ti/Kconfig
@@ -18,7 +18,7 @@ if NET_VENDOR_TI
 
 config TI_DAVINCI_EMAC
 	tristate "TI DaVinci EMAC Support"
-	depends on ARM && ( ARCH_DAVINCI || ARCH_OMAP3 )
+	depends on ARM && ( ARCH_DAVINCI || ARCH_OMAP3 ) || COMPILE_TEST
 	select TI_DAVINCI_MDIO
 	select TI_DAVINCI_CPDMA
 	select PHYLIB
@@ -30,7 +30,7 @@ config TI_DAVINCI_EMAC
 
 config TI_DAVINCI_MDIO
 	tristate "TI DaVinci MDIO Support"
-	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS || ARCH_KEYSTONE
+	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS || ARCH_KEYSTONE || COMPILE_TEST
 	select PHYLIB
 	---help---
 	  This driver supports TI's DaVinci MDIO module.
@@ -40,7 +40,7 @@ config TI_DAVINCI_MDIO
 
 config TI_DAVINCI_CPDMA
 	tristate "TI DaVinci CPDMA Support"
-	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS
+	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS || COMPILE_TEST
 	---help---
 	  This driver supports TI's DaVinci CPDMA dma engine.
 
@@ -60,7 +60,7 @@ config TI_CPSW_ALE
 
 config TI_CPSW
 	tristate "TI CPSW Switch Support"
-	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS
+	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS || COMPILE_TEST
 	select TI_DAVINCI_CPDMA
 	select TI_DAVINCI_MDIO
 	select TI_CPSW_PHY_SEL
@@ -75,7 +75,7 @@ config TI_CPSW
 
 config TI_CPTS
 	bool "TI Common Platform Time Sync (CPTS) Support"
-	depends on TI_CPSW || TI_KEYSTONE_NETCP
+	depends on TI_CPSW || TI_KEYSTONE_NETCP || COMPILE_TEST
 	depends on POSIX_TIMERS
 	---help---
 	  This driver supports the Common Platform Time Sync unit of
@@ -95,8 +95,8 @@ config TI_KEYSTONE_NETCP
 	tristate "TI Keystone NETCP Core Support"
 	select TI_CPSW_ALE
 	select TI_DAVINCI_MDIO
-	depends on OF
-	depends on KEYSTONE_NAVIGATOR_DMA && KEYSTONE_NAVIGATOR_QMSS
+	depends on OF && KEYSTONE_NAVIGATOR_DMA && KEYSTONE_NAVIGATOR_QMSS || \
+		   COMPILE_TEST
 	---help---
 	  This driver supports TI's Keystone NETCP Core.
 
-- 
2.14.1

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC with COMPILE_TEST
  2018-05-15 23:48 [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST Florian Fainelli
  2018-05-15 23:48 ` [PATCH net-next 1/3] net: ethernet: ti: Allow most " Florian Fainelli
@ 2018-05-15 23:48 ` Florian Fainelli
  2018-05-16  1:19   ` Andy Duan
                     ` (2 more replies)
  2018-05-15 23:48 ` [PATCH net-next 3/3] net: phy: Allow MDIO_MOXART and MDIO_SUN4I " Florian Fainelli
  2018-05-16 18:15 ` [PATCH net-next 0/3] net: Allow more drivers " David Miller
  3 siblings, 3 replies; 12+ messages in thread
From: Florian Fainelli @ 2018-05-15 23:48 UTC (permalink / raw)
  To: netdev; +Cc: Florian Fainelli, David S. Miller, Andrew Lunn, open list

The Freescale FEC driver builds fine with COMPILE_TEST, so make that
possible.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
 drivers/net/ethernet/freescale/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/freescale/Kconfig b/drivers/net/ethernet/freescale/Kconfig
index 6e490fd2345d..a580a3dcbe59 100644
--- a/drivers/net/ethernet/freescale/Kconfig
+++ b/drivers/net/ethernet/freescale/Kconfig
@@ -22,7 +22,7 @@ if NET_VENDOR_FREESCALE
 config FEC
 	tristate "FEC ethernet controller (of ColdFire and some i.MX CPUs)"
 	depends on (M523x || M527x || M5272 || M528x || M520x || M532x || \
-		   ARCH_MXC || SOC_IMX28)
+		   ARCH_MXC || SOC_IMX28 || COMPILE_TEST)
 	default ARCH_MXC || SOC_IMX28 if ARM
 	select PHYLIB
 	imply PTP_1588_CLOCK
-- 
2.14.1

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH net-next 3/3] net: phy: Allow MDIO_MOXART and MDIO_SUN4I with COMPILE_TEST
  2018-05-15 23:48 [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST Florian Fainelli
  2018-05-15 23:48 ` [PATCH net-next 1/3] net: ethernet: ti: Allow most " Florian Fainelli
  2018-05-15 23:48 ` [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC " Florian Fainelli
@ 2018-05-15 23:48 ` Florian Fainelli
  2018-05-16 18:15 ` [PATCH net-next 0/3] net: Allow more drivers " David Miller
  3 siblings, 0 replies; 12+ messages in thread
From: Florian Fainelli @ 2018-05-15 23:48 UTC (permalink / raw)
  To: netdev; +Cc: Florian Fainelli, David S. Miller, Andrew Lunn, open list

Those drivers build just fine with COMPILE_TEST, so make that possible.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
 drivers/net/phy/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
index 0e2305ccc91f..343989f9f9d9 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
@@ -118,7 +118,7 @@ config MDIO_I2C
 
 config MDIO_MOXART
 	tristate "MOXA ART MDIO interface support"
-	depends on ARCH_MOXART
+	depends on ARCH_MOXART || COMPILE_TEST
 	help
 	  This driver supports the MDIO interface found in the network
 	  interface units of the MOXA ART SoC
@@ -142,7 +142,7 @@ config MDIO_OCTEON
 
 config MDIO_SUN4I
 	tristate "Allwinner sun4i MDIO interface support"
-	depends on ARCH_SUNXI
+	depends on ARCH_SUNXI || COMPILE_TEST
 	help
 	  This driver supports the MDIO interface found in the network
 	  interface units of the Allwinner SoC that have an EMAC (A10,
-- 
2.14.1

^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC with COMPILE_TEST
  2018-05-15 23:48 ` [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC " Florian Fainelli
@ 2018-05-16  1:19   ` Andy Duan
  2018-05-17  3:38   ` kbuild test robot
  2018-05-17  4:03   ` kbuild test robot
  2 siblings, 0 replies; 12+ messages in thread
From: Andy Duan @ 2018-05-16  1:19 UTC (permalink / raw)
  To: Florian Fainelli, netdev; +Cc: David S. Miller, Andrew Lunn, open list

From: Florian Fainelli <f.fainelli@gmail.com> Sent: 2018年5月16日 7:48
> The Freescale FEC driver builds fine with COMPILE_TEST, so make that
> possible.
> 
> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>

Acked-by: Fugang Duan <fugang.duan@nxp.com>

> ---
>  drivers/net/ethernet/freescale/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/freescale/Kconfig
> b/drivers/net/ethernet/freescale/Kconfig
> index 6e490fd2345d..a580a3dcbe59 100644
> --- a/drivers/net/ethernet/freescale/Kconfig
> +++ b/drivers/net/ethernet/freescale/Kconfig
> @@ -22,7 +22,7 @@ if NET_VENDOR_FREESCALE  config FEC
>  	tristate "FEC ethernet controller (of ColdFire and some i.MX CPUs)"
>  	depends on (M523x || M527x || M5272 || M528x || M520x || M532x || \
> -		   ARCH_MXC || SOC_IMX28)
> +		   ARCH_MXC || SOC_IMX28 || COMPILE_TEST)
>  	default ARCH_MXC || SOC_IMX28 if ARM
>  	select PHYLIB
>  	imply PTP_1588_CLOCK
> --
> 2.14.1

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST
  2018-05-15 23:48 [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST Florian Fainelli
                   ` (2 preceding siblings ...)
  2018-05-15 23:48 ` [PATCH net-next 3/3] net: phy: Allow MDIO_MOXART and MDIO_SUN4I " Florian Fainelli
@ 2018-05-16 18:15 ` David Miller
  2018-05-16 18:17   ` David Miller
  3 siblings, 1 reply; 12+ messages in thread
From: David Miller @ 2018-05-16 18:15 UTC (permalink / raw)
  To: f.fainelli; +Cc: netdev, andrew, linux-kernel

From: Florian Fainelli <f.fainelli@gmail.com>
Date: Tue, 15 May 2018 16:48:22 -0700

> This patch series includes more drivers to be build tested with COMPILE_TEST
> enabled. This helps cover some of the issues I just ran into with missing
> a driver *sigh*.

Thank you for doing this.

Series applied.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST
  2018-05-16 18:15 ` [PATCH net-next 0/3] net: Allow more drivers " David Miller
@ 2018-05-16 18:17   ` David Miller
  2018-05-16 18:18     ` Florian Fainelli
  0 siblings, 1 reply; 12+ messages in thread
From: David Miller @ 2018-05-16 18:17 UTC (permalink / raw)
  To: f.fainelli; +Cc: netdev, andrew, linux-kernel

From: David Miller <davem@davemloft.net>
Date: Wed, 16 May 2018 14:15:14 -0400 (EDT)

> From: Florian Fainelli <f.fainelli@gmail.com>
> Date: Tue, 15 May 2018 16:48:22 -0700
> 
>> This patch series includes more drivers to be build tested with COMPILE_TEST
>> enabled. This helps cover some of the issues I just ran into with missing
>> a driver *sigh*.
> 
> Thank you for doing this.
> 
> Series applied.

Actually, I have to revert.

The FEC driver cannot be built tested without the appropriate platform
specific register set defines and x86-64 for example won't provide that.

drivers/net/ethernet/freescale/fec_main.c: In function ‘fec_restart’:
drivers/net/ethernet/freescale/fec_main.c:959:26: error: ‘FEC_RACC’ undeclared (first use in this function); did you mean ‘FEC_RXIC0’?
   val = readl(fep->hwp + FEC_RACC);
                          ^~~~~~~~
                          FEC_RXIC0
drivers/net/ethernet/freescale/fec_main.c:959:26: note: each undeclared identifier is reported only once for each function it appears in
drivers/net/ethernet/freescale/fec_main.c:968:38: error: ‘FEC_FTRL’ undeclared (first use in this function); did you mean ‘FEC_ECNTRL’?
   writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
                                      ^~~~~~~~
                                      FEC_ECNTRL
 ...

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST
  2018-05-16 18:17   ` David Miller
@ 2018-05-16 18:18     ` Florian Fainelli
  0 siblings, 0 replies; 12+ messages in thread
From: Florian Fainelli @ 2018-05-16 18:18 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, andrew, linux-kernel

On 05/16/2018 11:17 AM, David Miller wrote:
> From: David Miller <davem@davemloft.net>
> Date: Wed, 16 May 2018 14:15:14 -0400 (EDT)
> 
>> From: Florian Fainelli <f.fainelli@gmail.com>
>> Date: Tue, 15 May 2018 16:48:22 -0700
>>
>>> This patch series includes more drivers to be build tested with COMPILE_TEST
>>> enabled. This helps cover some of the issues I just ran into with missing
>>> a driver *sigh*.
>>
>> Thank you for doing this.
>>
>> Series applied.
> 
> Actually, I have to revert.
> 
> The FEC driver cannot be built tested without the appropriate platform
> specific register set defines and x86-64 for example won't provide that.

Ah, yes, it built okay for ARM 32-bit, let me fix that.

> 
> drivers/net/ethernet/freescale/fec_main.c: In function ‘fec_restart’:
> drivers/net/ethernet/freescale/fec_main.c:959:26: error: ‘FEC_RACC’ undeclared (first use in this function); did you mean ‘FEC_RXIC0’?
>    val = readl(fep->hwp + FEC_RACC);
>                           ^~~~~~~~
>                           FEC_RXIC0
> drivers/net/ethernet/freescale/fec_main.c:959:26: note: each undeclared identifier is reported only once for each function it appears in
> drivers/net/ethernet/freescale/fec_main.c:968:38: error: ‘FEC_FTRL’ undeclared (first use in this function); did you mean ‘FEC_ECNTRL’?
>    writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
>                                       ^~~~~~~~
>                                       FEC_ECNTRL
>  ...
> 


-- 
Florian

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 1/3] net: ethernet: ti: Allow most drivers with COMPILE_TEST
  2018-05-15 23:48 ` [PATCH net-next 1/3] net: ethernet: ti: Allow most " Florian Fainelli
@ 2018-05-17  3:02   ` kbuild test robot
  2018-05-17  4:25   ` kbuild test robot
  1 sibling, 0 replies; 12+ messages in thread
From: kbuild test robot @ 2018-05-17  3:02 UTC (permalink / raw)
  To: Florian Fainelli
  Cc: kbuild-all, netdev, Florian Fainelli, David S. Miller,
	Andrew Lunn, open list

[-- Attachment #1: Type: text/plain, Size: 10386 bytes --]

Hi Florian,

I love your patch! Perhaps something to improve:

[auto build test WARNING on net-next/master]

url:    https://github.com/0day-ci/linux/commits/Florian-Fainelli/net-Allow-more-drivers-with-COMPILE_TEST/20180517-092807
config: i386-allmodconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-16) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All warnings (new ones prefixed by >>):

   In file included from arch/x86/include/asm/realmode.h:15:0,
                    from arch/x86/include/asm/acpi.h:33,
                    from arch/x86/include/asm/fixmap.h:19,
                    from arch/x86/include/asm/apic.h:10,
                    from arch/x86/include/asm/smp.h:13,
                    from include/linux/smp.h:64,
                    from include/linux/topology.h:33,
                    from include/linux/gfp.h:9,
                    from include/linux/idr.h:16,
                    from include/linux/kernfs.h:14,
                    from include/linux/sysfs.h:16,
                    from include/linux/kobject.h:20,
                    from include/linux/device.h:16,
                    from drivers/net/ethernet/ti/davinci_cpdma.c:17:
   drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit':
>> drivers/net/ethernet/ti/davinci_cpdma.c:1083:17: warning: passing argument 1 of '__writel' makes integer from pointer without a cast [-Wint-conversion]
     writel_relaxed(token, &desc->sw_token);
                    ^
   arch/x86/include/asm/io.h:88:39: note: in definition of macro 'writel_relaxed'
    #define writel_relaxed(v, a) __writel(v, a)
                                          ^
   arch/x86/include/asm/io.h:71:18: note: expected 'unsigned int' but argument is of type 'void *'
    build_mmio_write(__writel, "l", unsigned int, "r", )
                     ^
   arch/x86/include/asm/io.h:53:20: note: in definition of macro 'build_mmio_write'
    static inline void name(type val, volatile void __iomem *addr) \
                       ^~~~

vim +/__writel +1083 drivers/net/ethernet/ti/davinci_cpdma.c

ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1029  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1030  int cpdma_chan_submit(struct cpdma_chan *chan, void *token, void *data,
aef614e1 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-04-23  1031  		      int len, int directed)
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1032  {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1033  	struct cpdma_ctlr		*ctlr = chan->ctlr;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1034  	struct cpdma_desc __iomem	*desc;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1035  	dma_addr_t			buffer;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1036  	unsigned long			flags;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1037  	u32				mode;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1038  	int				ret = 0;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1039  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1040  	spin_lock_irqsave(&chan->lock, flags);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1041  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1042  	if (chan->state == CPDMA_STATE_TEARDOWN) {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1043  		ret = -EINVAL;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1044  		goto unlock_ret;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1045  	}
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1046  
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1047  	if (chan->count >= chan->desc_num)	{
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1048  		chan->stats.desc_alloc_fail++;
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1049  		ret = -ENOMEM;
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1050  		goto unlock_ret;
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1051  	}
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1052  
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1053  	desc = cpdma_desc_alloc(ctlr->pool);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1054  	if (!desc) {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1055  		chan->stats.desc_alloc_fail++;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1056  		ret = -ENOMEM;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1057  		goto unlock_ret;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1058  	}
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1059  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1060  	if (len < ctlr->params.min_packet_size) {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1061  		len = ctlr->params.min_packet_size;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1062  		chan->stats.runt_transmit_buff++;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1063  	}
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1064  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1065  	buffer = dma_map_single(ctlr->dev, data, len, chan->dir);
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1066  	ret = dma_mapping_error(ctlr->dev, buffer);
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1067  	if (ret) {
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1068  		cpdma_desc_free(ctlr->pool, desc, 1);
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1069  		ret = -EINVAL;
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1070  		goto unlock_ret;
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1071  	}
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1072  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1073  	mode = CPDMA_DESC_OWNER | CPDMA_DESC_SOP | CPDMA_DESC_EOP;
f6e135c8 drivers/net/ethernet/ti/davinci_cpdma.c Mugunthan V N     2013-02-11  1074  	cpdma_desc_to_port(chan, mode, directed);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1075  
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1076  	/* Relaxed IO accessors can be used here as there is read barrier
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1077  	 * at the end of write sequence.
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1078  	 */
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1079  	writel_relaxed(0, &desc->hw_next);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1080  	writel_relaxed(buffer, &desc->hw_buffer);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1081  	writel_relaxed(len, &desc->hw_len);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1082  	writel_relaxed(mode | len, &desc->hw_mode);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06 @1083  	writel_relaxed(token, &desc->sw_token);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1084  	writel_relaxed(buffer, &desc->sw_buffer);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1085  	writel_relaxed(len, &desc->sw_len);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1086  	desc_read(desc, sw_len);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1087  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1088  	__cpdma_chan_submit(chan, desc);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1089  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1090  	if (chan->state == CPDMA_STATE_ACTIVE && chan->rxfree)
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1091  		chan_write(chan, rxfree, 1);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1092  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1093  	chan->count++;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1094  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1095  unlock_ret:
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1096  	spin_unlock_irqrestore(&chan->lock, flags);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1097  	return ret;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1098  }
32a6d90b drivers/net/ethernet/ti/davinci_cpdma.c Arnd Bergmann     2012-04-20  1099  EXPORT_SYMBOL_GPL(cpdma_chan_submit);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1100  

:::::: The code at line 1083 was first introduced by commit
:::::: a6c83ccf3c534214e0aeb167a70391864da9b1fc net: ethernet: ti: cpdma: am437x: allow descs to be plased in ddr

:::::: TO: Grygorii Strashko <grygorii.strashko@ti.com>
:::::: CC: David S. Miller <davem@davemloft.net>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 63048 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC with COMPILE_TEST
  2018-05-15 23:48 ` [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC " Florian Fainelli
  2018-05-16  1:19   ` Andy Duan
@ 2018-05-17  3:38   ` kbuild test robot
  2018-05-17  4:03   ` kbuild test robot
  2 siblings, 0 replies; 12+ messages in thread
From: kbuild test robot @ 2018-05-17  3:38 UTC (permalink / raw)
  To: Florian Fainelli
  Cc: kbuild-all, netdev, Florian Fainelli, David S. Miller,
	Andrew Lunn, open list

[-- Attachment #1: Type: text/plain, Size: 29906 bytes --]

Hi Florian,

I love your patch! Perhaps something to improve:

[auto build test WARNING on net-next/master]

url:    https://github.com/0day-ci/linux/commits/Florian-Fainelli/net-Allow-more-drivers-with-COMPILE_TEST/20180517-092807
config: m68k-allyesconfig (attached as .config)
compiler: m68k-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
        # save the attached .config to linux build tree
        make.cross ARCH=m68k 

All warnings (new ones prefixed by >>):

   In file included from include/linux/swab.h:5:0,
                    from include/uapi/linux/byteorder/big_endian.h:13,
                    from include/linux/byteorder/big_endian.h:5,
                    from arch/m68k/include/uapi/asm/byteorder.h:5,
                    from include/asm-generic/bitops/le.h:6,
                    from arch/m68k/include/asm/bitops.h:519,
                    from include/linux/bitops.h:38,
                    from include/linux/kernel.h:11,
                    from include/linux/list.h:9,
                    from include/linux/module.h:9,
                    from drivers/net/ethernet/freescale/fec_main.c:24:
   drivers/net/ethernet/freescale/fec_main.c: In function 'fec_restart':
   drivers/net/ethernet/freescale/fec_main.c:959:26: error: 'FEC_RACC' undeclared (first use in this function); did you mean 'FEC_RXIC0'?
      val = readl(fep->hwp + FEC_RACC);
                             ^
   include/uapi/linux/swab.h:117:32: note: in definition of macro '__swab32'
     (__builtin_constant_p((__u32)(x)) ? \
                                   ^
>> include/linux/byteorder/generic.h:89:21: note: in expansion of macro '__le32_to_cpu'
    #define le32_to_cpu __le32_to_cpu
                        ^~~~~~~~~~~~~
>> arch/m68k/include/asm/io_mm.h:452:26: note: in expansion of macro 'in_le32'
    #define readl(addr)      in_le32(addr)
                             ^~~~~~~
>> drivers/net/ethernet/freescale/fec_main.c:959:9: note: in expansion of macro 'readl'
      val = readl(fep->hwp + FEC_RACC);
            ^~~~~
   drivers/net/ethernet/freescale/fec_main.c:959:26: note: each undeclared identifier is reported only once for each function it appears in
      val = readl(fep->hwp + FEC_RACC);
                             ^
   include/uapi/linux/swab.h:117:32: note: in definition of macro '__swab32'
     (__builtin_constant_p((__u32)(x)) ? \
                                   ^
>> include/linux/byteorder/generic.h:89:21: note: in expansion of macro '__le32_to_cpu'
    #define le32_to_cpu __le32_to_cpu
                        ^~~~~~~~~~~~~
>> arch/m68k/include/asm/io_mm.h:452:26: note: in expansion of macro 'in_le32'
    #define readl(addr)      in_le32(addr)
                             ^~~~~~~
>> drivers/net/ethernet/freescale/fec_main.c:959:9: note: in expansion of macro 'readl'
      val = readl(fep->hwp + FEC_RACC);
            ^~~~~
   In file included from arch/m68k/include/asm/io_mm.h:27:0,
                    from arch/m68k/include/asm/io.h:5,
                    from include/linux/scatterlist.h:9,
                    from include/linux/dma-mapping.h:11,
                    from include/linux/skbuff.h:34,
                    from include/linux/if_ether.h:23,
                    from include/uapi/linux/ethtool.h:19,
                    from include/linux/ethtool.h:18,
                    from include/linux/netdevice.h:41,
                    from drivers/net/ethernet/freescale/fec_main.c:34:
   drivers/net/ethernet/freescale/fec_main.c:968:38: error: 'FEC_FTRL' undeclared (first use in this function); did you mean 'FEC_ECNTRL'?
      writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
>> drivers/net/ethernet/freescale/fec_main.c:968:3: note: in expansion of macro 'writel'
      writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
      ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1034:38: error: 'FEC_R_FIFO_RSEM' undeclared (first use in this function); did you mean 'FEC_FIFO_RAM'?
      writel(FEC_ENET_RSEM_V, fep->hwp + FEC_R_FIFO_RSEM);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1034:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RSEM_V, fep->hwp + FEC_R_FIFO_RSEM);
      ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1035:38: error: 'FEC_R_FIFO_RSFL' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSEM'?
      writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1035:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL);
      ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1036:38: error: 'FEC_R_FIFO_RAEM' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSEM'?
      writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1036:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM);
      ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1037:38: error: 'FEC_R_FIFO_RAFL' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSFL'?
      writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1037:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL);
      ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1040:37: error: 'FEC_OPD' undeclared (first use in this function); did you mean 'FEC_H'?
      writel(FEC_ENET_OPD_V, fep->hwp + FEC_OPD);
                                        ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1040:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_OPD_V, fep->hwp + FEC_OPD);
      ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1051:23: error: 'FEC_HASH_TABLE_HIGH' undeclared (first use in this function); did you mean 'FEC_GRP_HASH_TABLE_HIGH'?
     writel(0, fep->hwp + FEC_HASH_TABLE_HIGH);
                          ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1051:2: note: in expansion of macro 'writel'
     writel(0, fep->hwp + FEC_HASH_TABLE_HIGH);
     ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1052:23: error: 'FEC_HASH_TABLE_LOW' undeclared (first use in this function); did you mean 'FEC_HASH_TABLE_HIGH'?
     writel(0, fep->hwp + FEC_HASH_TABLE_LOW);
                          ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1052:2: note: in expansion of macro 'writel'
     writel(0, fep->hwp + FEC_HASH_TABLE_LOW);
     ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c:1067:29: error: 'FEC_MIB_CTRLSTAT' undeclared (first use in this function); did you mean 'TCP_MIB_CURRESTAB'?
     writel(0 << 31, fep->hwp + FEC_MIB_CTRLSTAT);
                                ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net/ethernet/freescale/fec_main.c:1067:2: note: in expansion of macro 'writel'
     writel(0 << 31, fep->hwp + FEC_MIB_CTRLSTAT);
     ^~~~~~
   drivers/net/ethernet/freescale/fec_main.c: At top level:
   drivers/net/ethernet/freescale/fec_main.c:2261:18: error: 'RMON_T_DROP' undeclared here (not in a function); did you mean 'RTN_THROW'?
     { "tx_dropped", RMON_T_DROP },
                     ^~~~~~~~~~~
                     RTN_THROW
   drivers/net/ethernet/freescale/fec_main.c:2262:18: error: 'RMON_T_PACKETS' undeclared here (not in a function); did you mean 'SOCK_PACKET'?
     { "tx_packets", RMON_T_PACKETS },
                     ^~~~~~~~~~~~~~
                     SOCK_PACKET
   drivers/net/ethernet/freescale/fec_main.c:2263:20: error: 'RMON_T_BC_PKT' undeclared here (not in a function); did you mean 'RMON_T_DROP'?
     { "tx_broadcast", RMON_T_BC_PKT },
                       ^~~~~~~~~~~~~
                       RMON_T_DROP
   drivers/net/ethernet/freescale/fec_main.c:2264:20: error: 'RMON_T_MC_PKT' undeclared here (not in a function); did you mean 'RMON_T_BC_PKT'?
     { "tx_multicast", RMON_T_MC_PKT },
                       ^~~~~~~~~~~~~
                       RMON_T_BC_PKT
   drivers/net/ethernet/freescale/fec_main.c:2265:21: error: 'RMON_T_CRC_ALIGN' undeclared here (not in a function); did you mean 'RMON_T_MC_PKT'?
     { "tx_crc_errors", RMON_T_CRC_ALIGN },
                        ^~~~~~~~~~~~~~~~
                        RMON_T_MC_PKT
   drivers/net/ethernet/freescale/fec_main.c:2266:20: error: 'RMON_T_UNDERSIZE' undeclared here (not in a function); did you mean 'RMON_T_DROP'?
     { "tx_undersize", RMON_T_UNDERSIZE },
                       ^~~~~~~~~~~~~~~~
                       RMON_T_DROP
   drivers/net/ethernet/freescale/fec_main.c:2267:19: error: 'RMON_T_OVERSIZE' undeclared here (not in a function); did you mean 'RMON_T_UNDERSIZE'?
--
   In file included from include/linux/swab.h:5:0,
                    from include/uapi/linux/byteorder/big_endian.h:13,
                    from include/linux/byteorder/big_endian.h:5,
                    from arch/m68k/include/uapi/asm/byteorder.h:5,
                    from include/asm-generic/bitops/le.h:6,
                    from arch/m68k/include/asm/bitops.h:519,
                    from include/linux/bitops.h:38,
                    from include/linux/kernel.h:11,
                    from include/linux/list.h:9,
                    from include/linux/module.h:9,
                    from drivers/net//ethernet/freescale/fec_main.c:24:
   drivers/net//ethernet/freescale/fec_main.c: In function 'fec_restart':
   drivers/net//ethernet/freescale/fec_main.c:959:26: error: 'FEC_RACC' undeclared (first use in this function); did you mean 'FEC_RXIC0'?
      val = readl(fep->hwp + FEC_RACC);
                             ^
   include/uapi/linux/swab.h:117:32: note: in definition of macro '__swab32'
     (__builtin_constant_p((__u32)(x)) ? \
                                   ^
>> include/linux/byteorder/generic.h:89:21: note: in expansion of macro '__le32_to_cpu'
    #define le32_to_cpu __le32_to_cpu
                        ^~~~~~~~~~~~~
>> arch/m68k/include/asm/io_mm.h:452:26: note: in expansion of macro 'in_le32'
    #define readl(addr)      in_le32(addr)
                             ^~~~~~~
   drivers/net//ethernet/freescale/fec_main.c:959:9: note: in expansion of macro 'readl'
      val = readl(fep->hwp + FEC_RACC);
            ^~~~~
   drivers/net//ethernet/freescale/fec_main.c:959:26: note: each undeclared identifier is reported only once for each function it appears in
      val = readl(fep->hwp + FEC_RACC);
                             ^
   include/uapi/linux/swab.h:117:32: note: in definition of macro '__swab32'
     (__builtin_constant_p((__u32)(x)) ? \
                                   ^
>> include/linux/byteorder/generic.h:89:21: note: in expansion of macro '__le32_to_cpu'
    #define le32_to_cpu __le32_to_cpu
                        ^~~~~~~~~~~~~
>> arch/m68k/include/asm/io_mm.h:452:26: note: in expansion of macro 'in_le32'
    #define readl(addr)      in_le32(addr)
                             ^~~~~~~
   drivers/net//ethernet/freescale/fec_main.c:959:9: note: in expansion of macro 'readl'
      val = readl(fep->hwp + FEC_RACC);
            ^~~~~
   In file included from arch/m68k/include/asm/io_mm.h:27:0,
                    from arch/m68k/include/asm/io.h:5,
                    from include/linux/scatterlist.h:9,
                    from include/linux/dma-mapping.h:11,
                    from include/linux/skbuff.h:34,
                    from include/linux/if_ether.h:23,
                    from include/uapi/linux/ethtool.h:19,
                    from include/linux/ethtool.h:18,
                    from include/linux/netdevice.h:41,
                    from drivers/net//ethernet/freescale/fec_main.c:34:
   drivers/net//ethernet/freescale/fec_main.c:968:38: error: 'FEC_FTRL' undeclared (first use in this function); did you mean 'FEC_ECNTRL'?
      writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:968:3: note: in expansion of macro 'writel'
      writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1034:38: error: 'FEC_R_FIFO_RSEM' undeclared (first use in this function); did you mean 'FEC_FIFO_RAM'?
      writel(FEC_ENET_RSEM_V, fep->hwp + FEC_R_FIFO_RSEM);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1034:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RSEM_V, fep->hwp + FEC_R_FIFO_RSEM);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1035:38: error: 'FEC_R_FIFO_RSFL' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSEM'?
      writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1035:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1036:38: error: 'FEC_R_FIFO_RAEM' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSEM'?
      writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1036:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1037:38: error: 'FEC_R_FIFO_RAFL' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSFL'?
      writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1037:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1040:37: error: 'FEC_OPD' undeclared (first use in this function); did you mean 'FEC_H'?
      writel(FEC_ENET_OPD_V, fep->hwp + FEC_OPD);
                                        ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1040:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_OPD_V, fep->hwp + FEC_OPD);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1051:23: error: 'FEC_HASH_TABLE_HIGH' undeclared (first use in this function); did you mean 'FEC_GRP_HASH_TABLE_HIGH'?
     writel(0, fep->hwp + FEC_HASH_TABLE_HIGH);
                          ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1051:2: note: in expansion of macro 'writel'
     writel(0, fep->hwp + FEC_HASH_TABLE_HIGH);
     ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1052:23: error: 'FEC_HASH_TABLE_LOW' undeclared (first use in this function); did you mean 'FEC_HASH_TABLE_HIGH'?
     writel(0, fep->hwp + FEC_HASH_TABLE_LOW);
                          ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1052:2: note: in expansion of macro 'writel'
     writel(0, fep->hwp + FEC_HASH_TABLE_LOW);
     ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1067:29: error: 'FEC_MIB_CTRLSTAT' undeclared (first use in this function); did you mean 'TCP_MIB_CURRESTAB'?
     writel(0 << 31, fep->hwp + FEC_MIB_CTRLSTAT);
                                ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1067:2: note: in expansion of macro 'writel'
     writel(0 << 31, fep->hwp + FEC_MIB_CTRLSTAT);
     ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c: At top level:
   drivers/net//ethernet/freescale/fec_main.c:2261:18: error: 'RMON_T_DROP' undeclared here (not in a function); did you mean 'RTN_THROW'?
     { "tx_dropped", RMON_T_DROP },
                     ^~~~~~~~~~~

vim +/__le32_to_cpu +89 include/linux/byteorder/generic.h

^1da177e Linus Torvalds 2005-04-16    4  
^1da177e Linus Torvalds 2005-04-16    5  /*
90a85643 Geoff Levand   2014-08-06    6   * linux/byteorder/generic.h
^1da177e Linus Torvalds 2005-04-16    7   * Generic Byte-reordering support
^1da177e Linus Torvalds 2005-04-16    8   *
e0487992 Ed L. Cashin   2005-09-19    9   * The "... p" macros, like le64_to_cpup, can be used with pointers
e0487992 Ed L. Cashin   2005-09-19   10   * to unaligned data, but there will be a performance penalty on 
e0487992 Ed L. Cashin   2005-09-19   11   * some architectures.  Use get_unaligned for unaligned data.
e0487992 Ed L. Cashin   2005-09-19   12   *
^1da177e Linus Torvalds 2005-04-16   13   * Francois-Rene Rideau <fare@tunes.org> 19970707
^1da177e Linus Torvalds 2005-04-16   14   *    gathered all the good ideas from all asm-foo/byteorder.h into one file,
^1da177e Linus Torvalds 2005-04-16   15   *    cleaned them up.
^1da177e Linus Torvalds 2005-04-16   16   *    I hope it is compliant with non-GCC compilers.
^1da177e Linus Torvalds 2005-04-16   17   *    I decided to put __BYTEORDER_HAS_U64__ in byteorder.h,
^1da177e Linus Torvalds 2005-04-16   18   *    because I wasn't sure it would be ok to put it in types.h
^1da177e Linus Torvalds 2005-04-16   19   *    Upgraded it to 2.1.43
^1da177e Linus Torvalds 2005-04-16   20   * Francois-Rene Rideau <fare@tunes.org> 19971012
^1da177e Linus Torvalds 2005-04-16   21   *    Upgraded it to 2.1.57
^1da177e Linus Torvalds 2005-04-16   22   *    to please Linus T., replaced huge #ifdef's between little/big endian
^1da177e Linus Torvalds 2005-04-16   23   *    by nestedly #include'd files.
^1da177e Linus Torvalds 2005-04-16   24   * Francois-Rene Rideau <fare@tunes.org> 19971205
^1da177e Linus Torvalds 2005-04-16   25   *    Made it to 2.1.71; now a facelift:
^1da177e Linus Torvalds 2005-04-16   26   *    Put files under include/linux/byteorder/
^1da177e Linus Torvalds 2005-04-16   27   *    Split swab from generic support.
^1da177e Linus Torvalds 2005-04-16   28   *
^1da177e Linus Torvalds 2005-04-16   29   * TODO:
^1da177e Linus Torvalds 2005-04-16   30   *   = Regular kernel maintainers could also replace all these manual
^1da177e Linus Torvalds 2005-04-16   31   *    byteswap macros that remain, disseminated among drivers,
^1da177e Linus Torvalds 2005-04-16   32   *    after some grep or the sources...
^1da177e Linus Torvalds 2005-04-16   33   *   = Linus might want to rename all these macros and files to fit his taste,
^1da177e Linus Torvalds 2005-04-16   34   *    to fit his personal naming scheme.
^1da177e Linus Torvalds 2005-04-16   35   *   = it seems that a few drivers would also appreciate
^1da177e Linus Torvalds 2005-04-16   36   *    nybble swapping support...
^1da177e Linus Torvalds 2005-04-16   37   *   = every architecture could add their byteswap macro in asm/byteorder.h
^1da177e Linus Torvalds 2005-04-16   38   *    see how some architectures already do (i386, alpha, ppc, etc)
^1da177e Linus Torvalds 2005-04-16   39   *   = cpu_to_beXX and beXX_to_cpu might some day need to be well
^1da177e Linus Torvalds 2005-04-16   40   *    distinguished throughout the kernel. This is not the case currently,
^1da177e Linus Torvalds 2005-04-16   41   *    since little endian, big endian, and pdp endian machines needn't it.
^1da177e Linus Torvalds 2005-04-16   42   *    But this might be the case for, say, a port of Linux to 20/21 bit
^1da177e Linus Torvalds 2005-04-16   43   *    architectures (and F21 Linux addict around?).
^1da177e Linus Torvalds 2005-04-16   44   */
^1da177e Linus Torvalds 2005-04-16   45  
^1da177e Linus Torvalds 2005-04-16   46  /*
^1da177e Linus Torvalds 2005-04-16   47   * The following macros are to be defined by <asm/byteorder.h>:
^1da177e Linus Torvalds 2005-04-16   48   *
^1da177e Linus Torvalds 2005-04-16   49   * Conversion of long and short int between network and host format
^1da177e Linus Torvalds 2005-04-16   50   *	ntohl(__u32 x)
^1da177e Linus Torvalds 2005-04-16   51   *	ntohs(__u16 x)
^1da177e Linus Torvalds 2005-04-16   52   *	htonl(__u32 x)
^1da177e Linus Torvalds 2005-04-16   53   *	htons(__u16 x)
^1da177e Linus Torvalds 2005-04-16   54   * It seems that some programs (which? where? or perhaps a standard? POSIX?)
^1da177e Linus Torvalds 2005-04-16   55   * might like the above to be functions, not macros (why?).
^1da177e Linus Torvalds 2005-04-16   56   * if that's true, then detect them, and take measures.
^1da177e Linus Torvalds 2005-04-16   57   * Anyway, the measure is: define only ___ntohl as a macro instead,
^1da177e Linus Torvalds 2005-04-16   58   * and in a separate file, have
^1da177e Linus Torvalds 2005-04-16   59   * unsigned long inline ntohl(x){return ___ntohl(x);}
^1da177e Linus Torvalds 2005-04-16   60   *
^1da177e Linus Torvalds 2005-04-16   61   * The same for constant arguments
^1da177e Linus Torvalds 2005-04-16   62   *	__constant_ntohl(__u32 x)
^1da177e Linus Torvalds 2005-04-16   63   *	__constant_ntohs(__u16 x)
^1da177e Linus Torvalds 2005-04-16   64   *	__constant_htonl(__u32 x)
^1da177e Linus Torvalds 2005-04-16   65   *	__constant_htons(__u16 x)
^1da177e Linus Torvalds 2005-04-16   66   *
^1da177e Linus Torvalds 2005-04-16   67   * Conversion of XX-bit integers (16- 32- or 64-)
^1da177e Linus Torvalds 2005-04-16   68   * between native CPU format and little/big endian format
^1da177e Linus Torvalds 2005-04-16   69   * 64-bit stuff only defined for proper architectures
^1da177e Linus Torvalds 2005-04-16   70   *	cpu_to_[bl]eXX(__uXX x)
^1da177e Linus Torvalds 2005-04-16   71   *	[bl]eXX_to_cpu(__uXX x)
^1da177e Linus Torvalds 2005-04-16   72   *
^1da177e Linus Torvalds 2005-04-16   73   * The same, but takes a pointer to the value to convert
^1da177e Linus Torvalds 2005-04-16   74   *	cpu_to_[bl]eXXp(__uXX x)
^1da177e Linus Torvalds 2005-04-16   75   *	[bl]eXX_to_cpup(__uXX x)
^1da177e Linus Torvalds 2005-04-16   76   *
^1da177e Linus Torvalds 2005-04-16   77   * The same, but change in situ
^1da177e Linus Torvalds 2005-04-16   78   *	cpu_to_[bl]eXXs(__uXX x)
^1da177e Linus Torvalds 2005-04-16   79   *	[bl]eXX_to_cpus(__uXX x)
^1da177e Linus Torvalds 2005-04-16   80   *
^1da177e Linus Torvalds 2005-04-16   81   * See asm-foo/byteorder.h for examples of how to provide
^1da177e Linus Torvalds 2005-04-16   82   * architecture-optimized versions
^1da177e Linus Torvalds 2005-04-16   83   *
^1da177e Linus Torvalds 2005-04-16   84   */
^1da177e Linus Torvalds 2005-04-16   85  
^1da177e Linus Torvalds 2005-04-16   86  #define cpu_to_le64 __cpu_to_le64
^1da177e Linus Torvalds 2005-04-16   87  #define le64_to_cpu __le64_to_cpu
^1da177e Linus Torvalds 2005-04-16   88  #define cpu_to_le32 __cpu_to_le32
^1da177e Linus Torvalds 2005-04-16  @89  #define le32_to_cpu __le32_to_cpu
^1da177e Linus Torvalds 2005-04-16   90  #define cpu_to_le16 __cpu_to_le16
^1da177e Linus Torvalds 2005-04-16   91  #define le16_to_cpu __le16_to_cpu
^1da177e Linus Torvalds 2005-04-16   92  #define cpu_to_be64 __cpu_to_be64
^1da177e Linus Torvalds 2005-04-16   93  #define be64_to_cpu __be64_to_cpu
^1da177e Linus Torvalds 2005-04-16   94  #define cpu_to_be32 __cpu_to_be32
^1da177e Linus Torvalds 2005-04-16   95  #define be32_to_cpu __be32_to_cpu
^1da177e Linus Torvalds 2005-04-16   96  #define cpu_to_be16 __cpu_to_be16
^1da177e Linus Torvalds 2005-04-16   97  #define be16_to_cpu __be16_to_cpu
^1da177e Linus Torvalds 2005-04-16   98  #define cpu_to_le64p __cpu_to_le64p
^1da177e Linus Torvalds 2005-04-16   99  #define le64_to_cpup __le64_to_cpup
^1da177e Linus Torvalds 2005-04-16  100  #define cpu_to_le32p __cpu_to_le32p
^1da177e Linus Torvalds 2005-04-16  101  #define le32_to_cpup __le32_to_cpup
^1da177e Linus Torvalds 2005-04-16  102  #define cpu_to_le16p __cpu_to_le16p
^1da177e Linus Torvalds 2005-04-16  103  #define le16_to_cpup __le16_to_cpup
^1da177e Linus Torvalds 2005-04-16  104  #define cpu_to_be64p __cpu_to_be64p
^1da177e Linus Torvalds 2005-04-16  105  #define be64_to_cpup __be64_to_cpup
^1da177e Linus Torvalds 2005-04-16  106  #define cpu_to_be32p __cpu_to_be32p
^1da177e Linus Torvalds 2005-04-16  107  #define be32_to_cpup __be32_to_cpup
^1da177e Linus Torvalds 2005-04-16  108  #define cpu_to_be16p __cpu_to_be16p
^1da177e Linus Torvalds 2005-04-16  109  #define be16_to_cpup __be16_to_cpup
^1da177e Linus Torvalds 2005-04-16  110  #define cpu_to_le64s __cpu_to_le64s
^1da177e Linus Torvalds 2005-04-16  111  #define le64_to_cpus __le64_to_cpus
^1da177e Linus Torvalds 2005-04-16  112  #define cpu_to_le32s __cpu_to_le32s
^1da177e Linus Torvalds 2005-04-16  113  #define le32_to_cpus __le32_to_cpus
^1da177e Linus Torvalds 2005-04-16  114  #define cpu_to_le16s __cpu_to_le16s
^1da177e Linus Torvalds 2005-04-16  115  #define le16_to_cpus __le16_to_cpus
^1da177e Linus Torvalds 2005-04-16  116  #define cpu_to_be64s __cpu_to_be64s
^1da177e Linus Torvalds 2005-04-16  117  #define be64_to_cpus __be64_to_cpus
^1da177e Linus Torvalds 2005-04-16  118  #define cpu_to_be32s __cpu_to_be32s
^1da177e Linus Torvalds 2005-04-16  119  #define be32_to_cpus __be32_to_cpus
^1da177e Linus Torvalds 2005-04-16  120  #define cpu_to_be16s __cpu_to_be16s
^1da177e Linus Torvalds 2005-04-16  121  #define be16_to_cpus __be16_to_cpus
^1da177e Linus Torvalds 2005-04-16  122  

:::::: The code at line 89 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2

:::::: TO: Linus Torvalds <torvalds@ppc970.osdl.org>
:::::: CC: Linus Torvalds <torvalds@ppc970.osdl.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 45454 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC with COMPILE_TEST
  2018-05-15 23:48 ` [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC " Florian Fainelli
  2018-05-16  1:19   ` Andy Duan
  2018-05-17  3:38   ` kbuild test robot
@ 2018-05-17  4:03   ` kbuild test robot
  2 siblings, 0 replies; 12+ messages in thread
From: kbuild test robot @ 2018-05-17  4:03 UTC (permalink / raw)
  To: Florian Fainelli
  Cc: kbuild-all, netdev, Florian Fainelli, David S. Miller,
	Andrew Lunn, open list

[-- Attachment #1: Type: text/plain, Size: 23061 bytes --]

Hi Florian,

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/0day-ci/linux/commits/Florian-Fainelli/net-Allow-more-drivers-with-COMPILE_TEST/20180517-092807
config: m68k-allmodconfig (attached as .config)
compiler: m68k-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
        # save the attached .config to linux build tree
        make.cross ARCH=m68k 

All errors (new ones prefixed by >>):

   In file included from include/linux/swab.h:5:0,
                    from include/uapi/linux/byteorder/big_endian.h:13,
                    from include/linux/byteorder/big_endian.h:5,
                    from arch/m68k/include/uapi/asm/byteorder.h:5,
                    from include/asm-generic/bitops/le.h:6,
                    from arch/m68k/include/asm/bitops.h:519,
                    from include/linux/bitops.h:38,
                    from include/linux/kernel.h:11,
                    from include/linux/list.h:9,
                    from include/linux/module.h:9,
                    from drivers/net//ethernet/freescale/fec_main.c:24:
   drivers/net//ethernet/freescale/fec_main.c: In function 'fec_restart':
>> drivers/net//ethernet/freescale/fec_main.c:959:26: error: 'FEC_RACC' undeclared (first use in this function); did you mean 'FEC_RXIC1'?
      val = readl(fep->hwp + FEC_RACC);
                             ^
   include/uapi/linux/swab.h:117:32: note: in definition of macro '__swab32'
     (__builtin_constant_p((__u32)(x)) ? \
                                   ^
   include/linux/byteorder/generic.h:89:21: note: in expansion of macro '__le32_to_cpu'
    #define le32_to_cpu __le32_to_cpu
                        ^~~~~~~~~~~~~
   arch/m68k/include/asm/io_mm.h:452:26: note: in expansion of macro 'in_le32'
    #define readl(addr)      in_le32(addr)
                             ^~~~~~~
   drivers/net//ethernet/freescale/fec_main.c:959:9: note: in expansion of macro 'readl'
      val = readl(fep->hwp + FEC_RACC);
            ^~~~~
   drivers/net//ethernet/freescale/fec_main.c:959:26: note: each undeclared identifier is reported only once for each function it appears in
      val = readl(fep->hwp + FEC_RACC);
                             ^
   include/uapi/linux/swab.h:117:32: note: in definition of macro '__swab32'
     (__builtin_constant_p((__u32)(x)) ? \
                                   ^
   include/linux/byteorder/generic.h:89:21: note: in expansion of macro '__le32_to_cpu'
    #define le32_to_cpu __le32_to_cpu
                        ^~~~~~~~~~~~~
   arch/m68k/include/asm/io_mm.h:452:26: note: in expansion of macro 'in_le32'
    #define readl(addr)      in_le32(addr)
                             ^~~~~~~
   drivers/net//ethernet/freescale/fec_main.c:959:9: note: in expansion of macro 'readl'
      val = readl(fep->hwp + FEC_RACC);
            ^~~~~
   In file included from arch/m68k/include/asm/io_mm.h:27:0,
                    from arch/m68k/include/asm/io.h:5,
                    from include/linux/scatterlist.h:9,
                    from include/linux/dma-mapping.h:11,
                    from include/linux/skbuff.h:34,
                    from include/linux/if_ether.h:23,
                    from include/uapi/linux/ethtool.h:19,
                    from include/linux/ethtool.h:18,
                    from include/linux/netdevice.h:41,
                    from drivers/net//ethernet/freescale/fec_main.c:34:
   drivers/net//ethernet/freescale/fec_main.c:968:38: error: 'FEC_FTRL' undeclared (first use in this function); did you mean 'FEC_ECNTRL'?
      writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:968:3: note: in expansion of macro 'writel'
      writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1034:38: error: 'FEC_R_FIFO_RSEM' undeclared (first use in this function); did you mean 'FEC_FIFO_RAM'?
      writel(FEC_ENET_RSEM_V, fep->hwp + FEC_R_FIFO_RSEM);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1034:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RSEM_V, fep->hwp + FEC_R_FIFO_RSEM);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1035:38: error: 'FEC_R_FIFO_RSFL' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSEM'?
      writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1035:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1036:38: error: 'FEC_R_FIFO_RAEM' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSEM'?
      writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1036:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1037:38: error: 'FEC_R_FIFO_RAFL' undeclared (first use in this function); did you mean 'FEC_R_FIFO_RSFL'?
      writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL);
                                         ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1037:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1040:37: error: 'FEC_OPD' undeclared (first use in this function); did you mean 'FEC_H'?
      writel(FEC_ENET_OPD_V, fep->hwp + FEC_OPD);
                                        ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1040:3: note: in expansion of macro 'writel'
      writel(FEC_ENET_OPD_V, fep->hwp + FEC_OPD);
      ^~~~~~
   drivers/net//ethernet/freescale/fec_main.c:1051:23: error: 'FEC_HASH_TABLE_HIGH' undeclared (first use in this function); did you mean 'FEC_GRP_HASH_TABLE_HIGH'?
     writel(0, fep->hwp + FEC_HASH_TABLE_HIGH);
                          ^
   arch/m68k/include/asm/raw_io.h:48:64: note: in definition of macro 'out_le32'
    #define out_le32(addr,l) (void)((*(__force volatile __le32 *) (addr)) = cpu_to_le32(l))
                                                                   ^~~~
   drivers/net//ethernet/freescale/fec_main.c:1051:2: note: in expansion of macro 'writel'

vim +959 drivers/net//ethernet/freescale/fec_main.c

14109a59c drivers/net/ethernet/freescale/fec.c      Frank Li         2013-03-26   898  
dbc64a8ea drivers/net/ethernet/freescale/fec_main.c Russell King     2014-07-08   899  /*
dbc64a8ea drivers/net/ethernet/freescale/fec_main.c Russell King     2014-07-08   900   * This function is called to start or restart the FEC during a link
dbc64a8ea drivers/net/ethernet/freescale/fec_main.c Russell King     2014-07-08   901   * change, transmit timeout, or to reconfigure the FEC.  The network
dbc64a8ea drivers/net/ethernet/freescale/fec_main.c Russell King     2014-07-08   902   * packet processing for this device must be stopped before this call.
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   903   */
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   904  static void
ef83337d1 drivers/net/ethernet/freescale/fec_main.c Russell King     2014-07-08   905  fec_restart(struct net_device *ndev)
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   906  {
c556167f8 drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   907  	struct fec_enet_private *fep = netdev_priv(ndev);
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   908  	u32 val;
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   909  	u32 temp_mac[2];
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   910  	u32 rcntl = OPT_FRAME_SIZE | 0x04;
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   911  	u32 ecntl = 0x2; /* ETHEREN */
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   912  
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   913  	/* Whack a reset.  We should wait for this.
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   914  	 * For i.MX6SX SOC, enet use AXI bus, we use disable MAC
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   915  	 * instead of reset MAC itself.
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   916  	 */
6b7e40083 drivers/net/ethernet/freescale/fec_main.c Lothar Waßmann   2014-11-17   917  	if (fep->quirks & FEC_QUIRK_HAS_AVB) {
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   918  		writel(0, fep->hwp + FEC_ECNTRL);
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   919  	} else {
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   920  		writel(1, fep->hwp + FEC_ECNTRL);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   921  		udelay(10);
106c314c7 drivers/net/ethernet/freescale/fec_main.c Fugang Duan      2014-09-13   922  	}
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   923  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   924  	/*
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   925  	 * enet-mac reset will reset mac address registers too,
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   926  	 * so need to reconfigure it.
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   927  	 */
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   928  	memcpy(&temp_mac, ndev->dev_addr, ETH_ALEN);
5cfa30397 drivers/net/ethernet/freescale/fec_main.c Johannes Berg    2016-01-24   929  	writel((__force u32)cpu_to_be32(temp_mac[0]),
5cfa30397 drivers/net/ethernet/freescale/fec_main.c Johannes Berg    2016-01-24   930  	       fep->hwp + FEC_ADDR_LOW);
5cfa30397 drivers/net/ethernet/freescale/fec_main.c Johannes Berg    2016-01-24   931  	writel((__force u32)cpu_to_be32(temp_mac[1]),
5cfa30397 drivers/net/ethernet/freescale/fec_main.c Johannes Berg    2016-01-24   932  	       fep->hwp + FEC_ADDR_HIGH);
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   933  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   934  	/* Clear any outstanding interrupt. */
e17f7fecd drivers/net/ethernet/freescale/fec_main.c Nimrod Andy      2014-12-11   935  	writel(0xffffffff, fep->hwp + FEC_IEVENT);
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   936  
14109a59c drivers/net/ethernet/freescale/fec.c      Frank Li         2013-03-26   937  	fec_enet_bd_init(ndev);
14109a59c drivers/net/ethernet/freescale/fec.c      Frank Li         2013-03-26   938  
59d0f7465 drivers/net/ethernet/freescale/fec_main.c Frank Li         2014-09-13   939  	fec_enet_enable_ring(ndev);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   940  
59d0f7465 drivers/net/ethernet/freescale/fec_main.c Frank Li         2014-09-13   941  	/* Reset tx SKB buffers. */
59d0f7465 drivers/net/ethernet/freescale/fec_main.c Frank Li         2014-09-13   942  	fec_enet_reset_skb(ndev);
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   943  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   944  	/* Enable MII mode */
ef83337d1 drivers/net/ethernet/freescale/fec_main.c Russell King     2014-07-08   945  	if (fep->full_duplex == DUPLEX_FULL) {
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   946  		/* FD enable */
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   947  		writel(0x04, fep->hwp + FEC_X_CNTRL);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   948  	} else {
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   949  		/* No Rcv on Xmit */
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   950  		rcntl |= 0x02;
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   951  		writel(0x0, fep->hwp + FEC_X_CNTRL);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   952  	}
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   953  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   954  	/* Set MII speed */
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   955  	writel(fep->phy_speed, fep->hwp + FEC_MII_SPEED);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   956  
d13919301 drivers/net/ethernet/freescale/fec_main.c Guenter Roeck    2013-06-18   957  #if !defined(CONFIG_M5272)
18803495a drivers/net/ethernet/freescale/fec_main.c Greg Ungerer     2015-06-20   958  	if (fep->quirks & FEC_QUIRK_HAS_RACC) {
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19  @959  		val = readl(fep->hwp + FEC_RACC);
3ac72b7b6 drivers/net/ethernet/freescale/fec_main.c Eric Nelson      2016-09-24   960  		/* align IP header */
3ac72b7b6 drivers/net/ethernet/freescale/fec_main.c Eric Nelson      2016-09-24   961  		val |= FEC_RACC_SHIFT16;
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   962  		if (fep->csum_flags & FLAG_RX_CSUM_ENABLED)
3ac72b7b6 drivers/net/ethernet/freescale/fec_main.c Eric Nelson      2016-09-24   963  			/* set RX checksum */
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   964  			val |= FEC_RACC_OPTIONS;
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   965  		else
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   966  			val &= ~FEC_RACC_OPTIONS;
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   967  		writel(val, fep->hwp + FEC_RACC);
55cd48c82 drivers/net/ethernet/freescale/fec_main.c Troy Kisky       2016-02-05   968  		writel(PKT_MAXBUF_SIZE, fep->hwp + FEC_FTRL);
32867fcc0 drivers/net/ethernet/freescale/fec_main.c Fabio Estevam    2016-03-31   969  	}
d13919301 drivers/net/ethernet/freescale/fec_main.c Guenter Roeck    2013-06-18   970  #endif
4c09eed9d drivers/net/ethernet/freescale/fec_main.c Jim Baxter       2013-04-19   971  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   972  	/*
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   973  	 * The phy interface and speed need to get configured
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   974  	 * differently on enet-mac.
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16   975  	 */
6b7e40083 drivers/net/ethernet/freescale/fec_main.c Lothar Waßmann   2014-11-17   976  	if (fep->quirks & FEC_QUIRK_ENET_MAC) {
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   977  		/* Enable flow control and length check */
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   978  		rcntl |= 0x40000000 | 0x00000020;
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   979  
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   980  		/* RGMII, RMII or MII */
e813bb2b9 drivers/net/ethernet/freescale/fec_main.c Markus Pargmann  2015-04-30   981  		if (fep->phy_interface == PHY_INTERFACE_MODE_RGMII ||
e813bb2b9 drivers/net/ethernet/freescale/fec_main.c Markus Pargmann  2015-04-30   982  		    fep->phy_interface == PHY_INTERFACE_MODE_RGMII_ID ||
e813bb2b9 drivers/net/ethernet/freescale/fec_main.c Markus Pargmann  2015-04-30   983  		    fep->phy_interface == PHY_INTERFACE_MODE_RGMII_RXID ||
e813bb2b9 drivers/net/ethernet/freescale/fec_main.c Markus Pargmann  2015-04-30   984  		    fep->phy_interface == PHY_INTERFACE_MODE_RGMII_TXID)
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   985  			rcntl |= (1 << 6);
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   986  		else if (fep->phy_interface == PHY_INTERFACE_MODE_RMII)
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   987  			rcntl |= (1 << 8);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   988  		else
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   989  			rcntl &= ~(1 << 8);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   990  
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   991  		/* 1G, 100M or 10M */
45f5c327c drivers/net/ethernet/freescale/fec_main.c Philippe Reynes  2016-05-10   992  		if (ndev->phydev) {
45f5c327c drivers/net/ethernet/freescale/fec_main.c Philippe Reynes  2016-05-10   993  			if (ndev->phydev->speed == SPEED_1000)
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   994  				ecntl |= (1 << 5);
45f5c327c drivers/net/ethernet/freescale/fec_main.c Philippe Reynes  2016-05-10   995  			else if (ndev->phydev->speed == SPEED_100)
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   996  				rcntl &= ~(1 << 9);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19   997  			else
cd1f402c1 drivers/net/fec.c                         Uwe Kleine-König 2011-01-25   998  				rcntl |= (1 << 9);
230dec613 drivers/net/ethernet/freescale/fec.c      Shawn Guo        2011-09-23   999  		}
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1000  	} else {
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1001  #ifdef FEC_MIIGSK_ENR
6b7e40083 drivers/net/ethernet/freescale/fec_main.c Lothar Waßmann   2014-11-17  1002  		if (fep->quirks & FEC_QUIRK_USE_GASKET) {
8d82f219c drivers/net/ethernet/freescale/fec.c      Eric Benard      2012-01-12  1003  			u32 cfgr;
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1004  			/* disable the gasket and wait */
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1005  			writel(0, fep->hwp + FEC_MIIGSK_ENR);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1006  			while (readl(fep->hwp + FEC_MIIGSK_ENR) & 4)
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1007  				udelay(1);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1008  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1009  			/*
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1010  			 * configure the gasket:
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1011  			 *   RMII, 50 MHz, no loopback, no echo
0ca1e290b drivers/net/fec.c                         Shawn Guo        2011-07-01  1012  			 *   MII, 25 MHz, no loopback, no echo
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1013  			 */
8d82f219c drivers/net/ethernet/freescale/fec.c      Eric Benard      2012-01-12  1014  			cfgr = (fep->phy_interface == PHY_INTERFACE_MODE_RMII)
8d82f219c drivers/net/ethernet/freescale/fec.c      Eric Benard      2012-01-12  1015  				? BM_MIIGSK_CFGR_RMII : BM_MIIGSK_CFGR_MII;
45f5c327c drivers/net/ethernet/freescale/fec_main.c Philippe Reynes  2016-05-10  1016  			if (ndev->phydev && ndev->phydev->speed == SPEED_10)
8d82f219c drivers/net/ethernet/freescale/fec.c      Eric Benard      2012-01-12  1017  				cfgr |= BM_MIIGSK_CFGR_FRCONT_10M;
8d82f219c drivers/net/ethernet/freescale/fec.c      Eric Benard      2012-01-12  1018  			writel(cfgr, fep->hwp + FEC_MIIGSK_CFGR);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1019  
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1020  			/* re-enable the gasket */
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1021  			writel(2, fep->hwp + FEC_MIIGSK_ENR);
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1022  		}
45993653b drivers/net/fec.c                         Uwe Kleine-König 2011-01-19  1023  #endif
^1da177e4 drivers/net/fec.c                         Linus Torvalds   2005-04-16  1024  	}
baa70a5c4 drivers/net/ethernet/freescale/fec.c      Frank Li         2013-01-16  1025  

:::::: The code at line 959 was first introduced by commit
:::::: 4c09eed9dc422e980fabdb25434ef68e599b704c net: fec: Enable imx6 enet checksum acceleration.

:::::: TO: Jim Baxter <jim_baxter@mentor.com>
:::::: CC: David S. Miller <davem@davemloft.net>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 45215 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH net-next 1/3] net: ethernet: ti: Allow most drivers with COMPILE_TEST
  2018-05-15 23:48 ` [PATCH net-next 1/3] net: ethernet: ti: Allow most " Florian Fainelli
  2018-05-17  3:02   ` kbuild test robot
@ 2018-05-17  4:25   ` kbuild test robot
  1 sibling, 0 replies; 12+ messages in thread
From: kbuild test robot @ 2018-05-17  4:25 UTC (permalink / raw)
  To: Florian Fainelli
  Cc: kbuild-all, netdev, Florian Fainelli, David S. Miller,
	Andrew Lunn, open list

[-- Attachment #1: Type: text/plain, Size: 10802 bytes --]

Hi Florian,

I love your patch! Perhaps something to improve:

[auto build test WARNING on net-next/master]

url:    https://github.com/0day-ci/linux/commits/Florian-Fainelli/net-Allow-more-drivers-with-COMPILE_TEST/20180517-092807
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 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
        # save the attached .config to linux build tree
        make.cross ARCH=xtensa 

All warnings (new ones prefixed by >>):

   drivers/net//ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit':
>> drivers/net//ethernet/ti/davinci_cpdma.c:1083:17: warning: passing argument 1 of 'writel_relaxed' makes integer from pointer without a cast [-Wint-conversion]
     writel_relaxed(token, &desc->sw_token);
                    ^~~~~
   In file included from arch/xtensa/include/asm/io.h:83:0,
                    from include/linux/scatterlist.h:9,
                    from include/linux/dma-mapping.h:11,
                    from drivers/net//ethernet/ti/davinci_cpdma.c:21:
   include/asm-generic/io.h:303:24: note: expected 'u32 {aka unsigned int}' but argument is of type 'void *'
    #define writel_relaxed writel_relaxed
                           ^
>> include/asm-generic/io.h:304:20: note: in expansion of macro 'writel_relaxed'
    static inline void writel_relaxed(u32 value, volatile void __iomem *addr)
                       ^~~~~~~~~~~~~~
--
   drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit':
   drivers/net/ethernet/ti/davinci_cpdma.c:1083:17: warning: passing argument 1 of 'writel_relaxed' makes integer from pointer without a cast [-Wint-conversion]
     writel_relaxed(token, &desc->sw_token);
                    ^~~~~
   In file included from arch/xtensa/include/asm/io.h:83:0,
                    from include/linux/scatterlist.h:9,
                    from include/linux/dma-mapping.h:11,
                    from drivers/net/ethernet/ti/davinci_cpdma.c:21:
   include/asm-generic/io.h:303:24: note: expected 'u32 {aka unsigned int}' but argument is of type 'void *'
    #define writel_relaxed writel_relaxed
                           ^
>> include/asm-generic/io.h:304:20: note: in expansion of macro 'writel_relaxed'
    static inline void writel_relaxed(u32 value, volatile void __iomem *addr)
                       ^~~~~~~~~~~~~~

vim +/writel_relaxed +1083 drivers/net//ethernet/ti/davinci_cpdma.c

ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1029  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1030  int cpdma_chan_submit(struct cpdma_chan *chan, void *token, void *data,
aef614e1 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-04-23  1031  		      int len, int directed)
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1032  {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1033  	struct cpdma_ctlr		*ctlr = chan->ctlr;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1034  	struct cpdma_desc __iomem	*desc;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1035  	dma_addr_t			buffer;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1036  	unsigned long			flags;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1037  	u32				mode;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1038  	int				ret = 0;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1039  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1040  	spin_lock_irqsave(&chan->lock, flags);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1041  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1042  	if (chan->state == CPDMA_STATE_TEARDOWN) {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1043  		ret = -EINVAL;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1044  		goto unlock_ret;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1045  	}
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1046  
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1047  	if (chan->count >= chan->desc_num)	{
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1048  		chan->stats.desc_alloc_fail++;
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1049  		ret = -ENOMEM;
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1050  		goto unlock_ret;
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1051  	}
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1052  
742fb20f drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2016-06-27  1053  	desc = cpdma_desc_alloc(ctlr->pool);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1054  	if (!desc) {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1055  		chan->stats.desc_alloc_fail++;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1056  		ret = -ENOMEM;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1057  		goto unlock_ret;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1058  	}
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1059  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1060  	if (len < ctlr->params.min_packet_size) {
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1061  		len = ctlr->params.min_packet_size;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1062  		chan->stats.runt_transmit_buff++;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1063  	}
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1064  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1065  	buffer = dma_map_single(ctlr->dev, data, len, chan->dir);
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1066  	ret = dma_mapping_error(ctlr->dev, buffer);
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1067  	if (ret) {
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1068  		cpdma_desc_free(ctlr->pool, desc, 1);
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1069  		ret = -EINVAL;
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1070  		goto unlock_ret;
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1071  	}
14bd0769 drivers/net/ethernet/ti/davinci_cpdma.c Sebastian Siewior 2013-06-20  1072  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1073  	mode = CPDMA_DESC_OWNER | CPDMA_DESC_SOP | CPDMA_DESC_EOP;
f6e135c8 drivers/net/ethernet/ti/davinci_cpdma.c Mugunthan V N     2013-02-11  1074  	cpdma_desc_to_port(chan, mode, directed);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1075  
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1076  	/* Relaxed IO accessors can be used here as there is read barrier
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1077  	 * at the end of write sequence.
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1078  	 */
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1079  	writel_relaxed(0, &desc->hw_next);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1080  	writel_relaxed(buffer, &desc->hw_buffer);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1081  	writel_relaxed(len, &desc->hw_len);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1082  	writel_relaxed(mode | len, &desc->hw_mode);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06 @1083  	writel_relaxed(token, &desc->sw_token);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1084  	writel_relaxed(buffer, &desc->sw_buffer);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1085  	writel_relaxed(len, &desc->sw_len);
a6c83ccf drivers/net/ethernet/ti/davinci_cpdma.c Grygorii Strashko 2017-01-06  1086  	desc_read(desc, sw_len);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1087  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1088  	__cpdma_chan_submit(chan, desc);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1089  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1090  	if (chan->state == CPDMA_STATE_ACTIVE && chan->rxfree)
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1091  		chan_write(chan, rxfree, 1);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1092  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1093  	chan->count++;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1094  
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1095  unlock_ret:
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1096  	spin_unlock_irqrestore(&chan->lock, flags);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1097  	return ret;
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1098  }
32a6d90b drivers/net/ethernet/ti/davinci_cpdma.c Arnd Bergmann     2012-04-20  1099  EXPORT_SYMBOL_GPL(cpdma_chan_submit);
ef8c2dab drivers/net/davinci_cpdma.c             Cyril Chemparathy 2010-09-15  1100  

:::::: The code at line 1083 was first introduced by commit
:::::: a6c83ccf3c534214e0aeb167a70391864da9b1fc net: ethernet: ti: cpdma: am437x: allow descs to be plased in ddr

:::::: TO: Grygorii Strashko <grygorii.strashko@ti.com>
:::::: CC: David S. Miller <davem@davemloft.net>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 53063 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-05-17  4:26 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-15 23:48 [PATCH net-next 0/3] net: Allow more drivers with COMPILE_TEST Florian Fainelli
2018-05-15 23:48 ` [PATCH net-next 1/3] net: ethernet: ti: Allow most " Florian Fainelli
2018-05-17  3:02   ` kbuild test robot
2018-05-17  4:25   ` kbuild test robot
2018-05-15 23:48 ` [PATCH net-next 2/3] net: ethernet: freescale: Allow FEC " Florian Fainelli
2018-05-16  1:19   ` Andy Duan
2018-05-17  3:38   ` kbuild test robot
2018-05-17  4:03   ` kbuild test robot
2018-05-15 23:48 ` [PATCH net-next 3/3] net: phy: Allow MDIO_MOXART and MDIO_SUN4I " Florian Fainelli
2018-05-16 18:15 ` [PATCH net-next 0/3] net: Allow more drivers " David Miller
2018-05-16 18:17   ` David Miller
2018-05-16 18:18     ` Florian Fainelli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).