From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5A5E3C4332F for ; Fri, 23 Dec 2022 16:42:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231839AbiLWQmi (ORCPT ); Fri, 23 Dec 2022 11:42:38 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51226 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230468AbiLWQmd (ORCPT ); Fri, 23 Dec 2022 11:42:33 -0500 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 56FF4631E for ; Fri, 23 Dec 2022 08:42:33 -0800 (PST) Received: by verein.lst.de (Postfix, from userid 2407) id DA0C068AA6; Fri, 23 Dec 2022 17:42:29 +0100 (CET) Date: Fri, 23 Dec 2022 17:42:29 +0100 From: Christoph Hellwig To: Dan Carpenter Cc: Christoph Hellwig , oe-kbuild@lists.linux.dev, Sagi Grimberg , lkp@intel.com, oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: drivers/nvme/host/auth.c:950 nvme_auth_init_ctrl() warn: missing error code? 'ret' Message-ID: <20221223164229.GA31884@lst.de> References: <202212222333.vrYfUBqM-lkp@intel.com> <20221223154754.GA30339@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Dec 23, 2022 at 07:21:49PM +0300, Dan Carpenter wrote: > > - if (!ctrl->opts->dhchap_secret && !ctrl->opts->dhchap_ctrl_secret) > > + if (!ctrl->host_key && !ctrl->ctrl_key) > > return ret; > > ret is uninitialized now. Yes. Should be a 'return 0'. We really need to turn the maybe uninitialized warnings back on.