Received: by 2002:ac0:c50a:0:0:0:0:0 with SMTP id y10csp1074104imi; Fri, 1 Jul 2022 02:29:05 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sSy7fQQsjN90bmGj/ymuWikQaGElBUss2OiN5f7U16hlKn1a3Mysa/plhEv6yvTkGOg5xT X-Received: by 2002:a17:907:2081:b0:726:b8d2:fba2 with SMTP id pv1-20020a170907208100b00726b8d2fba2mr12787921ejb.686.1656667745347; Fri, 01 Jul 2022 02:29:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656667745; cv=none; d=google.com; s=arc-20160816; b=qLFHZEjm4IDzo8pHXHArwXiBbrVv/oqWOyDBvGiT3+f6niiT1bIiLuRqrwpyGrQN0L tKMAL3VLRLAQN2NaPIElVnrSOFMdPLjHF6nRAoKMzaMIwD6lhDOfm6lu/uhYN/dkfDj7 uP36HfeaUwVwuHGqu1Z81ass76ngqTnEisLn0wMzqc1qECokr3yZBDqUwwlvJSd17OS9 0swv5p2y7uQ5ks01kuSqsln7qmy/oz0XL4gWClBXdfnyKJ7OvK5dYnMOsbjXGMunM5bm 2ux883ygl8wPssYdbcUY/uLWJSDN0IzluYa2Lupugkz/KXO95jokHexCufdc56XtSHKZ vvNw== 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=AWb6BFxwcPd09ZUNnwTDboNM6vesMs0cSvH/5Hd2i8Q=; b=TQhmAd+e8LZ1c91R4GCwuC0eQuw6q2194S1qIM+UV9NPL+tpCP4LPl0IJ5KA17tEbr dOqx1dGN+5pqvObLXiolnWmk4+ZB87g1mjqtdP1n6gyxtSqnurLNRtpBW19OfcKSzyL4 Gbfkm2VGnzh834IF/A+XuPUSCBSz+wnniy79aHvZlZ6aWgU0s1IS/MO5mPJ6OtGFGSEw RQ58q09la/lWgttD5QPd+cSdGjXobwkpz8fwngYPidL1g0YCi+DawMIG4jiZteGTyi+b KMheFBr6/LRvY9Gw9vl9bxK25LcZl54QNmxPptH4zdZzjNPOjdIx4OHzqnefg3CSjX6B rL+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=VGZAOKEo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id sc10-20020a1709078a0a00b00726b827dc70si14696490ejc.340.2022.07.01.02.28.38; Fri, 01 Jul 2022 02:29:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=VGZAOKEo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234463AbiGAI71 (ORCPT + 99 others); Fri, 1 Jul 2022 04:59:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42730 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231901AbiGAI7Z (ORCPT ); Fri, 1 Jul 2022 04:59:25 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7D935186D7 for ; Fri, 1 Jul 2022 01:59:24 -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 ams.source.kernel.org (Postfix) with ESMTPS id 1DB5EB828CF for ; Fri, 1 Jul 2022 08:59:23 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7D1CFC3411E; Fri, 1 Jul 2022 08:59:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1656665961; bh=Cp+VKrrZ5YR+oIkwv5yfto2VBhn5YWAggfrsVnGgAJo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=VGZAOKEoR1mdokjuWTdCEVkGdj5IQz8U19GroifZMlSyofONTzzsFLt7OtNgEVR/m tl7YfdD98PG+xIk2GIwPfaPej7zFEzYuP9nQwC+sVqGR0156Ozl2Nvv/JiYTnnKqiK 87rQtKgtR4vIlXGXjxFoyug0d2gu1nN2urnKgUPQ= Date: Fri, 1 Jul 2022 10:59:19 +0200 From: Greg Kroah-Hartman To: kernel test robot Cc: Shuah Khan , llvm@lists.linux.dev, kbuild-all@lists.01.org, linux-kernel@vger.kernel.org Subject: Re: [char-misc:char-misc-linus 3/3] drivers/misc/cardreader/rtsx_usb.c:639:6: warning: variable 'ret' is used uninitialized whenever 'if' condition is true Message-ID: References: <202207011658.rHJFVLWA-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <202207011658.rHJFVLWA-lkp@intel.com> X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 Fri, Jul 01, 2022 at 04:49:50PM +0800, kernel test robot wrote: > tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git char-misc-linus > head: 3776c78559853fd151be7c41e369fd076fb679d5 > commit: 3776c78559853fd151be7c41e369fd076fb679d5 [3/3] misc: rtsx_usb: use separate command and response buffers > config: arm-buildonly-randconfig-r006-20220629 (https://download.01.org/0day-ci/archive/20220701/202207011658.rHJFVLWA-lkp@intel.com/config) > compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project a9119143a2d1f4d0d0bc1fe0d819e5351b4e0deb) > reproduce (this is a W=1 build): > wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross > chmod +x ~/bin/make.cross > # install arm cross compiling tool for clang build > # apt-get install binutils-arm-linux-gnueabi > # https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git/commit/?id=3776c78559853fd151be7c41e369fd076fb679d5 > git remote add char-misc https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git > git fetch --no-tags char-misc char-misc-linus > git checkout 3776c78559853fd151be7c41e369fd076fb679d5 > # save the config file > mkdir build_dir && cp config build_dir/.config > COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash drivers/misc/cardreader/ > > If you fix the issue, kindly add following tag where applicable > Reported-by: kernel test robot > > All warnings (new ones prefixed by >>): > > >> drivers/misc/cardreader/rtsx_usb.c:639:6: warning: variable 'ret' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized] > if (!ucr->rsp_buf) > ^~~~~~~~~~~~~ > drivers/misc/cardreader/rtsx_usb.c:678:9: note: uninitialized use occurs here > return ret; > ^~~ > drivers/misc/cardreader/rtsx_usb.c:639:2: note: remove the 'if' if its condition is always false > if (!ucr->rsp_buf) > ^~~~~~~~~~~~~~~~~~ > drivers/misc/cardreader/rtsx_usb.c:622:9: note: initialize the variable 'ret' to silence this warning > int ret; > ^ > = 0 > 1 warning generated. Odd, gcc doesn't show this for me. Shuah, can you send a follow-on patch to fix this? The warning does look correct. thanks, greg k-h