Re: [PATCH] audit: fix memory leak in nf_tables_commit
by kernel test robot
Hi Dongliang,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on nf/master]
[also build test ERROR on nf-next/master ipvs/master v5.14-rc1 next-20210713]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Dongliang-Mu/audit-fix-memory-le...
base: https://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf.git master
config: x86_64-randconfig-a005-20210713 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 8d69635ed9ecf36fd0ca85906bfde17949671cbe)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
# https://github.com/0day-ci/linux/commit/2112ee88ee1fa56b43d8d4ba2554d8d94...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Dongliang-Mu/audit-fix-memory-leak-in-nf_tables_commit/20210713-174434
git checkout 2112ee88ee1fa56b43d8d4ba2554d8d94199bd37
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> net/netfilter/nf_tables_api.c:8522:26: error: passing 'struct list_head' to parameter of incompatible type 'struct list_head *'; take the address with &
nf_tables_commit_free(adl);
^~~
&
net/netfilter/nf_tables_api.c:8448:53: note: passing argument to parameter 'adl' here
static void nf_tables_commit_free(struct list_head *adl)
^
net/netfilter/nf_tables_api.c:8532:27: error: passing 'struct list_head' to parameter of incompatible type 'struct list_head *'; take the address with &
nf_tables_commit_free(adl);
^~~
&
net/netfilter/nf_tables_api.c:8448:53: note: passing argument to parameter 'adl' here
static void nf_tables_commit_free(struct list_head *adl)
^
2 errors generated.
vim +8522 net/netfilter/nf_tables_api.c
8491
8492 static int nf_tables_commit(struct net *net, struct sk_buff *skb)
8493 {
8494 struct nftables_pernet *nft_net = nft_pernet(net);
8495 struct nft_trans *trans, *next;
8496 struct nft_trans_elem *te;
8497 struct nft_chain *chain;
8498 struct nft_table *table;
8499 LIST_HEAD(adl);
8500 int err;
8501
8502 if (list_empty(&nft_net->commit_list)) {
8503 mutex_unlock(&nft_net->commit_mutex);
8504 return 0;
8505 }
8506
8507 /* 0. Validate ruleset, otherwise roll back for error reporting. */
8508 if (nf_tables_validate(net) < 0)
8509 return -EAGAIN;
8510
8511 err = nft_flow_rule_offload_commit(net);
8512 if (err < 0)
8513 return err;
8514
8515 /* 1. Allocate space for next generation rules_gen_X[] */
8516 list_for_each_entry_safe(trans, next, &nft_net->commit_list, list) {
8517 int ret;
8518
8519 ret = nf_tables_commit_audit_alloc(&adl, trans->ctx.table);
8520 if (ret) {
8521 nf_tables_commit_chain_prepare_cancel(net);
> 8522 nf_tables_commit_free(adl);
8523 return ret;
8524 }
8525 if (trans->msg_type == NFT_MSG_NEWRULE ||
8526 trans->msg_type == NFT_MSG_DELRULE) {
8527 chain = trans->ctx.chain;
8528
8529 ret = nf_tables_commit_chain_prepare(net, chain);
8530 if (ret < 0) {
8531 nf_tables_commit_chain_prepare_cancel(net);
8532 nf_tables_commit_free(adl);
8533 return ret;
8534 }
8535 }
8536 }
8537
8538 /* step 2. Make rules_gen_X visible to packet path */
8539 list_for_each_entry(table, &nft_net->tables, list) {
8540 list_for_each_entry(chain, &table->chains, list)
8541 nf_tables_commit_chain(net, chain);
8542 }
8543
8544 /*
8545 * Bump generation counter, invalidate any dump in progress.
8546 * Cannot fail after this point.
8547 */
8548 while (++nft_net->base_seq == 0)
8549 ;
8550
8551 /* step 3. Start new generation, rules_gen_X now in use. */
8552 net->nft.gencursor = nft_gencursor_next(net);
8553
8554 list_for_each_entry_safe(trans, next, &nft_net->commit_list, list) {
8555 nf_tables_commit_audit_collect(&adl, trans->ctx.table,
8556 trans->msg_type);
8557 switch (trans->msg_type) {
8558 case NFT_MSG_NEWTABLE:
8559 if (nft_trans_table_update(trans)) {
8560 if (!(trans->ctx.table->flags & __NFT_TABLE_F_UPDATE)) {
8561 nft_trans_destroy(trans);
8562 break;
8563 }
8564 if (trans->ctx.table->flags & NFT_TABLE_F_DORMANT)
8565 nf_tables_table_disable(net, trans->ctx.table);
8566
8567 trans->ctx.table->flags &= ~__NFT_TABLE_F_UPDATE;
8568 } else {
8569 nft_clear(net, trans->ctx.table);
8570 }
8571 nf_tables_table_notify(&trans->ctx, NFT_MSG_NEWTABLE);
8572 nft_trans_destroy(trans);
8573 break;
8574 case NFT_MSG_DELTABLE:
8575 list_del_rcu(&trans->ctx.table->list);
8576 nf_tables_table_notify(&trans->ctx, NFT_MSG_DELTABLE);
8577 break;
8578 case NFT_MSG_NEWCHAIN:
8579 if (nft_trans_chain_update(trans)) {
8580 nft_chain_commit_update(trans);
8581 nf_tables_chain_notify(&trans->ctx, NFT_MSG_NEWCHAIN);
8582 /* trans destroyed after rcu grace period */
8583 } else {
8584 nft_chain_commit_drop_policy(trans);
8585 nft_clear(net, trans->ctx.chain);
8586 nf_tables_chain_notify(&trans->ctx, NFT_MSG_NEWCHAIN);
8587 nft_trans_destroy(trans);
8588 }
8589 break;
8590 case NFT_MSG_DELCHAIN:
8591 nft_chain_del(trans->ctx.chain);
8592 nf_tables_chain_notify(&trans->ctx, NFT_MSG_DELCHAIN);
8593 nf_tables_unregister_hook(trans->ctx.net,
8594 trans->ctx.table,
8595 trans->ctx.chain);
8596 break;
8597 case NFT_MSG_NEWRULE:
8598 nft_clear(trans->ctx.net, nft_trans_rule(trans));
8599 nf_tables_rule_notify(&trans->ctx,
8600 nft_trans_rule(trans),
8601 NFT_MSG_NEWRULE);
8602 nft_trans_destroy(trans);
8603 break;
8604 case NFT_MSG_DELRULE:
8605 list_del_rcu(&nft_trans_rule(trans)->list);
8606 nf_tables_rule_notify(&trans->ctx,
8607 nft_trans_rule(trans),
8608 NFT_MSG_DELRULE);
8609 nft_rule_expr_deactivate(&trans->ctx,
8610 nft_trans_rule(trans),
8611 NFT_TRANS_COMMIT);
8612 break;
8613 case NFT_MSG_NEWSET:
8614 nft_clear(net, nft_trans_set(trans));
8615 /* This avoids hitting -EBUSY when deleting the table
8616 * from the transaction.
8617 */
8618 if (nft_set_is_anonymous(nft_trans_set(trans)) &&
8619 !list_empty(&nft_trans_set(trans)->bindings))
8620 trans->ctx.table->use--;
8621
8622 nf_tables_set_notify(&trans->ctx, nft_trans_set(trans),
8623 NFT_MSG_NEWSET, GFP_KERNEL);
8624 nft_trans_destroy(trans);
8625 break;
8626 case NFT_MSG_DELSET:
8627 list_del_rcu(&nft_trans_set(trans)->list);
8628 nf_tables_set_notify(&trans->ctx, nft_trans_set(trans),
8629 NFT_MSG_DELSET, GFP_KERNEL);
8630 break;
8631 case NFT_MSG_NEWSETELEM:
8632 te = (struct nft_trans_elem *)trans->data;
8633
8634 nft_setelem_activate(net, te->set, &te->elem);
8635 nf_tables_setelem_notify(&trans->ctx, te->set,
8636 &te->elem,
8637 NFT_MSG_NEWSETELEM, 0);
8638 nft_trans_destroy(trans);
8639 break;
8640 case NFT_MSG_DELSETELEM:
8641 te = (struct nft_trans_elem *)trans->data;
8642
8643 nf_tables_setelem_notify(&trans->ctx, te->set,
8644 &te->elem,
8645 NFT_MSG_DELSETELEM, 0);
8646 nft_setelem_remove(net, te->set, &te->elem);
8647 if (!nft_setelem_is_catchall(te->set, &te->elem)) {
8648 atomic_dec(&te->set->nelems);
8649 te->set->ndeact--;
8650 }
8651 break;
8652 case NFT_MSG_NEWOBJ:
8653 if (nft_trans_obj_update(trans)) {
8654 nft_obj_commit_update(trans);
8655 nf_tables_obj_notify(&trans->ctx,
8656 nft_trans_obj(trans),
8657 NFT_MSG_NEWOBJ);
8658 } else {
8659 nft_clear(net, nft_trans_obj(trans));
8660 nf_tables_obj_notify(&trans->ctx,
8661 nft_trans_obj(trans),
8662 NFT_MSG_NEWOBJ);
8663 nft_trans_destroy(trans);
8664 }
8665 break;
8666 case NFT_MSG_DELOBJ:
8667 nft_obj_del(nft_trans_obj(trans));
8668 nf_tables_obj_notify(&trans->ctx, nft_trans_obj(trans),
8669 NFT_MSG_DELOBJ);
8670 break;
8671 case NFT_MSG_NEWFLOWTABLE:
8672 if (nft_trans_flowtable_update(trans)) {
8673 nft_trans_flowtable(trans)->data.flags =
8674 nft_trans_flowtable_flags(trans);
8675 nf_tables_flowtable_notify(&trans->ctx,
8676 nft_trans_flowtable(trans),
8677 &nft_trans_flowtable_hooks(trans),
8678 NFT_MSG_NEWFLOWTABLE);
8679 list_splice(&nft_trans_flowtable_hooks(trans),
8680 &nft_trans_flowtable(trans)->hook_list);
8681 } else {
8682 nft_clear(net, nft_trans_flowtable(trans));
8683 nf_tables_flowtable_notify(&trans->ctx,
8684 nft_trans_flowtable(trans),
8685 &nft_trans_flowtable(trans)->hook_list,
8686 NFT_MSG_NEWFLOWTABLE);
8687 }
8688 nft_trans_destroy(trans);
8689 break;
8690 case NFT_MSG_DELFLOWTABLE:
8691 if (nft_trans_flowtable_update(trans)) {
8692 nft_flowtable_hooks_del(nft_trans_flowtable(trans),
8693 &nft_trans_flowtable_hooks(trans));
8694 nf_tables_flowtable_notify(&trans->ctx,
8695 nft_trans_flowtable(trans),
8696 &nft_trans_flowtable_hooks(trans),
8697 NFT_MSG_DELFLOWTABLE);
8698 nft_unregister_flowtable_net_hooks(net,
8699 &nft_trans_flowtable_hooks(trans));
8700 } else {
8701 list_del_rcu(&nft_trans_flowtable(trans)->list);
8702 nf_tables_flowtable_notify(&trans->ctx,
8703 nft_trans_flowtable(trans),
8704 &nft_trans_flowtable(trans)->hook_list,
8705 NFT_MSG_DELFLOWTABLE);
8706 nft_unregister_flowtable_net_hooks(net,
8707 &nft_trans_flowtable(trans)->hook_list);
8708 }
8709 break;
8710 }
8711 }
8712
8713 nft_commit_notify(net, NETLINK_CB(skb).portid);
8714 nf_tables_gen_notify(net, skb, NFT_MSG_NEWGEN);
8715 nf_tables_commit_audit_log(&adl, nft_net->base_seq);
8716 nf_tables_commit_release(net);
8717
8718 return 0;
8719 }
8720
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[linux-rt-devel:linux-5.13.y-rt-testing 207/228] kernel/entry/common.c:158:19: error: use of undeclared identifier '_TIF_NEED_RESCHED_MASK'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git linux-5.13.y-rt-testing
head: 87ca00748cfcc19b46d4622228d2e0e8514d5033
commit: f2f9e496208c584356e84e720a3dfd99970ee5e9 [207/228] x86: Support for lazy preemption
config: s390-buildonly-randconfig-r005-20210712 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 8d69635ed9ecf36fd0ca85906bfde17949671cbe)
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
# install s390 cross compiling tool for clang build
# apt-get install binutils-s390x-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git/com...
git remote add linux-rt-devel https://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git
git fetch --no-tags linux-rt-devel linux-5.13.y-rt-testing
git checkout f2f9e496208c584356e84e720a3dfd99970ee5e9
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross O=build_dir ARCH=s390 SHELL=/bin/bash kernel/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Note: the linux-rt-devel/linux-5.13.y-rt-testing HEAD 87ca00748cfcc19b46d4622228d2e0e8514d5033 builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
In file included from kernel/entry/common.c:4:
In file included from include/linux/entry-common.h:6:
In file included from include/linux/tracehook.h:50:
In file included from include/linux/memcontrol.h:22:
In file included from include/linux/writeback.h:14:
In file included from include/linux/blk-cgroup.h:23:
In file included from include/linux/blkdev.h:25:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:75:
include/asm-generic/io.h:464:31: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __raw_readb(PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:477:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le16_to_cpu((__le16 __force)__raw_readw(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:36:59: note: expanded from macro '__le16_to_cpu'
#define __le16_to_cpu(x) __swab16((__force __u16)(__le16)(x))
^
include/uapi/linux/swab.h:102:54: note: expanded from macro '__swab16'
#define __swab16(x) (__u16)__builtin_bswap16((__u16)(x))
^
In file included from kernel/entry/common.c:4:
In file included from include/linux/entry-common.h:6:
In file included from include/linux/tracehook.h:50:
In file included from include/linux/memcontrol.h:22:
In file included from include/linux/writeback.h:14:
In file included from include/linux/blk-cgroup.h:23:
In file included from include/linux/blkdev.h:25:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:75:
include/asm-generic/io.h:490:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:34:59: note: expanded from macro '__le32_to_cpu'
#define __le32_to_cpu(x) __swab32((__force __u32)(__le32)(x))
^
include/uapi/linux/swab.h:115:54: note: expanded from macro '__swab32'
#define __swab32(x) (__u32)__builtin_bswap32((__u32)(x))
^
In file included from kernel/entry/common.c:4:
In file included from include/linux/entry-common.h:6:
In file included from include/linux/tracehook.h:50:
In file included from include/linux/memcontrol.h:22:
In file included from include/linux/writeback.h:14:
In file included from include/linux/blk-cgroup.h:23:
In file included from include/linux/blkdev.h:25:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:75:
include/asm-generic/io.h:501:33: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
__raw_writeb(value, PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:511:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
__raw_writew((u16 __force)cpu_to_le16(value), PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:521:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
__raw_writel((u32 __force)cpu_to_le32(value), PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:609:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
readsb(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:617:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
readsw(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:625:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
readsl(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:634:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
writesb(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:643:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
writesw(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:652:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
writesl(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
>> kernel/entry/common.c:158:19: error: use of undeclared identifier '_TIF_NEED_RESCHED_MASK'
while (ti_work & EXIT_TO_USER_MODE_WORK) {
^
include/linux/entry-common.h:62:3: note: expanded from macro 'EXIT_TO_USER_MODE_WORK'
_TIF_NEED_RESCHED_MASK | _TIF_PATCH_PENDING | _TIF_NOTIFY_SIGNAL | \
^
kernel/entry/common.c:162:17: error: use of undeclared identifier '_TIF_NEED_RESCHED_MASK'
if (ti_work & _TIF_NEED_RESCHED_MASK)
^
kernel/entry/common.c:216:25: error: use of undeclared identifier '_TIF_NEED_RESCHED_MASK'
if (unlikely(ti_work & EXIT_TO_USER_MODE_WORK))
^
include/linux/entry-common.h:62:3: note: expanded from macro 'EXIT_TO_USER_MODE_WORK'
_TIF_NEED_RESCHED_MASK | _TIF_PATCH_PENDING | _TIF_NOTIFY_SIGNAL | \
^
12 warnings and 3 errors generated.
vim +/_TIF_NEED_RESCHED_MASK +158 kernel/entry/common.c
a9f3a74a29af09 Thomas Gleixner 2020-07-22 150
a9f3a74a29af09 Thomas Gleixner 2020-07-22 151 static unsigned long exit_to_user_mode_loop(struct pt_regs *regs,
a9f3a74a29af09 Thomas Gleixner 2020-07-22 152 unsigned long ti_work)
a9f3a74a29af09 Thomas Gleixner 2020-07-22 153 {
a9f3a74a29af09 Thomas Gleixner 2020-07-22 154 /*
a9f3a74a29af09 Thomas Gleixner 2020-07-22 155 * Before returning to user space ensure that all pending work
a9f3a74a29af09 Thomas Gleixner 2020-07-22 156 * items have been completed.
a9f3a74a29af09 Thomas Gleixner 2020-07-22 157 */
a9f3a74a29af09 Thomas Gleixner 2020-07-22 @158 while (ti_work & EXIT_TO_USER_MODE_WORK) {
a9f3a74a29af09 Thomas Gleixner 2020-07-22 159
a9f3a74a29af09 Thomas Gleixner 2020-07-22 160 local_irq_enable_exit_to_user(ti_work);
a9f3a74a29af09 Thomas Gleixner 2020-07-22 161
f2f9e496208c58 Thomas Gleixner 2012-11-01 162 if (ti_work & _TIF_NEED_RESCHED_MASK)
a9f3a74a29af09 Thomas Gleixner 2020-07-22 163 schedule();
a9f3a74a29af09 Thomas Gleixner 2020-07-22 164
:::::: The code at line 158 was first introduced by commit
:::::: a9f3a74a29af095f3e1b89e9176f8127912ae0f0 entry: Provide generic syscall exit function
:::::: TO: Thomas Gleixner <tglx(a)linutronix.de>
:::::: CC: Thomas Gleixner <tglx(a)linutronix.de>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [PATCH 24/51] ALSA: via82xx: Allocate resources with device-managed APIs
by kernel test robot
Hi Takashi,
I love your patch! Perhaps something to improve:
[auto build test WARNING on sound/for-next]
[also build test WARNING on v5.14-rc1 next-20210713]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Takashi-Iwai/ALSA-More-devres-us...
base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
config: arm64-buildonly-randconfig-r003-20210713 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 8d69635ed9ecf36fd0ca85906bfde17949671cbe)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://github.com/0day-ci/linux/commit/2fe9eb4f2c4739f0452db5aee6618679d...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Takashi-Iwai/ALSA-More-devres-usages/20210713-225131
git checkout 2fe9eb4f2c4739f0452db5aee6618679da3adc73
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> sound/pci/via82xx_modem.c:1075:2: warning: variable 'chip' is uninitialized when used here [-Wuninitialized]
chip->card = card;
^~~~
sound/pci/via82xx_modem.c:1067:28: note: initialize the variable 'chip' to silence this warning
struct via82xx_modem *chip;
^
= NULL
1 warning generated.
vim +/chip +1075 sound/pci/via82xx_modem.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 1060
e23e7a14362072 Bill Pemberton 2012-12-06 1061 static int snd_via82xx_create(struct snd_card *card,
^1da177e4c3f41 Linus Torvalds 2005-04-16 1062 struct pci_dev *pci,
^1da177e4c3f41 Linus Torvalds 2005-04-16 1063 int chip_type,
^1da177e4c3f41 Linus Torvalds 2005-04-16 1064 int revision,
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1065 unsigned int ac97_clock)
^1da177e4c3f41 Linus Torvalds 2005-04-16 1066 {
e437e3d7c7fb65 Takashi Iwai 2005-11-17 1067 struct via82xx_modem *chip;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1068 int err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1069
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1070 err = pcim_enable_device(pci);
afb342f02241a9 Takashi Iwai 2021-06-08 1071 if (err < 0)
^1da177e4c3f41 Linus Torvalds 2005-04-16 1072 return err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1073
^1da177e4c3f41 Linus Torvalds 2005-04-16 1074 spin_lock_init(&chip->reg_lock);
^1da177e4c3f41 Linus Torvalds 2005-04-16 @1075 chip->card = card;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1076 chip->pci = pci;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1077 chip->irq = -1;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1078
afb342f02241a9 Takashi Iwai 2021-06-08 1079 err = pci_request_regions(pci, card->driver);
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1080 if (err < 0)
^1da177e4c3f41 Linus Torvalds 2005-04-16 1081 return err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1082 chip->port = pci_resource_start(pci, 0);
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1083 if (devm_request_irq(&pci->dev, pci->irq, snd_via82xx_interrupt,
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1084 IRQF_SHARED, KBUILD_MODNAME, chip)) {
473439e06a2562 Takashi Iwai 2014-02-25 1085 dev_err(card->dev, "unable to grab IRQ %d\n", pci->irq);
^1da177e4c3f41 Linus Torvalds 2005-04-16 1086 return -EBUSY;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1087 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 1088 chip->irq = pci->irq;
c47583b0eb6847 Takashi Iwai 2019-12-10 1089 card->sync_irq = chip->irq;
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1090 card->private_free = snd_via82xx_free;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1091 if (ac97_clock >= 8000 && ac97_clock <= 48000)
^1da177e4c3f41 Linus Torvalds 2005-04-16 1092 chip->ac97_clock = ac97_clock;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1093
afb342f02241a9 Takashi Iwai 2021-06-08 1094 err = snd_via82xx_chip_init(chip);
2fe9eb4f2c4739 Takashi Iwai 2021-07-13 1095 if (err < 0)
^1da177e4c3f41 Linus Torvalds 2005-04-16 1096 return err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1097
^1da177e4c3f41 Linus Torvalds 2005-04-16 1098 /* The 8233 ac97 controller does not implement the master bit
^1da177e4c3f41 Linus Torvalds 2005-04-16 1099 * in the pci command register. IMHO this is a violation of the PCI spec.
^1da177e4c3f41 Linus Torvalds 2005-04-16 1100 * We call pci_set_master here because it does not hurt. */
^1da177e4c3f41 Linus Torvalds 2005-04-16 1101 pci_set_master(pci);
^1da177e4c3f41 Linus Torvalds 2005-04-16 1102 return 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 1103 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 1104
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [PATCH 50/51] ALSA: serial-u16550: Allocate resources with device-managed APIs
by kernel test robot
Hi Takashi,
I love your patch! Yet something to improve:
[auto build test ERROR on sound/for-next]
[also build test ERROR on next-20210713]
[cannot apply to v5.14-rc1]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Takashi-Iwai/ALSA-More-devres-us...
base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
config: arm64-randconfig-r006-20210713 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 8d69635ed9ecf36fd0ca85906bfde17949671cbe)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://github.com/0day-ci/linux/commit/a283d143a861578b305e87de7df0178f9...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Takashi-Iwai/ALSA-More-devres-usages/20210713-225131
git checkout a283d143a861578b305e87de7df0178f9d0adfa8
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross O=build_dir ARCH=arm64 SHELL=/bin/bash sound/drivers/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> sound/drivers/serial-u16550.c:766:47: error: too few arguments to function call, expected 3, have 2
uart = devm_kzalloc(sizeof(*uart), GFP_KERNEL);
~~~~~~~~~~~~ ^
include/linux/device.h:206:21: note: 'devm_kzalloc' declared here
static inline void *devm_kzalloc(struct device *dev, size_t size, gfp_t gfp)
^
1 error generated.
vim +766 sound/drivers/serial-u16550.c
752
753 static int snd_uart16550_create(struct snd_card *card,
754 unsigned long iobase,
755 int irq,
756 unsigned int speed,
757 unsigned int base,
758 int adaptor,
759 int droponfull,
760 struct snd_uart16550 **ruart)
761 {
762 struct snd_uart16550 *uart;
763 int err;
764
765
> 766 uart = devm_kzalloc(sizeof(*uart), GFP_KERNEL);
767 if (!uart)
768 return -ENOMEM;
769 uart->adaptor = adaptor;
770 uart->card = card;
771 spin_lock_init(&uart->open_lock);
772 uart->irq = -1;
773 uart->base = iobase;
774 uart->drop_on_full = droponfull;
775
776 err = snd_uart16550_detect(uart);
777 if (err <= 0) {
778 printk(KERN_ERR "no UART detected at 0x%lx\n", iobase);
779 return -ENODEV;
780 }
781
782 if (irq >= 0 && irq != SNDRV_AUTO_IRQ) {
783 if (devm_request_irq(card->dev, irq, snd_uart16550_interrupt,
784 0, "Serial MIDI", uart)) {
785 snd_printk(KERN_WARNING
786 "irq %d busy. Using Polling.\n", irq);
787 } else {
788 uart->irq = irq;
789 }
790 }
791 uart->divisor = base / speed;
792 uart->speed = base / (unsigned int)uart->divisor;
793 uart->speed_base = base;
794 uart->prev_out = -1;
795 uart->prev_in = 0;
796 uart->rstatus = 0;
797 memset(uart->prev_status, 0x80, sizeof(unsigned char) * SNDRV_SERIAL_MAX_OUTS);
798 timer_setup(&uart->buffer_timer, snd_uart16550_buffer_timer, 0);
799 uart->timer_running = 0;
800
801 switch (uart->adaptor) {
802 case SNDRV_SERIAL_MS124W_SA:
803 case SNDRV_SERIAL_MS124W_MB:
804 /* MS-124W can draw power from RTS and DTR if they
805 are in opposite states. */
806 outb(UART_MCR_RTS | (0&UART_MCR_DTR), uart->base + UART_MCR);
807 break;
808 case SNDRV_SERIAL_MS124T:
809 /* MS-124T can draw power from RTS and/or DTR (preferably
810 both) if they are asserted. */
811 outb(UART_MCR_RTS | UART_MCR_DTR, uart->base + UART_MCR);
812 break;
813 default:
814 break;
815 }
816
817 if (ruart)
818 *ruart = uart;
819
820 return 0;
821 }
822
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[android-common:android13-5.10 7/51] arch/arm64/kernel/machine_kexec.c:62:5: warning: no previous prototype for function 'machine_kexec_post_load'
by kernel test robot
tree: https://android.googlesource.com/kernel/common android13-5.10
head: 663bbfa2a48a042ef172114830ccf6ad1a16677c
commit: bdc7abb880337dc68bd400d3a69df9d61275e402 [7/51] UPSTREAM: arm64: kexec: move relocation function setup
config: arm64-randconfig-r003-20210713 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 8d69635ed9ecf36fd0ca85906bfde17949671cbe)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android13-5.10
git checkout bdc7abb880337dc68bd400d3a69df9d61275e402
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> arch/arm64/kernel/machine_kexec.c:62:5: warning: no previous prototype for function 'machine_kexec_post_load' [-Wmissing-prototypes]
int machine_kexec_post_load(struct kimage *kimage)
^
arch/arm64/kernel/machine_kexec.c:62:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int machine_kexec_post_load(struct kimage *kimage)
^
static
arch/arm64/kernel/machine_kexec.c:238:6: warning: no previous prototype for function 'machine_crash_shutdown' [-Wmissing-prototypes]
void machine_crash_shutdown(struct pt_regs *regs)
^
arch/arm64/kernel/machine_kexec.c:238:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void machine_crash_shutdown(struct pt_regs *regs)
^
static
2 warnings generated.
vim +/machine_kexec_post_load +62 arch/arm64/kernel/machine_kexec.c
61
> 62 int machine_kexec_post_load(struct kimage *kimage)
63 {
64 void *reloc_code = page_to_virt(kimage->control_code_page);
65
66 memcpy(reloc_code, arm64_relocate_new_kernel,
67 arm64_relocate_new_kernel_size);
68 kimage->arch.kern_reloc = __pa(reloc_code);
69
70 /* Flush the reloc_code in preparation for its execution. */
71 __flush_dcache_area(reloc_code, arm64_relocate_new_kernel_size);
72 flush_icache_range((uintptr_t)reloc_code, (uintptr_t)reloc_code +
73 arm64_relocate_new_kernel_size);
74
75 return 0;
76 }
77
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [PATCH v5 2/4] pwm: driver for qualcomm ipq6018 pwm block
by kernel test robot
Hi Baruch,
I love your patch! Yet something to improve:
[auto build test ERROR on pwm/for-next]
[also build test ERROR on robh/for-next v5.14-rc1 next-20210713]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Baruch-Siach/arm64-dts-ipq6018-c...
base: https://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm.git for-next
config: m68k-allmodconfig (attached as .config)
compiler: m68k-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
# https://github.com/0day-ci/linux/commit/3215e41e0c2fbd26202f21458ea6f1993...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Baruch-Siach/arm64-dts-ipq6018-correct-TCSR-block-area/20210713-193616
git checkout 3215e41e0c2fbd26202f21458ea6f1993f90e126
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=m68k
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/pwm/pwm-ipq.c: In function 'config_div_and_duty':
>> drivers/pwm/pwm-ipq.c:96:8: error: implicit declaration of function 'FIELD_PREP' [-Werror=implicit-function-declaration]
96 | val = FIELD_PREP(IPQ_PWM_REG0_HI_DURATION, hi_dur) |
| ^~~~~~~~~~
drivers/pwm/pwm-ipq.c: In function 'ipq_pwm_get_state':
>> drivers/pwm/pwm-ipq.c:182:12: error: implicit declaration of function 'FIELD_GET' [-Werror=implicit-function-declaration]
182 | pwm_div = FIELD_GET(IPQ_PWM_REG0_PWM_DIV, reg0);
| ^~~~~~~~~
cc1: some warnings being treated as errors
vim +/FIELD_PREP +96 drivers/pwm/pwm-ipq.c
80
81 static void config_div_and_duty(struct pwm_device *pwm, unsigned int pre_div,
82 unsigned int pwm_div, u64 period_ns, u64 duty_ns,
83 bool enable)
84 {
85 unsigned long hi_dur;
86 unsigned long long quotient;
87 unsigned long val = 0;
88
89 /*
90 * high duration = pwm duty * (pwm div + 1)
91 * pwm duty = duty_ns / period_ns
92 */
93 quotient = (pwm_div + 1) * duty_ns;
94 hi_dur = div64_u64(quotient, period_ns);
95
> 96 val = FIELD_PREP(IPQ_PWM_REG0_HI_DURATION, hi_dur) |
97 FIELD_PREP(IPQ_PWM_REG0_PWM_DIV, pwm_div);
98 ipq_pwm_reg_write(pwm, IPQ_PWM_CFG_REG0, val);
99
100 val = FIELD_PREP(IPQ_PWM_REG1_PRE_DIV, pre_div);
101 ipq_pwm_reg_write(pwm, IPQ_PWM_CFG_REG1, val);
102
103 /* Enable needs a separate write to REG1 */
104 val |= IPQ_PWM_REG1_UPDATE;
105 if (enable)
106 val |= IPQ_PWM_REG1_ENABLE;
107 else
108 val &= ~IPQ_PWM_REG1_ENABLE;
109 ipq_pwm_reg_write(pwm, IPQ_PWM_CFG_REG1, val);
110 }
111
112 static int ipq_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,
113 const struct pwm_state *state)
114 {
115 struct ipq_pwm_chip *ipq_chip = to_ipq_pwm_chip(chip);
116 unsigned long freq;
117 unsigned int pre_div, pwm_div, close_pre_div, close_pwm_div;
118 long long diff;
119 unsigned long rate = clk_get_rate(ipq_chip->clk);
120 unsigned long min_diff = rate;
121 uint64_t fin_ps;
122 u64 period_ns, duty_ns;
123
124 if (state->period < IPQ_PWM_MIN_PERIOD_NS)
125 return -ERANGE;
126
127 period_ns = min(state->period, IPQ_PWM_MAX_PERIOD_NS);
128 duty_ns = min(state->duty_cycle, period_ns);
129
130 /* freq in Hz for period in nano second */
131 freq = div64_u64(NSEC_PER_SEC, period_ns);
132 fin_ps = div64_u64(NSEC_PER_SEC * 1000ULL, rate);
133 close_pre_div = IPQ_PWM_MAX_DIV;
134 close_pwm_div = IPQ_PWM_MAX_DIV;
135
136 for (pre_div = 0; pre_div <= IPQ_PWM_MAX_DIV; pre_div++) {
137 pwm_div = DIV64_U64_ROUND_CLOSEST(period_ns * 1000,
138 fin_ps * (pre_div + 1));
139 pwm_div--;
140 if (pwm_div > IPQ_PWM_MAX_DIV)
141 continue;
142
143 diff = ((uint64_t)freq * (pre_div + 1) * (pwm_div + 1))
144 - (uint64_t)rate;
145
146 if (diff < 0) /* period larger than requested */
147 continue;
148 if (diff == 0) { /* bingo */
149 close_pre_div = pre_div;
150 close_pwm_div = pwm_div;
151 break;
152 }
153 if (diff < min_diff) {
154 min_diff = diff;
155 close_pre_div = pre_div;
156 close_pwm_div = pwm_div;
157 }
158 }
159
160 /* config divider values for the closest possible frequency */
161 config_div_and_duty(pwm, close_pre_div, close_pwm_div,
162 period_ns, duty_ns, state->enabled);
163
164 return 0;
165 }
166
167 static void ipq_pwm_get_state(struct pwm_chip *chip, struct pwm_device *pwm,
168 struct pwm_state *state)
169 {
170 struct ipq_pwm_chip *ipq_chip = to_ipq_pwm_chip(chip);
171 unsigned long rate = clk_get_rate(ipq_chip->clk);
172 unsigned int pre_div, pwm_div, hi_dur;
173 u64 effective_div, hi_div;
174 u32 reg0, reg1;
175
176 reg0 = ipq_pwm_reg_read(pwm, IPQ_PWM_CFG_REG0);
177 reg1 = ipq_pwm_reg_read(pwm, IPQ_PWM_CFG_REG1);
178
179 state->polarity = PWM_POLARITY_NORMAL;
180 state->enabled = reg1 & IPQ_PWM_REG1_ENABLE;
181
> 182 pwm_div = FIELD_GET(IPQ_PWM_REG0_PWM_DIV, reg0);
183 hi_dur = FIELD_GET(IPQ_PWM_REG0_HI_DURATION, reg0);
184 pre_div = FIELD_GET(IPQ_PWM_REG1_PRE_DIV, reg1);
185
186 effective_div = (pre_div + 1) * (pwm_div + 1);
187 state->period = div64_u64(effective_div * NSEC_PER_SEC, rate);
188
189 hi_div = hi_dur * (pre_div + 1);
190 state->duty_cycle = div64_u64(hi_div * NSEC_PER_SEC, rate);
191 }
192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[freescale-fslc:5.4-2.3.x-imx 14893/19641] drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h:133:20: error: array type has incomplete element type 'struct msix_entry'
by kernel test robot
Hi Fugang,
FYI, the error/warning still remains.
tree: https://github.com/Freescale/linux-fslc 5.4-2.3.x-imx
head: 909767eaf44d67f51a0eba5dc9260ca43851363c
commit: f186a4e65f54a28973c743f8c007b18c1ce95be6 [14893/19641] MLK-24962 net: wireless: nxp: mxm_wifiex: upgrade to mxm5x16203 release
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
# https://github.com/Freescale/linux-fslc/commit/f186a4e65f54a28973c743f8c0...
git remote add freescale-fslc https://github.com/Freescale/linux-fslc
git fetch --no-tags freescale-fslc 5.4-2.3.x-imx
git checkout f186a4e65f54a28973c743f8c007b18c1ce95be6
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross O=build_dir ARCH=sh SHELL=/bin/bash M=drivers/net/wireless/nxp/mxm_wifiex/wlan_src
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:37:
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h:133:20: error: array type has incomplete element type 'struct msix_entry'
133 | struct msix_entry msix_entries[PCIE_NUM_MSIX_VECTORS];
| ^~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c: In function 'woal_get_mode':
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:990:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
990 | int ret = 0;
| ^~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c: At top level:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:2150:6: warning: no previous prototype for 'woal_request_init_user_conf_callback' [-Wmissing-prototypes]
2150 | void woal_request_init_user_conf_callback(const struct firmware *firmware,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:2650:13: warning: no previous prototype for 'woal_add_card_dpc' [-Wmissing-prototypes]
2650 | mlan_status woal_add_card_dpc(moal_handle *handle)
| ^~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:3355:6: warning: no previous prototype for 'woal_fill_mlan_buffer' [-Wmissing-prototypes]
3355 | void woal_fill_mlan_buffer(moal_private *priv, mlan_buffer *pmbuf,
| ^~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:4283:6: warning: no previous prototype for 'woal_flush_evt_queue' [-Wmissing-prototypes]
4283 | void woal_flush_evt_queue(moal_handle *handle)
| ^~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:4866:6: warning: no previous prototype for 'woal_ioctl_timeout' [-Wmissing-prototypes]
4866 | void woal_ioctl_timeout(moal_handle *handle)
| ^~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:5172:6: warning: no previous prototype for 'woal_tcp_ack_timer_func' [-Wmissing-prototypes]
5172 | void woal_tcp_ack_timer_func(void *context)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:5239:6: warning: no previous prototype for 'woal_send_tcp_ack' [-Wmissing-prototypes]
5239 | void woal_send_tcp_ack(moal_private *priv, struct tcp_sess *tcp_session)
| ^~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:5296:5: warning: no previous prototype for 'woal_process_tcp_ack' [-Wmissing-prototypes]
5296 | int woal_process_tcp_ack(moal_private *priv, mlan_buffer *pmbuf)
| ^~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:8025:5: warning: no previous prototype for 'woal_netdev_poll_rx' [-Wmissing-prototypes]
8025 | int woal_netdev_poll_rx(struct napi_struct *napi, int budget)
| ^~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:8908:6: warning: no previous prototype for 'woal_pre_reset' [-Wmissing-prototypes]
8908 | void woal_pre_reset(moal_handle *handle)
| ^~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:8926:6: warning: no previous prototype for 'woal_post_reset' [-Wmissing-prototypes]
8926 | void woal_post_reset(moal_handle *handle)
| ^~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c: In function 'woal_request_fw_reload':
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:9019:3: error: implicit declaration of function 'pci_reset_function' [-Werror=implicit-function-declaration]
9019 | pci_reset_function(pdev);
| ^~~~~~~~~~~~~~~~~~
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.h:130,
from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.c:29:
At top level:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_priv.h:282:34: warning: 'woal_private_args' defined but not used [-Wunused-const-variable=]
282 | static const struct iw_priv_args woal_private_args[] = {
| ^~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_shim.c:36:
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h:133:20: error: array type has incomplete element type 'struct msix_entry'
133 | struct msix_entry msix_entries[PCIE_NUM_MSIX_VECTORS];
| ^~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_shim.c: In function 'moal_print':
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_shim.c:3005:4: warning: function 'moal_print' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
3005 | vprintk(pformat, args);
| ^~~~~~~
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.h:130,
from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_shim.c:28:
At top level:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_priv.h:282:34: warning: 'woal_private_args' defined but not used [-Wunused-const-variable=]
282 | static const struct iw_priv_args woal_private_args[] = {
| ^~~~~~~~~~~~~~~~~
--
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:48:
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h:133:20: error: array type has incomplete element type 'struct msix_entry'
133 | struct msix_entry msix_entries[PCIE_NUM_MSIX_VECTORS];
| ^~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:130:13: warning: no previous prototype for 'parse_arguments' [-Wmissing-prototypes]
130 | mlan_status parse_arguments(t_u8 *pos, int *data, int datalen,
| ^~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:190:5: warning: no previous prototype for 'string2raw' [-Wmissing-prototypes]
190 | int string2raw(unsigned char *str, unsigned char *raw, int raw_size)
| ^~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:293:13: warning: no previous prototype for 'woal_set_miracast_mode' [-Wmissing-prototypes]
293 | mlan_status woal_set_miracast_mode(moal_private *priv, t_u8 *pdata, size_t len)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:341:5: warning: no previous prototype for 'woal_get_priv_driver_version' [-Wmissing-prototypes]
341 | int woal_get_priv_driver_version(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:570:5: warning: no previous prototype for 'woal_priv_customie' [-Wmissing-prototypes]
570 | int woal_priv_customie(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:633:5: warning: no previous prototype for 'woal_setget_priv_bandcfg' [-Wmissing-prototypes]
633 | int woal_setget_priv_bandcfg(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:760:5: warning: no previous prototype for 'woal_setget_priv_httxcfg' [-Wmissing-prototypes]
760 | int woal_setget_priv_httxcfg(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:859:5: warning: no previous prototype for 'woal_setget_priv_htcapinfo' [-Wmissing-prototypes]
859 | int woal_setget_priv_htcapinfo(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:961:5: warning: no previous prototype for 'woal_setget_priv_addbapara' [-Wmissing-prototypes]
961 | int woal_setget_priv_addbapara(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1067:5: warning: no previous prototype for 'woal_priv_delba' [-Wmissing-prototypes]
1067 | int woal_priv_delba(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1163:5: warning: no previous prototype for 'woal_priv_rejectaddbareq' [-Wmissing-prototypes]
1163 | int woal_priv_rejectaddbareq(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1243:13: warning: no previous prototype for 'woal_ioctl_addba_reject' [-Wmissing-prototypes]
1243 | mlan_status woal_ioctl_addba_reject(moal_private *priv, t_u32 action,
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1344:13: warning: no previous prototype for 'woal_ioctl_addba_param' [-Wmissing-prototypes]
1344 | mlan_status woal_ioctl_addba_param(moal_private *priv, t_u32 action,
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1393:5: warning: no previous prototype for 'woal_set_rx_ba_winsize' [-Wmissing-prototypes]
1393 | int woal_set_rx_ba_winsize(moal_private *priv, t_u8 *respbuf, int respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1472:5: warning: no previous prototype for 'woal_set_tx_ba_winsize' [-Wmissing-prototypes]
1472 | int woal_set_tx_ba_winsize(moal_private *priv, t_u8 *respbuf, int respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1557:5: warning: no previous prototype for 'woal_setget_priv_aggrpriotbl' [-Wmissing-prototypes]
1557 | int woal_setget_priv_aggrpriotbl(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1645:5: warning: no previous prototype for 'woal_setget_priv_addbareject' [-Wmissing-prototypes]
1645 | int woal_setget_priv_addbareject(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1728:5: warning: no previous prototype for 'woal_setget_priv_vhtcfg' [-Wmissing-prototypes]
1728 | int woal_setget_priv_vhtcfg(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1883:5: warning: no previous prototype for 'woal_setget_priv_opermodecfg' [-Wmissing-prototypes]
1883 | int woal_setget_priv_opermodecfg(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:1966:5: warning: no previous prototype for 'woal_get_priv_datarate' [-Wmissing-prototypes]
1966 | int woal_get_priv_datarate(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2016:5: warning: no previous prototype for 'woal_setget_priv_txratecfg' [-Wmissing-prototypes]
2016 | int woal_setget_priv_txratecfg(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c: In function 'woal_get_stats_info':
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2229:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
2229 | int ret = 0;
| ^~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c: At top level:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2281:5: warning: no previous prototype for 'woal_get_priv_getlog' [-Wmissing-prototypes]
2281 | int woal_get_priv_getlog(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2321:5: warning: no previous prototype for 'woal_setget_priv_esuppmode' [-Wmissing-prototypes]
2321 | int woal_setget_priv_esuppmode(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2411:5: warning: no previous prototype for 'woal_setget_priv_passphrase' [-Wmissing-prototypes]
2411 | int woal_setget_priv_passphrase(moal_private *priv, t_u8 *respbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2616:5: warning: no previous prototype for 'woal_priv_deauth' [-Wmissing-prototypes]
2616 | int woal_priv_deauth(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2833:5: warning: no previous prototype for 'woal_priv_bssrole' [-Wmissing-prototypes]
2833 | int woal_priv_bssrole(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2914:5: warning: no previous prototype for 'woal_priv_setuserscan' [-Wmissing-prototypes]
2914 | int woal_priv_setuserscan(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2948:5: warning: no previous prototype for 'woal_priv_get_chanstats' [-Wmissing-prototypes]
2948 | int woal_priv_get_chanstats(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:2988:5: warning: no previous prototype for 'moal_ret_get_scan_table_ioctl' [-Wmissing-prototypes]
2988 | int moal_ret_get_scan_table_ioctl(t_u8 *respbuf, t_u32 respbuflen,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:3065:5: warning: no previous prototype for 'woal_priv_getscantable' [-Wmissing-prototypes]
3065 | int woal_priv_getscantable(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_eth_ioctl.c:3126:5: warning: no previous prototype for 'woal_priv_extcapcfg' [-Wmissing-prototypes]
3126 | int woal_priv_extcapcfg(moal_private *priv, t_u8 *respbuf, t_u32 respbuflen)
| ^~~~~~~~~~~~~~~~~~~
--
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:31:
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h:133:20: error: array type has incomplete element type 'struct msix_entry'
133 | struct msix_entry msix_entries[PCIE_NUM_MSIX_VECTORS];
| ^~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:394:5: warning: no previous prototype for 'woal_pcie_probe' [-Wmissing-prototypes]
394 | int woal_pcie_probe(struct pci_dev *pdev, const struct pci_device_id *id)
| ^~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c: In function 'woal_pcie_probe':
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:441:6: error: implicit declaration of function 'pci_is_enabled'; did you mean 'pci_acs_enabled'? [-Werror=implicit-function-declaration]
441 | if (pci_is_enabled(pdev))
| ^~~~~~~~~~~~~~
| pci_acs_enabled
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c: At top level:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:896:13: warning: no previous prototype for 'woal_pcie_write_data_sync' [-Wmissing-prototypes]
896 | mlan_status woal_pcie_write_data_sync(moal_handle *handle, mlan_buffer *pmbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:912:13: warning: no previous prototype for 'woal_pcie_read_data_sync' [-Wmissing-prototypes]
912 | mlan_status woal_pcie_read_data_sync(moal_handle *handle, mlan_buffer *pmbuf,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c: In function 'woal_pcie_init':
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1089:8: error: implicit declaration of function 'pci_request_region'; did you mean 'pci_request_regions'? [-Werror=implicit-function-declaration]
1089 | ret = pci_request_region(pdev, 0, DRV_NAME);
| ^~~~~~~~~~~~~~~~~~
| pci_request_regions
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1094:19: error: implicit declaration of function 'pci_iomap'; did you mean 'pcim_iomap'? [-Werror=implicit-function-declaration]
1094 | card->pci_mmap = pci_iomap(pdev, 0, 0);
| ^~~~~~~~~
| pcim_iomap
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1094:17: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
1094 | card->pci_mmap = pci_iomap(pdev, 0, 0);
| ^
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1104:18: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
1104 | card->pci_mmap1 = pci_iomap(pdev, 2, 0);
| ^
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1118:2: error: implicit declaration of function 'pci_release_region'; did you mean 'pci_release_regions'? [-Werror=implicit-function-declaration]
1118 | pci_release_region(pdev, 2);
| ^~~~~~~~~~~~~~~~~~
| pci_release_regions
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1120:2: error: implicit declaration of function 'pci_iounmap'; did you mean 'pcim_iounmap'? [-Werror=implicit-function-declaration]
1120 | pci_iounmap(pdev, card->pci_mmap);
| ^~~~~~~~~~~
| pcim_iounmap
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c: In function 'woal_pcie_register_dev':
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1174:9: error: implicit declaration of function 'pci_enable_msix_exact' [-Werror=implicit-function-declaration]
1174 | ret = pci_enable_msix_exact(pdev, card->msix_entries, nvec);
| ^~~~~~~~~~~~~~~~~~~~~
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1197:6: error: implicit declaration of function 'pci_disable_msix'; did you mean 'pci_disable_sriov'? [-Werror=implicit-function-declaration]
1197 | pci_disable_msix(pdev);
| ^~~~~~~~~~~~~~~~
| pci_disable_sriov
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1209:9: error: implicit declaration of function 'pci_enable_msi'; did you mean 'pci_enable_ats'? [-Werror=implicit-function-declaration]
1209 | ret = pci_enable_msi(pdev);
| ^~~~~~~~~~~~~~
| pci_enable_ats
>> drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1216:5: error: implicit declaration of function 'pci_disable_msi'; did you mean 'pci_disable_ats'? [-Werror=implicit-function-declaration]
1216 | pci_disable_msi(pdev);
| ^~~~~~~~~~~~~~~
| pci_disable_ats
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c: At top level:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1418:5: warning: no previous prototype for 'woal_pcie_dump_reg_info' [-Wmissing-prototypes]
1418 | int woal_pcie_dump_reg_info(moal_handle *phandle, t_u8 *buffer)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1752:13: warning: no previous prototype for 'woal_read_reg_eight_bit' [-Wmissing-prototypes]
1752 | mlan_status woal_read_reg_eight_bit(moal_handle *handle, t_u32 reg, t_u8 *data)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:1767:13: warning: no previous prototype for 'woal_pcie_rdwr_firmware' [-Wmissing-prototypes]
1767 | rdwr_status woal_pcie_rdwr_firmware(moal_handle *phandle, t_u8 doneflag)
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:2013:6: warning: no previous prototype for 'woal_pcie_dump_fw_info_v2' [-Wmissing-prototypes]
2013 | void woal_pcie_dump_fw_info_v2(moal_handle *phandle)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:2192:6: warning: no previous prototype for 'woal_pcie_dump_fw_info' [-Wmissing-prototypes]
2192 | void woal_pcie_dump_fw_info(moal_handle *phandle)
| ^~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_main.h:130,
from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h:62,
from drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.c:31:
drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_priv.h:282:34: warning: 'woal_private_args' defined but not used [-Wunused-const-variable=]
282 | static const struct iw_priv_args woal_private_args[] = {
| ^~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +133 drivers/net/wireless/nxp/mxm_wifiex/wlan_src/mlinux/moal_pcie.h
688b67b2c7220b Fugang Duan 2020-04-19 121
688b67b2c7220b Fugang Duan 2020-04-19 122 /** Structure: PCIE service card */
688b67b2c7220b Fugang Duan 2020-04-19 123 typedef struct _pcie_service_card {
688b67b2c7220b Fugang Duan 2020-04-19 124 /** pci_dev structure pointer */
688b67b2c7220b Fugang Duan 2020-04-19 125 struct pci_dev *dev;
688b67b2c7220b Fugang Duan 2020-04-19 126 /** moal_handle structure pointer */
688b67b2c7220b Fugang Duan 2020-04-19 127 moal_handle *handle;
688b67b2c7220b Fugang Duan 2020-04-19 128 /** I/O memory regions pointer to the bus */
688b67b2c7220b Fugang Duan 2020-04-19 129 void __iomem *pci_mmap;
688b67b2c7220b Fugang Duan 2020-04-19 130 /** I/O memory regions pointer to the bus */
688b67b2c7220b Fugang Duan 2020-04-19 131 void __iomem *pci_mmap1;
688b67b2c7220b Fugang Duan 2020-04-19 132 #if defined(PCIE)
688b67b2c7220b Fugang Duan 2020-04-19 @133 struct msix_entry msix_entries[PCIE_NUM_MSIX_VECTORS];
688b67b2c7220b Fugang Duan 2020-04-19 134 msix_context msix_contexts[PCIE_NUM_MSIX_VECTORS];
688b67b2c7220b Fugang Duan 2020-04-19 135 #endif
688b67b2c7220b Fugang Duan 2020-04-19 136 } pcie_service_card, *ppcie_service_card;
688b67b2c7220b Fugang Duan 2020-04-19 137
:::::: The code at line 133 was first introduced by commit
:::::: 688b67b2c7220b01521ffe560da7eee33042c7bd MLK-23806-01 net: wireless: nxp: mxm_wifiex: add initial MxM wifi driver
:::::: TO: Fugang Duan <fugang.duan(a)nxp.com>
:::::: CC: Fugang Duan <fugang.duan(a)nxp.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [PATCH 11/51] ALSA: bt87x: Allocate resources with device-managed APIs
by kernel test robot
Hi Takashi,
I love your patch! Perhaps something to improve:
[auto build test WARNING on sound/for-next]
[also build test WARNING on v5.14-rc1 next-20210713]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Takashi-Iwai/ALSA-More-devres-us...
base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
config: arm64-buildonly-randconfig-r003-20210713 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 8d69635ed9ecf36fd0ca85906bfde17949671cbe)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://github.com/0day-ci/linux/commit/5a2db1e1f5fcf4283a42d5a93a10436ef...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Takashi-Iwai/ALSA-More-devres-usages/20210713-225131
git checkout 5a2db1e1f5fcf4283a42d5a93a10436ef67e2829
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> sound/pci/bt87x.c:841:10: warning: variable 'chip' is uninitialized when used here [-Wuninitialized]
memcpy(&chip->board, &snd_bt87x_boards[boardid], sizeof(chip->board));
^~~~
sound/pci/bt87x.c:813:24: note: initialize the variable 'chip' to silence this warning
struct snd_bt87x *chip;
^
= NULL
1 warning generated.
vim +/chip +841 sound/pci/bt87x.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 807
3dd0676335f846 Bill Pemberton 2012-12-06 808 static int snd_bt87x_probe(struct pci_dev *pci,
^1da177e4c3f41 Linus Torvalds 2005-04-16 809 const struct pci_device_id *pci_id)
^1da177e4c3f41 Linus Torvalds 2005-04-16 810 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 811 static int dev;
9f362dce9d6315 Takashi Iwai 2005-11-17 812 struct snd_card *card;
9f362dce9d6315 Takashi Iwai 2005-11-17 813 struct snd_bt87x *chip;
dcfb4140328eed Trent Piepho 2007-09-06 814 int err;
dcfb4140328eed Trent Piepho 2007-09-06 815 enum snd_bt87x_boardid boardid;
^1da177e4c3f41 Linus Torvalds 2005-04-16 816
dcfb4140328eed Trent Piepho 2007-09-06 817 if (!pci_id->driver_data) {
dcfb4140328eed Trent Piepho 2007-09-06 818 err = snd_bt87x_detect_card(pci);
dcfb4140328eed Trent Piepho 2007-09-06 819 if (err < 0)
^1da177e4c3f41 Linus Torvalds 2005-04-16 820 return -ENODEV;
dcfb4140328eed Trent Piepho 2007-09-06 821 boardid = err;
dcfb4140328eed Trent Piepho 2007-09-06 822 } else
dcfb4140328eed Trent Piepho 2007-09-06 823 boardid = pci_id->driver_data;
^1da177e4c3f41 Linus Torvalds 2005-04-16 824
^1da177e4c3f41 Linus Torvalds 2005-04-16 825 if (dev >= SNDRV_CARDS)
^1da177e4c3f41 Linus Torvalds 2005-04-16 826 return -ENODEV;
^1da177e4c3f41 Linus Torvalds 2005-04-16 827 if (!enable[dev]) {
^1da177e4c3f41 Linus Torvalds 2005-04-16 828 ++dev;
^1da177e4c3f41 Linus Torvalds 2005-04-16 829 return -ENOENT;
^1da177e4c3f41 Linus Torvalds 2005-04-16 830 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 831
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 832 err = snd_devm_card_new(&pci->dev, index[dev], id[dev], THIS_MODULE,
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 833 sizeof(*chip), &card);
e58de7baf7de11 Takashi Iwai 2008-12-28 834 if (err < 0)
e58de7baf7de11 Takashi Iwai 2008-12-28 835 return err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 836
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 837 err = snd_bt87x_create(card, pci);
^1da177e4c3f41 Linus Torvalds 2005-04-16 838 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 839 return err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 840
dcfb4140328eed Trent Piepho 2007-09-06 @841 memcpy(&chip->board, &snd_bt87x_boards[boardid], sizeof(chip->board));
dcfb4140328eed Trent Piepho 2007-09-06 842
dcfb4140328eed Trent Piepho 2007-09-06 843 if (!chip->board.no_digital) {
^1da177e4c3f41 Linus Torvalds 2005-04-16 844 if (digital_rate[dev] > 0)
dcfb4140328eed Trent Piepho 2007-09-06 845 chip->board.dig_rate = digital_rate[dev];
dcfb4140328eed Trent Piepho 2007-09-06 846
dcfb4140328eed Trent Piepho 2007-09-06 847 chip->reg_control |= chip->board.digital_fmt;
^1da177e4c3f41 Linus Torvalds 2005-04-16 848
^1da177e4c3f41 Linus Torvalds 2005-04-16 849 err = snd_bt87x_pcm(chip, DEVICE_DIGITAL, "Bt87x Digital");
^1da177e4c3f41 Linus Torvalds 2005-04-16 850 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 851 return err;
dcfb4140328eed Trent Piepho 2007-09-06 852 }
dcfb4140328eed Trent Piepho 2007-09-06 853 if (!chip->board.no_analog) {
^1da177e4c3f41 Linus Torvalds 2005-04-16 854 err = snd_bt87x_pcm(chip, DEVICE_ANALOG, "Bt87x Analog");
^1da177e4c3f41 Linus Torvalds 2005-04-16 855 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 856 return err;
dcfb4140328eed Trent Piepho 2007-09-06 857 err = snd_ctl_add(card, snd_ctl_new1(
dcfb4140328eed Trent Piepho 2007-09-06 858 &snd_bt87x_capture_volume, chip));
^1da177e4c3f41 Linus Torvalds 2005-04-16 859 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 860 return err;
dcfb4140328eed Trent Piepho 2007-09-06 861 err = snd_ctl_add(card, snd_ctl_new1(
dcfb4140328eed Trent Piepho 2007-09-06 862 &snd_bt87x_capture_boost, chip));
^1da177e4c3f41 Linus Torvalds 2005-04-16 863 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 864 return err;
dcfb4140328eed Trent Piepho 2007-09-06 865 err = snd_ctl_add(card, snd_ctl_new1(
dcfb4140328eed Trent Piepho 2007-09-06 866 &snd_bt87x_capture_source, chip));
^1da177e4c3f41 Linus Torvalds 2005-04-16 867 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 868 return err;
dcfb4140328eed Trent Piepho 2007-09-06 869 }
02c33520b35fe7 Takashi Iwai 2014-02-25 870 dev_info(card->dev, "bt87x%d: Using board %d, %sanalog, %sdigital "
dcfb4140328eed Trent Piepho 2007-09-06 871 "(rate %d Hz)\n", dev, boardid,
dcfb4140328eed Trent Piepho 2007-09-06 872 chip->board.no_analog ? "no " : "",
dcfb4140328eed Trent Piepho 2007-09-06 873 chip->board.no_digital ? "no " : "", chip->board.dig_rate);
^1da177e4c3f41 Linus Torvalds 2005-04-16 874
^1da177e4c3f41 Linus Torvalds 2005-04-16 875 strcpy(card->driver, "Bt87x");
^1da177e4c3f41 Linus Torvalds 2005-04-16 876 sprintf(card->shortname, "Brooktree Bt%x", pci->device);
aa0a2ddc54fa8a Greg Kroah-Hartman 2006-06-12 877 sprintf(card->longname, "%s at %#llx, irq %i",
aa0a2ddc54fa8a Greg Kroah-Hartman 2006-06-12 878 card->shortname, (unsigned long long)pci_resource_start(pci, 0),
aa0a2ddc54fa8a Greg Kroah-Hartman 2006-06-12 879 chip->irq);
^1da177e4c3f41 Linus Torvalds 2005-04-16 880 strcpy(card->mixername, "Bt87x");
^1da177e4c3f41 Linus Torvalds 2005-04-16 881
^1da177e4c3f41 Linus Torvalds 2005-04-16 882 err = snd_card_register(card);
^1da177e4c3f41 Linus Torvalds 2005-04-16 883 if (err < 0)
5a2db1e1f5fcf4 Takashi Iwai 2021-07-13 884 return err;
^1da177e4c3f41 Linus Torvalds 2005-04-16 885
^1da177e4c3f41 Linus Torvalds 2005-04-16 886 pci_set_drvdata(pci, card);
^1da177e4c3f41 Linus Torvalds 2005-04-16 887 ++dev;
^1da177e4c3f41 Linus Torvalds 2005-04-16 888 return 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 889 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 890
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [PATCH] RDMA/rxe: Bump up default maximum values used via uverbs
by kernel test robot
Hi Rao,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on rdma/for-next]
[also build test WARNING on v5.14-rc1 next-20210713]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Rao-Shoaib/RDMA-rxe-Bump-up-defa...
base: https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git for-next
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://github.com/0day-ci/linux/commit/823f0c9f1aff85ad2abeed713bf89fad2...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Rao-Shoaib/RDMA-rxe-Bump-up-default-maximum-values-used-via-uverbs/20210713-163821
git checkout 823f0c9f1aff85ad2abeed713bf89fad22254f24
# save the attached .config to linux build tree
make W=1 ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/infiniband/sw/rxe/rxe.c: In function 'rxe_init_device_param':
>> drivers/infiniband/sw/rxe/rxe.c:71:26: warning: unsigned conversion from 'int' to 'u16' {aka 'short unsigned int'} changes value from '1048576' to '0' [-Woverflow]
71 | rxe->attr.max_pkeys = RXE_MAX_PKEYS;
| ^~~~~~~~~~~~~
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for PHY_SPARX5_SERDES
Depends on (ARCH_SPARX5 || COMPILE_TEST && OF && HAS_IOMEM
Selected by
- SPARX5_SWITCH && NETDEVICES && ETHERNET && NET_VENDOR_MICROCHIP && NET_SWITCHDEV && HAS_IOMEM
vim +71 drivers/infiniband/sw/rxe/rxe.c
8700e3e7c4857d Moni Shoua 2016-06-16 39
8700e3e7c4857d Moni Shoua 2016-06-16 40 /* initialize rxe device parameters */
befd8d98f230d9 Zhu Yanjun 2018-03-07 41 static void rxe_init_device_param(struct rxe_dev *rxe)
8700e3e7c4857d Moni Shoua 2016-06-16 42 {
8700e3e7c4857d Moni Shoua 2016-06-16 43 rxe->max_inline_data = RXE_MAX_INLINE_DATA;
8700e3e7c4857d Moni Shoua 2016-06-16 44
0184afd15a141d Zhu Yanjun 2020-04-06 45 rxe->attr.vendor_id = RXE_VENDOR_ID;
8700e3e7c4857d Moni Shoua 2016-06-16 46 rxe->attr.max_mr_size = RXE_MAX_MR_SIZE;
8700e3e7c4857d Moni Shoua 2016-06-16 47 rxe->attr.page_size_cap = RXE_PAGE_SIZE_CAP;
8700e3e7c4857d Moni Shoua 2016-06-16 48 rxe->attr.max_qp = RXE_MAX_QP;
8700e3e7c4857d Moni Shoua 2016-06-16 49 rxe->attr.max_qp_wr = RXE_MAX_QP_WR;
8700e3e7c4857d Moni Shoua 2016-06-16 50 rxe->attr.device_cap_flags = RXE_DEVICE_CAP_FLAGS;
33023fb85a42b5 Steve Wise 2018-06-18 51 rxe->attr.max_send_sge = RXE_MAX_SGE;
33023fb85a42b5 Steve Wise 2018-06-18 52 rxe->attr.max_recv_sge = RXE_MAX_SGE;
8700e3e7c4857d Moni Shoua 2016-06-16 53 rxe->attr.max_sge_rd = RXE_MAX_SGE_RD;
8700e3e7c4857d Moni Shoua 2016-06-16 54 rxe->attr.max_cq = RXE_MAX_CQ;
8700e3e7c4857d Moni Shoua 2016-06-16 55 rxe->attr.max_cqe = (1 << RXE_MAX_LOG_CQE) - 1;
8700e3e7c4857d Moni Shoua 2016-06-16 56 rxe->attr.max_mr = RXE_MAX_MR;
af732adfacb2c6 Bob Pearson 2021-06-07 57 rxe->attr.max_mw = RXE_MAX_MW;
8700e3e7c4857d Moni Shoua 2016-06-16 58 rxe->attr.max_pd = RXE_MAX_PD;
8700e3e7c4857d Moni Shoua 2016-06-16 59 rxe->attr.max_qp_rd_atom = RXE_MAX_QP_RD_ATOM;
8700e3e7c4857d Moni Shoua 2016-06-16 60 rxe->attr.max_res_rd_atom = RXE_MAX_RES_RD_ATOM;
8700e3e7c4857d Moni Shoua 2016-06-16 61 rxe->attr.max_qp_init_rd_atom = RXE_MAX_QP_INIT_RD_ATOM;
0797e6f1a85872 Nathan Chancellor 2018-09-26 62 rxe->attr.atomic_cap = IB_ATOMIC_HCA;
8700e3e7c4857d Moni Shoua 2016-06-16 63 rxe->attr.max_mcast_grp = RXE_MAX_MCAST_GRP;
8700e3e7c4857d Moni Shoua 2016-06-16 64 rxe->attr.max_mcast_qp_attach = RXE_MAX_MCAST_QP_ATTACH;
8700e3e7c4857d Moni Shoua 2016-06-16 65 rxe->attr.max_total_mcast_qp_attach = RXE_MAX_TOT_MCAST_QP_ATTACH;
8700e3e7c4857d Moni Shoua 2016-06-16 66 rxe->attr.max_ah = RXE_MAX_AH;
8700e3e7c4857d Moni Shoua 2016-06-16 67 rxe->attr.max_srq = RXE_MAX_SRQ;
8700e3e7c4857d Moni Shoua 2016-06-16 68 rxe->attr.max_srq_wr = RXE_MAX_SRQ_WR;
8700e3e7c4857d Moni Shoua 2016-06-16 69 rxe->attr.max_srq_sge = RXE_MAX_SRQ_SGE;
8700e3e7c4857d Moni Shoua 2016-06-16 70 rxe->attr.max_fast_reg_page_list_len = RXE_MAX_FMR_PAGE_LIST_LEN;
8700e3e7c4857d Moni Shoua 2016-06-16 @71 rxe->attr.max_pkeys = RXE_MAX_PKEYS;
8700e3e7c4857d Moni Shoua 2016-06-16 72 rxe->attr.local_ca_ack_delay = RXE_LOCAL_CA_ACK_DELAY;
d0ca2c35dd15a3 Zhu Yanjun 2020-03-23 73 addrconf_addr_eui48((unsigned char *)&rxe->attr.sys_image_guid,
d0ca2c35dd15a3 Zhu Yanjun 2020-03-23 74 rxe->ndev->dev_addr);
8700e3e7c4857d Moni Shoua 2016-06-16 75
8700e3e7c4857d Moni Shoua 2016-06-16 76 rxe->max_ucontext = RXE_MAX_UCONTEXT;
8700e3e7c4857d Moni Shoua 2016-06-16 77 }
8700e3e7c4857d Moni Shoua 2016-06-16 78
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months