diff mbox series

[XEN,4/7] xen/sched: address MISRA C:2012 Rule 2.1

Message ID 4006f1eb1977a89a57c5c02f003a2fefc06dfc42.1702283415.git.nicola.vetrini@bugseng.com (mailing list archive)
State Superseded
Headers show
Series address violations of MISRA C:2012 Rule 2.1 | expand

Commit Message

Nicola Vetrini Dec. 11, 2023, 10:30 a.m. UTC
The break statement after the return statement is definitely unreachable
and can be removed with no functional change.

Signed-off-by: Nicola Vetrini <nicola.vetrini@bugseng.com>
---
 xen/common/sched/core.c | 1 -
 1 file changed, 1 deletion(-)

Comments

George Dunlap Dec. 11, 2023, 1:30 p.m. UTC | #1
On Mon, Dec 11, 2023 at 10:30 AM Nicola Vetrini
<nicola.vetrini@bugseng.com> wrote:
>
> The break statement after the return statement is definitely unreachable
> and can be removed with no functional change.
>
> Signed-off-by: Nicola Vetrini <nicola.vetrini@bugseng.com>

Acked-by: George Dunlap <george.dunlap@cloud.com>
Stefano Stabellini Dec. 12, 2023, 1:43 a.m. UTC | #2
On Mon, 11 Dec 2023, Nicola Vetrini wrote:
> The break statement after the return statement is definitely unreachable
> and can be removed with no functional change.
> 
> Signed-off-by: Nicola Vetrini <nicola.vetrini@bugseng.com>

Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
diff mbox series

Patch

diff --git a/xen/common/sched/core.c b/xen/common/sched/core.c
index f6ac1e5af8bd..d177c675c81b 100644
--- a/xen/common/sched/core.c
+++ b/xen/common/sched/core.c
@@ -2239,7 +2239,6 @@  static bool sched_tasklet_check_cpu(unsigned int cpu)
         /* fallthrough */
     case TASKLET_enqueued|TASKLET_scheduled:
         return true;
-        break;
     case TASKLET_scheduled:
         clear_bit(_TASKLET_scheduled, tasklet_work);
         /* fallthrough */