From: kernel test robot <lkp@intel.com>
To: yunaixin03610@163.com, netdev@vger.kernel.org,
davem@davemloft.net, linux-kernel@vger.kernel.org,
wuguanping@huawei.com, wangqindong@huawei.com
Cc: kbuild-all@lists.01.org, yunaixin <yunaixin03610@163.com>
Subject: Re: [PATCH 3/5] Huawei BMA: Adding Huawei BMA driver: host_veth_drv
Date: Tue, 23 Jun 2020 04:27:38 +0800 [thread overview]
Message-ID: <202006230440.BMxU0vEO%lkp@intel.com> (raw)
In-Reply-To: <20200622160311.1533-4-yunaixin03610@163.com>
[-- Attachment #1: Type: text/plain, Size: 11242 bytes --]
Hi,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on sparc-next/master]
[also build test WARNING on linux/master linus/master v5.8-rc2 next-20200622]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/yunaixin03610-163-com/Adding-Huawei-BMA-drivers/20200623-014140
base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-next.git master
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
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
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=sh
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>, old ones prefixed by <<):
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:394:5: warning: no previous prototype for 'bspveth_setup_tx_resources' [-Wmissing-prototypes]
394 | s32 bspveth_setup_tx_resources(struct bspveth_device *pvethdev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from arch/sh/include/asm/thread_info.h:15,
from include/linux/thread_info.h:38,
from include/asm-generic/preempt.h:5,
from ./arch/sh/include/generated/asm/preempt.h:1,
from include/linux/preempt.h:78,
from include/linux/spinlock.h:51,
from include/linux/seqlock.h:36,
from include/linux/time.h:6,
from include/linux/stat.h:19,
from include/linux/module.h:13,
from drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:18:
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: In function 'bspveth_setup_tx_resources':
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:427:37: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
427 | ptx_queue->pbdbase_p = (u8 *)(__pa((BSP_VETH_T)(ptx_queue->pbdbase_v)));
| ^
arch/sh/include/asm/page.h:138:20: note: in definition of macro '___pa'
138 | #define ___pa(x) ((x)-PAGE_OFFSET)
| ^
>> drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:427:32: note: in expansion of macro '__pa'
427 | ptx_queue->pbdbase_p = (u8 *)(__pa((BSP_VETH_T)(ptx_queue->pbdbase_v)));
| ^~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: At top level:
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:443:6: warning: no previous prototype for 'bspveth_free_tx_resources' [-Wmissing-prototypes]
443 | void bspveth_free_tx_resources(struct bspveth_device *pvethdev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:485:5: warning: no previous prototype for 'bspveth_setup_all_tx_resources' [-Wmissing-prototypes]
485 | s32 bspveth_setup_all_tx_resources(struct bspveth_device *pvethdev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: In function 'bspveth_setup_all_tx_resources':
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:514:33: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
514 | (struct bspveth_dma_shmbd *)((BSP_VETH_T)(shmq_head)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:514:4: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
514 | (struct bspveth_dma_shmbd *)((BSP_VETH_T)(shmq_head)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:517:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
517 | (u8 *)((BSP_VETH_T)(shmq_head_p)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:517:4: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
517 | (u8 *)((BSP_VETH_T)(shmq_head_p)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:520:28: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
520 | (struct bspveth_dmal *)((BSP_VETH_T)(shmq_head)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:520:4: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
520 | (struct bspveth_dmal *)((BSP_VETH_T)(shmq_head)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:523:4: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
523 | (u8 *)(u64)(VETH_SHAREPOOL_BASE_INBMC +
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: At top level:
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:554:6: warning: no previous prototype for 'bspveth_free_all_tx_resources' [-Wmissing-prototypes]
554 | void bspveth_free_all_tx_resources(struct bspveth_device *pvethdev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:571:5: warning: no previous prototype for 'veth_alloc_one_rx_skb' [-Wmissing-prototypes]
571 | s32 veth_alloc_one_rx_skb(struct bspveth_rxtx_q *prx_queue, int idx)
| ^~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:616:5: warning: no previous prototype for 'veth_refill_rxskb' [-Wmissing-prototypes]
616 | s32 veth_refill_rxskb(struct bspveth_rxtx_q *prx_queue, int queue)
| ^~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:654:5: warning: no previous prototype for 'bspveth_setup_rx_skb' [-Wmissing-prototypes]
654 | s32 bspveth_setup_rx_skb(struct bspveth_device *pvethdev,
| ^~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:685:6: warning: no previous prototype for 'bspveth_free_rx_skb' [-Wmissing-prototypes]
685 | void bspveth_free_rx_skb(struct bspveth_device *pvethdev,
| ^~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:718:5: warning: no previous prototype for 'bspveth_setup_all_rx_skb' [-Wmissing-prototypes]
718 | s32 bspveth_setup_all_rx_skb(struct bspveth_device *pvethdev)
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:746:6: warning: no previous prototype for 'bspveth_free_all_rx_skb' [-Wmissing-prototypes]
746 | void bspveth_free_all_rx_skb(struct bspveth_device *pvethdev)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:758:5: warning: no previous prototype for 'bspveth_setup_rx_resources' [-Wmissing-prototypes]
758 | s32 bspveth_setup_rx_resources(struct bspveth_device *pvethdev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from arch/sh/include/asm/thread_info.h:15,
from include/linux/thread_info.h:38,
from include/asm-generic/preempt.h:5,
from ./arch/sh/include/generated/asm/preempt.h:1,
from include/linux/preempt.h:78,
from include/linux/spinlock.h:51,
from include/linux/seqlock.h:36,
from include/linux/time.h:6,
from include/linux/stat.h:19,
from include/linux/module.h:13,
from drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:18:
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: In function 'bspveth_setup_rx_resources':
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:792:36: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
792 | prx_queue->pbdbase_p = (u8 *)__pa((BSP_VETH_T) (prx_queue->pbdbase_v));
| ^
arch/sh/include/asm/page.h:138:20: note: in definition of macro '___pa'
138 | #define ___pa(x) ((x)-PAGE_OFFSET)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:792:31: note: in expansion of macro '__pa'
792 | prx_queue->pbdbase_p = (u8 *)__pa((BSP_VETH_T) (prx_queue->pbdbase_v));
| ^~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: At top level:
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:809:6: warning: no previous prototype for 'bspveth_free_rx_resources' [-Wmissing-prototypes]
809 | void bspveth_free_rx_resources(struct bspveth_device *pvethdev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:841:5: warning: no previous prototype for 'bspveth_setup_all_rx_resources' [-Wmissing-prototypes]
841 | s32 bspveth_setup_all_rx_resources(struct bspveth_device *pvethdev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c: In function 'bspveth_setup_all_rx_resources':
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:871:33: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
871 | (struct bspveth_dma_shmbd *)((BSP_VETH_T)(shmq_head)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:871:4: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
871 | (struct bspveth_dma_shmbd *)((BSP_VETH_T)(shmq_head)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:874:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
874 | (u8 *)((BSP_VETH_T)(shmq_head_p)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:874:4: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
874 | (u8 *)((BSP_VETH_T)(shmq_head_p)
| ^
drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c:877:28: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
877 | (struct bspveth_dmal *)((BSP_VETH_T)(shmq_head)
| ^
vim +/__pa +427 drivers/net/ethernet/huawei/bma/veth_drv/veth_hb.c
393
394 s32 bspveth_setup_tx_resources(struct bspveth_device *pvethdev,
395 struct bspveth_rxtx_q *ptx_queue)
396 {
397 unsigned int size;
398
399 if (!pvethdev || !ptx_queue)
400 return BSP_ERR_NULL_POINTER;
401
402 ptx_queue->count = MAX_QUEUE_BDNUM;
403
404 size = sizeof(struct bspveth_bd_info) * ptx_queue->count;
405 ptx_queue->pbdinfobase_v = vmalloc(size);
406 if (!ptx_queue->pbdinfobase_v)
407 goto alloc_failed;
408
409 memset(ptx_queue->pbdinfobase_v, 0, size);
410
411 /* round up to nearest 4K */
412 ptx_queue->size = ptx_queue->count * sizeof(struct bspveth_bd_info);
413 ptx_queue->size = ALIGN(ptx_queue->size, 4096);
414
415 /* prepare 4096 send buffer */
416 ptx_queue->pbdbase_v = kmalloc(ptx_queue->size, GFP_KERNEL);
417 if (!ptx_queue->pbdbase_v) {
418 VETH_LOG(DLOG_ERROR,
419 "Unable to kmalloc for the receive descriptor ring\n");
420
421 vfree(ptx_queue->pbdinfobase_v);
422 ptx_queue->pbdinfobase_v = NULL;
423
424 goto alloc_failed;
425 }
426
> 427 ptx_queue->pbdbase_p = (u8 *)(__pa((BSP_VETH_T)(ptx_queue->pbdbase_v)));
428
429 ptx_queue->next_to_fill = 0;
430 ptx_queue->next_to_free = 0;
431 ptx_queue->head = 0;
432 ptx_queue->tail = 0;
433 ptx_queue->work_limit = BSPVETH_WORK_LIMIT;
434
435 memset(&ptx_queue->s, 0, sizeof(struct bspveth_rxtx_statis));
436
437 return 0;
438
439 alloc_failed:
440 return -ENOMEM;
441 }
442
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 55650 bytes --]
next prev parent reply other threads:[~2020-06-22 21:01 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-22 16:03 [PATCH 0/5] Adding Huawei BMA drivers yunaixin03610
2020-06-22 16:03 ` [PATCH 1/5] Huawei BMA: Adding Huawei BMA driver: host_edma_drv yunaixin03610
2020-06-22 16:39 ` Randy Dunlap
2020-06-25 1:54 ` kernel test robot
2020-06-22 16:03 ` [PATCH 2/5] Huawei BMA: Adding Huawei BMA driver: host_cdev_drv yunaixin03610
2020-06-22 16:40 ` Randy Dunlap
2020-06-22 16:03 ` [PATCH 3/5] Huawei BMA: Adding Huawei BMA driver: host_veth_drv yunaixin03610
2020-06-22 16:41 ` Randy Dunlap
2020-06-22 18:38 ` Andrew Lunn
2020-06-22 20:27 ` kernel test robot [this message]
2020-06-22 16:03 ` [PATCH 4/5] Huawei BMA: Adding Huawei BMA driver: cdev_veth_drv yunaixin03610
2020-06-22 16:43 ` Randy Dunlap
2020-06-22 18:22 ` Andrew Lunn
2020-06-22 16:03 ` [PATCH 5/5] Huawei BMA: Adding Huawei BMA driver: host_kbox_drv yunaixin03610
2020-06-22 18:21 ` Andrew Lunn
2020-06-22 18:18 ` [PATCH 0/5] Adding Huawei BMA drivers Andrew Lunn
2020-06-22 19:38 ` Jakub Kicinski
-- strict thread matches above, loose matches on Subject: below --
2020-06-15 14:56 yunaixin03610
2020-06-15 14:56 ` [PATCH 3/5] Huawei BMA: Adding Huawei BMA driver: host_veth_drv yunaixin03610
2020-06-15 15:50 ` Randy Dunlap
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202006230440.BMxU0vEO%lkp@intel.com \
--to=lkp@intel.com \
--cc=davem@davemloft.net \
--cc=kbuild-all@lists.01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=wangqindong@huawei.com \
--cc=wuguanping@huawei.com \
--cc=yunaixin03610@163.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox