* [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE
@ 2020-07-06 6:41 kernel test robot
2020-07-06 6:41 ` [PATCH] mt6625l: fix boolconv.cocci warnings kernel test robot
` (8 more replies)
0 siblings, 9 replies; 11+ messages in thread
From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw)
To: kbuild-all
[-- Attachment #1: Type: text/plain, Size: 3430 bytes --]
tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi
head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9
commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder
config: arm-randconfig-c024-20200706 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
coccinelle warnings: (new ones prefixed by >>)
>> drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE
drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:117:37-38: WARNING: Use ARRAY_SIZE
--
>> drivers/misc/mediatek/connectivity/common/conn_soc/core/stp_core.c:2976:41-42: WARNING: Use ARRAY_SIZE
drivers/misc/mediatek/connectivity/common/conn_soc/core/stp_core.c:3035:41-42: WARNING: Use ARRAY_SIZE
--
>> drivers/misc/mediatek/connectivity/common/conn_soc/core/wmt_ic_soc.c:1877:73-74: WARNING: Use ARRAY_SIZE
drivers/misc/mediatek/connectivity/common/conn_soc/core/wmt_ic_soc.c:1837:58-59: WARNING: Use ARRAY_SIZE
--
>> drivers/misc/mediatek/btif/common/mtk_btif_exp.c:592:64-69: WARNING: conversion to bool not needed here
drivers/misc/mediatek/btif/common/mtk_btif_exp.c:406:64-69: WARNING: conversion to bool not needed here
--
>> drivers/misc/mediatek/connectivity/common/conn_soc/core/mtk_wcn_stub_alps.c:383:2-4: WARNING: possible condition with no effect (if == else)
--
>> drivers/misc/mediatek/connectivity/common/conn_soc/linux/pri/stp_dbg.c:2001:5-11: ERROR: allocation function on line 1998 returns NULL not ERR_PTR on failure
--
>> drivers/misc/mediatek/connectivity/common/common_detect/wmt_detect.c:269:3-8: No need to set .owner here. The core will do it.
--
>> drivers/misc/mediatek/connectivity/common/common_detect/drv_init/bluetooth_drv_init.c:25:5-10: Unneeded variable: "i_ret". Return "- 1" on line 35
--
>> drivers/misc/mediatek/btif/common/btif_dma_plat.c:393:5-10: Unneeded variable: "i_ret". Return "0" on line 468
drivers/misc/mediatek/btif/common/btif_dma_plat.c:587:14-19: Unneeded variable: "i_ret". Return "- 1" on line 599
drivers/misc/mediatek/btif/common/btif_dma_plat.c:1375:14-19: Unneeded variable: "i_ret". Return "- 1" on line 1377
--
>> drivers/misc/mediatek/btif/common/btif_plat.c:194:5-10: Unneeded variable: "i_ret". Return "0" on line 198
drivers/misc/mediatek/btif/common/btif_plat.c:633:5-10: Unneeded variable: "i_ret". Return "- 1" on line 646
drivers/misc/mediatek/btif/common/btif_plat.c:1141:5-10: Unneeded variable: "i_ret". Return "- 1" on line 1155
--
>> drivers/misc/mediatek/btif/common/mtk_btif.c:958:5-10: Unneeded variable: "i_ret". Return "0" on line 967
drivers/misc/mediatek/btif/common/mtk_btif.c:2082:5-10: Unneeded variable: "i_ret". Return "0" on line 2085
drivers/misc/mediatek/btif/common/mtk_btif.c:2430:5-10: Unneeded variable: "i_ret". Return "0" on line 2444
--
>> drivers/misc/mediatek/connectivity/common/conn_soc/linux/pub/osal.c:470:7-10: Unneeded variable: "ret". Return "0" on line 473
--
>> drivers/misc/mediatek/connectivity/common/common_detect/wmt_gpio.c:352:7-11: Unneeded variable: "iret". Return "0" on line 370
Please review and possibly fold the followup patch.
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 28208 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread* [PATCH] mt6625l: fix boolconv.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix eno.cocci warnings kernel test robot ` (7 subsequent siblings) 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1602 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/btif/common/mtk_btif_exp.c:592:64-69: WARNING: conversion to bool not needed here drivers/misc/mediatek/btif/common/mtk_btif_exp.c:406:64-69: WARNING: conversion to bool not needed here Remove unneeded conversion to bool Semantic patch information: Relational and logical operators evaluate to bool, explicit conversion is overly verbose and unneeded. Generated by: scripts/coccinelle/misc/boolconv.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! mtk_btif_exp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/misc/mediatek/btif/common/mtk_btif_exp.c +++ b/drivers/misc/mediatek/btif/common/mtk_btif_exp.c @@ -403,7 +403,7 @@ int mtk_wcn_btif_loopback_ctrl(unsigned if (p_btif == NULL) return E_BTIF_INVAL_PARAM; i_ret = - btif_lpbk_ctrl(p_btif, enable == BTIF_LPBK_ENABLE ? true : false); + btif_lpbk_ctrl(p_btif, enable == BTIF_LPBK_ENABLE); return i_ret; } @@ -589,7 +589,7 @@ int btif_loopback_ctrl_no_id(ENUM_BTIF_L p_mtk_btif p_btif = &g_btif[0]; i_ret = - btif_lpbk_ctrl(p_btif, enable == BTIF_LPBK_ENABLE ? true : false); + btif_lpbk_ctrl(p_btif, enable == BTIF_LPBK_ENABLE); return i_ret; } ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix eno.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix boolconv.cocci warnings kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings kernel test robot ` (6 subsequent siblings) 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1127 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/connectivity/common/conn_soc/linux/pri/stp_dbg.c:2001:5-11: ERROR: allocation function on line 1998 returns NULL not ERR_PTR on failure The various basic memory allocation functions don't return ERR_PTR Generated by: scripts/coccinelle/null/eno.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder stp_dbg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/misc/mediatek/connectivity/common/conn_soc/linux/pri/stp_dbg.c +++ b/drivers/misc/mediatek/connectivity/common/conn_soc/linux/pri/stp_dbg.c @@ -1998,7 +1998,7 @@ MTKSTP_DBG_T *stp_dbg_init(void *btm_hal stp_dbg = kzalloc(sizeof(MTKSTP_DBG_T), GFP_KERNEL); if (stp_dbg == NULL) goto ERR_EXIT1; - if (IS_ERR(stp_dbg)) { + if (!stp_dbg) { STP_DBG_ERR_FUNC("-ENOMEM\n"); goto ERR_EXIT1; } ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix boolconv.cocci warnings kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix eno.cocci warnings kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix returnvar.cocci warnings kernel test robot ` (5 subsequent siblings) 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1078 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/connectivity/common/common_detect/wmt_detect.c:269:3-8: No need to set .owner here. The core will do it. Remove .owner field if calls are used which set it automatically Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder wmt_detect.c | 1 - 1 file changed, 1 deletion(-) --- a/drivers/misc/mediatek/connectivity/common/common_detect/wmt_detect.c +++ b/drivers/misc/mediatek/connectivity/common/common_detect/wmt_detect.c @@ -266,7 +266,6 @@ static struct platform_driver wmt_detect .probe = wmt_detect_probe, .remove = wmt_detect_remove, .driver = { - .owner = THIS_MODULE, .name = "mediatek,connectivity-combo", .of_match_table = wmt_detect_match, }, ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix returnvar.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot ` (2 preceding siblings ...) 2020-07-06 6:41 ` [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot ` (4 subsequent siblings) 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1355 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/connectivity/common/common_detect/drv_init/bluetooth_drv_init.c:25:5-10: Unneeded variable: "i_ret". Return "- 1" on line 35 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! bluetooth_drv_init.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/drivers/misc/mediatek/connectivity/common/common_detect/drv_init/bluetooth_drv_init.c +++ b/drivers/misc/mediatek/connectivity/common/common_detect/drv_init/bluetooth_drv_init.c @@ -22,7 +22,6 @@ int do_bluetooth_drv_init(int chip_id) { - int i_ret = -1; #if 0 #if defined(CONFIG_MTK_COMBO_BT) || defined(CONFIG_MTK_COMBO_BT_HCI) WMT_DETECT_INFO_FUNC("start to do bluetooth driver init\n"); @@ -32,5 +31,5 @@ int do_bluetooth_drv_init(int chip_id) WMT_DETECT_INFO_FUNC("CONFIG_MTK_COMBO_BT is not defined\n"); #endif #endif - return i_ret; + return -1; } ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix returnvar.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot ` (3 preceding siblings ...) 2020-07-06 6:41 ` [PATCH] mt6625l: fix returnvar.cocci warnings kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot ` (3 subsequent siblings) 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 2456 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/btif/common/btif_dma_plat.c:393:5-10: Unneeded variable: "i_ret". Return "0" on line 468 drivers/misc/mediatek/btif/common/btif_dma_plat.c:587:14-19: Unneeded variable: "i_ret". Return "- 1" on line 599 drivers/misc/mediatek/btif/common/btif_dma_plat.c:1375:14-19: Unneeded variable: "i_ret". Return "- 1" on line 1377 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! btif_dma_plat.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) --- a/drivers/misc/mediatek/btif/common/btif_dma_plat.c +++ b/drivers/misc/mediatek/btif/common/btif_dma_plat.c @@ -390,7 +390,6 @@ int hal_btif_dma_clk_ctrl(P_MTK_DMA_INFO int hal_btif_dma_hw_init(P_MTK_DMA_INFO_STR p_dma_info) { - int i_ret = 0; unsigned int dat = 0; unsigned long base = p_dma_info->base; unsigned long addr_h = 0; @@ -465,7 +464,7 @@ int hal_btif_dma_hw_init(P_MTK_DMA_INFO_ hal_btif_dma_ier_ctrl(p_dma_info, false); } - return i_ret; + return 0; } /***************************************************************************** @@ -584,7 +583,6 @@ int btif_rx_dma_ctrl(P_MTK_DMA_INFO_STR *****************************************************************************/ int hal_btif_vfifo_reset(P_MTK_DMA_INFO_STR p_dma_info) { - unsigned int i_ret = -1; P_DMA_VFIFO p_vfifo = p_dma_info->p_vfifo; P_MTK_BTIF_DMA_VFIFO p_mtk_dma_vfifo = container_of(p_vfifo, MTK_BTIF_DMA_VFIFO, @@ -596,7 +594,7 @@ int hal_btif_vfifo_reset(P_MTK_DMA_INFO_ p_mtk_dma_vfifo->wpt = 0; p_mtk_dma_vfifo->last_wpt_wrap = 0; BTIF_TRC_FUNC(); - return i_ret; + return -1; } /***************************************************************************** @@ -1372,9 +1370,7 @@ int hal_dma_pm_ops(P_MTK_DMA_INFO_STR p_ int hal_dma_receive_data(P_MTK_DMA_INFO_STR p_dma_info, unsigned char *p_buf, const unsigned int max_len) { - unsigned int i_ret = -1; - - return i_ret; + return -1; } #endif ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix returnvar.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot ` (4 preceding siblings ...) 2020-07-06 6:41 ` kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot ` (2 subsequent siblings) 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 2797 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/btif/common/btif_plat.c:194:5-10: Unneeded variable: "i_ret". Return "0" on line 198 drivers/misc/mediatek/btif/common/btif_plat.c:633:5-10: Unneeded variable: "i_ret". Return "- 1" on line 646 drivers/misc/mediatek/btif/common/btif_plat.c:1141:5-10: Unneeded variable: "i_ret". Return "- 1" on line 1155 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! btif_plat.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) --- a/drivers/misc/mediatek/btif/common/btif_plat.c +++ b/drivers/misc/mediatek/btif/common/btif_plat.c @@ -191,11 +191,9 @@ static int _get_btif_tx_fifo_room(P_MTK_ static int _btif_tx_fifo_reset(P_MTK_BTIF_INFO_STR p_btif_info) { - int i_ret = 0; - if (p_btif_info->p_tx_fifo != NULL) kfifo_reset(p_btif_info->p_tx_fifo); - return i_ret; + return 0; } #endif @@ -630,7 +628,6 @@ int btif_sleep_ctrl(P_MTK_BTIF_INFO_STR static int btif_tx_thr_set(P_MTK_BTIF_INFO_STR p_btif, unsigned int thr_count) { - int i_ret = -1; unsigned long base = p_btif->base; unsigned int value = 0; @@ -643,7 +640,7 @@ static int btif_tx_thr_set(P_MTK_BTIF_IN /*write back to BTIF_TRI_LVL*/ btif_reg_sync_writel(value, BTIF_TRI_LVL(base)); - return i_ret; + return -1; } /***************************************************************************** @@ -1137,8 +1134,6 @@ int hal_btif_raise_wak_sig(P_MTK_BTIF_IN *****************************************************************************/ int hal_btif_dump_reg(P_MTK_BTIF_INFO_STR p_btif, ENUM_BTIF_REG_ID flag) { -/*Chaozhong: To be implement*/ - int i_ret = -1; int idx = 0; /*unsigned long irq_flag = 0;*/ unsigned long base = p_btif->base; @@ -1152,7 +1147,7 @@ int hal_btif_dump_reg(P_MTK_BTIF_INFO_ST /*spin_unlock_irqrestore(&(g_clk_cg_spinlock), irq_flag);*/ BTIF_ERR_FUNC("%s: clock is off, this should never happen!!!\n", __FILE__); - return i_ret; + return -1; } #endif lsr = BTIF_READ32(BTIF_LSR(base)); @@ -1203,7 +1198,7 @@ int hal_btif_dump_reg(P_MTK_BTIF_INFO_ST BTIF_INFO_FUNC("Tx data is %s\n", (lsr & BTIF_LSR_TEMT_BIT) ? "empty" : "not empty"); - return i_ret; + return -1; } /***************************************************************************** ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix returnvar.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot ` (5 preceding siblings ...) 2020-07-06 6:41 ` kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 2213 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/btif/common/mtk_btif.c:958:5-10: Unneeded variable: "i_ret". Return "0" on line 967 drivers/misc/mediatek/btif/common/mtk_btif.c:2082:5-10: Unneeded variable: "i_ret". Return "0" on line 2085 drivers/misc/mediatek/btif/common/mtk_btif.c:2430:5-10: Unneeded variable: "i_ret". Return "0" on line 2444 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! mtk_btif.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) --- a/drivers/misc/mediatek/btif/common/mtk_btif.c +++ b/drivers/misc/mediatek/btif/common/mtk_btif.c @@ -955,7 +955,6 @@ int _btif_irq_reg(P_MTK_BTIF_IRQ_STR p_i int _btif_irq_free(P_MTK_BTIF_IRQ_STR p_irq, void *data) { - int i_ret = 0; unsigned int eint_num = p_irq->irq_id; if ((p_irq->is_irq_sup) && (p_irq->reg_flag)) { @@ -964,7 +963,7 @@ int _btif_irq_free(P_MTK_BTIF_IRQ_STR p_ p_irq->reg_flag = false; } /*do nothing for this operation*/ - return i_ret; + return 0; } int _btif_irq_ctrl(P_MTK_BTIF_IRQ_STR p_irq, bool en) @@ -2079,10 +2078,8 @@ static ENUM_BTIF_STATE _btif_state_get(p static int _btif_state_release(p_mtk_btif p_btif) { - int i_ret = 0; - BTIF_MUTEX_UNLOCK(&(p_btif->state_mtx)); - return i_ret; + return 0; } static int _btif_state_deinit(p_mtk_btif p_btif) @@ -2427,8 +2424,6 @@ btm_init_err: static int _btif_tx_ctx_deinit(p_mtk_btif p_btif) { - int i_ret = 0; - if (p_btif->tx_ctx == BTIF_TX_SINGLE_CTX) { if (p_btif->p_tx_wq) { destroy_workqueue(p_btif->p_tx_wq); @@ -2441,7 +2436,7 @@ static int _btif_tx_ctx_deinit(p_mtk_bti p_btif->p_tx_fifo = NULL; } } - return i_ret; + return 0; } static int _btif_rx_btm_init(p_mtk_btif p_btif) ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix returnvar.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot ` (6 preceding siblings ...) 2020-07-06 6:41 ` kernel test robot @ 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1148 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/connectivity/common/conn_soc/linux/pub/osal.c:470:7-10: Unneeded variable: "ret". Return "0" on line 473 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! osal.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/drivers/misc/mediatek/connectivity/common/conn_soc/linux/pub/osal.c +++ b/drivers/misc/mediatek/connectivity/common/conn_soc/linux/pub/osal.c @@ -467,10 +467,8 @@ INT32 osal_wait_for_event_timeout(P_OSAL INT32 osal_trigger_event(P_OSAL_EVENT pEvent) { - INT32 ret = 0; - wake_up_interruptible(&pEvent->waitQueue); - return ret; + return 0; } INT32 osal_event_deinit(P_OSAL_EVENT pEvent) ^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH] mt6625l: fix returnvar.cocci warnings 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot ` (7 preceding siblings ...) 2020-07-06 6:41 ` kernel test robot @ 2020-07-06 6:41 ` kernel test robot 8 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 6:41 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1123 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/connectivity/common/common_detect/wmt_gpio.c:352:7-11: Unneeded variable: "iret". Return "0" on line 370 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci Fixes: 5a3d075a983c ("mt6625l: include wifi-folder") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 4b8951570a4f2ef564d134f5aa8779fd067af1c9 commit: 5a3d075a983c166a2a4294c272b47698e24c97c6 [5/11] mt6625l: include wifi-folder Please take the patch only if it's a positive warning. Thanks! wmt_gpio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/drivers/misc/mediatek/connectivity/common/common_detect/wmt_gpio.c +++ b/drivers/misc/mediatek/connectivity/common/common_detect/wmt_gpio.c @@ -349,7 +349,6 @@ err: INT32 wmt_gpio_deinit(VOID) { - INT32 iret = 0; UINT32 i; UINT32 j; @@ -367,5 +366,5 @@ INT32 wmt_gpio_deinit(VOID) gpio_ctrl_info.pinctrl_info = NULL; } - return iret; + return 0; } ^ permalink raw reply [flat|nested] 11+ messages in thread
* [frank-w-bpi-r2-4.14:5.8-wifi 9/14] drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:103:6-11: No need to set .owner here. The core will do it.
@ 2020-07-06 9:43 kernel test robot
2020-07-06 9:43 ` [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings kernel test robot
0 siblings, 1 reply; 11+ messages in thread
From: kernel test robot @ 2020-07-06 9:43 UTC (permalink / raw)
To: kbuild-all
[-- Attachment #1: Type: text/plain, Size: 29474 bytes --]
tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi
head: 647f6f36134f2165d37e44dcfb6a77a4671d529c
commit: f63b913be60c8b22005bf3bfd8fcfa16f7957365 [9/14] mt6625l: set MTK_PLATFORM in Makefile if none is set via *config
config: arm-randconfig-c024-20200706 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All error/warnings (new ones prefixed by >>):
cc1: error: drivers/misc/mediatek/include/mt-plat//include: No such file or directory [-Werror=missing-include-dirs]
cc1: error: drivers/misc/mediatek/include/mt-plat//include/mach: No such file or directory [-Werror=missing-include-dirs]
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wmt_probe':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:118:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
118 | WMT_PLAT_ERR_FUNC("Wmt cannot find pinctrl!\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:124:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
124 | WMT_PLAT_ERR_FUNC("Wmt Cannot find pinctrl default!\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:136:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
136 | WMT_PLAT_ERR_FUNC("Pwrap node has not register regmap.\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:143:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
143 | WMT_PLAT_ERR_FUNC("sean debug [CCF]cannot get clk_infra_conn_main clock.\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:151:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
151 | WMT_PLAT_ERR_FUNC("Regulator_get VCN_1V8 fail, ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:156:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
156 | WMT_PLAT_ERR_FUNC("Regulator_get VCN_2V8 fail, ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:161:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
161 | WMT_PLAT_ERR_FUNC("Regulator_get VCN33_BT fail, ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:166:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
166 | WMT_PLAT_ERR_FUNC("Regulator_get VCN33_WIFI fail, ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:172:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
172 | WMT_PLAT_ERR_FUNC("CanNot get consys reset. ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:179:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
179 | WMT_PLAT_ERR_FUNC("CanNot find consys pinctrl. ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: At top level:
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:192:6: error: no previous prototype for 'mtk_wcn_consys_power_on' [-Werror=missing-prototypes]
192 | VOID mtk_wcn_consys_power_on(VOID)
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_power_on':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:197:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
197 | WMT_PLAT_ERR_FUNC("pm_runtime_get_sync() fail(%d)\n", iRet);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:203:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
203 | WMT_PLAT_ERR_FUNC("device_init_wakeup(true) fail.\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: At top level:
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:208:6: error: no previous prototype for 'mtk_wcn_consys_power_off' [-Werror=missing-prototypes]
208 | VOID mtk_wcn_consys_power_off(VOID)
| ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_power_off':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:214:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
214 | WMT_PLAT_ERR_FUNC("pm_runtime_put_sync() fail.\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:220:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
220 | WMT_PLAT_ERR_FUNC("device_init_wakeup(false) fail.\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: At top level:
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:225:7: error: no previous prototype for 'mtk_wcn_consys_hw_reg_ctrl' [-Werror=missing-prototypes]
225 | INT32 mtk_wcn_consys_hw_reg_ctrl(UINT32 on, UINT32 co_clock_type)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_hw_reg_ctrl':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:240:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
240 | WMT_PLAT_ERR_FUNC("enable VCN18 fail\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:264:6: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
264 | WMT_PLAT_ERR_FUNC("enable VCN_2V8 fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:291:4: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
291 | WMT_PLAT_ERR_FUNC("Read CONSYS chipId(0x%08x)", consysHwChipId);
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:296:4: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
296 | WMT_PLAT_ERR_FUNC("Maybe has a consys power on issue,(0x%08x)\n", consysHwChipId);
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:316:6: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
316 | WMT_PLAT_ERR_FUNC("disable VCN_2V8 fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:326:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
326 | WMT_PLAT_ERR_FUNC("disable VCN_1V8 fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: At top level:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:336:7: error: no previous prototype for 'mtk_wcn_consys_hw_gpio_ctrl' [-Werror=missing-prototypes]
336 | INT32 mtk_wcn_consys_hw_gpio_ctrl(UINT32 on)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_hw_bt_paldo_ctrl':
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:465:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
465 | WMT_PLAT_ERR_FUNC("WMT do BT PMIC on fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:475:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
475 | WMT_PLAT_ERR_FUNC("WMT do BT PMIC off fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_hw_wifi_paldo_ctrl':
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:492:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
492 | WMT_PLAT_ERR_FUNC("WMT do WIFI PMIC on fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:504:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
504 | WMT_PLAT_ERR_FUNC("WMT do WIFI PMIC off fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_hw_vcn28_ctrl':
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:522:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
522 | WMT_PLAT_ERR_FUNC("WMT do VCN28 PMIC on fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:529:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
529 | WMT_PLAT_ERR_FUNC("WMT do VCN28 PMIC off fail!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: At top level:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:540:7: error: no previous prototype for 'mtk_wcn_consys_hw_restore' [-Werror=missing-prototypes]
540 | INT32 mtk_wcn_consys_hw_restore(struct device *device)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_hw_restore':
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:583:4: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
583 | WMT_PLAT_ERR_FUNC("EMI mapping fail\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:586:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
586 | WMT_PLAT_ERR_FUNC("consys emi memory address gConEmiPhyBase invalid\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: At top level:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:593:5: error: no previous prototype for 'reserve_memory_consys_fn' [-Werror=missing-prototypes]
593 | int reserve_memory_consys_fn(struct reserved_mem *rmem)
| ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:30:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c: In function 'mtk_wcn_consys_hw_init':
--
cc1: error: drivers/misc/mediatek/include/mt-plat//include: No such file or directory [-Werror=missing-include-dirs]
cc1: error: drivers/misc/mediatek/include/mt-plat//include/mach: No such file or directory [-Werror=missing-include-dirs]
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:38:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_audio_ctrl':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:191:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
191 | WMT_PLAT_ERR_FUNC("invalid state [%d]\n", state);
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: At top level:
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:255:13: error: no previous prototype for 'wmt_plat_bgf_irq_isr' [-Werror=missing-prototypes]
255 | irqreturn_t wmt_plat_bgf_irq_isr(INT32 i, VOID *arg)
| ^~~~~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:296:8: error: no previous prototype for 'wmt_plat_soc_co_clock_flag_get' [-Werror=missing-prototypes]
296 | UINT32 wmt_plat_soc_co_clock_flag_get(VOID)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/include/mtk_wcn_consys_hw.h:12,
from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:38:
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_eirq_ctrl':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:486:6: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
486 | WMT_PLAT_ERR_FUNC("get irq flags from DTS fail!!\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:493:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
493 | WMT_PLAT_ERR_FUNC("[%s] can't find CONSYS compatible node\n", __func__);
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:502:5: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
502 | WMT_PLAT_ERR_FUNC("request_irq fail,irq_no(%d),iret(%d)\n", bgf_irq_num, iret);
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_gps_lna_ctrl':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:683:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
683 | WMT_PLAT_ERR_FUNC("get consys pinctrl fail\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:689:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
689 | WMT_PLAT_ERR_FUNC("Cannot find gps lna pin init state!\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:695:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
695 | WMT_PLAT_ERR_FUNC("Cannot find gps lna pin oh state!\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:701:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
701 | WMT_PLAT_ERR_FUNC("Cannot find gps lna pin ol state!\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_wake_lock_ctrl':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:812:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
812 | WMT_PLAT_ERR_FUNC("--->lock gOsSLock failed, ret=%d\n", ret);
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_set_host_dump_state':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:935:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
935 | WMT_PLAT_ERR_FUNC("get virtual address fail\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_force_trigger_assert':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:955:4: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
955 | WMT_PLAT_ERR_FUNC("get virtual address fail\n");
| ^~~~~~~~~~~~~~~~~
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:978:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
978 | WMT_PLAT_ERR_FUNC("unknown force trigger assert type\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_update_host_sync_num':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:993:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
993 | WMT_PLAT_ERR_FUNC("get virtual address fail\n");
| ^~~~~~~~~~~~~~~~~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c: In function 'wmt_plat_get_dump_info':
>> drivers/misc/mediatek/connectivity/common/conn_soc/include/wmt_plat.h:69:20: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
69 | if (wmtPlatLogLvl >= WMT_PLAT_LOG_ERR) \
| ^~
drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:1010:3: note: in expansion of macro 'WMT_PLAT_ERR_FUNC'
1010 | WMT_PLAT_ERR_FUNC("get virtual address fail\n");
| ^~~~~~~~~~~~~~~~~
In file included from drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/wmt_plat_alps.c:39:
At top level:
drivers/misc/mediatek/connectivity/common/conn_soc/linux/pri/include/stp_dbg.h:61:20: error: 'gStpDbgType' defined but not used [-Werror=unused-const-variable=]
61 | static char *const gStpDbgType[] = {
| ^~~~~~~~~~~
cc1: all warnings being treated as errors
coccinelle warnings: (new ones prefixed by >>)
>> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:103:6-11: No need to set .owner here. The core will do it.
Please review and possibly fold the followup patch.
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 28208 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread* [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings 2020-07-06 9:43 [frank-w-bpi-r2-4.14:5.8-wifi 9/14] drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:103:6-11: No need to set .owner here. The core will do it kernel test robot @ 2020-07-06 9:43 ` kernel test robot 0 siblings, 0 replies; 11+ messages in thread From: kernel test robot @ 2020-07-06 9:43 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 1165 bytes --] From: kernel test robot <lkp@intel.com> drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:103:6-11: No need to set .owner here. The core will do it. Remove .owner field if calls are used which set it automatically Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci Fixes: f63b913be60c ("mt6625l: set MTK_PLATFORM in Makefile if none is set via *config") Signed-off-by: kernel test robot <lkp@intel.com> --- tree: https://github.com/frank-w/BPI-R2-4.14 5.8-wifi head: 647f6f36134f2165d37e44dcfb6a77a4671d529c commit: f63b913be60c8b22005bf3bfd8fcfa16f7957365 [9/14] mt6625l: set MTK_PLATFORM in Makefile if none is set via *config mtk_wcn_consys_hw.c | 1 - 1 file changed, 1 deletion(-) --- a/drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c +++ b/drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c @@ -100,7 +100,6 @@ static struct platform_driver mtk_wmt_de .remove = mtk_wmt_remove, .driver = { .name = "mt7623consys", - .owner = THIS_MODULE, .of_match_table = of_match_ptr(apwmt_of_ids), }, }; ^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2020-07-06 9:43 UTC | newest] Thread overview: 11+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-07-06 6:41 [frank-w-bpi-r2-4.14:5.8-wifi 5/11] drivers/misc/mediatek/connectivity/common/common_detect/sdio_detect.c:88:34-35: WARNING: Use ARRAY_SIZE kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix boolconv.cocci warnings kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix eno.cocci warnings kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings kernel test robot 2020-07-06 6:41 ` [PATCH] mt6625l: fix returnvar.cocci warnings kernel test robot 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot 2020-07-06 6:41 ` kernel test robot -- strict thread matches above, loose matches on Subject: below -- 2020-07-06 9:43 [frank-w-bpi-r2-4.14:5.8-wifi 9/14] drivers/misc/mediatek/connectivity/common/conn_soc/mt7623/mtk_wcn_consys_hw.c:103:6-11: No need to set .owner here. The core will do it kernel test robot 2020-07-06 9:43 ` [PATCH] mt6625l: fix platform_no_drv_owner.cocci warnings kernel test robot
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.