From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jon Mason Date: Thu, 13 Jun 2019 13:26:39 +0000 Subject: Re: [PATCH] NTB: amd: Silence shift wrapping warning in amd_ntb_db_vector_mask() Message-Id: <20190613132638.GD1572@kudzu.us> List-Id: References: <20190325092326.GE16023@kadam> In-Reply-To: <20190325092326.GE16023@kadam> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: kernel-janitors@vger.kernel.org On Tue, Mar 26, 2019 at 05:46:44AM +0000, S-k, Shyam-sundar wrote: > On 3/25/2019 2:53 PM, Dan Carpenter wrote: > > This code triggers a Smatch warning: > > > > drivers/ntb/hw/amd/ntb_hw_amd.c:336 amd_ntb_db_vector_mask() > > warn: should '(1 << db_vector)' be a 64 bit type? > > > > I don't think "db_vector" can be higher than 16 so this doesn't affect > > runtime, but it's nice to silence the static checker warning and we > > might increase "ndev->db_count" in the future. > > > > Signed-off-by: Dan Carpenter > Acked-by: Shyam Sundar S K Sorry for the delay. The patch is now in the ntb branch. We've missed window for 5.2, but it will be in the 5.3 pull request. Thanks, Jon From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yb1-xb44.google.com (mail-yb1-xb44.google.com. [2607:f8b0:4864:20::b44]) by gmr-mx.google.com with ESMTPS id s128si62247pfs.5.2019.06.13.06.26.42 for (version=TLS1_3 cipher=AEAD-AES128-GCM-SHA256 bits=128/128); Thu, 13 Jun 2019 06:26:42 -0700 (PDT) Received: by mail-yb1-xb44.google.com with SMTP id g62so7817562ybg.7 for ; Thu, 13 Jun 2019 06:26:42 -0700 (PDT) Return-Path: Date: Thu, 13 Jun 2019 09:26:39 -0400 From: Jon Mason Subject: Re: [PATCH] NTB: amd: Silence shift wrapping warning in amd_ntb_db_vector_mask() Message-ID: <20190613132638.GD1572@kudzu.us> References: <20190325092326.GE16023@kadam> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: To: "S-k, Shyam-sundar" Cc: Dan Carpenter , Dave Jiang , Allen Hubbe , "linux-ntb@googlegroups.com" , "kernel-janitors@vger.kernel.org" List-ID: On Tue, Mar 26, 2019 at 05:46:44AM +0000, S-k, Shyam-sundar wrote: > On 3/25/2019 2:53 PM, Dan Carpenter wrote: > > This code triggers a Smatch warning: > > > > drivers/ntb/hw/amd/ntb_hw_amd.c:336 amd_ntb_db_vector_mask() > > warn: should '(1 << db_vector)' be a 64 bit type? > > > > I don't think "db_vector" can be higher than 16 so this doesn't affect > > runtime, but it's nice to silence the static checker warning and we > > might increase "ndev->db_count" in the future. > > > > Signed-off-by: Dan Carpenter > Acked-by: Shyam Sundar S K Sorry for the delay. The patch is now in the ntb branch. We've missed window for 5.2, but it will be in the 5.3 pull request. Thanks, Jon