From: "Alex Bennée" <alex.bennee@linaro.org>
To: "Radim Krčmář" <rkrcmar@redhat.com>
Cc: pbonzini@redhat.com, marc.zyngier@arm.com,
christoffer.dall@linaro.org, drjones@redhat.com,
kvm@vger.kernel.org
Subject: Re: [kvm-unit-tests PATCH v2 3/3] arm/debugtest: test access to the debug registers for guest
Date: Mon, 22 May 2017 19:40:10 +0100 [thread overview]
Message-ID: <87pof03fcl.fsf@linaro.org> (raw)
In-Reply-To: <20170522165605.GA27253@potion>
Radim Krčmář <rkrcmar@redhat.com> writes:
> 2017-05-18 17:02+0100, Alex Bennée:
>> Currently this is a fairly simple test that reads the debug register
>> state and attempts to write/read-back the watchpoint and breakpoint
>> registers.
>>
>> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
>> ---
>> diff --git a/arm/debugtest.c b/arm/debugtest.c
>> @@ -0,0 +1,671 @@
>> +
>> +static void read_dbgb(int n, struct dbgregs *array)
>> +{
>> + switch (n-1) {
>> + case 15:
>> + array[15].dbgbcr = read_debug_bcr(15);
>> + array[15].dbgbvr = read_debug_bvr(15);
>
> Newer GCC (I have 7.0.1) does not like a fall through without a comment:
>
> arm/debugtest.c: In function ‘read_dbgb’:
> arm/debugtest.c:144:20: error: this statement may fall through [-Werror=implicit-fallthrough=]
> array[15].dbgbvr = read_debug_bvr(15);
> arm/debugtest.c:145:2: note: here
> case 14:
> ^~~~
>
> I managed to compile with
>
> + /* fall through */
>
> everywhere.
And here was I thinking checkpatch was being overly anal. OK I shall fix
that up for the next version.
>
>> + case 14:
>> + array[14].dbgbcr = read_debug_bcr(14);
>> + array[14].dbgbvr = read_debug_bvr(14);
--
Alex Bennée
next prev parent reply other threads:[~2017-05-22 18:40 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-18 16:02 [kvm-unit-tests PATCH v2 0/3] ARM debug register test Alex Bennée
2017-05-18 16:02 ` [kvm-unit-tests PATCH v2 1/3] sysregs: add __ACCESS_CP14 macro Alex Bennée
2017-05-22 17:27 ` Andrew Jones
2017-05-18 16:02 ` [kvm-unit-tests PATCH v2 2/3] arm/run: ensure we use processor=host for kvm Alex Bennée
2017-05-18 16:03 ` Paolo Bonzini
2017-05-19 6:29 ` Christoffer Dall
2017-05-19 8:11 ` Paolo Bonzini
2017-05-22 17:25 ` Andrew Jones
2017-05-18 16:02 ` [kvm-unit-tests PATCH v2 3/3] arm/debugtest: test access to the debug registers for guest Alex Bennée
2017-05-22 16:56 ` Radim Krčmář
2017-05-22 18:40 ` Alex Bennée [this message]
2017-05-22 17:22 ` Andrew Jones
2017-05-22 18:41 ` Alex Bennée
2017-05-23 9:41 ` Andrew Jones
2017-05-23 9:50 ` Andrew Jones
2017-05-25 15:32 ` [kvm-unit-tests PATCH v2 0/3] ARM debug register test 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=87pof03fcl.fsf@linaro.org \
--to=alex.bennee@linaro.org \
--cc=christoffer.dall@linaro.org \
--cc=drjones@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=marc.zyngier@arm.com \
--cc=pbonzini@redhat.com \
--cc=rkrcmar@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
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