Skip to contentSkip to conversation

sparc64: uprobes: add missing break

PATCH In review Rosen Penev 3 participants 3 messages May 6 – Jun 12

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sparc64: uprobes: add missing break

Missing fallthrough causes failure with newer compilers:

arch/sparc/kernel/uprobes.c:284:2: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]

  284 |         default:
      |         ^
arch/sparc/kernel/uprobes.c:284:2: note: insert 'break;' to avoid fall-through
  284 |         default:
      |         ^
      |         break;
---
 arch/sparc/kernel/uprobes.c | 1 +
 1 file changed, 1 insertion(+)
arch/sparc/kernel/uprobes.c +1 -0
index 305017bec164..c8cac64e9988 100644
@@ -280,6 +280,7 @@ int arch_uprobe_exception_notify(struct notifier_block *self,
 	case DIE_SSTEP:
 		if (uprobe_post_sstep_notifier(args->regs))
 			ret = NOTIFY_STOP;
+		break;
 
 	default:
 		break;
Signature · 1 line
2.54.0
maintainer Reviewed-by on v1 1/1
#1 lore raw
Quoted 11 lines · On Tue, 5 May 2026 20:18:15 -0700 Rosen Penev <[email protected]> wrote:

Missing fallthrough causes failure with newer compilers:

arch/sparc/kernel/uprobes.c:284:2: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]

  284 |         default:
      |         ^
arch/sparc/kernel/uprobes.c:284:2: note: insert 'break;' to avoid fall-through
  284 |         default:
      |         ^
      |         break;

Looks good to me.

Quoted 19 lines
---
 arch/sparc/kernel/uprobes.c | 1 +
 1 file changed, 1 insertion(+)
arch/sparc/kernel/uprobes.c +1 -0
index 305017bec164..c8cac64e9988 100644
@@ -280,6 +280,7 @@ int arch_uprobe_exception_notify(struct notifier_block *self,
 	case DIE_SSTEP:
 		if (uprobe_post_sstep_notifier(args->regs))
 			ret = NOTIFY_STOP;
+		break;
 
 	default:
 		break;
Signature · 1 line
2.54.0
Signature · 1 line
Masami Hiramatsu (Google) <[email protected]>
maintainer Reviewed-by on v1 1/1
#2 lore raw
In reply to Rosen Penev
Quoted 20 lines · Rosen Penev

Missing fallthrough causes failure with newer compilers:

arch/sparc/kernel/uprobes.c:284:2: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]

  284 |         default:
      |         ^
arch/sparc/kernel/uprobes.c:284:2: note: insert 'break;' to avoid fall-through
  284 |         default:
      |         ^
      |         break;
---
 arch/sparc/kernel/uprobes.c | 1 +
 1 file changed, 1 insertion(+)
arch/sparc/kernel/uprobes.c +0 -0
index 305017bec164..c8cac64e9988 100644

arch/sparc/kernel/uprobes.c int arch_uprobe_exception_notify(struct notifier_block *self, · line 286

Quoted 7 lines
arch/sparc/kernel/uprobes.c +1 -0
@@ -280,6 +280,7 @@ int arch_uprobe_exception_notify(struct notifier_block *self,
 	case DIE_SSTEP:
 		if (uprobe_post_sstep_notifier(args->regs))
 			ret = NOTIFY_STOP;
+		break;
 
 	default:
 		break;

Picking this up to my for-next.

Thanks,
Andreas