[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <201701061620.RIIzj1Xp%fengguang.wu@intel.com>
Date: Fri, 6 Jan 2017 16:32:56 +0800
From: kbuild test robot <lkp@...el.com>
To: Joao Pinto <Joao.Pinto@...opsys.com>
Cc: kbuild-all@...org, davem@...emloft.net, lars.persson@...s.com,
niklass@...s.com, swarren@...dia.com, treding@...dia.com,
netdev@...r.kernel.org, Joao Pinto <Joao.Pinto@...opsys.com>
Subject: Re: [PATCH v4 3/3] stmmac: adding new glue driver dwmac-dwc-qos-eth
Hi Joao,
[auto build test ERROR on net-next/master]
[also build test ERROR on next-20170105]
[cannot apply to v4.10-rc2]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Joao-Pinto/adding-new-glue-driver-dwmac-dwc-qos-eth/20170106-154152
config: i386-allmodconfig (attached as .config)
compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All errors (new ones prefixed by >>):
In file included from arch/x86/include/asm/string.h:2:0,
from include/linux/string.h:18,
from arch/x86/include/asm/page_32.h:34,
from arch/x86/include/asm/page.h:13,
from arch/x86/include/asm/processor.h:17,
from include/linux/mutex.h:19,
from include/linux/notifier.h:13,
from include/linux/clk.h:17,
from drivers/net/ethernet/stmicro/stmmac/dwmac-dwc-qos-eth.c:14:
drivers/net/ethernet/stmicro/stmmac/dwmac-dwc-qos-eth.c: In function 'dwc_eth_dwmac_probe':
>> drivers/net/ethernet/stmicro/stmmac/dwmac-dwc-qos-eth.c:116:9: error: incompatible type for argument 1 of '__builtin_memset'
memset(stmmac_res, 0, sizeof(struct stmmac_resources));
^
arch/x86/include/asm/string_32.h:325:46: note: in definition of macro 'memset'
#define memset(s, c, count) __builtin_memset(s, c, count)
^
drivers/net/ethernet/stmicro/stmmac/dwmac-dwc-qos-eth.c:116:9: note: expected 'void *' but argument is of type 'struct stmmac_resources'
memset(stmmac_res, 0, sizeof(struct stmmac_resources));
^
arch/x86/include/asm/string_32.h:325:46: note: in definition of macro 'memset'
#define memset(s, c, count) __builtin_memset(s, c, count)
^
vim +/__builtin_memset +116 drivers/net/ethernet/stmicro/stmmac/dwmac-dwc-qos-eth.c
8 * published by the Free Software Foundation.
9 *
10 * You should have received a copy of the GNU General Public License
11 * along with this program. If not, see <http://www.gnu.org/licenses/>.
12 */
13
> 14 #include <linux/clk.h>
15 #include <linux/clk-provider.h>
16 #include <linux/device.h>
17 #include <linux/ethtool.h>
18 #include <linux/io.h>
19 #include <linux/ioport.h>
20 #include <linux/module.h>
21 #include <linux/of_net.h>
22 #include <linux/mfd/syscon.h>
23 #include <linux/platform_device.h>
24 #include <linux/stmmac.h>
25
26 #include "stmmac_platform.h"
27
28 static int dwc_eth_dwmac_config_dt(struct platform_device *pdev,
29 struct plat_stmmacenet_data *plat_dat)
30 {
31 struct device_node *np = pdev->dev.of_node;
32 u32 burst_map = 0;
33 u32 bit_index = 0;
34 u32 a_index = 0;
35
36 if (!plat_dat->axi) {
37 plat_dat->axi = kzalloc(sizeof(struct stmmac_axi), GFP_KERNEL);
38
39 if (!plat_dat->axi)
40 return -ENOMEM;
41 }
42
43 plat_dat->axi->axi_lpi_en = of_property_read_bool(np, "snps,en-lpi");
44 if (of_property_read_u32(np, "snps,write-requests",
45 &plat_dat->axi->axi_wr_osr_lmt)) {
46 /**
47 * Since the register has a reset value of 1, if property
48 * is missing, default to 1.
49 */
50 plat_dat->axi->axi_wr_osr_lmt = 1;
51 } else {
52 /**
53 * If property exists, to keep the behavior from dwc_eth_qos,
54 * subtract one after parsing.
55 */
56 plat_dat->axi->axi_wr_osr_lmt--;
57 }
58
59 if (of_property_read_u32(np, "read,read-requests",
60 &plat_dat->axi->axi_rd_osr_lmt)) {
61 /**
62 * Since the register has a reset value of 1, if property
63 * is missing, default to 1.
64 */
65 plat_dat->axi->axi_rd_osr_lmt = 1;
66 } else {
67 /**
68 * If property exists, to keep the behavior from dwc_eth_qos,
69 * subtract one after parsing.
70 */
71 plat_dat->axi->axi_rd_osr_lmt--;
72 }
73 of_property_read_u32(np, "snps,burst-map", &burst_map);
74
75 /* converts burst-map bitmask to burst array */
76 for (bit_index = 0; bit_index < 7; bit_index++) {
77 if (burst_map & (1 << bit_index)) {
78 switch (bit_index) {
79 case 0:
80 plat_dat->axi->axi_blen[a_index] = 4; break;
81 case 1:
82 plat_dat->axi->axi_blen[a_index] = 8; break;
83 case 2:
84 plat_dat->axi->axi_blen[a_index] = 16; break;
85 case 3:
86 plat_dat->axi->axi_blen[a_index] = 32; break;
87 case 4:
88 plat_dat->axi->axi_blen[a_index] = 64; break;
89 case 5:
90 plat_dat->axi->axi_blen[a_index] = 128; break;
91 case 6:
92 plat_dat->axi->axi_blen[a_index] = 256; break;
93 default:
94 break;
95 }
96 a_index++;
97 }
98 }
99
100 /* dwc-qos needs GMAC4, AAL, TSO and PMT */
101 plat_dat->has_gmac4 = 1;
102 plat_dat->dma_cfg->aal = 1;
103 plat_dat->tso_en = 1;
104 plat_dat->pmt = 1;
105
106 return 0;
107 }
108
109 static int dwc_eth_dwmac_probe(struct platform_device *pdev)
110 {
111 struct plat_stmmacenet_data *plat_dat;
112 struct stmmac_resources stmmac_res;
113 struct resource *res;
114 int ret;
115
> 116 memset(stmmac_res, 0, sizeof(struct stmmac_resources));
117
118 /**
119 * Since stmmac_platform supports name IRQ only, basic platform
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Download attachment ".config.gz" of type "application/gzip" (57940 bytes)
Powered by blists - more mailing lists