From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-yw1-f171.google.com (mail-yw1-f171.google.com [209.85.128.171]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D4F4481D for ; Fri, 3 Jun 2022 02:03:20 +0000 (UTC) Received: by mail-yw1-f171.google.com with SMTP id 00721157ae682-2ec42eae76bso69173047b3.10 for ; Thu, 02 Jun 2022 19:03:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:from:date:message-id:subject:to:cc; bh=A63naTJt6zUwlvsuridWvEjPR850QwDyhCVKh38nSkg=; b=BA+nmzQ0FWBRZdwycD89lmG45gs/rZHmmHf4aXaNUBF4rJpKNO6fZv1aKWNIqY7nZF woEVBUvPkFGR9N6ZkFJBmMUjvWwIY0hg8x7WUEzTTGWIsqnJ8F2ZnpTuPGQHqhagUX5S zsbVo78PCaODionwH7zAabX8oO06A6vqeRZ9CxV78TTuDpJxkGJ+Nqz+Jg9tH/GJEbT8 iHSSS0ytgervWGnmaghPu99QRU2hSJ+8zAm6vGpuJXAc7bJACp5pPU3eZ+Nbzfxpn6/N zTBzTiz5PRZ399D8AePUXfiR9I092HroZPKrXaU6jMI5UCqqBWaEqRD/u15iKhNeufBP WQXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=A63naTJt6zUwlvsuridWvEjPR850QwDyhCVKh38nSkg=; b=FrYESGps7txQYgQjChgbkqfo0n4JYcwh7vk1I2uxcWD0A4+vj+l6XIhCMklT/3cWde QDvs6PZ9kx7WV6+TKCSB0MfNs6RU+4z2rEFuFJEarw/bWkWl6ciuz2Uvu5YhiP3OV0GD mfHp0IFqP34b+aiJ7a+mVkat2VZycJ8R5LAeTOBrf5vvI5SS0Ly5jTPf5dG3yuFRPai7 Yg9Z4I/WjLIUUy1s+c8au7wXkXkpuPv9WQ249x7/0GN0m2UQGgtGRdtNgm/PW0/5cgw2 JFpgyKt+3p/FsRo9d5PyctbUHsex6TwE26QkvsTszWvCQRQmi0GVSc/I5HOmUzONMIfx FOtw== X-Gm-Message-State: AOAM530oJMvOL0DCT5EQkP4h7kybkfrExPCqBGxxyFUkhe11cGjIe65t u2VLvrHcocw83wwvhV9jvQBQ13pyDfAj+auv+kys7g== X-Google-Smtp-Source: ABdhPJzJwy/AoL8jAbntm39SvG2wCGLTOiet46mi3kxXZTznFyNhscdIk9C8MGeZg1TG+JxhbHlKdw0wtXgD1cQgbI4= X-Received: by 2002:a0d:d4d5:0:b0:30c:8231:b950 with SMTP id w204-20020a0dd4d5000000b0030c8231b950mr9252585ywd.189.1654221799635; Thu, 02 Jun 2022 19:03:19 -0700 (PDT) Precedence: bulk X-Mailing-List: regressions@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Naresh Kamboju Date: Fri, 3 Jun 2022 07:33:08 +0530 Message-ID: Subject: gcc-12: build errors: arch/arm64/kernel/setup.c:225:56: warning: array subscript -1 is outside array bounds of 'char[]' [-Warray-bounds] To: Linux ARM , open list , regressions@lists.linux.dev, lkft-triage@lists.linaro.org Cc: Catalin Marinas , Will Deacon , Andrew Morton , John Donnelly , Huacai Chen , Bjorn Andersson , Andy Shevchenko , David Hildenbrand , "Guilherme G. Piccoli" , Zhen Lei , Anshuman Khandual , Kefeng Wang Content-Type: text/plain; charset="UTF-8" While building Linux kernel with gcc-12 for arm64 the following warnings/errors noticed. These are specific to gcc-12 builds. Reported-by: Linux Kernel Functional Testing make --silent --keep-going --jobs=8 O=/home/tuxbuild/.cache/tuxmake/builds/2/build CROSS_COMPILE_COMPAT=arm-linux-gnueabihf- ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- 'CC=sccache aarch64-linux-gnu-gcc' 'HOSTCC=sccache gcc' In file included from arch/arm64/include/asm/thread_info.h:17, from include/linux/thread_info.h:60, from arch/arm64/include/asm/preempt.h:6, from include/linux/preempt.h:78, from include/linux/smp.h:110, from include/linux/lockdep.h:14, from include/linux/mutex.h:17, from include/linux/kernfs.h:11, from include/linux/sysfs.h:16, from include/linux/kobject.h:20, from include/linux/of.h:17, from include/linux/irqdomain.h:35, from include/linux/acpi.h:13, from arch/arm64/kernel/setup.c:9: In function 'request_standard_resources', inlined from 'setup_arch' at arch/arm64/kernel/setup.c:350:2: arch/arm64/kernel/setup.c:225:56: warning: array subscript -1 is outside array bounds of 'char[]' [-Warray-bounds] 225 | kernel_code.end = __pa_symbol(__init_begin - 1); steps to reproduce: # To install tuxmake on your system globally: # sudo pip3 install -U tuxmake tuxmake --runtime podman --target-arch arm64 --toolchain gcc-12 --kconfig tinyconfig CROSS_COMPILE_COMPAT=arm-linux-gnueabihf- Build link: https://builds.tuxbuild.com/2A2iyFqotDfgkLynaKzmpf8H7Nf/ -- Linaro LKFT https://lkft.linaro.org 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 81C6CC43334 for ; Fri, 3 Jun 2022 02:05:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:Subject:Message-ID:Date:From: MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=rAKQtYI1afywnMR+qcVLlcWDj0uEkSs9VoNTnGy5kZE=; b=phyABuoaNNEKau 0g5Fp20JWMCsOaoZYzybkTJDpjvd5vkggdqbM9nsoF+t4g7/GKGz0943jKfpZ8sI61xuKORZlUeJa OfZVoStD4Kl6HKojHuJtKKSx0q1dIuESbGv7ev90b7ytRyj2eOBH6XrIdkRMFQikGXdu/TZ71TC0x 58va5uIYji8rXQjcmEU3de1yJV/yLTFdfo8Lq2EFxT0wJVla3++19ROV4SQyISnoryKBu906e1wNq jhKz2hna1hJleRFfY0PBdRcUh0FN++S+Ka2Bjaof9YqrHowsyrA5UBg9e8ZGA+mFtRO+n83z8wRUJ UrHoRvV1a9FAfBF5aMWw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nwwet-005RCz-Q2; Fri, 03 Jun 2022 02:03:27 +0000 Received: from mail-yw1-x1129.google.com ([2607:f8b0:4864:20::1129]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nwwep-005RCY-Jv for linux-arm-kernel@lists.infradead.org; Fri, 03 Jun 2022 02:03:25 +0000 Received: by mail-yw1-x1129.google.com with SMTP id 00721157ae682-30c143c41e5so69330027b3.3 for ; Thu, 02 Jun 2022 19:03:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:from:date:message-id:subject:to:cc; bh=A63naTJt6zUwlvsuridWvEjPR850QwDyhCVKh38nSkg=; b=BA+nmzQ0FWBRZdwycD89lmG45gs/rZHmmHf4aXaNUBF4rJpKNO6fZv1aKWNIqY7nZF woEVBUvPkFGR9N6ZkFJBmMUjvWwIY0hg8x7WUEzTTGWIsqnJ8F2ZnpTuPGQHqhagUX5S zsbVo78PCaODionwH7zAabX8oO06A6vqeRZ9CxV78TTuDpJxkGJ+Nqz+Jg9tH/GJEbT8 iHSSS0ytgervWGnmaghPu99QRU2hSJ+8zAm6vGpuJXAc7bJACp5pPU3eZ+Nbzfxpn6/N zTBzTiz5PRZ399D8AePUXfiR9I092HroZPKrXaU6jMI5UCqqBWaEqRD/u15iKhNeufBP WQXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=A63naTJt6zUwlvsuridWvEjPR850QwDyhCVKh38nSkg=; b=hZ1hkxyatDhpvp+w1lMwGf8enHuhSF+vjd/WUYo+BHgMTF/dc8vDse9TFDsBW9ugC8 +Cvb9ctcys721rVg+fHQ+GiOJedvArATx5pZWfG3RIP5OyHyzAn3J6eGyNynpmBFHF9N MSA3dL+lJ0Ql7PRTss5AcPqPPe13JAlMGTWZmqB+xP048VJLmgtU/nR91mXJObo5Xj5p SnYt4ohmYx5Bv4zb2rWPPEGTJw7XY1IcMBcO3cNmSNxqPrbYkj0dkXeDg84/Qh0uVepf 2Y25uaRoXm8uJnsRL8cHDp3F1XlOpPJs5hycvismP34RSLFzQi1BNPVNfzSS9ZvcFsXS p+Hw== X-Gm-Message-State: AOAM532iYf3wiVr773bqIM9kEz2OPQtCnQEEaREl7SuOvDIWW4B4vNcw RaMl6rp/mmb8zqjoVwb1SSaxO/eS/XeB+4inoKakB0W8bCg6Fg== X-Google-Smtp-Source: ABdhPJzJwy/AoL8jAbntm39SvG2wCGLTOiet46mi3kxXZTznFyNhscdIk9C8MGeZg1TG+JxhbHlKdw0wtXgD1cQgbI4= X-Received: by 2002:a0d:d4d5:0:b0:30c:8231:b950 with SMTP id w204-20020a0dd4d5000000b0030c8231b950mr9252585ywd.189.1654221799635; Thu, 02 Jun 2022 19:03:19 -0700 (PDT) MIME-Version: 1.0 From: Naresh Kamboju Date: Fri, 3 Jun 2022 07:33:08 +0530 Message-ID: Subject: gcc-12: build errors: arch/arm64/kernel/setup.c:225:56: warning: array subscript -1 is outside array bounds of 'char[]' [-Warray-bounds] To: Linux ARM , open list , regressions@lists.linux.dev, lkft-triage@lists.linaro.org Cc: Catalin Marinas , Will Deacon , Andrew Morton , John Donnelly , Huacai Chen , Bjorn Andersson , Andy Shevchenko , David Hildenbrand , "Guilherme G. Piccoli" , Zhen Lei , Anshuman Khandual , Kefeng Wang X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220602_190324_224205_4E5A2E6D X-CRM114-Status: UNSURE ( 5.69 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org While building Linux kernel with gcc-12 for arm64 the following warnings/errors noticed. These are specific to gcc-12 builds. Reported-by: Linux Kernel Functional Testing make --silent --keep-going --jobs=8 O=/home/tuxbuild/.cache/tuxmake/builds/2/build CROSS_COMPILE_COMPAT=arm-linux-gnueabihf- ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- 'CC=sccache aarch64-linux-gnu-gcc' 'HOSTCC=sccache gcc' In file included from arch/arm64/include/asm/thread_info.h:17, from include/linux/thread_info.h:60, from arch/arm64/include/asm/preempt.h:6, from include/linux/preempt.h:78, from include/linux/smp.h:110, from include/linux/lockdep.h:14, from include/linux/mutex.h:17, from include/linux/kernfs.h:11, from include/linux/sysfs.h:16, from include/linux/kobject.h:20, from include/linux/of.h:17, from include/linux/irqdomain.h:35, from include/linux/acpi.h:13, from arch/arm64/kernel/setup.c:9: In function 'request_standard_resources', inlined from 'setup_arch' at arch/arm64/kernel/setup.c:350:2: arch/arm64/kernel/setup.c:225:56: warning: array subscript -1 is outside array bounds of 'char[]' [-Warray-bounds] 225 | kernel_code.end = __pa_symbol(__init_begin - 1); steps to reproduce: # To install tuxmake on your system globally: # sudo pip3 install -U tuxmake tuxmake --runtime podman --target-arch arm64 --toolchain gcc-12 --kconfig tinyconfig CROSS_COMPILE_COMPAT=arm-linux-gnueabihf- Build link: https://builds.tuxbuild.com/2A2iyFqotDfgkLynaKzmpf8H7Nf/ -- Linaro LKFT https://lkft.linaro.org _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel