Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp337313iof; Mon, 6 Jun 2022 04:34:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyPbYfMW3WIvYRHUGVs/3456e+11xLRceWJ/YkTNWWq+de8+k2r8TuAea0WklcZDm4A/q7W X-Received: by 2002:a63:6cf:0:b0:3fc:961b:deac with SMTP id 198-20020a6306cf000000b003fc961bdeacmr20257897pgg.180.1654515294105; Mon, 06 Jun 2022 04:34:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654515294; cv=none; d=google.com; s=arc-20160816; b=ocSuaRtBg+dgp8GKFPQV6WXBeXs+15g7ro6y4ORojr5A+K7A5/L6FH4OuB+pu0AqM1 /r2lJitO4O9aGi8x38JsqoSk7glUuEz56WiY4l2RbeoKmWcuCGYOyncbBysGdt5XeD4V /wd0ljG0BVBaci/b8YM9ztbsgwU//QKBKxkAPHvcVOAIapNgiKh8aIiclFPRodrGr0iB FSau7d+r3/vcO5zFLFhF0cgExGN8Onkxm5MiHfM6/0o3v8151076CGAGrGLBPHofOwYp sDrnD0zqxoNhjjuq3dtcyLBe7lDuXZ1KU10woIJfD0fK/AoBKEKvEE239QIUCHvGgJAm XkJg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=+mS0K0WXqof7nHGIO71fzBMrYpK8px4AT8fVhsZtCGA=; b=fY9V+VM7LWrSTSFlTLT5OvMZObSSHn9Bs9cr1URYtBTvzvzKbKFOAVm164I6BQifE6 zGIs+GFQZW2U3fHRp5c1ajFlyMJ7V19DNDm8YfA361ojvl5mbT64/pi77ZCyy+PDUP1s Janj5JLlbywmHwLIzUwQ+ziXMuh6IQcwdYBG5gooC2MmLNImD5MDhSH3RCXbmuAgtKCB 4TbjNpx/pGRumddbHurOyocn159V6QHdT/BReUehuLCrWHN3/YLjGrZd4JjfEoJOnk+4 +T1FGkJX6TZh4ZSIUHagKq5O6Lr97qzoh9X4i3eGhqxcB+9xVXSyqlsHhiG2ROmqcnaE HegA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Gb95uirI; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id 19-20020a170902e9d300b00156f362e9ecsi18632846plk.105.2022.06.06.04.34.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jun 2022 04:34:54 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Gb95uirI; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 064C07CDF9; Mon, 6 Jun 2022 04:22:44 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235240AbiFFLWj (ORCPT + 99 others); Mon, 6 Jun 2022 07:22:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40594 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235096AbiFFLWb (ORCPT ); Mon, 6 Jun 2022 07:22:31 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B23F165A2 for ; Mon, 6 Jun 2022 04:22:30 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 17FF960F5D for ; Mon, 6 Jun 2022 11:22:30 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 22506C385A9; Mon, 6 Jun 2022 11:22:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1654514549; bh=LQjv5O0rd1ERlthtaY7/M3iUV0w+tC6Poio1lFYxDbE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Gb95uirI059eeP8HvUSi7QlLL5mI55Ia1s/QZuoT8Gm8GzFjK3+XfEnVvv32L+Yhl 23qm6Vl+VzE1NGrnQMZbbPcng5V7OcQ5GhDNLijtaHu8RCUjaENdC/d+0lHoJgHm67 KsOfuW0bf9JzLnUImToAzxpuzP7A61Ro2Zw0JVsc= Date: Mon, 6 Jun 2022 13:22:26 +0200 From: Greg Kroah-Hartman To: Alexander Lobakin Cc: Nathan Chancellor , Arnd Bergmann , Nick Desaulniers , linux-kernel@vger.kernel.org, llvm@lists.linux.dev, patches@lists.linux.dev, Dan Carpenter , kernel test robot , Tom Rix , Ricky WU Subject: Re: [PATCH] misc: rtsx: Fix clang -Wsometimes-uninitialized in rts5261_init_from_hw() Message-ID: References: <20220523150521.2947108-1-nathan@kernel.org> <20220606105819.349320-1-alexandr.lobakin@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220606105819.349320-1-alexandr.lobakin@intel.com> X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 06, 2022 at 12:58:19PM +0200, Alexander Lobakin wrote: > From: Nathan Chancellor > Date: Mon, 23 May 2022 08:05:22 -0700 > > > Clang warns: > > > > drivers/misc/cardreader/rts5261.c:406:13: error: variable 'setting_reg2' is used uninitialized whenever 'if' condition is false [-Werror,-Wsometimes-uninitialized] > > } else if (efuse_valid == 0) { > > ^~~~~~~~~~~~~~~~ > > drivers/misc/cardreader/rts5261.c:412:30: note: uninitialized use occurs here > > pci_read_config_dword(pdev, setting_reg2, &lval2); > > ^~~~~~~~~~~~ > > > > efuse_valid == 1 is not a valid value so just return early from the > > function to avoid using setting_reg2 uninitialized. > > > > Fixes: b1c5f3085149 ("misc: rtsx: add rts5261 efuse function") > > Reported-by: Dan Carpenter > > Reported-by: kernel test robot > > Reported-by: Tom Rix > > Suggested-by: Ricky WU > > Signed-off-by: Nathan Chancellor > > Ping? Mainline 5.19-rc1 is now broken due to this. Perhaps use a different compiler? :) It's in my "to apply" queue, will get there hopefully this week, it came in during the merge window which prevented me from touching it. You know this... thanks, greg k-h