Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp143403pxa; Tue, 11 Aug 2020 20:24:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyyMeD2990Gqav39j+G8a2sUjXysoDqQ3Ijfifp8tdF52pu8fcKKenJVksrZFm/WvIGUF8W X-Received: by 2002:a17:907:104a:: with SMTP id oy10mr29484915ejb.267.1597202693748; Tue, 11 Aug 2020 20:24:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597202693; cv=none; d=google.com; s=arc-20160816; b=MKQZjjhP4xTqmRp9hl+e/C9clLFrYQvmRWgaI7GLqPvIxfW9SboXxR4XmnNMUnhQSH tKBP1VPF6k/JCJ1yxA6aRQuB5F+00R0AQsGOUV8gnDCPh2u+Otco0U1E4jMuOZH1Ch6f DgVEfJE0WqKEFf5qaavU3kGCyDB7qiBAqtCSIG41UV+Kxt7xwq4Y7B+mZvtaOffwXgUX Qrl4NJ/vbT5aR45rjPnH8GaBXOHB1wIPVgbFODkTVctgp6AAUElHha/GbYFgI55i0Lwk IfiHaVp53UP/XdnHlgmYkFuc4kgH9MMVsMS0nJANg1vdMeyoWOtv5zuRbzBFV5zfw+iU mLZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:ironport-sdr:ironport-sdr; bh=kGSnZ2F2byplOc0XsO2w5Ncv6ufrKiqb0TasUJ9nCMQ=; b=MMqD8GLVDbRDlD3qlbgmH4RqqMElk4R2XKEZ7OUxeqnx7FzlPqZYl09oTx0GFO4rHS 8g1tPOx7PxV2XBrXtIzQxSYGu/WAXKT1e0MX2cdF8m1cJnywgRftQttBg10uUq1CJ8Of YFyfc139bSX3lZ0OTQDdApOl0QbUCfZSza4939Lrcah5778ysOoe2OOzHMuUFlBwajk5 Yxpfb8BfF53jvFK/i75CmqfZTAtOqqByxuNZ1FFGtxdVlMXxlMFWSFfyb5uqTYoJdMhD lLD17YwVSln0j36NYSTmyTqOyGUVR8hCteX0k3rxmjzRCX/Cz4/agkKIv09AyX3w8SWI tr4A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id lz17si366676ejb.521.2020.08.11.20.24.07; Tue, 11 Aug 2020 20:24:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726531AbgHLDXO (ORCPT + 99 others); Tue, 11 Aug 2020 23:23:14 -0400 Received: from mga06.intel.com ([134.134.136.31]:41409 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726333AbgHLDXO (ORCPT ); Tue, 11 Aug 2020 23:23:14 -0400 IronPort-SDR: Fwh8n7fy43aWXi/Gpi9Kr3MSYVXWqllrxJmJ0AZhHnq8IMsrimDU9Mq+Jtww71brxG/l8J59UE yYJ2iglpNXZQ== X-IronPort-AV: E=McAfee;i="6000,8403,9710"; a="215396806" X-IronPort-AV: E=Sophos;i="5.76,302,1592895600"; d="scan'208";a="215396806" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Aug 2020 20:23:13 -0700 IronPort-SDR: 8Ntqf9bKTlQ/6rSRI4Sr4fNm6XilpPALipbN+NNWVx33eAuERpOf0eGomaIU37KgSSYC7RpQQA 9ICutRePGsvA== X-IronPort-AV: E=Sophos;i="5.76,302,1592895600"; d="scan'208";a="469658117" Received: from shao2-debian.sh.intel.com (HELO [10.239.13.3]) ([10.239.13.3]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Aug 2020 20:23:11 -0700 Subject: Re: [kbuild-all] Re: arch/sparc/include/asm/cmpxchg_64.h:161:55: sparse: sparse: cast truncates bits from constant value (ffffffffe0f510cc becomes cc) To: Gao Xiang , kernel test robot Cc: Gao Xiang , kbuild-all@lists.01.org, linux-kernel@vger.kernel.org, Greg Kroah-Hartman References: <202008120933.YrVhHyoA%lkp@intel.com> <20200812030956.GA17005@xiangao.remote.csb> From: Rong Chen Message-ID: Date: Wed, 12 Aug 2020 11:22:31 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <20200812030956.GA17005@xiangao.remote.csb> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 8/12/20 11:09 AM, Gao Xiang wrote: > Hi, > > On Wed, Aug 12, 2020 at 09:49:38AM +0800, kernel test robot wrote: >> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master >> head: fb893de323e2d39f7a1f6df425703a2edbdf56ea >> commit: 47e4937a4a7ca4184fd282791dfee76c6799966a erofs: move erofs out of staging >> date: 12 months ago >> config: sparc64-randconfig-s032-20200812 (attached as .config) >> compiler: sparc64-linux-gcc (GCC) 9.3.0 >> reproduce: >> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross >> chmod +x ~/bin/make.cross >> # apt-get install sparse >> # sparse version: v0.6.2-168-g9554805c-dirty >> git checkout 47e4937a4a7ca4184fd282791dfee76c6799966a >> # save the attached .config to linux build tree >> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=sparc64 >> >> If you fix the issue, kindly add following tag as appropriate >> Reported-by: kernel test robot >> >> >> sparse warnings: (new ones prefixed by >>) >> >> fs/erofs/utils.c: note: in included file (through arch/sparc/include/asm/cmpxchg.h, arch/sparc/include/asm/atomic_64.h, arch/sparc/include/asm/atomic.h, ...): >>>> arch/sparc/include/asm/cmpxchg_64.h:161:55: sparse: sparse: cast truncates bits from constant value (ffffffffe0f510cc becomes cc) >> -- >> fs/erofs/zdata.c: note: in included file (through arch/sparc/include/asm/cmpxchg.h, arch/sparc/include/asm/atomic_64.h, arch/sparc/include/asm/atomic.h, ...): >>>> arch/sparc/include/asm/cmpxchg_64.h:161:55: sparse: sparse: cast truncates bits from constant value (ffffffffe0f510cc becomes cc) >> arch/sparc/include/asm/cmpxchg_64.h:161:50: sparse: sparse: cast truncates bits from constant value (5f0ecafe becomes fe) >> arch/sparc/include/asm/cmpxchg_64.h:161:50: sparse: sparse: cast truncates bits from constant value (5f0ecafe becomes fe) >> arch/sparc/include/asm/cmpxchg_64.h:161:55: sparse: sparse: cast truncates bits from constant value (5f0edead becomes ad) >> >> vim +161 arch/sparc/include/asm/cmpxchg_64.h >> >> d550bbd40c0e10 David Howells 2012-03-28 155 >> d550bbd40c0e10 David Howells 2012-03-28 156 static inline unsigned long >> d550bbd40c0e10 David Howells 2012-03-28 157 __cmpxchg(volatile void *ptr, unsigned long old, unsigned long new, int size) >> d550bbd40c0e10 David Howells 2012-03-28 158 { >> d550bbd40c0e10 David Howells 2012-03-28 159 switch (size) { >> a12ee2349312d7 Babu Moger 2017-05-24 160 case 1: >> a12ee2349312d7 Babu Moger 2017-05-24 @161 return __cmpxchg_u8(ptr, old, new); >> d550bbd40c0e10 David Howells 2012-03-28 162 case 4: >> d550bbd40c0e10 David Howells 2012-03-28 163 return __cmpxchg_u32(ptr, old, new); >> d550bbd40c0e10 David Howells 2012-03-28 164 case 8: >> d550bbd40c0e10 David Howells 2012-03-28 165 return __cmpxchg_u64(ptr, old, new); >> d550bbd40c0e10 David Howells 2012-03-28 166 } >> d550bbd40c0e10 David Howells 2012-03-28 167 __cmpxchg_called_with_bad_pointer(); >> d550bbd40c0e10 David Howells 2012-03-28 168 return old; >> d550bbd40c0e10 David Howells 2012-03-28 169 } >> d550bbd40c0e10 David Howells 2012-03-28 170 > Again, I have no idea how to deal with that in my current > gatekeeping code. > > I got these reports, but I cannot help to resolve that. > Even I don't know if that's another sparse issue (since I > only got such reports on sparc and alpha arch, but no x86 > or arm64.) > > https://lore.kernel.org/r/202007251532.y5A10ZoO%25lkp@intel.com > https://lore.kernel.org/r/202007272132.1AgbBO3U%25lkp@intel.com > https://lore.kernel.org/r/202008100408.Wc6WGrac%25lkp@intel.com > https://lore.kernel.org/r/202008120933.YrVhHyoA%25lkp@intel.com > > If no one can help that, could you please silence such reports. > It really makes me confusing. Hi Gao Xiang, Sorry for the inconvenience, we'll silence the reports on this commit. Best Regards, Rong Chen > > Thanks, > Gao Xiang > >> :::::: The code at line 161 was first introduced by commit >> :::::: a12ee2349312d7112b9b7c6ac2e70c5ec2ca334e arch/sparc: Introduce cmpxchg_u8 SPARC >> >> :::::: TO: Babu Moger >> :::::: CC: David S. Miller >> >> --- >> 0-DAY CI Kernel Test Service, Intel Corporation >> https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org > _______________________________________________ > kbuild-all mailing list -- kbuild-all@lists.01.org > To unsubscribe send an email to kbuild-all-leave@lists.01.org