Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp451898pxb; Thu, 9 Sep 2021 04:56:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJydiyNuDOmGk2RA+OEzf7GyH+eXlv5SoitgdbyekZaT4dUPnTxgCxlBYMXvG6rOZPbb16CH X-Received: by 2002:a05:6402:5188:: with SMTP id q8mr2716536edd.138.1631188562536; Thu, 09 Sep 2021 04:56:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631188562; cv=none; d=google.com; s=arc-20160816; b=lLhzEbp/aRVpbWkWaD0ms213rvgkSX2eNPPphGBmYcs9dqqLQlrPIQ7eDyjhhcFvkd y1wzehNdP+zn//uNOOWtYgd2DYGn/LqemTgoJFpFq4HHM8NwmvaGCqCLQkJTQtf6iLvR 8T2uh5EHVj+sgOhGJ0fnAIvSR19gZgPMZ3DPNyTAiMQqP4ybyXrcPoDluX+vgb7fgQlQ Vaa4w6/yiTNRYDNFyDYzTHwHE3kNcDBZXsfFN+HMlL4NTdXPbNw5MkbLErliqGyzupxG SFxIotHqreQpSyN31y5BWMOuhgPlI/lntmkUUqe9fHyKcBIXn3i82qY0rQQulEic75oq +eTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=09qUc6WuwStcCvWtd5vEtYVbM5xLVo1Q/dO3mAcv//I=; b=X/iGTg0f6qIC64d7Cxxh1wjbz7k6QbZaPpVYTcQ9raDu2dFbH8GA5tFuTurg21Sf8U 9V7gCLYxtucqWYTayELSUawAILUzLUyuQdy0d7wgLOTzR2KDMy0gMMKZvOCD37ew2V9/ 9hMfOrslrncthW89v5q+N0bzRwaGDOgTKw/RXkDlbJf5+bHzELcRWeBSIA0TCFtvtvF3 ngDqHglFoqLRe1IPoWyzW+sJfae68pm8TvDOolR5SSWngl6c8BdpLf/3REDEPTvhKJ6/ Co8ph2fDEBnfgLzGBw+6H2ulmY6H74BMfq3leTFuVXexVuCQsuiws1rZX6C54oo9FP8S Rx/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ap9PZr4V; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id nc1si1837939ejc.377.2021.09.09.04.55.38; Thu, 09 Sep 2021 04:56:02 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ap9PZr4V; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343633AbhIILzU (ORCPT + 99 others); Thu, 9 Sep 2021 07:55:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:54736 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240211AbhIILwJ (ORCPT ); Thu, 9 Sep 2021 07:52:09 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id AFC5D6135D; Thu, 9 Sep 2021 11:44:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1631187857; bh=sYydYxRyDsnWxhv0ACQkOPeeGjMFpExS/qG7QDvFyBU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ap9PZr4V66Bsa3yqBKUUwQixqUBhBR2yt+Vx3+4BUwm9K8phxW5cgvTtG6zBfILpq j//h5NTgBU102DkSE6fLxsoinEmsnSfYEqTkrPsumIQp0EjVsVawoIsflU2QVQXGUI 1AL9Mk6PYh9jaZqUv5XKT47uN346rMGNesri+sWokVEoegJst2lm9RQ/11e5T9k1e3 nnI0Tv9S8t0wL5QReUgsXohGvMdmiQh9YpIQzEF+ljs3ScFN7dheiGkXlmSBQMXVsh Uhlo4fqzmPi9oNuo1DLx5ChW94D8/KEsybxEkkmoFxRpAaN4nEtUdMEztL+qRsgP58 wcffXeAyPngDw== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Eran Ben Elisha , kernel test robot , Dan Carpenter , Moshe Shemesh , Saeed Mahameed , Sasha Levin , netdev@vger.kernel.org, linux-rdma@vger.kernel.org Subject: [PATCH AUTOSEL 5.14 146/252] net/mlx5: Fix variable type to match 64bit Date: Thu, 9 Sep 2021 07:39:20 -0400 Message-Id: <20210909114106.141462-146-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210909114106.141462-1-sashal@kernel.org> References: <20210909114106.141462-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eran Ben Elisha [ Upstream commit 979aa51967add26b37f9d77e01729d44a2da8e5f ] Fix the following smatch warning: wait_func_handle_exec_timeout() warn: should '1 << ent->idx' be a 64 bit type? Use 1ULL, to have a 64 bit type variable. Reported-by: kernel test robot Reported-by: Dan Carpenter Signed-off-by: Eran Ben Elisha Reviewed-by: Moshe Shemesh Signed-off-by: Saeed Mahameed Signed-off-by: Sasha Levin --- drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/cmd.c b/drivers/net/ethernet/mellanox/mlx5/core/cmd.c index 9d79c5ec31e9..db5dfff585c9 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/cmd.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/cmd.c @@ -877,7 +877,7 @@ static void cb_timeout_handler(struct work_struct *work) ent->ret = -ETIMEDOUT; mlx5_core_warn(dev, "cmd[%d]: %s(0x%x) Async, timeout. Will cause a leak of a command resource\n", ent->idx, mlx5_command_str(msg_to_opcode(ent->in)), msg_to_opcode(ent->in)); - mlx5_cmd_comp_handler(dev, 1UL << ent->idx, true); + mlx5_cmd_comp_handler(dev, 1ULL << ent->idx, true); out: cmd_ent_put(ent); /* for the cmd_ent_get() took on schedule delayed work */ @@ -994,7 +994,7 @@ static void cmd_work_handler(struct work_struct *work) MLX5_SET(mbox_out, ent->out, status, status); MLX5_SET(mbox_out, ent->out, syndrome, drv_synd); - mlx5_cmd_comp_handler(dev, 1UL << ent->idx, true); + mlx5_cmd_comp_handler(dev, 1ULL << ent->idx, true); return; } @@ -1008,7 +1008,7 @@ static void cmd_work_handler(struct work_struct *work) poll_timeout(ent); /* make sure we read the descriptor after ownership is SW */ rmb(); - mlx5_cmd_comp_handler(dev, 1UL << ent->idx, (ent->ret == -ETIMEDOUT)); + mlx5_cmd_comp_handler(dev, 1ULL << ent->idx, (ent->ret == -ETIMEDOUT)); } } @@ -1068,7 +1068,7 @@ static void wait_func_handle_exec_timeout(struct mlx5_core_dev *dev, mlx5_command_str(msg_to_opcode(ent->in)), msg_to_opcode(ent->in)); ent->ret = -ETIMEDOUT; - mlx5_cmd_comp_handler(dev, 1UL << ent->idx, true); + mlx5_cmd_comp_handler(dev, 1ULL << ent->idx, true); } static int wait_func(struct mlx5_core_dev *dev, struct mlx5_cmd_work_ent *ent) -- 2.30.2