[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <201805171259.V5ot5f21%fengguang.wu@intel.com>
Date: Thu, 17 May 2018 12:25:25 +0800
From: kbuild test robot <lkp@...el.com>
To: Florian Fainelli <f.fainelli@...il.com>
Cc: kbuild-all@...org, netdev@...r.kernel.org,
Florian Fainelli <f.fainelli@...il.com>,
"David S. Miller" <davem@...emloft.net>,
Andrew Lunn <andrew@...n.ch>,
open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net-next 1/3] net: ethernet: ti: Allow most drivers with
COMPILE_TEST
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@...com>
:::::: CC: David S. Miller <davem@...emloft.net>
---
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" (53063 bytes)
Powered by blists - more mailing lists