public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Raed Salem <raeds@mellanox.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	Saeed Mahameed <saeedm@mellanox.com>,
	Boris Pismenny <borisp@mellanox.com>,
	Huy Nguyen <huyn@mellanox.com>
Subject: drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c:856 mlx5_fpga_ipsec_release_sa_ctx() warn: bitwise AND condition is false here
Date: Fri, 12 Mar 2021 03:34:25 +0800	[thread overview]
Message-ID: <202103120321.TVZMeLRz-lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 2145 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   a74e6a014c9d4d4161061f770c9b4f98372ac778
commit: 7dfee4b1d79e1800818abcfb47747b162c9a2d31 net/mlx5: IPsec, Refactor SA handle creation and destruction
date:   11 months ago
config: arc-randconfig-m031-20210311 (attached as .config)
compiler: arceb-elf-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

New smatch warnings:
drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c:856 mlx5_fpga_ipsec_release_sa_ctx() warn: bitwise AND condition is false here

Old smatch warnings:
drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c:711 mlx5_fpga_ipsec_create_sa_ctx() warn: bitwise AND condition is false here
drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c:762 mlx5_fpga_ipsec_create_sa_ctx() warn: bitwise AND condition is false here
arch/arc/include/asm/thread_info.h:65 current_thread_info() error: uninitialized symbol 'sp'.

vim +856 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c

   837	
   838	static void
   839	mlx5_fpga_ipsec_release_sa_ctx(struct mlx5_fpga_ipsec_sa_ctx *sa_ctx)
   840	{
   841		struct mlx5_fpga_device *fdev = sa_ctx->dev->fpga;
   842		struct mlx5_fpga_ipsec *fipsec = fdev->ipsec;
   843		int opcode = is_v2_sadb_supported(fdev->ipsec) ?
   844				MLX5_FPGA_IPSEC_CMD_OP_DEL_SA_V2 :
   845				MLX5_FPGA_IPSEC_CMD_OP_DEL_SA;
   846		int err;
   847	
   848		err = mlx5_fpga_ipsec_update_hw_sa(fdev, &sa_ctx->hw_sa, opcode);
   849		sa_ctx->hw_sa.ipsec_sa_v1.cmd = 0;
   850		if (err) {
   851			WARN_ON(err);
   852			return;
   853		}
   854	
   855		if (sa_ctx->fpga_xfrm->accel_xfrm.attrs.action &
 > 856		    MLX5_ACCEL_ESP_ACTION_DECRYPT)
   857			ida_simple_remove(&fipsec->halloc, sa_ctx->sa_handle);
   858	
   859		mutex_lock(&fipsec->sa_hash_lock);
   860		WARN_ON(rhashtable_remove_fast(&fipsec->sa_hash, &sa_ctx->hash,
   861					       rhash_sa));
   862		mutex_unlock(&fipsec->sa_hash_lock);
   863	}
   864	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 27839 bytes --]

                 reply	other threads:[~2021-03-11 19:36 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202103120321.TVZMeLRz-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=borisp@mellanox.com \
    --cc=huyn@mellanox.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=raeds@mellanox.com \
    --cc=saeedm@mellanox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox