From: kernel test robot <lkp@intel.com>
To: Ratheesh Kannoth <rkannoth@marvell.com>
Cc: kbuild-all@lists.01.org, netdev@vger.kernel.org
Subject: [net-next:master 5/16] drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c:388:5: warning: no previous prototype for 'rvu_exact_calculate_hash'
Date: Wed, 6 Jul 2022 18:12:54 +0800 [thread overview]
Message-ID: <202207061806.PD7mLTe7-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head: 2ef8e39f58f08589ab035223c2687830c0eba30f
commit: 017691914c115903ee513d9ca058335bb35f8bd6 [5/16] octeontx2-af: Exact match support
config: alpha-allyesconfig (https://download.01.org/0day-ci/archive/20220706/202207061806.PD7mLTe7-lkp@intel.com/config)
compiler: alpha-linux-gcc (GCC) 11.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://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git/commit/?id=017691914c115903ee513d9ca058335bb35f8bd6
git remote add net-next https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git
git fetch --no-tags net-next master
git checkout 017691914c115903ee513d9ca058335bb35f8bd6
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=alpha SHELL=/bin/bash drivers/net/ethernet/marvell/octeontx2/af/
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c:388:5: warning: no previous prototype for 'rvu_exact_calculate_hash' [-Wmissing-prototypes]
388 | u32 rvu_exact_calculate_hash(struct rvu *rvu, u16 chan, u16 ctype, u8 *mac,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c:1026:5: warning: no previous prototype for 'rvu_npc_exact_add_table_entry' [-Wmissing-prototypes]
1026 | int rvu_npc_exact_add_table_entry(struct rvu *rvu, u8 cgx_id, u8 lmac_id, u8 *mac,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c: In function 'rvu_npc_exact_add_table_entry':
>> drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c:1032:33: warning: variable 'table' set but not used [-Wunused-but-set-variable]
1032 | struct npc_exact_table *table;
| ^~~~~
drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c: At top level:
drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c:1084:5: warning: no previous prototype for 'rvu_npc_exact_update_table_entry' [-Wmissing-prototypes]
1084 | int rvu_npc_exact_update_table_entry(struct rvu *rvu, u8 cgx_id, u8 lmac_id,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/rvu_exact_calculate_hash +388 drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c
378
379 /**
380 * rvu_exact_calculate_hash - calculate hash index to mem table.
381 * @rvu: resource virtualization unit.
382 * @chan: Channel number
383 * @ctype: Channel type.
384 * @mac: MAC address
385 * @mask: HASH mask.
386 * @table_depth: Depth of table.
387 */
> 388 u32 rvu_exact_calculate_hash(struct rvu *rvu, u16 chan, u16 ctype, u8 *mac,
389 u64 mask, u32 table_depth)
390 {
391 struct npc_exact_table *table = rvu->hw->table;
392 u64 hash_key[2];
393 u64 key_in[2];
394 u64 ldata;
395 u32 hash;
396
397 key_in[0] = RVU_NPC_HASH_SECRET_KEY0;
398 key_in[1] = RVU_NPC_HASH_SECRET_KEY2;
399
400 hash_key[0] = key_in[0] << 31;
401 hash_key[0] |= key_in[1];
402 hash_key[1] = key_in[0] >> 33;
403
404 ldata = rvu_exact_prepare_mdata(mac, chan, ctype, mask);
405
406 dev_dbg(rvu->dev, "%s: ldata=0x%llx hash_key0=0x%llx hash_key2=0x%llx\n", __func__,
407 ldata, hash_key[1], hash_key[0]);
408 hash = rvu_npc_toeplitz_hash(&ldata, (u64 *)hash_key, 64, 95);
409
410 hash &= table->mem_table.hash_mask;
411 hash += table->mem_table.hash_offset;
412 dev_dbg(rvu->dev, "%s: hash=%x\n", __func__, hash);
413
414 return hash;
415 }
416
--
0-DAY CI Kernel Test Service
https://01.org/lkp
next reply other threads:[~2022-07-06 10:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-06 10:12 kernel test robot [this message]
2022-07-06 13:09 ` [EXT] [net-next:master 5/16] drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_hash.c:388:5: warning: no previous prototype for 'rvu_exact_calculate_hash' Ratheesh Kannoth
2022-07-06 13:09 ` Ratheesh Kannoth
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202207061806.PD7mLTe7-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
--cc=netdev@vger.kernel.org \
--cc=rkannoth@marvell.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is 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.