[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC PATCH v3 09/78] hw/acpi/aml-build.c: add fallthrough pseudo-key
From: |
Ani Sinha |
Subject: |
Re: [RFC PATCH v3 09/78] hw/acpi/aml-build.c: add fallthrough pseudo-keyword |
Date: |
Tue, 17 Oct 2023 14:10:34 +0530 |
> On 13-Oct-2023, at 2:15 PM, Emmanouil Pitsidianakis
> <manos.pitsidianakis@linaro.org> wrote:
>
> In preparation of raising -Wimplicit-fallthrough to 5, replace all
> fall-through comments with the fallthrough attribute pseudo-keyword.
>
> Signed-off-by: Emmanouil Pitsidianakis <manos.pitsidianakis@linaro.org>
What was wrong with QEMU_FALLTHROUGH?
https://www.mail-archive.com/qemu-devel@nongnu.org/msg996916.html does not
explain and there is no commit message that justifies the change.
Other than that,
Reviewed-by: Ani Sinha <anisinha@redhat.com>
> ---
> hw/acpi/aml-build.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
> index af66bde0f5..b0cf0c6073 100644
> --- a/hw/acpi/aml-build.c
> +++ b/hw/acpi/aml-build.c
> @@ -326,17 +326,16 @@ build_prepend_package_length(GArray *package, unsigned
> length, bool incl_self)
> byte = length >> PACKAGE_LENGTH_4BYTE_SHIFT;
> build_prepend_byte(package, byte);
> length &= (1 << PACKAGE_LENGTH_4BYTE_SHIFT) - 1;
> - /* fall through */
> + fallthrough;
> case 3:
> byte = length >> PACKAGE_LENGTH_3BYTE_SHIFT;
> build_prepend_byte(package, byte);
> length &= (1 << PACKAGE_LENGTH_3BYTE_SHIFT) - 1;
> - /* fall through */
> + fallthrough;
> case 2:
> byte = length >> PACKAGE_LENGTH_2BYTE_SHIFT;
> build_prepend_byte(package, byte);
> length &= (1 << PACKAGE_LENGTH_2BYTE_SHIFT) - 1;
> - /* fall through */
> }
> /*
> * Most significant two bits of byte zero indicate how many following
> bytes
> @@ -528,6 +527,7 @@ void aml_append(Aml *parent_ctx, Aml *child)
> */
> build_append_byte(buf, 0);
> /* fall through, to pack resources in buffer */
> + fallthrough;
> case AML_BUFFER:
> build_buffer(buf, child->op);
> break;
> --
> 2.39.2
>
- Re: [RFC PATCH v3 08/78] hw/block: add fallthrough pseudo-keyword, (continued)
- [RFC PATCH v3 02/78] block: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 05/78] qobject/json: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 06/78] tcg: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 10/78] hw/ide/atapi.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 11/78] hw/timer: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 12/78] hw/usb: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 13/78] hw/adc: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 09/78] hw/acpi/aml-build.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- Re: [RFC PATCH v3 09/78] hw/acpi/aml-build.c: add fallthrough pseudo-keyword,
Ani Sinha <=
- [RFC PATCH v3 16/78] audio: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 17/78] ui/sdl2.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 20/78] target/mips: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 19/78] target/hppa: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 14/78] util/error-report.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 18/78] ui/win32-kbd-hook.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 15/78] accel/tcg: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 21/78] target/sparc: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH v3 26/78] target/s390x: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13