Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1256721rdb; Mon, 19 Feb 2024 09:01:08 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCU+GPc/8E1D3gLEjGQw7WV4Il5wWeMywIAXA/PsCChneCwwMND9u0Pa90vA6j0MfHS+ysEP1wwt6tMr5BYY1KHVYCqLgYAUXtfbwipo+g== X-Google-Smtp-Source: AGHT+IHyEC4LDzRqFfZGPTcPizjQbSljqk6oSrqHvSDFYMa9uTgDHdJGIIZNs6I404H6C8PQ3/He X-Received: by 2002:a17:902:c949:b0:1db:d13e:2708 with SMTP id i9-20020a170902c94900b001dbd13e2708mr6661942pla.14.1708362068514; Mon, 19 Feb 2024 09:01:08 -0800 (PST) Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id q197-20020a632ace000000b005dc8ccd36d9si14881pgq.250.2024.02.19.09.01.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Feb 2024 09:01:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-71722-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@kernel.org header.s=k20201202 header.b=F5grmsz4; arc=fail (body hash mismatch); spf=pass (google.com: domain of linux-kernel+bounces-71722-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-71722-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 52004286248 for ; Mon, 19 Feb 2024 17:00:57 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 97E86446C1; Mon, 19 Feb 2024 17:00:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="F5grmsz4" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B709D44388; Mon, 19 Feb 2024 17:00:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708362043; cv=none; b=XiR3q7k5mez2ykKYF+/NF4T31CGHfpFSLBNowKrbRZ2LDWRa86KMI5lG41EaifaLAyd02V4mu345wvV9kw/YW8klIVeVZHyYel62VyUXywUoukdUNonfYn+jiSk9m97IiXVlxDM+F/+PjnA7DdrUlVjeDE/NQDvQkfUsAU3gHEA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708362043; c=relaxed/simple; bh=XPPEt6wCtblH7LoSRYodT/mgjuR30D08tbYVNR6SbwQ=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=gCjh62BZ6vTXG7SlF/Q7IRIUSEO9bDLz3jBaBWePNI5pxNOIOVRsyKhiA2HbkceYjQEmOsnHrmuu+cT+IZqVeIPlFe5U+yTtyzHjx2NerJdUcajbF9EWQuIMasrxCQ1NJn9kCYDkwtE9Ixx22q1D9mEBVAxFmkQO58AeyYmyuxg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=F5grmsz4; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0EA21C433F1; Mon, 19 Feb 2024 17:00:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1708362043; bh=XPPEt6wCtblH7LoSRYodT/mgjuR30D08tbYVNR6SbwQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=F5grmsz4Yqu3H+DNp3b4VFSbkNje/wxgHQfyroU3XauDb5My9vZWR7kRhX1YM8RXv u4IeOeWPw9mnGnOqKIwUuz4Qb7Zcv9CUQzrJ20JJh7Rc89Xpf6xdgtcGMlvEa5BXW0 aR8thf991KLEUKzTEg/gCo//DKZpRCng+1+6EUxTdGem4+jIyySUVtDa3TLE1hrhsV s3HyrKb+lS8ddbsRgvRUX7r5torKsMu5hjhnlEkYfunbJ9qPmgLwX4s6earMm85Uu3 bO1IAzoSyoawecfmvM3/asqxJrKqBP85mykK49YH6WSstCu8LbXavXWQLvpEoUfWvf Q5GT21b3xKpeA== Date: Mon, 19 Feb 2024 17:00:38 +0000 From: Simon Horman To: Oliver Hartkopp Cc: Daniil Dulov , Wolfgang Grandegger , Marc Kleine-Budde , "David S. Miller" , Jakub Kicinski , Kurt Van Dijck , linux-can@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, lvc-project@linuxtesting.org Subject: Re: [PATCH] can: softing: remove redundant NULL check Message-ID: <20240219170038.GH40273@kernel.org> References: <20240211150535.3529-1-d.dulov@aladdin.ru> <20240216172701.GP40273@kernel.org> <12cd0fd0-be86-4af0-8d6b-85d3a81edd2a@hartkopp.net> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <12cd0fd0-be86-4af0-8d6b-85d3a81edd2a@hartkopp.net> On Fri, Feb 16, 2024 at 08:47:43PM +0100, Oliver Hartkopp wrote: > Hi Simon, > > I have a general question on the "Fixes:" tag in this patch: > > On 16.02.24 18:27, Simon Horman wrote: > > On Sun, Feb 11, 2024 at 07:05:35AM -0800, Daniil Dulov wrote: > > > In this case dev cannot be NULL, so remove redundant check. > > > > > > Found by Linux Verification Center (linuxtesting.org) with SVACE. > > > > > > Fixes: 03fd3cf5a179 ("can: add driver for Softing card") > > IMHO this is simply an improvement which is done by all patches applied to > the kernel but it does not really "fix" anything from a functional > standpoint. > > Shouldn't we either invent a new tag or better leave it out to not confuse > the stable maintainers? Hi Oliver, sorry for missing that in my review. Yes, I agree that this is probably not a fix, for which my rule of thumb is something that addresses a user-visible problem. So I agree it should not have a fixes tag. I would suggest that we can just change the text to something that has no tag. Something like: .. Introduced by 03fd3cf5a179 ("can: add driver for Softing card") Signed-of-by: ... > > Best regards, > Oliver > > > > Signed-off-by: Daniil Dulov > > > > Hi Daniil, > > > > I am not sure that dev cannot be NULL. > > But I do see that the code assumes it is not, and would crash if it is. > > So I think that, functionally, your statement is correct. > > > > priv = netdev_priv(dev); > > card = priv->card; > > > > Reviewed-by: Simon Horman > > >