Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp3752749rdg; Wed, 18 Oct 2023 05:17:58 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHWPSn/4vyS9QvuR6v33Wn0EXuRCn01EyZGXBLfbo2gNBXAa9cvGn/Wiwj0NJtmcXijp74D X-Received: by 2002:a17:902:bd07:b0:1ca:8629:829b with SMTP id p7-20020a170902bd0700b001ca8629829bmr4556689pls.50.1697631477663; Wed, 18 Oct 2023 05:17:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697631477; cv=none; d=google.com; s=arc-20160816; b=tiFitHiF9chEOMYXs6yltUXUdxnkligHBveWL1CGAOHB5Iil6/I1cIRN9ndqVJ6zu5 z1C60+mwt2FI/fcQPIdVmx+Rf+G3kGKutqOQj8TEn62viFqGccpULu305fCBQBbFxvVY Gj1gHjANJWGZKEav6TgzojnZpRX5oXIaI5Q5yKS2JCwiaai/bUYzBnXnjv1BDStlNMDr QBnoFgbPJqF8PdMZ5Ys9ChztxA9xWkqWb2GPjB+uQyOR2ZKxAeoogIK27uOdVz8bnbAL yo9j88nUaiLeM1deKvmZp5niFrlPfcQPMvreKa/TjolsQE5gHZ2e2YIz7FkX3Hd1bh7+ 24kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-disposition:mime-version:message-id :subject:cc:to:from:date:dkim-signature; bh=7UXNRMtWqBEtM7IZVFbjzmevXd04y3frGmoQzPD2VLQ=; fh=eX7l/8/glUzLMqc/d6Y+cYzAISrC1GrE8xhOxHjTS+A=; b=S5y95kT877brekJxKhgjCWi8pIUHewRo/ez66cIQ1wJPlYu5pKYV3vD18sPD7WAF9E yFSpkoqQoK1BzImcg8yZItg8iZR3x9LHxlNBBSF+RUW8L1SUyprlCNgiaf7j+aVvC4Vr ZXXMCH1Esv3uSvFTuNFTey/Sk2mhZ7dZgZwI0gi8FkL2s4RBN+/mvm8gEU3EuASV1Emk sGq9bd828odRCDU4BlvW5Qb6edawPZMSNda0T8dSCf8A65yAYspZIJnx6IYgL/sHjBUe KbGaU8NMw/cVGNpEsxQqCyP69QAWWCs9wigvnwNwHrl0t0Le3UosTc8h22W2l/IA69O2 GpBA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=Tkv++MTY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id b7-20020a170902650700b001c9b258508dsi3157790plk.248.2023.10.18.05.17.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 05:17:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=Tkv++MTY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 72A5480FC14B; Wed, 18 Oct 2023 05:17:54 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230125AbjJRMRo (ORCPT + 99 others); Wed, 18 Oct 2023 08:17:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229529AbjJRMRo (ORCPT ); Wed, 18 Oct 2023 08:17:44 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.7]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 39D1298 for ; Wed, 18 Oct 2023 05:17:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1697631462; x=1729167462; h=date:from:to:cc:subject:message-id:mime-version; bh=dHkoLIfxnYUWY2Iox3++2sra/kbJ6jFmxl4MQYmTP6k=; b=Tkv++MTYugSwgmtCJ9Gyxc023dJ2Opp0ICYml0KD5jI/JsWu1M+3ZDHa ha6Hszh2QdjGzomIEcP1rUJQLxEANmYDxQHyZgpVgUkGMmr52cCVKOJG/ INxOCxjuC/Xs2WDuujFK0oHup15lORbho5HI3B4Fj6VJghWdJfGob7rR+ 4+Hq737YFS81UgElBYx3twMlqzk32Vf92IIx+mH2n86463SzXNC1f97rZ dADdrO26KVDzeymJPFOND1nNkQeKW24V27RPtBw8Fy7DDXUZxb5momSUA hKxYmvJ+wSVQWokfZnkHIQgXsF0FQU0mOdAxJmpPnsqN4xhcbTB7mU/gJ g==; X-IronPort-AV: E=McAfee;i="6600,9927,10866"; a="7550788" X-IronPort-AV: E=Sophos;i="6.03,235,1694761200"; d="scan'208";a="7550788" Received: from fmviesa001.fm.intel.com ([10.60.135.141]) by fmvoesa101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Oct 2023 05:17:41 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.03,235,1694761200"; d="scan'208";a="4520992" Received: from lkp-server01.sh.intel.com (HELO 8917679a5d3e) ([10.239.97.150]) by fmviesa001.fm.intel.com with ESMTP; 18 Oct 2023 05:17:44 -0700 Received: from kbuild by 8917679a5d3e with local (Exim 4.96) (envelope-from ) id 1qt5UY-0000Kq-0d; Wed, 18 Oct 2023 12:17:38 +0000 Date: Wed, 18 Oct 2023 20:16:49 +0800 From: kernel test robot To: Linus Walleij Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org Subject: arch/arm/kernel/hibernate.c:29:40: warning: array subscript -1 is outside array bounds of 'const void[2147483647]' Message-ID: <202310182007.8ziiRe0j-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 18 Oct 2023 05:17:54 -0700 (PDT) tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 06dc10eae55b5ceabfef287a7e5f16ceea204aa0 commit: a9ff6961601d9aa0c42b6eb7d850371f31b1f5e6 ARM: mm: Make virt_to_pfn() a static inline date: 5 months ago config: arm-allyesconfig (https://download.01.org/0day-ci/archive/20231018/202310182007.8ziiRe0j-lkp@intel.com/config) compiler: arm-linux-gnueabi-gcc (GCC) 13.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231018/202310182007.8ziiRe0j-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot | Closes: https://lore.kernel.org/oe-kbuild-all/202310182007.8ziiRe0j-lkp@intel.com/ All warnings (new ones prefixed by >>): arch/arm/kernel/hibernate.c: In function 'pfn_is_nosave': >> arch/arm/kernel/hibernate.c:29:40: warning: array subscript -1 is outside array bounds of 'const void[2147483647]' [-Warray-bounds=] 29 | unsigned long nosave_end_pfn = virt_to_pfn(&__nosave_end - 1); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from arch/arm/include/asm/sections.h:5, from include/linux/interrupt.h:21, from include/linux/kernel_stat.h:9, from include/linux/cgroup.h:26, from include/linux/memcontrol.h:13, from include/linux/swap.h:9, from include/linux/suspend.h:5, from arch/arm/kernel/hibernate.c:18: include/asm-generic/sections.h:59:45: note: at offset -1 into object '__nosave_end' of size [0, 2147483647] 59 | extern __visible const void __nosave_begin, __nosave_end; | ^~~~~~~~~~~~ vim +29 arch/arm/kernel/hibernate.c 603fb42a66499a Sebastian Capella 2014-03-25 25 603fb42a66499a Sebastian Capella 2014-03-25 26 int pfn_is_nosave(unsigned long pfn) 603fb42a66499a Sebastian Capella 2014-03-25 27 { 603fb42a66499a Sebastian Capella 2014-03-25 28 unsigned long nosave_begin_pfn = virt_to_pfn(&__nosave_begin); 603fb42a66499a Sebastian Capella 2014-03-25 @29 unsigned long nosave_end_pfn = virt_to_pfn(&__nosave_end - 1); 603fb42a66499a Sebastian Capella 2014-03-25 30 603fb42a66499a Sebastian Capella 2014-03-25 31 return (pfn >= nosave_begin_pfn) && (pfn <= nosave_end_pfn); 603fb42a66499a Sebastian Capella 2014-03-25 32 } 603fb42a66499a Sebastian Capella 2014-03-25 33 :::::: The code at line 29 was first introduced by commit :::::: 603fb42a66499ab353466c7afa3d38beea20a8a9 ARM: 8011/1: ARM hibernation / suspend-to-disk :::::: TO: Sebastian Capella :::::: CC: Russell King -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki