qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] hw/arm/pxa2xx: Add missing fallthrough comment
@ 2020-09-11 12:18 Thomas Huth
  2020-09-11 12:41 ` Philippe Mathieu-Daudé
  0 siblings, 1 reply; 4+ messages in thread
From: Thomas Huth @ 2020-09-11 12:18 UTC (permalink / raw)
  To: qemu-arm, Peter Maydell; +Cc: qemu-trivial, qemu-devel

Let's make this file compilable with -Werror=implicit-fallthrough :
Looking at the code, it seems like the fallthrough is intended here,
so we should add the corresponding "/* fallthrough */" comment here.

Signed-off-by: Thomas Huth <thuth@redhat.com>
---
 hw/arm/pxa2xx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/arm/pxa2xx.c b/hw/arm/pxa2xx.c
index 76975d17a4..c1f45b2adf 100644
--- a/hw/arm/pxa2xx.c
+++ b/hw/arm/pxa2xx.c
@@ -443,7 +443,7 @@ static void pxa2xx_mm_write(void *opaque, hwaddr addr,
             s->mm_regs[addr >> 2] = value;
             break;
         }
-
+        /* fallthrough */
     default:
         qemu_log_mask(LOG_GUEST_ERROR,
                       "%s: Bad write offset 0x%"HWADDR_PRIx"\n",
-- 
2.18.2



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] hw/arm/pxa2xx: Add missing fallthrough comment
  2020-09-11 12:18 [PATCH] hw/arm/pxa2xx: Add missing fallthrough comment Thomas Huth
@ 2020-09-11 12:41 ` Philippe Mathieu-Daudé
  2020-09-11 12:50   ` Thomas Huth
  2020-09-11 12:52   ` Laurent Vivier
  0 siblings, 2 replies; 4+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-09-11 12:41 UTC (permalink / raw)
  To: Thomas Huth, qemu-arm, Peter Maydell
  Cc: qemu-trivial, Stefan Weil, qemu-devel

On 9/11/20 2:18 PM, Thomas Huth wrote:
> Let's make this file compilable with -Werror=implicit-fallthrough :
> Looking at the code, it seems like the fallthrough is intended here,
> so we should add the corresponding "/* fallthrough */" comment here.
> 
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> ---
>  hw/arm/pxa2xx.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/hw/arm/pxa2xx.c b/hw/arm/pxa2xx.c
> index 76975d17a4..c1f45b2adf 100644
> --- a/hw/arm/pxa2xx.c
> +++ b/hw/arm/pxa2xx.c
> @@ -443,7 +443,7 @@ static void pxa2xx_mm_write(void *opaque, hwaddr addr,
>              s->mm_regs[addr >> 2] = value;
>              break;
>          }
> -
> +        /* fallthrough */
>      default:
>          qemu_log_mask(LOG_GUEST_ERROR,
>                        "%s: Bad write offset 0x%"HWADDR_PRIx"\n",
> 

I keep rebasing this one from Stefan, not sure why never upstreamed :/
https://repo.or.cz/qemu/ar7.git/blobdiff/2a9c928409..5ebb514633:/hw/arm/pxa2xx.c

Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] hw/arm/pxa2xx: Add missing fallthrough comment
  2020-09-11 12:41 ` Philippe Mathieu-Daudé
@ 2020-09-11 12:50   ` Thomas Huth
  2020-09-11 12:52   ` Laurent Vivier
  1 sibling, 0 replies; 4+ messages in thread
From: Thomas Huth @ 2020-09-11 12:50 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-arm, Peter Maydell
  Cc: qemu-trivial, Stefan Weil, qemu-devel

On 11/09/2020 14.41, Philippe Mathieu-Daudé wrote:
> On 9/11/20 2:18 PM, Thomas Huth wrote:
>> Let's make this file compilable with -Werror=implicit-fallthrough :
>> Looking at the code, it seems like the fallthrough is intended here,
>> so we should add the corresponding "/* fallthrough */" comment here.
>>
>> Signed-off-by: Thomas Huth <thuth@redhat.com>
>> ---
>>  hw/arm/pxa2xx.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/hw/arm/pxa2xx.c b/hw/arm/pxa2xx.c
>> index 76975d17a4..c1f45b2adf 100644
>> --- a/hw/arm/pxa2xx.c
>> +++ b/hw/arm/pxa2xx.c
>> @@ -443,7 +443,7 @@ static void pxa2xx_mm_write(void *opaque, hwaddr addr,
>>              s->mm_regs[addr >> 2] = value;
>>              break;
>>          }
>> -
>> +        /* fallthrough */
>>      default:
>>          qemu_log_mask(LOG_GUEST_ERROR,
>>                        "%s: Bad write offset 0x%"HWADDR_PRIx"\n",
>>
> 
> I keep rebasing this one from Stefan, not sure why never upstreamed :/
> https://repo.or.cz/qemu/ar7.git/blobdiff/2a9c928409..5ebb514633:/hw/arm/pxa2xx.c

Are there more patches like this in that tree? If so, could you maybe
send them upstream?

> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

Thanks!

 Thomas




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] hw/arm/pxa2xx: Add missing fallthrough comment
  2020-09-11 12:41 ` Philippe Mathieu-Daudé
  2020-09-11 12:50   ` Thomas Huth
@ 2020-09-11 12:52   ` Laurent Vivier
  1 sibling, 0 replies; 4+ messages in thread
From: Laurent Vivier @ 2020-09-11 12:52 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, Thomas Huth, qemu-arm, Peter Maydell
  Cc: qemu-trivial, Stefan Weil, qemu-devel

Le 11/09/2020 à 14:41, Philippe Mathieu-Daudé a écrit :
> On 9/11/20 2:18 PM, Thomas Huth wrote:
>> Let's make this file compilable with -Werror=implicit-fallthrough :
>> Looking at the code, it seems like the fallthrough is intended here,
>> so we should add the corresponding "/* fallthrough */" comment here.
>>
>> Signed-off-by: Thomas Huth <thuth@redhat.com>
>> ---
>>  hw/arm/pxa2xx.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/hw/arm/pxa2xx.c b/hw/arm/pxa2xx.c
>> index 76975d17a4..c1f45b2adf 100644
>> --- a/hw/arm/pxa2xx.c
>> +++ b/hw/arm/pxa2xx.c
>> @@ -443,7 +443,7 @@ static void pxa2xx_mm_write(void *opaque, hwaddr addr,
>>              s->mm_regs[addr >> 2] = value;
>>              break;
>>          }
>> -
>> +        /* fallthrough */
>>      default:
>>          qemu_log_mask(LOG_GUEST_ERROR,
>>                        "%s: Bad write offset 0x%"HWADDR_PRIx"\n",
>>
> 
> I keep rebasing this one from Stefan, not sure why never upstreamed :/
> https://repo.or.cz/qemu/ar7.git/blobdiff/2a9c928409..5ebb514633:/hw/arm/pxa2xx.c

Has it been sent to qemu-trivial? I don't find it in my folder.

> 
> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> 
> 

Applied to my trivial-patches branch.

Thanks,
Laurent


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-09-11 12:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-09-11 12:18 [PATCH] hw/arm/pxa2xx: Add missing fallthrough comment Thomas Huth
2020-09-11 12:41 ` Philippe Mathieu-Daudé
2020-09-11 12:50   ` Thomas Huth
2020-09-11 12:52   ` Laurent Vivier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).