diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
index a05fc68b98fa..74bee6895dcd 100644
--- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
+++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
@@ -1188,7 +1188,7 @@ void RPiCameraData::queueFrameAction(unsigned int frame, const IPAOperationData
 		ControlList controls = action.controls[0];
 		if (!staggeredCtrl_.set(controls))
 			LOG(RPI, Error) << "V4L2 staggered set failed";
-		goto done;
+		return;
 	}
 
 	case RPI_IPA_ACTION_SET_SENSOR_CONFIG: {
@@ -1206,18 +1206,18 @@ void RPiCameraData::queueFrameAction(unsigned int frame, const IPAOperationData
 		/* Set the sensor orientation here as well. */
 		ControlList controls = action.controls[0];
 		unicam_[Unicam::Image].dev()->setControls(&controls);
-		goto done;
+		return;
 	}
 
 	case RPI_IPA_ACTION_V4L2_SET_ISP: {
 		ControlList controls = action.controls[0];
 		isp_[Isp::Input].dev()->setControls(&controls);
-		goto done;
+		return;
 	}
 	}
 
 	if (state_ == State::Stopped)
-		goto done;
+		return;
 
 	/*
 	 * The following actions must not be handled when the pipeline handler
@@ -1261,7 +1261,6 @@ void RPiCameraData::queueFrameAction(unsigned int frame, const IPAOperationData
 		break;
 	}
 
-done:
 	handleState();
 }
 
