From: Stephen Rothwell <sfr@canb•auug.org.au>
To: Joey Gouly <joey.gouly@arm•com>
Cc: Paolo Bonzini <pbonzini@redhat•com>,
Christoffer Dall <cdall@cs•columbia.edu>,
Marc Zyngier <maz@kernel•org>, KVM <kvm@vger•kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger•kernel.org>,
Linux Next Mailing List <linux-next@vger•kernel.org>
Subject: Re: linux-next: build failure after merge of the kvm-arm tree
Date: Thu, 22 Feb 2024 22:40:41 +1100 [thread overview]
Message-ID: <20240222224041.782761fd@canb.auug.org.au> (raw)
In-Reply-To: <20240222111129.GA946362@e124191.cambridge.arm.com>
[-- Attachment #1: Type: text/plain, Size: 3863 bytes --]
Hi Joey,
On Thu, 22 Feb 2024 11:11:29 +0000 Joey Gouly <joey.gouly@arm•com> wrote:
>
> On Thu, Feb 22, 2024 at 10:03:49PM +1100, Stephen Rothwell wrote:
> >
> > After merging the kvm tree, today's linux-next build (arm64 defconfig)
> > failed like this:
> >
> > In file included from <command-line>:
> > In function 'check_res_bits',
> > inlined from 'kvm_sys_reg_table_init' at arch/arm64/kvm/sys_regs.c:4109:2:
> > include/linux/compiler_types.h:449:45: error: call to '__compiletime_assert_591' declared with attribute error: BUILD_BUG_ON failed: ID_AA64DFR1_EL1_RES0 != (GENMASK_ULL(63, 0))
> > 449 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
> > | ^
> > include/linux/compiler_types.h:430:25: note: in definition of macro '__compiletime_assert'
> > 430 | prefix ## suffix(); \
> > | ^~~~~~
> > include/linux/compiler_types.h:449:9: note: in expansion of macro '_compiletime_assert'
> > 449 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
> > | ^~~~~~~~~~~~~~~~~~~
> > include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert'
> > 39 | #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
> > | ^~~~~~~~~~~~~~~~~~
> > include/linux/build_bug.h:50:9: note: in expansion of macro 'BUILD_BUG_ON_MSG'
> > 50 | BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
> > | ^~~~~~~~~~~~~~~~
> > arch/arm64/kvm/check-res-bits.h:58:9: note: in expansion of macro 'BUILD_BUG_ON'
> > 58 | BUILD_BUG_ON(ID_AA64DFR1_EL1_RES0 != (GENMASK_ULL(63, 0)));
> > | ^~~~~~~~~~~~
> >
> > I bisected this to the merge of the kvm-arm tree into linux-next but I
> > could not figure out why it fails :-(
> >
> > --
> > Cheers,
> > Stephen Rothwell
>
> This fails because https://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git/commit/?id=fdd867fe9b32
> added new fields to that register (ID_AA64DFR1_EL1)
>
> and commit b80b701d5a6 ("KVM: arm64: Snapshot all non-zero RES0/RES1 sysreg fields for later checking")
> took a snapshot of the fields, so the RES0 (reserved 0) bits don't match anymore.
>
> Not sure how to resolve it in the git branches though.
Thanks. I will apply this patch to the merge of the kvm-arm tree from
tomorrow (and at the end of today's tree).
From: Stephen Rothwell <sfr@canb•auug.org.au>
Date: Thu, 22 Feb 2024 22:31:22 +1100
Subject: [PATCH] fix up for "arm64/sysreg: Add register fields for ID_AA64DFR1_EL1"
interacting with "KVM: arm64: Snapshot all non-zero RES0/RES1 sysreg fields for later checking"
Signed-off-by: Stephen Rothwell <sfr@canb•auug.org.au>
---
arch/arm64/kvm/check-res-bits.h | 1 -
1 file changed, 1 deletion(-)
diff --git a/arch/arm64/kvm/check-res-bits.h b/arch/arm64/kvm/check-res-bits.h
index 967b5d171d53..39f537875d17 100644
--- a/arch/arm64/kvm/check-res-bits.h
+++ b/arch/arm64/kvm/check-res-bits.h
@@ -55,7 +55,6 @@ static inline void check_res_bits(void)
BUILD_BUG_ON(ID_AA64SMFR0_EL1_RES0 != (GENMASK_ULL(62, 61) | GENMASK_ULL(51, 49) | GENMASK_ULL(31, 31) | GENMASK_ULL(27, 0)));
BUILD_BUG_ON(ID_AA64FPFR0_EL1_RES0 != (GENMASK_ULL(63, 32) | GENMASK_ULL(27, 2)));
BUILD_BUG_ON(ID_AA64DFR0_EL1_RES0 != (GENMASK_ULL(27, 24) | GENMASK_ULL(19, 16)));
- BUILD_BUG_ON(ID_AA64DFR1_EL1_RES0 != (GENMASK_ULL(63, 0)));
BUILD_BUG_ON(ID_AA64AFR0_EL1_RES0 != (GENMASK_ULL(63, 32)));
BUILD_BUG_ON(ID_AA64AFR1_EL1_RES0 != (GENMASK_ULL(63, 0)));
BUILD_BUG_ON(ID_AA64ISAR0_EL1_RES0 != (GENMASK_ULL(3, 0)));
--
2.43.0
--
Cheers,
Stephen Rothwell
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2024-02-22 11:40 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-22 11:03 linux-next: build failure after merge of the kvm-arm tree Stephen Rothwell
2024-02-22 11:11 ` Joey Gouly
2024-02-22 11:40 ` Stephen Rothwell [this message]
2024-02-22 13:11 ` Paolo Bonzini
2024-02-22 13:11 ` Paolo Bonzini
2024-02-22 14:31 ` Marc Zyngier
2024-02-22 18:58 ` Oliver Upton
-- strict thread matches above, loose matches on Subject: below --
2025-09-23 15:28 Mark Brown
2025-09-23 16:02 ` Will Deacon
2025-09-23 16:44 ` Will Deacon
2025-09-24 2:37 ` Anshuman Khandual
2025-09-24 7:45 ` Will Deacon
2025-07-29 4:22 Stephen Rothwell
2025-07-29 18:05 ` Oliver Upton
2025-03-20 9:32 Stephen Rothwell
2025-03-20 13:35 ` Oliver Upton
2025-03-06 5:46 Stephen Rothwell
2025-03-06 9:56 ` Shameerali Kolothum Thodi
2025-03-07 0:00 ` Marc Zyngier
2025-03-07 0:51 ` Oliver Upton
2023-10-05 1:31 Stephen Rothwell
2023-10-05 1:53 ` Oliver Upton
2022-05-05 10:10 Stephen Rothwell
2022-05-05 10:11 ` Stephen Rothwell
2022-05-05 11:27 ` Marc Zyngier
2016-09-23 3:31 Stephen Rothwell
2016-09-23 8:43 ` Marc Zyngier
2014-09-22 4:06 Stephen Rothwell
2014-09-22 5:07 ` Eric Auger
2014-09-22 5:31 ` Eric Auger
[not found] ` <CAEDV+g+qVgG+=1Q7gBCPs8oAjK8rpzpoQ2cPMF0hi5Q1M3Nckw@mail.gmail.com>
2014-09-22 21:26 ` Paolo Bonzini
2014-09-24 6:50 ` Stephen Rothwell
2014-09-24 7:06 ` Christoffer Dall
2014-09-24 10:05 ` Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240222224041.782761fd@canb.auug.org.au \
--to=sfr@canb$(echo .)auug.org.au \
--cc=cdall@cs$(echo .)columbia.edu \
--cc=joey.gouly@arm$(echo .)com \
--cc=kvm@vger$(echo .)kernel.org \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=linux-next@vger$(echo .)kernel.org \
--cc=maz@kernel$(echo .)org \
--cc=pbonzini@redhat$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox