Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1a66dc3a authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: camera: lrme: Change list iterator api during requests deletion"

parents 2c112fe0 e9d2104c
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -727,6 +727,7 @@ static int cam_lrme_mgr_hw_flush(void *hw_mgr_priv, void *hw_flush_args)
	struct cam_hw_flush_args *args;
	struct cam_lrme_device *hw_device;
	struct cam_lrme_frame_request *frame_req = NULL, *req_to_flush = NULL;
	struct cam_lrme_frame_request *frame_req_temp = NULL;
	struct cam_lrme_frame_request **req_list = NULL;
	uint32_t device_index;
	struct cam_lrme_hw_flush_args lrme_flush_args;
@@ -752,15 +753,15 @@ static int cam_lrme_mgr_hw_flush(void *hw_mgr_priv, void *hw_flush_args)
	}

	spin_lock(&hw_device->high_req_lock);
	list_for_each_entry(frame_req, &hw_device->frame_pending_list_high,
		frame_list) {
	list_for_each_entry_safe(frame_req, frame_req_temp,
		&hw_device->frame_pending_list_high, frame_list) {
		list_del_init(&frame_req->frame_list);
	}
	spin_unlock(&hw_device->high_req_lock);

	spin_lock(&hw_device->normal_req_lock);
	list_for_each_entry(frame_req, &hw_device->frame_pending_list_normal,
		frame_list) {
	list_for_each_entry_safe(frame_req, frame_req_temp,
		&hw_device->frame_pending_list_normal, frame_list) {
		list_del_init(&frame_req->frame_list);
	}
	spin_unlock(&hw_device->normal_req_lock);