[PATCH] target/openrisc: Remove superfluous breaks

Yi Wang posted 1 patch 3 years, 9 months ago
Test checkpatch passed
Test docker-mingw@fedora passed
Test FreeBSD passed
Test docker-quick@centos7 passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/1594600448-23328-1-git-send-email-wang.yi59@zte.com.cn
Maintainers: Stafford Horne <shorne@gmail.com>
target/openrisc/sys_helper.c | 2 --
1 file changed, 2 deletions(-)
[PATCH] target/openrisc: Remove superfluous breaks
Posted by Yi Wang 3 years, 9 months ago
From: Liao Pingfang <liao.pingfang@zte.com.cn>

Remove superfluous breaks, as there is a "return" before them.

Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn>
---
 target/openrisc/sys_helper.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/target/openrisc/sys_helper.c b/target/openrisc/sys_helper.c
index d9fe6c5..d9691d0 100644
--- a/target/openrisc/sys_helper.c
+++ b/target/openrisc/sys_helper.c
@@ -289,10 +289,8 @@ target_ulong HELPER(mfspr)(CPUOpenRISCState *env, target_ulong rd,
 
     case TO_SPR(5, 1):  /* MACLO */
         return (uint32_t)env->mac;
-        break;
     case TO_SPR(5, 2):  /* MACHI */
         return env->mac >> 32;
-        break;
 
     case TO_SPR(8, 0):  /* PMR */
         return env->pmr;
-- 
2.9.5


Re: [PATCH] target/openrisc: Remove superfluous breaks
Posted by Philippe Mathieu-Daudé 3 years, 9 months ago
Hi,

On 7/13/20 2:34 AM, Yi Wang wrote:
> From: Liao Pingfang <liao.pingfang@zte.com.cn>
> 
> Remove superfluous breaks, as there is a "return" before them.
> 
> Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn>

This patch (and various other you posted recently) misses your
S-o-b tag, see:
https://wiki.qemu.org/Contribute/SubmitAPatch#Patch_emails_must_include_a_Signed-off-by:_line

When reposting with your S-o-b please amend:
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

> ---
>  target/openrisc/sys_helper.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/target/openrisc/sys_helper.c b/target/openrisc/sys_helper.c
> index d9fe6c5..d9691d0 100644
> --- a/target/openrisc/sys_helper.c
> +++ b/target/openrisc/sys_helper.c
> @@ -289,10 +289,8 @@ target_ulong HELPER(mfspr)(CPUOpenRISCState *env, target_ulong rd,
>  
>      case TO_SPR(5, 1):  /* MACLO */
>          return (uint32_t)env->mac;
> -        break;
>      case TO_SPR(5, 2):  /* MACHI */
>          return env->mac >> 32;
> -        break;
>  
>      case TO_SPR(8, 0):  /* PMR */
>          return env->pmr;
>